@cloudflare/config 0.7.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { $ as R2Binding, A as triggers, B as D1Binding, C as exports, D as QueueConsumerTrigger, E as FetchTrigger, F as AnalyticsEngineDatasetBinding, G as ImagesBinding, H as DurableObjectBinding, I as ArtifactsBinding, J as LogfwdrBinding, K as JsonBinding, L as AssetsBinding, M as AiBinding, N as AiSearchBinding, O as ScheduledTrigger, P as AiSearchNamespaceBinding, Q as QueueBinding, R as Bindings, S as WorkerEntrypointExportOptions, St as bindings, T as EmailTrigger, U as FlagshipBinding, V as DispatchNamespaceBinding, W as HyperdriveBinding, X as MtlsCertificateBinding, Y as MediaBinding, Z as PipelineBinding, _ as DurableObjectExpectingTransferExport, _t as VpcServiceBinding, a as InferMainModule, at as TextBinding, b as Exports, bt as WorkerLoaderBinding, c as WorkerConfigExport, ct as TypedKvBinding, d as SettingsConfig, dt as TypedWorkerBinding, et as RateLimitBinding, f as WorkerConfig, ft as TypedWorkflowBinding, g as DurableObjectDeletedExport, gt as VpcNetworkBinding, h as DurableObjectCreatedExport, ht as VersionMetadataBinding, i as InferEnv, it as StreamBinding, j as AgentMemoryBinding, k as Triggers, l as WorkerConfigInput, lt as TypedPipelineBinding, m as resolveExportDefinition, mt as VectorizeBinding, n as defineSettings, nt as SecretsStoreSecretBinding, o as UnwrapConfig, ot as TypedAiBinding, p as ConfigContext, pt as UnsafeBinding, q as KvBinding, r as InferDurableNamespaces, rt as SendEmailBinding, s as TypedWorkerDefinition, st as TypedDurableObjectBinding, t as SettingsConfigInput, tt as SecretBinding, u as defineWorker, ut as TypedQueueBinding, v as DurableObjectRenamedExport, vt as WebSearchBinding, w as ConnectTrigger, x as WorkerEntrypointExport, xt as WorkflowBinding, y as DurableObjectTransferredExport, yt as WorkerBinding, z as BrowserBinding } from "./public-CCrtkZee.mjs";
1
+ import { $ as PipelineBinding, A as Triggers, B as Bindings, C as WorkerEntrypointExportOptions, Ct as WorkflowBinding, D as FetchTrigger, E as EmailTrigger, F as AiSearchNamespaceBinding, G as FlagshipBinding, H as D1Binding, I as AnalyticsEngineDatasetBinding, J as JsonBinding, K as HyperdriveBinding, L as ArtifactsBinding, M as AgentMemoryBinding, N as AiBinding, O as QueueConsumerTrigger, P as AiSearchBinding, Q as MtlsCertificateBinding, R as AssetsBinding, S as WorkerEntrypointExport, St as WorkerLoaderBinding, T as ConnectTrigger, U as DispatchNamespaceBinding, V as BrowserBinding, W as DurableObjectBinding, X as LogfwdrBinding, Y as KvBinding, Z as MediaBinding, _ as DurableObjectDeletedExport, _t as VersionMetadataBinding, a as InferEnv, at as SendEmailBinding, b as DurableObjectTransferredExport, bt as WebSearchBinding, c as TypedWorkerDefinition, ct as TypedAiBinding, d as defineWorker, dt as TypedPipelineBinding, et as QueueBinding, f as SettingsConfig, ft as TypedQueueBinding, g as DurableObjectCreatedExport, gt as VectorizeBinding, h as resolveExportDefinition, ht as UnsafeBinding, i as InferDurableNamespaces, it as SecretsStoreSecretBinding, j as triggers, k as ScheduledTrigger, l as WorkerConfigExport, lt as TypedDurableObjectBinding, m as ConfigContext, mt as TypedWorkflowBinding, n as SettingsDefinition, nt as RateLimitBinding, o as InferMainModule, ot as StreamBinding, p as WorkerConfig, pt as TypedWorkerBinding, q as ImagesBinding, r as defineSettings, rt as SecretBinding, s as UnwrapConfig, st as TextBinding, t as SettingsConfigInput, tt as R2Binding, u as WorkerConfigInput, ut as TypedKvBinding, v as DurableObjectExpectingTransferExport, vt as VpcNetworkBinding, w as exports, wt as bindings, x as Exports, xt as WorkerBinding, y as DurableObjectRenamedExport, yt as VpcServiceBinding, z as BindingDevOptions } from "./public-C3uXDKsB.mjs";
2
2
  import * as z from "zod";
3
3
  import { RawConfig } from "@cloudflare/workers-utils";
4
4
 
@@ -19,38 +19,48 @@ declare const AssetsSchema: z.ZodObject<{
19
19
  }, z.core.$strict>;
20
20
  declare const BrowserBindingSchema: z.ZodObject<{
21
21
  type: z.ZodLiteral<"browser">;
22
- remote: z.ZodOptional<z.ZodBoolean>;
22
+ dev: z.ZodOptional<z.ZodObject<{
23
+ remote: z.ZodOptional<z.ZodBoolean>;
24
+ }, z.core.$strict>>;
23
25
  }, z.core.$strict>;
24
26
  declare const WorkerBindingSchema: z.ZodObject<{
25
27
  type: z.ZodLiteral<"worker">;
26
28
  workerName: z.ZodString;
27
29
  exportName: z.ZodOptional<z.ZodString>;
28
30
  props: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
29
- remote: z.ZodOptional<z.ZodBoolean>;
31
+ dev: z.ZodOptional<z.ZodObject<{
32
+ remote: z.ZodOptional<z.ZodBoolean>;
33
+ }, z.core.$strict>>;
30
34
  }, z.core.$strict>;
31
35
  declare const D1BindingSchema: z.ZodObject<{
32
36
  type: z.ZodLiteral<"d1">;
33
37
  name: z.ZodOptional<z.ZodString>;
34
38
  id: z.ZodOptional<z.ZodString>;
35
- remote: z.ZodOptional<z.ZodBoolean>;
39
+ dev: z.ZodOptional<z.ZodObject<{
40
+ remote: z.ZodOptional<z.ZodBoolean>;
41
+ }, z.core.$strict>>;
36
42
  }, z.core.$strict>;
37
43
  declare const KVBindingSchema: z.ZodObject<{
38
44
  type: z.ZodLiteral<"kv">;
39
45
  id: z.ZodOptional<z.ZodString>;
40
- remote: z.ZodOptional<z.ZodBoolean>;
46
+ dev: z.ZodOptional<z.ZodObject<{
47
+ remote: z.ZodOptional<z.ZodBoolean>;
48
+ }, z.core.$strict>>;
41
49
  }, z.core.$strict>;
42
50
  declare const QueueBindingSchema: z.ZodObject<{
43
51
  type: z.ZodLiteral<"queue">;
44
52
  name: z.ZodOptional<z.ZodString>;
45
53
  deliveryDelay: z.ZodOptional<z.ZodNumber>;
46
- remote: z.ZodOptional<z.ZodBoolean>;
54
+ dev: z.ZodOptional<z.ZodObject<{
55
+ remote: z.ZodOptional<z.ZodBoolean>;
56
+ }, z.core.$strict>>;
47
57
  }, z.core.$strict>;
48
58
  declare const R2BindingSchema: z.ZodObject<{
49
59
  type: z.ZodLiteral<"r2">;
50
60
  name: z.ZodOptional<z.ZodString>;
51
61
  jurisdiction: z.ZodOptional<z.ZodString>;
52
- remote: z.ZodOptional<z.ZodBoolean>;
53
- localDev: z.ZodOptional<z.ZodObject<{
62
+ dev: z.ZodOptional<z.ZodObject<{
63
+ remote: z.ZodOptional<z.ZodBoolean>;
54
64
  experimentalS3Credentials: z.ZodOptional<z.ZodObject<{
55
65
  accessKeyId: z.ZodString;
56
66
  secretAccessKey: z.ZodString;
@@ -64,45 +74,63 @@ declare const AnalyticsEngineDatasetBindingSchema: z.ZodObject<{
64
74
  declare const FlagshipBindingSchema: z.ZodObject<{
65
75
  type: z.ZodLiteral<"flagship">;
66
76
  id: z.ZodOptional<z.ZodString>;
67
- remote: z.ZodOptional<z.ZodBoolean>;
77
+ dev: z.ZodOptional<z.ZodObject<{
78
+ remote: z.ZodOptional<z.ZodBoolean>;
79
+ }, z.core.$strict>>;
68
80
  }, z.core.$strict>;
69
81
  declare const HyperdriveBindingSchema: z.ZodObject<{
70
82
  type: z.ZodLiteral<"hyperdrive">;
71
83
  id: z.ZodString;
72
- localConnectionString: z.ZodOptional<z.ZodString>;
84
+ dev: z.ZodOptional<z.ZodObject<{
85
+ connectionString: z.ZodOptional<z.ZodString>;
86
+ }, z.core.$strict>>;
73
87
  }, z.core.$strict>;
74
88
  declare const KnownBindingSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
75
89
  type: z.ZodLiteral<"agent-memory">;
76
90
  namespace: z.ZodString;
77
- remote: z.ZodOptional<z.ZodBoolean>;
91
+ dev: z.ZodOptional<z.ZodObject<{
92
+ remote: z.ZodOptional<z.ZodBoolean>;
93
+ }, z.core.$strict>>;
78
94
  }, z.core.$strict>, z.ZodObject<{
79
95
  type: z.ZodLiteral<"ai">;
80
- remote: z.ZodOptional<z.ZodBoolean>;
96
+ dev: z.ZodOptional<z.ZodObject<{
97
+ remote: z.ZodOptional<z.ZodBoolean>;
98
+ }, z.core.$strict>>;
81
99
  }, z.core.$strict>, z.ZodObject<{
82
100
  type: z.ZodLiteral<"ai-search">;
83
101
  name: z.ZodString;
84
- remote: z.ZodOptional<z.ZodBoolean>;
102
+ dev: z.ZodOptional<z.ZodObject<{
103
+ remote: z.ZodOptional<z.ZodBoolean>;
104
+ }, z.core.$strict>>;
85
105
  }, z.core.$strict>, z.ZodObject<{
86
106
  type: z.ZodLiteral<"ai-search-namespace">;
87
107
  namespace: z.ZodString;
88
- remote: z.ZodOptional<z.ZodBoolean>;
108
+ dev: z.ZodOptional<z.ZodObject<{
109
+ remote: z.ZodOptional<z.ZodBoolean>;
110
+ }, z.core.$strict>>;
89
111
  }, z.core.$strict>, z.ZodObject<{
90
112
  type: z.ZodLiteral<"analytics-engine-dataset">;
91
113
  name: z.ZodOptional<z.ZodString>;
92
114
  }, z.core.$strict>, z.ZodObject<{
93
115
  type: z.ZodLiteral<"artifacts">;
94
116
  namespace: z.ZodString;
95
- remote: z.ZodOptional<z.ZodBoolean>;
117
+ dev: z.ZodOptional<z.ZodObject<{
118
+ remote: z.ZodOptional<z.ZodBoolean>;
119
+ }, z.core.$strict>>;
96
120
  }, z.core.$strict>, z.ZodObject<{
97
121
  type: z.ZodLiteral<"assets">;
98
122
  }, z.core.$strict>, z.ZodObject<{
99
123
  type: z.ZodLiteral<"browser">;
100
- remote: z.ZodOptional<z.ZodBoolean>;
124
+ dev: z.ZodOptional<z.ZodObject<{
125
+ remote: z.ZodOptional<z.ZodBoolean>;
126
+ }, z.core.$strict>>;
101
127
  }, z.core.$strict>, z.ZodObject<{
102
128
  type: z.ZodLiteral<"d1">;
103
129
  name: z.ZodOptional<z.ZodString>;
104
130
  id: z.ZodOptional<z.ZodString>;
105
- remote: z.ZodOptional<z.ZodBoolean>;
131
+ dev: z.ZodOptional<z.ZodObject<{
132
+ remote: z.ZodOptional<z.ZodBoolean>;
133
+ }, z.core.$strict>>;
106
134
  }, z.core.$strict>, z.ZodObject<{
107
135
  type: z.ZodLiteral<"dispatch-namespace">;
108
136
  namespace: z.ZodOptional<z.ZodString>;
@@ -110,7 +138,9 @@ declare const KnownBindingSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
110
138
  workerName: z.ZodString;
111
139
  parameters: z.ZodOptional<z.ZodArray<z.ZodString>>;
112
140
  }, z.core.$strict>>;
113
- remote: z.ZodOptional<z.ZodBoolean>;
141
+ dev: z.ZodOptional<z.ZodObject<{
142
+ remote: z.ZodOptional<z.ZodBoolean>;
143
+ }, z.core.$strict>>;
114
144
  }, z.core.$strict>, z.ZodObject<{
115
145
  type: z.ZodLiteral<"durable-object">;
116
146
  workerName: z.ZodString;
@@ -118,40 +148,56 @@ declare const KnownBindingSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
118
148
  }, z.core.$strict>, z.ZodObject<{
119
149
  type: z.ZodLiteral<"flagship">;
120
150
  id: z.ZodOptional<z.ZodString>;
121
- remote: z.ZodOptional<z.ZodBoolean>;
151
+ dev: z.ZodOptional<z.ZodObject<{
152
+ remote: z.ZodOptional<z.ZodBoolean>;
153
+ }, z.core.$strict>>;
122
154
  }, z.core.$strict>, z.ZodObject<{
123
155
  type: z.ZodLiteral<"hyperdrive">;
124
156
  id: z.ZodString;
125
- localConnectionString: z.ZodOptional<z.ZodString>;
157
+ dev: z.ZodOptional<z.ZodObject<{
158
+ connectionString: z.ZodOptional<z.ZodString>;
159
+ }, z.core.$strict>>;
126
160
  }, z.core.$strict>, z.ZodObject<{
127
161
  type: z.ZodLiteral<"images">;
128
- remote: z.ZodOptional<z.ZodBoolean>;
162
+ dev: z.ZodOptional<z.ZodObject<{
163
+ remote: z.ZodOptional<z.ZodBoolean>;
164
+ }, z.core.$strict>>;
129
165
  }, z.core.$strict>, z.ZodObject<{
130
166
  type: z.ZodLiteral<"json">;
131
167
  value: z.ZodJSONSchema;
132
168
  }, z.core.$strict>, z.ZodObject<{
133
169
  type: z.ZodLiteral<"kv">;
134
170
  id: z.ZodOptional<z.ZodString>;
135
- remote: z.ZodOptional<z.ZodBoolean>;
171
+ dev: z.ZodOptional<z.ZodObject<{
172
+ remote: z.ZodOptional<z.ZodBoolean>;
173
+ }, z.core.$strict>>;
136
174
  }, z.core.$strict>, z.ZodObject<{
137
175
  type: z.ZodLiteral<"logfwdr">;
138
176
  destination: z.ZodString;
139
177
  }, z.core.$strict>, z.ZodObject<{
140
178
  type: z.ZodLiteral<"media">;
141
- remote: z.ZodOptional<z.ZodBoolean>;
179
+ dev: z.ZodOptional<z.ZodObject<{
180
+ remote: z.ZodOptional<z.ZodBoolean>;
181
+ }, z.core.$strict>>;
142
182
  }, z.core.$strict>, z.ZodObject<{
143
183
  type: z.ZodLiteral<"mtls-certificate">;
144
184
  id: z.ZodString;
145
- remote: z.ZodOptional<z.ZodBoolean>;
185
+ dev: z.ZodOptional<z.ZodObject<{
186
+ remote: z.ZodOptional<z.ZodBoolean>;
187
+ }, z.core.$strict>>;
146
188
  }, z.core.$strict>, z.ZodObject<{
147
189
  type: z.ZodLiteral<"pipeline">;
148
190
  name: z.ZodString;
149
- remote: z.ZodOptional<z.ZodBoolean>;
191
+ dev: z.ZodOptional<z.ZodObject<{
192
+ remote: z.ZodOptional<z.ZodBoolean>;
193
+ }, z.core.$strict>>;
150
194
  }, z.core.$strict>, z.ZodObject<{
151
195
  type: z.ZodLiteral<"queue">;
152
196
  name: z.ZodOptional<z.ZodString>;
153
197
  deliveryDelay: z.ZodOptional<z.ZodNumber>;
154
- remote: z.ZodOptional<z.ZodBoolean>;
198
+ dev: z.ZodOptional<z.ZodObject<{
199
+ remote: z.ZodOptional<z.ZodBoolean>;
200
+ }, z.core.$strict>>;
155
201
  }, z.core.$strict>, z.ZodObject<{
156
202
  type: z.ZodLiteral<"rate-limit">;
157
203
  namespace: z.ZodString;
@@ -163,8 +209,8 @@ declare const KnownBindingSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
163
209
  type: z.ZodLiteral<"r2">;
164
210
  name: z.ZodOptional<z.ZodString>;
165
211
  jurisdiction: z.ZodOptional<z.ZodString>;
166
- remote: z.ZodOptional<z.ZodBoolean>;
167
- localDev: z.ZodOptional<z.ZodObject<{
212
+ dev: z.ZodOptional<z.ZodObject<{
213
+ remote: z.ZodOptional<z.ZodBoolean>;
168
214
  experimentalS3Credentials: z.ZodOptional<z.ZodObject<{
169
215
  accessKeyId: z.ZodString;
170
216
  secretAccessKey: z.ZodString;
@@ -181,37 +227,81 @@ declare const KnownBindingSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
181
227
  destinationAddress: z.ZodOptional<z.ZodString>;
182
228
  allowedDestinationAddresses: z.ZodOptional<z.ZodArray<z.ZodString>>;
183
229
  allowedSenderAddresses: z.ZodOptional<z.ZodArray<z.ZodString>>;
184
- remote: z.ZodOptional<z.ZodBoolean>;
185
- }, z.core.$strict>, z.ZodObject<{
230
+ dev: z.ZodOptional<z.ZodObject<{
231
+ remote: z.ZodOptional<z.ZodBoolean>;
232
+ }, z.core.$strict>>;
233
+ }, z.core.$strict> & z.ZodType<SendEmailBinding, {
234
+ type: "send-email";
235
+ destinationAddress?: string | undefined;
236
+ allowedDestinationAddresses?: string[] | undefined;
237
+ allowedSenderAddresses?: string[] | undefined;
238
+ dev?: {
239
+ remote?: boolean | undefined;
240
+ } | undefined;
241
+ }, z.core.$ZodTypeInternals<SendEmailBinding, {
242
+ type: "send-email";
243
+ destinationAddress?: string | undefined;
244
+ allowedDestinationAddresses?: string[] | undefined;
245
+ allowedSenderAddresses?: string[] | undefined;
246
+ dev?: {
247
+ remote?: boolean | undefined;
248
+ } | undefined;
249
+ }>>, z.ZodObject<{
186
250
  type: z.ZodLiteral<"stream">;
187
- remote: z.ZodOptional<z.ZodBoolean>;
251
+ dev: z.ZodOptional<z.ZodObject<{
252
+ remote: z.ZodOptional<z.ZodBoolean>;
253
+ }, z.core.$strict>>;
188
254
  }, z.core.$strict>, z.ZodObject<{
189
255
  type: z.ZodLiteral<"text">;
190
256
  value: z.ZodString;
191
257
  }, z.core.$strict>, z.ZodObject<{
192
258
  type: z.ZodLiteral<"vectorize">;
193
259
  name: z.ZodString;
194
- remote: z.ZodOptional<z.ZodBoolean>;
260
+ dev: z.ZodOptional<z.ZodObject<{
261
+ remote: z.ZodOptional<z.ZodBoolean>;
262
+ }, z.core.$strict>>;
195
263
  }, z.core.$strict>, z.ZodObject<{
196
264
  type: z.ZodLiteral<"version-metadata">;
197
265
  }, z.core.$strict>, z.ZodObject<{
198
266
  type: z.ZodLiteral<"vpc-service">;
199
267
  id: z.ZodString;
200
- remote: z.ZodOptional<z.ZodBoolean>;
268
+ dev: z.ZodOptional<z.ZodObject<{
269
+ remote: z.ZodOptional<z.ZodBoolean>;
270
+ }, z.core.$strict>>;
201
271
  }, z.core.$strict>, z.ZodObject<{
202
272
  type: z.ZodLiteral<"vpc-network">;
203
273
  tunnelId: z.ZodOptional<z.ZodString>;
204
274
  networkId: z.ZodOptional<z.ZodString>;
205
- remote: z.ZodOptional<z.ZodBoolean>;
206
- }, z.core.$strict>, z.ZodObject<{
275
+ dev: z.ZodOptional<z.ZodObject<{
276
+ remote: z.ZodOptional<z.ZodBoolean>;
277
+ }, z.core.$strict>>;
278
+ }, z.core.$strict> & z.ZodType<VpcNetworkBinding, {
279
+ type: "vpc-network";
280
+ tunnelId?: string | undefined;
281
+ networkId?: string | undefined;
282
+ dev?: {
283
+ remote?: boolean | undefined;
284
+ } | undefined;
285
+ }, z.core.$ZodTypeInternals<VpcNetworkBinding, {
286
+ type: "vpc-network";
287
+ tunnelId?: string | undefined;
288
+ networkId?: string | undefined;
289
+ dev?: {
290
+ remote?: boolean | undefined;
291
+ } | undefined;
292
+ }>>, z.ZodObject<{
207
293
  type: z.ZodLiteral<"web-search">;
208
- remote: z.ZodOptional<z.ZodBoolean>;
294
+ dev: z.ZodOptional<z.ZodObject<{
295
+ remote: z.ZodOptional<z.ZodBoolean>;
296
+ }, z.core.$strict>>;
209
297
  }, z.core.$strict>, z.ZodObject<{
210
298
  type: z.ZodLiteral<"worker">;
211
299
  workerName: z.ZodString;
212
300
  exportName: z.ZodOptional<z.ZodString>;
213
301
  props: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
214
- remote: z.ZodOptional<z.ZodBoolean>;
302
+ dev: z.ZodOptional<z.ZodObject<{
303
+ remote: z.ZodOptional<z.ZodBoolean>;
304
+ }, z.core.$strict>>;
215
305
  }, z.core.$strict>, z.ZodObject<{
216
306
  type: z.ZodLiteral<"worker-loader">;
217
307
  }, z.core.$strict>], "type">;
@@ -471,18 +561,32 @@ declare const InputWorkerSchema: z.ZodObject<{
471
561
  }, z.core.$strict>;
472
562
  type ParsedInputWorkerConfig = z.output<typeof InputWorkerSchema>;
473
563
  /**
474
- * Settings schema — validates the named `settings` export of a
564
+ * Input settings schema — validates the named `settings` export of a
475
565
  * `cloudflare.config.ts`. Holds account/deployment settings shared by the other exports.
476
566
  */
477
- declare const SettingsSchema: z.ZodObject<{
567
+ declare const InputSettingsSchema: z.ZodObject<{
568
+ type: z.ZodLiteral<"settings">;
569
+ accountId: z.ZodOptional<z.ZodString>;
570
+ complianceRegion: z.ZodOptional<z.ZodEnum<{
571
+ public: "public";
572
+ "fedramp-high": "fedramp-high";
573
+ }>>;
574
+ }, z.core.$strict>;
575
+ type ParsedInputSettingsConfig = z.output<typeof InputSettingsSchema>;
576
+ /**
577
+ * Output settings schema — the shape of the top-level `config.json` in the
578
+ * Build Output Specification. Adds the `mode` the build was produced in.
579
+ */
580
+ declare const OutputSettingsSchema: z.ZodObject<{
478
581
  type: z.ZodLiteral<"settings">;
479
582
  accountId: z.ZodOptional<z.ZodString>;
480
583
  complianceRegion: z.ZodOptional<z.ZodEnum<{
481
584
  public: "public";
482
585
  "fedramp-high": "fedramp-high";
483
586
  }>>;
587
+ mode: z.ZodOptional<z.ZodString>;
484
588
  }, z.core.$strict>;
485
- type ParsedSettingsConfig = z.output<typeof SettingsSchema>;
589
+ type ParsedOutputSettingsConfig = z.output<typeof OutputSettingsSchema>;
486
590
  /**
487
591
  * Schema for the resolved config exports, keyed by export
488
592
  * name. Each value is discriminated on its `type` field. Reserves the
@@ -490,7 +594,16 @@ type ParsedSettingsConfig = z.output<typeof SettingsSchema>;
490
594
  * config must live on the `settings` export, and the `settings` export
491
595
  * may only hold a `settings` config.
492
596
  */
493
- declare const ConfigExportsSchema: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
597
+ declare const ConfigExportsSchema: z.ZodPipe<z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodObject<{
598
+ settings: z.ZodOptional<z.ZodObject<{
599
+ type: z.ZodLiteral<"settings">;
600
+ accountId: z.ZodOptional<z.ZodString>;
601
+ complianceRegion: z.ZodOptional<z.ZodEnum<{
602
+ public: "public";
603
+ "fedramp-high": "fedramp-high";
604
+ }>>;
605
+ }, z.core.$strict>>;
606
+ }, z.core.$catchall<z.ZodObject<{
494
607
  type: z.ZodLiteral<"worker">;
495
608
  name: z.ZodString;
496
609
  compatibilityDate: z.ZodString;
@@ -642,14 +755,7 @@ declare const ConfigExportsSchema: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUn
642
755
  }, z.core.$strict>]>, z.ZodTransform<string, string | {
643
756
  default: string;
644
757
  }>>>;
645
- }, z.core.$strict>, z.ZodObject<{
646
- type: z.ZodLiteral<"settings">;
647
- accountId: z.ZodOptional<z.ZodString>;
648
- complianceRegion: z.ZodOptional<z.ZodEnum<{
649
- public: "public";
650
- "fedramp-high": "fedramp-high";
651
- }>>;
652
- }, z.core.$strict>], "type">>;
758
+ }, z.core.$strict>>>>;
653
759
  type ParsedConfigExports = z.output<typeof ConfigExportsSchema>;
654
760
  declare const ModuleTypeSchema: z.ZodEnum<{
655
761
  json: "json";
@@ -881,7 +987,7 @@ declare function generateTypes({
881
987
  * are merged onto the result.
882
988
  * @returns The corresponding Wrangler `RawConfig`.
883
989
  */
884
- declare function convertToWranglerConfig(workerConfig: ParsedInputWorkerConfig, settingsConfig?: ParsedSettingsConfig): RawConfig;
990
+ declare function convertToWranglerConfig(workerConfig: ParsedInputWorkerConfig, settingsConfig?: ParsedInputSettingsConfig): RawConfig;
885
991
  //#endregion
886
992
  //#region src/load.d.ts
887
993
  /**
@@ -961,4 +1067,4 @@ declare function loadAndValidateConfig(configPath: string, ctx: ConfigContext, o
961
1067
  include?: string[];
962
1068
  }): Promise<LoadAndValidateConfigResult>;
963
1069
  //#endregion
964
- export { AgentMemoryBinding, AiBinding, AiSearchBinding, AiSearchNamespaceBinding, AnalyticsEngineDatasetBinding, AnalyticsEngineDatasetBindingSchema, ArtifactsBinding, AssetsBinding, AssetsSchema, BindingSchema, Bindings, BrowserBinding, BrowserBindingSchema, ConfigContext, ConfigExportsSchema, ConnectTrigger, D1Binding, D1BindingSchema, DispatchNamespaceBinding, DurableObjectBinding, DurableObjectCreatedExport, DurableObjectCreatedExportSchema, DurableObjectDeletedExport, DurableObjectDeletedExportSchema, DurableObjectExpectingTransferExport, DurableObjectExpectingTransferExportSchema, DurableObjectRenamedExport, DurableObjectRenamedExportSchema, DurableObjectTransferredExport, DurableObjectTransferredExportSchema, EmailTrigger, ExportSchema, Exports, FetchTrigger, FlagshipBinding, FlagshipBindingSchema, HyperdriveBinding, HyperdriveBindingSchema, ImagesBinding, InferDurableNamespaces, InferEnv, InferMainModule, InputWorkerSchema, JsonBinding, KVBindingSchema, KnownBindingSchema, KvBinding, type LoadAndValidateConfigResult, type LoadConfigResult, LogfwdrBinding, MediaBinding, type ModuleType, ModuleTypeSchema, MtlsCertificateBinding, OutputWorkerSchema, type ParsedConfigExports, type ParsedInputWorkerConfig, type ParsedOutputWorkerConfig, type ParsedSettingsConfig, PipelineBinding, QueueBinding, QueueBindingSchema, QueueConsumerTrigger, R2Binding, R2BindingSchema, RateLimitBinding, ScheduledTrigger, SecretBinding, SecretsStoreSecretBinding, SendEmailBinding, SettingsConfig, SettingsConfigInput, SettingsSchema, StreamBinding, TailConsumerSchema, TextBinding, Triggers, TypedAiBinding, TypedDurableObjectBinding, TypedKvBinding, TypedPipelineBinding, TypedQueueBinding, TypedWorkerBinding, TypedWorkerDefinition, TypedWorkflowBinding, UnsafeBinding, UnsafeBindingSchema, UnwrapConfig, VectorizeBinding, VersionMetadataBinding, VpcNetworkBinding, VpcServiceBinding, WebSearchBinding, WorkerBinding, WorkerBindingSchema, WorkerConfig, WorkerConfigExport, WorkerConfigInput, WorkerEntrypointExport, WorkerEntrypointExportOptions, WorkerEntrypointExportSchema, WorkerLoaderBinding, WorkflowBinding, bindings, convertToWranglerConfig, defineSettings, defineWorker, exports, generateTypes, loadAndValidateConfig, loadConfig, registerConfigHooks, resolveExportDefinition, triggers, validateSingletonBindings };
1070
+ export { AgentMemoryBinding, AiBinding, AiSearchBinding, AiSearchNamespaceBinding, AnalyticsEngineDatasetBinding, AnalyticsEngineDatasetBindingSchema, ArtifactsBinding, AssetsBinding, AssetsSchema, BindingDevOptions, BindingSchema, Bindings, BrowserBinding, BrowserBindingSchema, ConfigContext, ConfigExportsSchema, ConnectTrigger, D1Binding, D1BindingSchema, DispatchNamespaceBinding, DurableObjectBinding, DurableObjectCreatedExport, DurableObjectCreatedExportSchema, DurableObjectDeletedExport, DurableObjectDeletedExportSchema, DurableObjectExpectingTransferExport, DurableObjectExpectingTransferExportSchema, DurableObjectRenamedExport, DurableObjectRenamedExportSchema, DurableObjectTransferredExport, DurableObjectTransferredExportSchema, EmailTrigger, ExportSchema, Exports, FetchTrigger, FlagshipBinding, FlagshipBindingSchema, HyperdriveBinding, HyperdriveBindingSchema, ImagesBinding, InferDurableNamespaces, InferEnv, InferMainModule, InputSettingsSchema, InputWorkerSchema, JsonBinding, KVBindingSchema, KnownBindingSchema, KvBinding, type LoadAndValidateConfigResult, type LoadConfigResult, LogfwdrBinding, MediaBinding, type ModuleType, ModuleTypeSchema, MtlsCertificateBinding, OutputSettingsSchema, OutputWorkerSchema, type ParsedConfigExports, type ParsedInputSettingsConfig, type ParsedInputWorkerConfig, type ParsedOutputSettingsConfig, type ParsedOutputWorkerConfig, PipelineBinding, QueueBinding, QueueBindingSchema, QueueConsumerTrigger, R2Binding, R2BindingSchema, RateLimitBinding, ScheduledTrigger, SecretBinding, SecretsStoreSecretBinding, SendEmailBinding, SettingsConfig, SettingsConfigInput, SettingsDefinition, StreamBinding, TailConsumerSchema, TextBinding, Triggers, TypedAiBinding, TypedDurableObjectBinding, TypedKvBinding, TypedPipelineBinding, TypedQueueBinding, TypedWorkerBinding, TypedWorkerDefinition, TypedWorkflowBinding, UnsafeBinding, UnsafeBindingSchema, UnwrapConfig, VectorizeBinding, VersionMetadataBinding, VpcNetworkBinding, VpcServiceBinding, WebSearchBinding, WorkerBinding, WorkerBindingSchema, WorkerConfig, WorkerConfigExport, WorkerConfigInput, WorkerEntrypointExport, WorkerEntrypointExportOptions, WorkerEntrypointExportSchema, WorkerLoaderBinding, WorkflowBinding, bindings, convertToWranglerConfig, defineSettings, defineWorker, exports, generateTypes, loadAndValidateConfig, loadConfig, registerConfigHooks, resolveExportDefinition, triggers, validateSingletonBindings };
package/dist/index.mjs CHANGED
@@ -14,6 +14,7 @@ var __commonJS = (cb, mod) => function() {
14
14
 
15
15
  //#endregion
16
16
  //#region src/schema.ts
17
+ const RemoteBindingDevSchema = z.strictObject({ remote: z.boolean().optional() });
17
18
  const AssetsSchema = z.strictObject({
18
19
  htmlHandling: z.enum([
19
20
  "auto-trailing-slash",
@@ -30,38 +31,37 @@ const AssetsSchema = z.strictObject({
30
31
  });
31
32
  const BrowserBindingSchema = z.strictObject({
32
33
  type: z.literal("browser"),
33
- remote: z.boolean().optional()
34
+ dev: RemoteBindingDevSchema.optional()
34
35
  });
35
36
  const WorkerBindingSchema = z.strictObject({
36
37
  type: z.literal("worker"),
37
38
  workerName: z.string(),
38
39
  exportName: z.string().optional(),
39
40
  props: z.record(z.string(), z.unknown()).optional(),
40
- remote: z.boolean().optional()
41
+ dev: RemoteBindingDevSchema.optional()
41
42
  });
42
43
  const D1BindingSchema = z.strictObject({
43
44
  type: z.literal("d1"),
44
45
  name: z.string().optional(),
45
46
  id: z.string().optional(),
46
- remote: z.boolean().optional()
47
+ dev: RemoteBindingDevSchema.optional()
47
48
  });
48
49
  const KVBindingSchema = z.strictObject({
49
50
  type: z.literal("kv"),
50
51
  id: z.string().optional(),
51
- remote: z.boolean().optional()
52
+ dev: RemoteBindingDevSchema.optional()
52
53
  });
53
54
  const QueueBindingSchema = z.strictObject({
54
55
  type: z.literal("queue"),
55
56
  name: z.string().optional(),
56
57
  deliveryDelay: z.number().optional(),
57
- remote: z.boolean().optional()
58
+ dev: RemoteBindingDevSchema.optional()
58
59
  });
59
60
  const R2BindingSchema = z.strictObject({
60
61
  type: z.literal("r2"),
61
62
  name: z.string().optional(),
62
63
  jurisdiction: z.string().optional(),
63
- remote: z.boolean().optional(),
64
- localDev: z.strictObject({ experimentalS3Credentials: z.object({
64
+ dev: RemoteBindingDevSchema.extend({ experimentalS3Credentials: z.object({
65
65
  accessKeyId: z.string(),
66
66
  secretAccessKey: z.string()
67
67
  }).optional() }).optional()
@@ -73,38 +73,38 @@ const AnalyticsEngineDatasetBindingSchema = z.strictObject({
73
73
  const FlagshipBindingSchema = z.strictObject({
74
74
  type: z.literal("flagship"),
75
75
  id: z.string().optional(),
76
- remote: z.boolean().optional()
76
+ dev: RemoteBindingDevSchema.optional()
77
77
  });
78
78
  const HyperdriveBindingSchema = z.strictObject({
79
79
  type: z.literal("hyperdrive"),
80
80
  id: z.string(),
81
- localConnectionString: z.string().optional()
81
+ dev: z.strictObject({ connectionString: z.string().optional() }).optional()
82
82
  });
83
83
  const KnownBindingSchema = z.discriminatedUnion("type", [
84
84
  z.strictObject({
85
85
  type: z.literal("agent-memory"),
86
86
  namespace: z.string(),
87
- remote: z.boolean().optional()
87
+ dev: RemoteBindingDevSchema.optional()
88
88
  }),
89
89
  z.strictObject({
90
90
  type: z.literal("ai"),
91
- remote: z.boolean().optional()
91
+ dev: RemoteBindingDevSchema.optional()
92
92
  }),
93
93
  z.strictObject({
94
94
  type: z.literal("ai-search"),
95
95
  name: z.string(),
96
- remote: z.boolean().optional()
96
+ dev: RemoteBindingDevSchema.optional()
97
97
  }),
98
98
  z.strictObject({
99
99
  type: z.literal("ai-search-namespace"),
100
100
  namespace: z.string(),
101
- remote: z.boolean().optional()
101
+ dev: RemoteBindingDevSchema.optional()
102
102
  }),
103
103
  AnalyticsEngineDatasetBindingSchema,
104
104
  z.strictObject({
105
105
  type: z.literal("artifacts"),
106
106
  namespace: z.string(),
107
- remote: z.boolean().optional()
107
+ dev: RemoteBindingDevSchema.optional()
108
108
  }),
109
109
  z.strictObject({ type: z.literal("assets") }),
110
110
  BrowserBindingSchema,
@@ -116,7 +116,7 @@ const KnownBindingSchema = z.discriminatedUnion("type", [
116
116
  workerName: z.string(),
117
117
  parameters: z.array(z.string()).optional()
118
118
  }).optional(),
119
- remote: z.boolean().optional()
119
+ dev: RemoteBindingDevSchema.optional()
120
120
  }),
121
121
  z.strictObject({
122
122
  type: z.literal("durable-object"),
@@ -127,7 +127,7 @@ const KnownBindingSchema = z.discriminatedUnion("type", [
127
127
  HyperdriveBindingSchema,
128
128
  z.strictObject({
129
129
  type: z.literal("images"),
130
- remote: z.boolean().optional()
130
+ dev: RemoteBindingDevSchema.optional()
131
131
  }),
132
132
  z.strictObject({
133
133
  type: z.literal("json"),
@@ -140,17 +140,17 @@ const KnownBindingSchema = z.discriminatedUnion("type", [
140
140
  }),
141
141
  z.strictObject({
142
142
  type: z.literal("media"),
143
- remote: z.boolean().optional()
143
+ dev: RemoteBindingDevSchema.optional()
144
144
  }),
145
145
  z.strictObject({
146
146
  type: z.literal("mtls-certificate"),
147
147
  id: z.string(),
148
- remote: z.boolean().optional()
148
+ dev: RemoteBindingDevSchema.optional()
149
149
  }),
150
150
  z.strictObject({
151
151
  type: z.literal("pipeline"),
152
152
  name: z.string(),
153
- remote: z.boolean().optional()
153
+ dev: RemoteBindingDevSchema.optional()
154
154
  }),
155
155
  QueueBindingSchema,
156
156
  z.strictObject({
@@ -173,11 +173,11 @@ const KnownBindingSchema = z.discriminatedUnion("type", [
173
173
  destinationAddress: z.string().optional(),
174
174
  allowedDestinationAddresses: z.array(z.string()).optional(),
175
175
  allowedSenderAddresses: z.array(z.string()).optional(),
176
- remote: z.boolean().optional()
177
- }),
176
+ dev: RemoteBindingDevSchema.optional()
177
+ }).refine((value) => value.destinationAddress === void 0 || value.allowedDestinationAddresses === void 0, { message: "\"send-email\" bindings cannot specify both \"destinationAddress\" and \"allowedDestinationAddresses\"" }),
178
178
  z.strictObject({
179
179
  type: z.literal("stream"),
180
- remote: z.boolean().optional()
180
+ dev: RemoteBindingDevSchema.optional()
181
181
  }),
182
182
  z.strictObject({
183
183
  type: z.literal("text"),
@@ -186,29 +186,26 @@ const KnownBindingSchema = z.discriminatedUnion("type", [
186
186
  z.strictObject({
187
187
  type: z.literal("vectorize"),
188
188
  name: z.string(),
189
- remote: z.boolean().optional()
189
+ dev: RemoteBindingDevSchema.optional()
190
190
  }),
191
191
  z.strictObject({ type: z.literal("version-metadata") }),
192
192
  z.strictObject({
193
193
  type: z.literal("vpc-service"),
194
194
  id: z.string(),
195
- remote: z.boolean().optional()
195
+ dev: RemoteBindingDevSchema.optional()
196
196
  }),
197
197
  z.strictObject({
198
198
  type: z.literal("vpc-network"),
199
199
  tunnelId: z.string().optional(),
200
200
  networkId: z.string().optional(),
201
- remote: z.boolean().optional()
202
- }).superRefine((value, ctx) => {
203
- const hasTunnel = value.tunnelId !== void 0;
204
- if (hasTunnel === (value.networkId !== void 0)) ctx.addIssue({
205
- code: "custom",
206
- message: hasTunnel ? `"vpc-network" bindings must specify exactly one of "tunnelId" or "networkId", not both` : `"vpc-network" bindings must specify either "tunnelId" or "networkId"`
207
- });
208
- }),
201
+ dev: RemoteBindingDevSchema.optional()
202
+ }).refine((value) => value.tunnelId !== void 0 !== (value.networkId !== void 0), { error: ({ input }) => {
203
+ const value = input;
204
+ return value.tunnelId !== void 0 && value.networkId !== void 0 ? `"vpc-network" bindings must specify exactly one of "tunnelId" or "networkId", not both` : `"vpc-network" bindings must specify either "tunnelId" or "networkId"`;
205
+ } }),
209
206
  z.strictObject({
210
207
  type: z.literal("web-search"),
211
- remote: z.boolean().optional()
208
+ dev: RemoteBindingDevSchema.optional()
212
209
  }),
213
210
  WorkerBindingSchema,
214
211
  z.strictObject({ type: z.literal("worker-loader") })
@@ -432,30 +429,39 @@ const BaseWorkerSchema = z.strictObject({
432
429
  */
433
430
  const InputWorkerSchema = BaseWorkerSchema.extend({ entrypoint: z.union([z.string(), z.strictObject({ default: z.string() })]).transform((value) => typeof value === "string" ? value : value.default).optional() });
434
431
  /**
435
- * Settings schema — validates the named `settings` export of a
432
+ * Input settings schema — validates the named `settings` export of a
436
433
  * `cloudflare.config.ts`. Holds account/deployment settings shared by the other exports.
437
434
  */
438
- const SettingsSchema = z.strictObject({
435
+ const InputSettingsSchema = z.strictObject({
439
436
  type: z.literal("settings"),
440
437
  accountId: z.string().optional(),
441
438
  complianceRegion: z.enum(["public", "fedramp-high"]).optional()
442
439
  });
443
440
  /**
444
- * Discriminated union of the config kinds a single export may resolve to.
441
+ * Output settings schema — the shape of the top-level `config.json` in the
442
+ * Build Output Specification. Adds the `mode` the build was produced in.
445
443
  */
446
- const ConfigExportSchema = z.discriminatedUnion("type", [InputWorkerSchema, SettingsSchema]);
444
+ const OutputSettingsSchema = InputSettingsSchema.extend({ mode: z.string().optional() });
447
445
  const SETTINGS_EXPORT_NAME = "settings";
448
- /**
449
- * Schema for the resolved config exports, keyed by export
450
- * name. Each value is discriminated on its `type` field. Reserves the
451
- * `settings` export name exclusively for settings configs: a `settings`
452
- * config must live on the `settings` export, and the `settings` export
453
- * may only hold a `settings` config.
454
- */
455
- const ConfigExportsSchema = z.record(z.string(), ConfigExportSchema).check((ctx) => {
446
+ const SUPPORTED_EXPORT_TYPES = new Set(["worker", "settings"]);
447
+ function invalidConfigExportMessage(exportName) {
448
+ return `The \`${exportName}\` export is not a supported export type. Move constants, helper functions, and other unsupported exports to a separate module.`;
449
+ }
450
+ const ConfigExportsTypeSchema = z.record(z.string(), z.unknown()).check((ctx) => {
456
451
  for (const [key, value] of Object.entries(ctx.value)) {
452
+ const isObject = typeof value === "object" && value !== null;
453
+ const type = isObject && "type" in value ? value.type : void 0;
454
+ if (typeof type !== "string" || !SUPPORTED_EXPORT_TYPES.has(type)) {
455
+ ctx.issues.push({
456
+ code: "custom",
457
+ input: value,
458
+ path: isObject ? [key, "type"] : [key],
459
+ message: invalidConfigExportMessage(key)
460
+ });
461
+ continue;
462
+ }
457
463
  const isSettingsName = key === SETTINGS_EXPORT_NAME;
458
- const isSettingsType = value.type === "settings";
464
+ const isSettingsType = type === "settings";
459
465
  if (isSettingsType && !isSettingsName) ctx.issues.push({
460
466
  code: "custom",
461
467
  input: value,
@@ -466,10 +472,19 @@ const ConfigExportsSchema = z.record(z.string(), ConfigExportSchema).check((ctx)
466
472
  code: "custom",
467
473
  input: value,
468
474
  path: [key],
469
- message: `The \`${SETTINGS_EXPORT_NAME}\` export is reserved for a \`settings\` config; found a \`${value.type}\` config.`
475
+ message: `The \`${SETTINGS_EXPORT_NAME}\` export is reserved for a \`settings\` config; found a \`${type}\` config.`
470
476
  });
471
477
  }
472
478
  });
479
+ const ConfigExportsObjectSchema = z.object({ settings: InputSettingsSchema.optional() }).catchall(InputWorkerSchema);
480
+ /**
481
+ * Schema for the resolved config exports, keyed by export
482
+ * name. Each value is discriminated on its `type` field. Reserves the
483
+ * `settings` export name exclusively for settings configs: a `settings`
484
+ * config must live on the `settings` export, and the `settings` export
485
+ * may only hold a `settings` config.
486
+ */
487
+ const ConfigExportsSchema = ConfigExportsTypeSchema.pipe(ConfigExportsObjectSchema);
473
488
  const ModuleTypeSchema = z.enum([
474
489
  "esm",
475
490
  "cjs",
@@ -3215,27 +3230,27 @@ function convertBindingsAndAssets(config, result) {
3215
3230
  agentMemory.push(omitUndefined({
3216
3231
  binding: name,
3217
3232
  namespace: binding.namespace,
3218
- remote: binding.remote
3233
+ remote: binding.dev?.remote
3219
3234
  }));
3220
3235
  break;
3221
3236
  case "ai":
3222
3237
  result.ai = omitUndefined({
3223
3238
  binding: name,
3224
- remote: binding.remote
3239
+ remote: binding.dev?.remote
3225
3240
  });
3226
3241
  break;
3227
3242
  case "ai-search":
3228
3243
  aiSearch.push(omitUndefined({
3229
3244
  binding: name,
3230
3245
  instance_name: binding.name,
3231
- remote: binding.remote
3246
+ remote: binding.dev?.remote
3232
3247
  }));
3233
3248
  break;
3234
3249
  case "ai-search-namespace":
3235
3250
  aiSearchNamespaces.push(omitUndefined({
3236
3251
  binding: name,
3237
3252
  namespace: binding.namespace,
3238
- remote: binding.remote
3253
+ remote: binding.dev?.remote
3239
3254
  }));
3240
3255
  break;
3241
3256
  case "analytics-engine-dataset":
@@ -3248,7 +3263,7 @@ function convertBindingsAndAssets(config, result) {
3248
3263
  artifacts.push(omitUndefined({
3249
3264
  binding: name,
3250
3265
  namespace: binding.namespace,
3251
- remote: binding.remote
3266
+ remote: binding.dev?.remote
3252
3267
  }));
3253
3268
  break;
3254
3269
  case "assets":
@@ -3257,7 +3272,7 @@ function convertBindingsAndAssets(config, result) {
3257
3272
  case "browser":
3258
3273
  result.browser = omitUndefined({
3259
3274
  binding: name,
3260
- remote: binding.remote
3275
+ remote: binding.dev?.remote
3261
3276
  });
3262
3277
  break;
3263
3278
  case "d1":
@@ -3265,7 +3280,7 @@ function convertBindingsAndAssets(config, result) {
3265
3280
  binding: name,
3266
3281
  database_id: binding.id,
3267
3282
  database_name: binding.name,
3268
- remote: binding.remote
3283
+ remote: binding.dev?.remote
3269
3284
  }));
3270
3285
  break;
3271
3286
  case "dispatch-namespace": {
@@ -3277,7 +3292,7 @@ function convertBindingsAndAssets(config, result) {
3277
3292
  service: binding.outbound.workerName,
3278
3293
  parameters: binding.outbound.parameters
3279
3294
  });
3280
- if (binding.remote !== void 0) entry.remote = binding.remote;
3295
+ if (binding.dev?.remote !== void 0) entry.remote = binding.dev.remote;
3281
3296
  dispatchNamespaces.push(entry);
3282
3297
  break;
3283
3298
  }
@@ -3292,20 +3307,20 @@ function convertBindingsAndAssets(config, result) {
3292
3307
  flagship.push(omitUndefined({
3293
3308
  binding: name,
3294
3309
  app_id: binding.id,
3295
- remote: binding.remote
3310
+ remote: binding.dev?.remote
3296
3311
  }));
3297
3312
  break;
3298
3313
  case "hyperdrive":
3299
3314
  hyperdrive.push(omitUndefined({
3300
3315
  binding: name,
3301
3316
  id: binding.id,
3302
- localConnectionString: binding.localConnectionString
3317
+ localConnectionString: binding.dev?.connectionString
3303
3318
  }));
3304
3319
  break;
3305
3320
  case "images":
3306
3321
  result.images = omitUndefined({
3307
3322
  binding: name,
3308
- remote: binding.remote
3323
+ remote: binding.dev?.remote
3309
3324
  });
3310
3325
  break;
3311
3326
  case "json":
@@ -3315,7 +3330,7 @@ function convertBindingsAndAssets(config, result) {
3315
3330
  kvNamespaces.push(omitUndefined({
3316
3331
  binding: name,
3317
3332
  id: binding.id,
3318
- remote: binding.remote
3333
+ remote: binding.dev?.remote
3319
3334
  }));
3320
3335
  break;
3321
3336
  case "logfwdr":
@@ -3327,21 +3342,21 @@ function convertBindingsAndAssets(config, result) {
3327
3342
  case "media":
3328
3343
  result.media = omitUndefined({
3329
3344
  binding: name,
3330
- remote: binding.remote
3345
+ remote: binding.dev?.remote
3331
3346
  });
3332
3347
  break;
3333
3348
  case "mtls-certificate":
3334
3349
  mtlsCertificates.push(omitUndefined({
3335
3350
  binding: name,
3336
3351
  certificate_id: binding.id,
3337
- remote: binding.remote
3352
+ remote: binding.dev?.remote
3338
3353
  }));
3339
3354
  break;
3340
3355
  case "pipeline":
3341
3356
  pipelines.push(omitUndefined({
3342
3357
  binding: name,
3343
3358
  stream: binding.name,
3344
- remote: binding.remote
3359
+ remote: binding.dev?.remote
3345
3360
  }));
3346
3361
  break;
3347
3362
  case "queue":
@@ -3349,7 +3364,7 @@ function convertBindingsAndAssets(config, result) {
3349
3364
  binding: name,
3350
3365
  queue: binding.name,
3351
3366
  delivery_delay: binding.deliveryDelay,
3352
- remote: binding.remote
3367
+ remote: binding.dev?.remote
3353
3368
  }));
3354
3369
  break;
3355
3370
  case "rate-limit":
@@ -3360,12 +3375,12 @@ function convertBindingsAndAssets(config, result) {
3360
3375
  });
3361
3376
  break;
3362
3377
  case "r2": {
3363
- const experimentalS3Credentials = binding.localDev?.experimentalS3Credentials;
3378
+ const experimentalS3Credentials = binding.dev?.experimentalS3Credentials;
3364
3379
  r2Buckets.push(omitUndefined({
3365
3380
  binding: name,
3366
3381
  bucket_name: binding.name,
3367
3382
  jurisdiction: binding.jurisdiction,
3368
- remote: binding.remote,
3383
+ remote: binding.dev?.remote,
3369
3384
  local_dev: experimentalS3Credentials === void 0 ? void 0 : { experimental_s3_credentials: experimentalS3Credentials }
3370
3385
  }));
3371
3386
  break;
@@ -3386,13 +3401,13 @@ function convertBindingsAndAssets(config, result) {
3386
3401
  destination_address: binding.destinationAddress,
3387
3402
  allowed_destination_addresses: binding.allowedDestinationAddresses,
3388
3403
  allowed_sender_addresses: binding.allowedSenderAddresses,
3389
- remote: binding.remote
3404
+ remote: binding.dev?.remote
3390
3405
  }));
3391
3406
  break;
3392
3407
  case "stream":
3393
3408
  result.stream = omitUndefined({
3394
3409
  binding: name,
3395
- remote: binding.remote
3410
+ remote: binding.dev?.remote
3396
3411
  });
3397
3412
  break;
3398
3413
  case "text":
@@ -3402,7 +3417,7 @@ function convertBindingsAndAssets(config, result) {
3402
3417
  vectorize.push(omitUndefined({
3403
3418
  binding: name,
3404
3419
  index_name: binding.name,
3405
- remote: binding.remote
3420
+ remote: binding.dev?.remote
3406
3421
  }));
3407
3422
  break;
3408
3423
  case "version-metadata":
@@ -3412,25 +3427,25 @@ function convertBindingsAndAssets(config, result) {
3412
3427
  vpcServices.push(omitUndefined({
3413
3428
  binding: name,
3414
3429
  service_id: binding.id,
3415
- remote: binding.remote
3430
+ remote: binding.dev?.remote
3416
3431
  }));
3417
3432
  break;
3418
3433
  case "vpc-network":
3419
3434
  if (binding.tunnelId !== void 0) vpcNetworks.push(omitUndefined({
3420
3435
  binding: name,
3421
3436
  tunnel_id: binding.tunnelId,
3422
- remote: binding.remote
3437
+ remote: binding.dev?.remote
3423
3438
  }));
3424
3439
  else if (binding.networkId !== void 0) vpcNetworks.push(omitUndefined({
3425
3440
  binding: name,
3426
3441
  network_id: binding.networkId,
3427
- remote: binding.remote
3442
+ remote: binding.dev?.remote
3428
3443
  }));
3429
3444
  break;
3430
3445
  case "web-search":
3431
3446
  result.websearch = omitUndefined({
3432
3447
  binding: name,
3433
- remote: binding.remote
3448
+ remote: binding.dev?.remote
3434
3449
  });
3435
3450
  break;
3436
3451
  case "worker":
@@ -3439,7 +3454,7 @@ function convertBindingsAndAssets(config, result) {
3439
3454
  service: binding.workerName,
3440
3455
  entrypoint: binding.exportName,
3441
3456
  props: binding.props,
3442
- remote: binding.remote
3457
+ remote: binding.dev?.remote
3443
3458
  }));
3444
3459
  break;
3445
3460
  case "worker-loader":
@@ -3776,4 +3791,4 @@ async function loadAndValidateConfig(configPath, ctx, options) {
3776
3791
  }
3777
3792
 
3778
3793
  //#endregion
3779
- export { AnalyticsEngineDatasetBindingSchema, AssetsSchema, BindingSchema, BrowserBindingSchema, ConfigExportsSchema, D1BindingSchema, DurableObjectCreatedExportSchema, DurableObjectDeletedExportSchema, DurableObjectExpectingTransferExportSchema, DurableObjectRenamedExportSchema, DurableObjectTransferredExportSchema, ExportSchema, FlagshipBindingSchema, HyperdriveBindingSchema, InputWorkerSchema, KVBindingSchema, KnownBindingSchema, ModuleTypeSchema, OutputWorkerSchema, QueueBindingSchema, R2BindingSchema, SettingsSchema, TailConsumerSchema, UnsafeBindingSchema, WorkerBindingSchema, WorkerEntrypointExportSchema, bindings, convertToWranglerConfig, defineSettings, defineWorker, exports$1 as exports, generateTypes, loadAndValidateConfig, loadConfig, registerConfigHooks, resolveExportDefinition, triggers, validateSingletonBindings };
3794
+ export { AnalyticsEngineDatasetBindingSchema, AssetsSchema, BindingSchema, BrowserBindingSchema, ConfigExportsSchema, D1BindingSchema, DurableObjectCreatedExportSchema, DurableObjectDeletedExportSchema, DurableObjectExpectingTransferExportSchema, DurableObjectRenamedExportSchema, DurableObjectTransferredExportSchema, ExportSchema, FlagshipBindingSchema, HyperdriveBindingSchema, InputSettingsSchema, InputWorkerSchema, KVBindingSchema, KnownBindingSchema, ModuleTypeSchema, OutputSettingsSchema, OutputWorkerSchema, QueueBindingSchema, R2BindingSchema, TailConsumerSchema, UnsafeBindingSchema, WorkerBindingSchema, WorkerEntrypointExportSchema, bindings, convertToWranglerConfig, defineSettings, defineWorker, exports$1 as exports, generateTypes, loadAndValidateConfig, loadConfig, registerConfigHooks, resolveExportDefinition, triggers, validateSingletonBindings };
@@ -9,11 +9,16 @@ type Json = string | number | boolean | null | Json[] | {
9
9
  };
10
10
  //#endregion
11
11
  //#region src/bindings.d.ts
12
+ /** Options that control a binding during local development. */
13
+ interface BindingDevOptions {
14
+ /** Whether the binding should connect to the remote resource. */
15
+ remote?: boolean;
16
+ }
12
17
  interface AgentMemoryBindingOptions {
13
18
  /** The user-chosen namespace name. Must exist in Cloudflare at deploy time. */
14
19
  namespace: string;
15
- /** Whether the Agent Memory binding should be remote in local development. */
16
- remote?: boolean;
20
+ /** Options that only apply during local development. */
21
+ dev?: BindingDevOptions;
17
22
  }
18
23
  /**
19
24
  * Agent Memory namespace binding. Each binding is scoped to a namespace and
@@ -23,8 +28,8 @@ interface AgentMemoryBinding extends AgentMemoryBindingOptions {
23
28
  type: "agent-memory";
24
29
  }
25
30
  interface AiBindingOptions {
26
- /** Whether the AI binding should be remote or not in local development. */
27
- remote?: boolean;
31
+ /** Options that only apply during local development. */
32
+ dev?: BindingDevOptions;
28
33
  }
29
34
  /**
30
35
  * Binding to the Workers AI project.
@@ -46,8 +51,8 @@ interface TypedAiBinding<TAiModelList extends AiModelListType = AiModels> extend
46
51
  interface AiSearchBindingOptions {
47
52
  /** The user-chosen instance name. Must exist in Cloudflare at deploy time. */
48
53
  name: string;
49
- /** Whether the AI Search instance binding should be remote in local development. */
50
- remote?: boolean;
54
+ /** Options that only apply during local development. */
55
+ dev?: BindingDevOptions;
51
56
  }
52
57
  /**
53
58
  * AI Search instance binding. Each binding is bound directly to a single
@@ -59,8 +64,8 @@ interface AiSearchBinding extends AiSearchBindingOptions {
59
64
  interface AiSearchNamespaceBindingOptions {
60
65
  /** The user-chosen namespace name. Must exist in Cloudflare at deploy time. */
61
66
  namespace: string;
62
- /** Whether the AI Search namespace binding should be remote in local development. */
63
- remote?: boolean;
67
+ /** Options that only apply during local development. */
68
+ dev?: BindingDevOptions;
64
69
  }
65
70
  /**
66
71
  * AI Search namespace binding. Each binding is scoped to a namespace and
@@ -84,8 +89,8 @@ interface AnalyticsEngineDatasetBinding extends AnalyticsEngineDatasetBindingOpt
84
89
  interface ArtifactsBindingOptions {
85
90
  /** The namespace to use. */
86
91
  namespace: string;
87
- /** Whether to use the remote Artifacts service in local dev. */
88
- remote?: boolean;
92
+ /** Options that only apply during local development. */
93
+ dev?: BindingDevOptions;
89
94
  }
90
95
  /**
91
96
  * Binding to an Artifacts instance. Artifacts provides git-compatible file
@@ -103,8 +108,8 @@ interface AssetsBinding {
103
108
  type: "assets";
104
109
  }
105
110
  interface BrowserBindingOptions {
106
- /** Whether the Browser binding should be remote or not in local development. */
107
- remote?: boolean;
111
+ /** Options that only apply during local development. */
112
+ dev?: BindingDevOptions;
108
113
  }
109
114
  /**
110
115
  * Binding to a headless browser usable from the Worker.
@@ -119,8 +124,8 @@ interface D1BindingOptions {
119
124
  id?: string;
120
125
  /** The name of this D1 database. */
121
126
  name?: string;
122
- /** Whether the D1 database should be remote or not in local development. */
123
- remote?: boolean;
127
+ /** Options that only apply during local development. */
128
+ dev?: BindingDevOptions;
124
129
  }
125
130
  /**
126
131
  * Binding to a D1 database.
@@ -140,8 +145,8 @@ interface DispatchNamespaceBindingOptions {
140
145
  /** (Optional) List of parameter names, for sending context from your dispatch Worker to the outbound handler. */
141
146
  parameters?: string[];
142
147
  };
143
- /** Whether the Dispatch Namespace should be remote or not in local development. */
144
- remote?: boolean;
148
+ /** Options that only apply during local development. */
149
+ dev?: BindingDevOptions;
145
150
  }
146
151
  /**
147
152
  * Binding to a Workers for Platforms dispatch namespace.
@@ -181,8 +186,8 @@ interface TypedDurableObjectBinding<TConfig$1, TExportName$1 extends string> ext
181
186
  interface FlagshipBindingOptions {
182
187
  /** The Flagship app ID to bind to. */
183
188
  id?: string;
184
- /** Set to `true` to suppress the remote binding warning in local dev. Flagship bindings are always remote. */
185
- remote?: boolean;
189
+ /** Options that only apply during local development. */
190
+ dev?: BindingDevOptions;
186
191
  }
187
192
  /** Binding to a Flagship feature-flag service. */
188
193
  interface FlagshipBinding extends FlagshipBindingOptions {
@@ -191,8 +196,11 @@ interface FlagshipBinding extends FlagshipBindingOptions {
191
196
  interface HyperdriveBindingOptions {
192
197
  /** The ID of the Hyperdrive configuration. */
193
198
  id: string;
194
- /** The local database connection string used during local development. */
195
- localConnectionString?: string;
199
+ /** Options that only apply during local development. */
200
+ dev?: {
201
+ /** The database connection string used during local development. */
202
+ connectionString?: string;
203
+ };
196
204
  }
197
205
  /**
198
206
  * Binding to a Hyperdrive configuration.
@@ -203,8 +211,8 @@ interface HyperdriveBinding extends HyperdriveBindingOptions {
203
211
  type: "hyperdrive";
204
212
  }
205
213
  interface ImagesBindingOptions {
206
- /** Whether the Images binding should be remote or not in local development. */
207
- remote?: boolean;
214
+ /** Options that only apply during local development. */
215
+ dev?: BindingDevOptions;
208
216
  }
209
217
  /**
210
218
  * Binding to Cloudflare Images.
@@ -226,8 +234,8 @@ interface JsonBinding<T$1 extends Json = Json> {
226
234
  interface KvBindingOptions {
227
235
  /** The ID of the KV namespace. */
228
236
  id?: string;
229
- /** Whether the KV namespace should be remote or not in local development. */
230
- remote?: boolean;
237
+ /** Options that only apply during local development. */
238
+ dev?: BindingDevOptions;
231
239
  }
232
240
  /**
233
241
  * Binding to a Workers KV namespace.
@@ -255,8 +263,8 @@ interface LogfwdrBinding extends LogfwdrBindingOptions {
255
263
  type: "logfwdr";
256
264
  }
257
265
  interface MediaBindingOptions {
258
- /** Whether the Media binding should be remote or not. */
259
- remote?: boolean;
266
+ /** Options that only apply during local development. */
267
+ dev?: BindingDevOptions;
260
268
  }
261
269
  /** Binding to Cloudflare Media Transformations. */
262
270
  interface MediaBinding$1 extends MediaBindingOptions {
@@ -265,8 +273,8 @@ interface MediaBinding$1 extends MediaBindingOptions {
265
273
  interface MtlsCertificateBindingOptions {
266
274
  /** The UUID of the uploaded mTLS certificate. */
267
275
  id: string;
268
- /** Whether the mTLS fetcher should be remote or not in local development. */
269
- remote?: boolean;
276
+ /** Options that only apply during local development. */
277
+ dev?: BindingDevOptions;
270
278
  }
271
279
  /**
272
280
  * Binding to an uploaded mTLS certificate.
@@ -279,8 +287,8 @@ interface MtlsCertificateBinding extends MtlsCertificateBindingOptions {
279
287
  interface PipelineBindingOptions {
280
288
  /** Name of the Pipeline to bind. */
281
289
  name: string;
282
- /** Whether the pipeline should be remote or not in local development. */
283
- remote?: boolean;
290
+ /** Options that only apply during local development. */
291
+ dev?: BindingDevOptions;
284
292
  }
285
293
  /** Binding to a Cloudflare Pipeline. */
286
294
  interface PipelineBinding extends PipelineBindingOptions {
@@ -296,8 +304,8 @@ interface QueueBindingOptions {
296
304
  name?: string;
297
305
  /** The number of seconds to wait before delivering a message. */
298
306
  deliveryDelay?: number;
299
- /** Whether the Queue producer should be remote or not in local development. */
300
- remote?: boolean;
307
+ /** Options that only apply during local development. */
308
+ dev?: BindingDevOptions;
301
309
  }
302
310
  /**
303
311
  * Producer binding to a Cloudflare Queue.
@@ -321,10 +329,8 @@ interface R2BindingOptions {
321
329
  name?: string;
322
330
  /** The jurisdiction that the bucket exists in. Default if not present. */
323
331
  jurisdiction?: string;
324
- /** Whether the R2 bucket should be remote or not in local development. */
325
- remote?: boolean;
326
332
  /** Settings that only apply to local development. */
327
- localDev?: {
333
+ dev?: BindingDevOptions & {
328
334
  /** EXPERIMENTAL: credentials for the local S3-compatible endpoint. */
329
335
  experimentalS3Credentials?: {
330
336
  accessKeyId: string;
@@ -378,27 +384,35 @@ interface SecretsStoreSecretBindingOptions {
378
384
  interface SecretsStoreSecretBinding extends SecretsStoreSecretBindingOptions {
379
385
  type: "secrets-store-secret";
380
386
  }
381
- interface SendEmailBindingOptions {
387
+ type SendEmailDestinationOptions = {
382
388
  /** If this binding should be restricted to a specific verified address. */
383
- destinationAddress?: string;
389
+ destinationAddress: string;
390
+ allowedDestinationAddresses?: never;
391
+ } | {
392
+ destinationAddress?: never;
384
393
  /** If this binding should be restricted to a set of verified addresses. */
385
- allowedDestinationAddresses?: string[];
394
+ allowedDestinationAddresses: string[];
395
+ } | {
396
+ destinationAddress?: never;
397
+ allowedDestinationAddresses?: never;
398
+ };
399
+ type SendEmailBindingOptions = SendEmailDestinationOptions & {
386
400
  /** If this binding should be restricted to a set of sender addresses. */
387
401
  allowedSenderAddresses?: string[];
388
- /** Whether the binding should be remote or not in local development. */
389
- remote?: boolean;
390
- }
402
+ /** Options that only apply during local development. */
403
+ dev?: BindingDevOptions;
404
+ };
391
405
  /**
392
406
  * Binding for sending email from inside the Worker.
393
407
  *
394
408
  * For reference, see https://developers.cloudflare.com/workers/wrangler/configuration/#email-bindings
395
409
  */
396
- interface SendEmailBinding extends SendEmailBindingOptions {
410
+ type SendEmailBinding = SendEmailBindingOptions & {
397
411
  type: "send-email";
398
- }
412
+ };
399
413
  interface StreamBindingOptions {
400
- /** Whether the Stream binding should be remote or not in local development. */
401
- remote?: boolean;
414
+ /** Options that only apply during local development. */
415
+ dev?: BindingDevOptions;
402
416
  }
403
417
  /** Binding to Cloudflare Stream. */
404
418
  interface StreamBinding$1 extends StreamBindingOptions {
@@ -439,8 +453,8 @@ interface UnsafeBinding extends UnsafeBindingOptions {
439
453
  interface VectorizeBindingOptions {
440
454
  /** The name of the Vectorize index. */
441
455
  name: string;
442
- /** Whether the Vectorize index should be remote or not in local development. */
443
- remote?: boolean;
456
+ /** Options that only apply during local development. */
457
+ dev?: BindingDevOptions;
444
458
  }
445
459
  /**
446
460
  * Binding to a Vectorize index.
@@ -457,13 +471,15 @@ interface VersionMetadataBinding {
457
471
  type VpcNetworkBindingOptions = {
458
472
  /** The tunnel ID of the Cloudflare Tunnel to route traffic through. Mutually exclusive with `networkId`. */
459
473
  tunnelId: string;
460
- /** Whether the VPC network is remote or not. */
461
- remote?: boolean;
474
+ networkId?: never;
475
+ /** Options that only apply during local development. */
476
+ dev?: BindingDevOptions;
462
477
  } | {
478
+ tunnelId?: never;
463
479
  /** The network ID to route traffic through. Mutually exclusive with `tunnelId`. */
464
480
  networkId: string;
465
- /** Whether the VPC network is remote or not. */
466
- remote?: boolean;
481
+ /** Options that only apply during local development. */
482
+ dev?: BindingDevOptions;
467
483
  };
468
484
  /** Binding to a VPC network. */
469
485
  type VpcNetworkBinding = VpcNetworkBindingOptions & {
@@ -472,16 +488,16 @@ type VpcNetworkBinding = VpcNetworkBindingOptions & {
472
488
  interface VpcServiceBindingOptions {
473
489
  /** The service ID of the VPC connectivity service. */
474
490
  id: string;
475
- /** Whether the VPC service is remote or not. */
476
- remote?: boolean;
491
+ /** Options that only apply during local development. */
492
+ dev?: BindingDevOptions;
477
493
  }
478
494
  /** Binding to a VPC service. */
479
495
  interface VpcServiceBinding extends VpcServiceBindingOptions {
480
496
  type: "vpc-service";
481
497
  }
482
498
  interface WebSearchBindingOptions {
483
- /** Whether the Web Search binding should be remote or not in local development. */
484
- remote?: boolean;
499
+ /** Options that only apply during local development. */
500
+ dev?: BindingDevOptions;
485
501
  }
486
502
  /**
487
503
  * Cloudflare Web Search binding. There is exactly one shared web corpus, so
@@ -497,8 +513,8 @@ interface WorkerBindingOptions {
497
513
  exportName?: string;
498
514
  /** Optional properties that will be made available to the service via `ctx.props`. */
499
515
  props?: Record<string, unknown>;
500
- /** Whether the service binding should be remote or not in local development. */
501
- remote?: boolean;
516
+ /** Options that only apply during local development. */
517
+ dev?: BindingDevOptions;
502
518
  }
503
519
  /**
504
520
  * Service binding (Worker-to-Worker). `workerName` is the name of the bound
@@ -1414,7 +1430,7 @@ interface TypedWorkerDefinition<TConfig$1 extends WorkerConfig, TWorkerName exte
1414
1430
  workerName: TWorkerName;
1415
1431
  exportName?: TExportName$1;
1416
1432
  props?: Record<string, unknown>;
1417
- remote?: boolean;
1433
+ dev?: BindingDevOptions;
1418
1434
  }): TypedWorkerBinding<TConfig$1, TExportName$1 extends string ? TExportName$1 : "default">;
1419
1435
  }
1420
1436
  type WorkerConfigExport<T$1 extends WorkerConfig = WorkerConfig> = ConfigInput<T$1>;
@@ -1643,14 +1659,18 @@ type InferMainModule<TUnwrappedConfig$1> = TUnwrappedConfig$1 extends {
1643
1659
  */
1644
1660
  type SettingsConfigInput = Omit<SettingsConfig, "type">;
1645
1661
  /**
1646
- * Declare shared settings.
1647
- * Authored as a named `settings` export.
1662
+ * A settings definition created by {@link defineSettings}.
1648
1663
  */
1649
- declare function defineSettings(config: ConfigInput<SettingsConfigInput>): {
1664
+ interface SettingsDefinition {
1650
1665
  [DEFINITION]: {
1651
1666
  config: ConfigInput<SettingsConfigInput>;
1652
- type: string;
1667
+ type: "settings";
1653
1668
  };
1654
- };
1669
+ }
1670
+ /**
1671
+ * Declare shared settings.
1672
+ * Authored as a named `settings` export.
1673
+ */
1674
+ declare function defineSettings(config: ConfigInput<SettingsConfigInput>): SettingsDefinition;
1655
1675
  //#endregion
1656
- export { R2Binding as $, triggers as A, D1Binding as B, exports as C, QueueConsumerTrigger as D, FetchTrigger as E, AnalyticsEngineDatasetBinding as F, ImagesBinding$1 as G, DurableObjectBinding as H, ArtifactsBinding as I, LogfwdrBinding as J, JsonBinding as K, AssetsBinding as L, AiBinding as M, AiSearchBinding as N, ScheduledTrigger as O, AiSearchNamespaceBinding as P, QueueBinding as Q, Bindings as R, WorkerEntrypointExportOptions as S, bindings as St, EmailTrigger as T, FlagshipBinding as U, DispatchNamespaceBinding as V, HyperdriveBinding as W, MtlsCertificateBinding as X, MediaBinding$1 as Y, PipelineBinding as Z, DurableObjectExpectingTransferExport as _, VpcServiceBinding as _t, InferMainModule as a, TextBinding as at, Exports as b, WorkerLoaderBinding as bt, WorkerConfigExport as c, TypedKvBinding as ct, SettingsConfig as d, TypedWorkerBinding as dt, RateLimitBinding as et, WorkerConfig as f, TypedWorkflowBinding as ft, DurableObjectDeletedExport as g, VpcNetworkBinding as gt, DurableObjectCreatedExport as h, VersionMetadataBinding as ht, InferEnv as i, StreamBinding$1 as it, AgentMemoryBinding as j, Triggers as k, WorkerConfigInput as l, TypedPipelineBinding as lt, resolveExportDefinition as m, VectorizeBinding as mt, defineSettings as n, SecretsStoreSecretBinding as nt, UnwrapConfig as o, TypedAiBinding as ot, ConfigContext as p, UnsafeBinding as pt, KvBinding as q, InferDurableNamespaces as r, SendEmailBinding as rt, TypedWorkerDefinition as s, TypedDurableObjectBinding as st, SettingsConfigInput as t, SecretBinding as tt, defineWorker as u, TypedQueueBinding as ut, DurableObjectRenamedExport as v, WebSearchBinding as vt, ConnectTrigger as w, WorkerEntrypointExport as x, WorkflowBinding as xt, DurableObjectTransferredExport as y, WorkerBinding as yt, BrowserBinding as z };
1676
+ export { PipelineBinding as $, Triggers as A, Bindings as B, WorkerEntrypointExportOptions as C, WorkflowBinding as Ct, FetchTrigger as D, EmailTrigger as E, AiSearchNamespaceBinding as F, FlagshipBinding as G, D1Binding as H, AnalyticsEngineDatasetBinding as I, JsonBinding as J, HyperdriveBinding as K, ArtifactsBinding as L, AgentMemoryBinding as M, AiBinding as N, QueueConsumerTrigger as O, AiSearchBinding as P, MtlsCertificateBinding as Q, AssetsBinding as R, WorkerEntrypointExport as S, WorkerLoaderBinding as St, ConnectTrigger as T, DispatchNamespaceBinding as U, BrowserBinding as V, DurableObjectBinding as W, LogfwdrBinding as X, KvBinding as Y, MediaBinding$1 as Z, DurableObjectDeletedExport as _, VersionMetadataBinding as _t, InferEnv as a, SendEmailBinding as at, DurableObjectTransferredExport as b, WebSearchBinding as bt, TypedWorkerDefinition as c, TypedAiBinding as ct, defineWorker as d, TypedPipelineBinding as dt, QueueBinding as et, SettingsConfig as f, TypedQueueBinding as ft, DurableObjectCreatedExport as g, VectorizeBinding as gt, resolveExportDefinition as h, UnsafeBinding as ht, InferDurableNamespaces as i, SecretsStoreSecretBinding as it, triggers as j, ScheduledTrigger as k, WorkerConfigExport as l, TypedDurableObjectBinding as lt, ConfigContext as m, TypedWorkflowBinding as mt, SettingsDefinition as n, RateLimitBinding as nt, InferMainModule as o, StreamBinding$1 as ot, WorkerConfig as p, TypedWorkerBinding as pt, ImagesBinding$1 as q, defineSettings as r, SecretBinding as rt, UnwrapConfig as s, TextBinding as st, SettingsConfigInput as t, R2Binding as tt, WorkerConfigInput as u, TypedKvBinding as ut, DurableObjectExpectingTransferExport as v, VpcNetworkBinding as vt, exports as w, bindings as wt, Exports as x, WorkerBinding as xt, DurableObjectRenamedExport as y, VpcServiceBinding as yt, BindingDevOptions as z };
package/dist/public.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- import { $ as R2Binding, A as triggers, B as D1Binding, C as exports, D as QueueConsumerTrigger, E as FetchTrigger, F as AnalyticsEngineDatasetBinding, G as ImagesBinding, H as DurableObjectBinding, I as ArtifactsBinding, J as LogfwdrBinding, K as JsonBinding, L as AssetsBinding, M as AiBinding, N as AiSearchBinding, O as ScheduledTrigger, P as AiSearchNamespaceBinding, Q as QueueBinding, R as Bindings, S as WorkerEntrypointExportOptions, St as bindings, T as EmailTrigger, U as FlagshipBinding, V as DispatchNamespaceBinding, W as HyperdriveBinding, X as MtlsCertificateBinding, Y as MediaBinding, Z as PipelineBinding, _ as DurableObjectExpectingTransferExport, _t as VpcServiceBinding, a as InferMainModule, at as TextBinding, b as Exports, bt as WorkerLoaderBinding, c as WorkerConfigExport, ct as TypedKvBinding, d as SettingsConfig, dt as TypedWorkerBinding, et as RateLimitBinding, f as WorkerConfig, ft as TypedWorkflowBinding, g as DurableObjectDeletedExport, gt as VpcNetworkBinding, h as DurableObjectCreatedExport, ht as VersionMetadataBinding, i as InferEnv, it as StreamBinding, j as AgentMemoryBinding, k as Triggers, l as WorkerConfigInput, lt as TypedPipelineBinding, mt as VectorizeBinding, n as defineSettings, nt as SecretsStoreSecretBinding, o as UnwrapConfig, ot as TypedAiBinding, p as ConfigContext, pt as UnsafeBinding, q as KvBinding, r as InferDurableNamespaces, rt as SendEmailBinding, s as TypedWorkerDefinition, st as TypedDurableObjectBinding, t as SettingsConfigInput, tt as SecretBinding, u as defineWorker, ut as TypedQueueBinding, v as DurableObjectRenamedExport, vt as WebSearchBinding, w as ConnectTrigger, x as WorkerEntrypointExport, xt as WorkflowBinding, y as DurableObjectTransferredExport, yt as WorkerBinding, z as BrowserBinding } from "./public-CCrtkZee.mjs";
2
- export { AgentMemoryBinding, AiBinding, AiSearchBinding, AiSearchNamespaceBinding, AnalyticsEngineDatasetBinding, ArtifactsBinding, AssetsBinding, Bindings, BrowserBinding, ConfigContext, ConnectTrigger, D1Binding, DispatchNamespaceBinding, DurableObjectBinding, DurableObjectCreatedExport, DurableObjectDeletedExport, DurableObjectExpectingTransferExport, DurableObjectRenamedExport, DurableObjectTransferredExport, EmailTrigger, Exports, FetchTrigger, FlagshipBinding, HyperdriveBinding, ImagesBinding, InferDurableNamespaces, InferEnv, InferMainModule, JsonBinding, KvBinding, LogfwdrBinding, MediaBinding, MtlsCertificateBinding, PipelineBinding, QueueBinding, QueueConsumerTrigger, R2Binding, RateLimitBinding, ScheduledTrigger, SecretBinding, SecretsStoreSecretBinding, SendEmailBinding, SettingsConfig, SettingsConfigInput, StreamBinding, TextBinding, Triggers, TypedAiBinding, TypedDurableObjectBinding, TypedKvBinding, TypedPipelineBinding, TypedQueueBinding, TypedWorkerBinding, TypedWorkerDefinition, TypedWorkflowBinding, UnsafeBinding, UnwrapConfig, VectorizeBinding, VersionMetadataBinding, VpcNetworkBinding, VpcServiceBinding, WebSearchBinding, WorkerBinding, WorkerConfig, WorkerConfigExport, WorkerConfigInput, WorkerEntrypointExport, WorkerEntrypointExportOptions, WorkerLoaderBinding, WorkflowBinding, bindings, defineSettings, defineWorker, exports, triggers };
1
+ import { $ as PipelineBinding, A as Triggers, B as Bindings, C as WorkerEntrypointExportOptions, Ct as WorkflowBinding, D as FetchTrigger, E as EmailTrigger, F as AiSearchNamespaceBinding, G as FlagshipBinding, H as D1Binding, I as AnalyticsEngineDatasetBinding, J as JsonBinding, K as HyperdriveBinding, L as ArtifactsBinding, M as AgentMemoryBinding, N as AiBinding, O as QueueConsumerTrigger, P as AiSearchBinding, Q as MtlsCertificateBinding, R as AssetsBinding, S as WorkerEntrypointExport, St as WorkerLoaderBinding, T as ConnectTrigger, U as DispatchNamespaceBinding, V as BrowserBinding, W as DurableObjectBinding, X as LogfwdrBinding, Y as KvBinding, Z as MediaBinding, _ as DurableObjectDeletedExport, _t as VersionMetadataBinding, a as InferEnv, at as SendEmailBinding, b as DurableObjectTransferredExport, bt as WebSearchBinding, c as TypedWorkerDefinition, ct as TypedAiBinding, d as defineWorker, dt as TypedPipelineBinding, et as QueueBinding, f as SettingsConfig, ft as TypedQueueBinding, g as DurableObjectCreatedExport, gt as VectorizeBinding, ht as UnsafeBinding, i as InferDurableNamespaces, it as SecretsStoreSecretBinding, j as triggers, k as ScheduledTrigger, l as WorkerConfigExport, lt as TypedDurableObjectBinding, m as ConfigContext, mt as TypedWorkflowBinding, n as SettingsDefinition, nt as RateLimitBinding, o as InferMainModule, ot as StreamBinding, p as WorkerConfig, pt as TypedWorkerBinding, q as ImagesBinding, r as defineSettings, rt as SecretBinding, s as UnwrapConfig, st as TextBinding, t as SettingsConfigInput, tt as R2Binding, u as WorkerConfigInput, ut as TypedKvBinding, v as DurableObjectExpectingTransferExport, vt as VpcNetworkBinding, w as exports, wt as bindings, x as Exports, xt as WorkerBinding, y as DurableObjectRenamedExport, yt as VpcServiceBinding, z as BindingDevOptions } from "./public-C3uXDKsB.mjs";
2
+ export { AgentMemoryBinding, AiBinding, AiSearchBinding, AiSearchNamespaceBinding, AnalyticsEngineDatasetBinding, ArtifactsBinding, AssetsBinding, BindingDevOptions, Bindings, BrowserBinding, ConfigContext, ConnectTrigger, D1Binding, DispatchNamespaceBinding, DurableObjectBinding, DurableObjectCreatedExport, DurableObjectDeletedExport, DurableObjectExpectingTransferExport, DurableObjectRenamedExport, DurableObjectTransferredExport, EmailTrigger, Exports, FetchTrigger, FlagshipBinding, HyperdriveBinding, ImagesBinding, InferDurableNamespaces, InferEnv, InferMainModule, JsonBinding, KvBinding, LogfwdrBinding, MediaBinding, MtlsCertificateBinding, PipelineBinding, QueueBinding, QueueConsumerTrigger, R2Binding, RateLimitBinding, ScheduledTrigger, SecretBinding, SecretsStoreSecretBinding, SendEmailBinding, SettingsConfig, SettingsConfigInput, SettingsDefinition, StreamBinding, TextBinding, Triggers, TypedAiBinding, TypedDurableObjectBinding, TypedKvBinding, TypedPipelineBinding, TypedQueueBinding, TypedWorkerBinding, TypedWorkerDefinition, TypedWorkflowBinding, UnsafeBinding, UnwrapConfig, VectorizeBinding, VersionMetadataBinding, VpcNetworkBinding, VpcServiceBinding, WebSearchBinding, WorkerBinding, WorkerConfig, WorkerConfigExport, WorkerConfigInput, WorkerEntrypointExport, WorkerEntrypointExportOptions, WorkerLoaderBinding, WorkflowBinding, bindings, defineSettings, defineWorker, exports, triggers };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloudflare/config",
3
- "version": "0.7.0",
3
+ "version": "0.8.0",
4
4
  "description": "Definitions and utilities for configuring Cloudflare Workers and related products. This is not yet stable enough for external use — APIs may change without notice.",
5
5
  "homepage": "https://github.com/cloudflare/workers-sdk/tree/main/packages/config#readme",
6
6
  "bugs": {
@@ -31,7 +31,7 @@
31
31
  "zod": "4.4.3"
32
32
  },
33
33
  "devDependencies": {
34
- "@cloudflare/workers-types": "^5.20260820.1",
34
+ "@cloudflare/workers-types": "^5.20260825.1",
35
35
  "ts-dedent": "^2.2.0",
36
36
  "tsdown": "0.16.3",
37
37
  "typescript": "5.8.3",