diff --git a/worker-configuration.d.ts b/worker-configuration.d.ts index 28e1dfd..41dfb7a 100644 --- a/worker-configuration.d.ts +++ b/worker-configuration.d.ts @@ -1,6 +1,6 @@ /* eslint-disable */ -// Generated by Wrangler by running `wrangler types --env-interface=CloudflareBindings` (hash: 638f9f42c5e2278cdee1cf6fac59f4de) -// Runtime types generated with workerd@1.20261001.1 2026-10-01 +// Generated by Wrangler by running `wrangler types --env-interface=CloudflareBindings` (hash: e27e965b107adae819c46ccc0379af8f) +// Runtime types generated with workerd@1.20261006.1 2026-10-01 interface __BaseEnv_CloudflareBindings { AUTH_KV: KVNamespace; CACHE_KV: KVNamespace; @@ -35,7 +35,30 @@ type StringifyValues> = { declare namespace NodeJS { interface ProcessEnv extends StringifyValues> {} } - +declare module "*.txt" { + const value: string; + export default value; +} +declare module "*.html" { + const value: string; + export default value; +} +declare module "*.sql" { + const value: string; + export default value; +} +declare module "*.bin" { + const value: ArrayBuffer; + export default value; +} +declare module "*.wasm" { + const value: WebAssembly.Module; + export default value; +} +declare module "*.wasm?module" { + const value: WebAssembly.Module; + export default value; +} // Begin runtime types /*! ***************************************************************************** Copyright (c) Cloudflare. All rights reserved. @@ -518,6 +541,7 @@ interface CachePurgeOptions { } interface CacheContext { purge(options: CachePurgeOptions): Promise; + invalidate(options: CachePurgeOptions): Promise; } interface CloudflareAccessContext { readonly aud: string; @@ -15932,10 +15956,16 @@ declare abstract class Workflow { */ public create(options?: WorkflowInstanceCreateOptions): Promise; /** - * Create a batch of instances and return handle for all of them. If a provided id exists, an error will be thrown. + * Create a batch of instances and return handles for the created instances and any per-instance errors. * `createBatch` is limited at 100 instances at a time or when the RPC limit for the batch (1MiB) is reached. - * @param batch List of Options when creating an instance including name and params - * @returns A promise that resolves with a list of handles for the created instances. + * @param options Options for creating instances by count or from a list of instance options + * @returns A promise that resolves with the created instance handles and any per-instance errors. + */ + public createBatch(options: WorkflowBatchCreateOptions): Promise; + /** + * Create a batch of instances and return handles for the ones that were created. + * Instances that could not be created, for example because their ID already exists, are omitted from the result without an error. + * @deprecated Use the object form of `createBatch` instead of the array form. */ public createBatch(batch: WorkflowInstanceCreateOptions[]): Promise; /** @@ -15947,6 +15977,31 @@ declare abstract class Workflow { */ public deleteBatch(instanceIds: string[]): Promise; } +type WorkflowBatchCreateOptions = { + count: number; + params?: PARAMS; + retention?: { + successRetention?: WorkflowRetentionDuration; + errorRetention?: WorkflowRetentionDuration; + }; + locationHint?: WorkflowInstanceLocationHint; + instances?: never; +} | { + instances: WorkflowInstanceCreateOptions[]; + count?: never; + params?: never; + retention?: never; + locationHint?: never; +}; +type WorkflowBatchCreateResult = { + created: WorkflowInstance[]; + errors: { + index: number; + id?: string; + code: number; + message: string; + }[]; +}; type WorkflowBatchDeleteResult = { deleted: { id: string;