@uniformdev/mesh-edgehancer-sdk 20.32.1-alpha.4 → 20.32.2-alpha.2

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.esm.js CHANGED
@@ -1,86 +1,3 @@
1
- // ../../lib/ai-sdk/src/InvocationContexts.ts
2
- import { z } from "zod";
3
- var invocationContextsSchema = z.enum([
4
- "composition",
5
- "compositionPattern",
6
- "componentPattern",
7
- "entry",
8
- "entryPattern",
9
- "general"
10
- ]);
11
- var invocationContextInfoSchema = z.object({
12
- context: invocationContextsSchema,
13
- id: z.string(),
14
- displayName: z.string().optional(),
15
- icon: z.string().optional()
16
- });
17
- var invocationContextAnnotationSchema = z.object({
18
- type: z.literal("invocationContext"),
19
- value: invocationContextInfoSchema
20
- });
21
-
22
- // ../../lib/ai-sdk/src/toolDefinitions/editing/createPropertyEdit.ts
23
- import { z as z2 } from "zod";
24
- var createPropertyEdit = {
25
- displayName: "Create Property Edit",
26
- description: "Edits a property on a composition, entry, or pattern with AI. This is a callable tool NOT FOR AGENT USE - agents use applyPropertyEdit to broker client-side application of the edit.",
27
- inputSchema: z2.object({
28
- edit: z2.string().describe("Describe the edit to be made to the property"),
29
- currentValue: z2.unknown().describe("Current value of the property (if any exists)").optional(),
30
- projectGuidance: z2.string().describe("Guidance prompt for the project (if any exists)").optional(),
31
- componentGuidance: z2.string().describe("Guidance prompt for the parent component").optional(),
32
- audienceGuidance: z2.string().describe(
33
- "Guidance prompt for the target audience of a personalized variation. Omit for non-variation edits."
34
- ).optional(),
35
- propertyDefinition: z2.object({
36
- id: z2.string(),
37
- name: z2.string(),
38
- type: z2.string(),
39
- guidance: z2.string().describe("Guidance prompt from the property definition (if any exists)").optional(),
40
- typeConfig: z2.unknown().optional().describe("Type-specific configuration for the property")
41
- }),
42
- outputLocale: z2.string().optional().describe("The locale to use when writing the edited value"),
43
- documentContext: z2.string().describe("Content of the surrounding document the property is part of").optional()
44
- }),
45
- outputSchema: z2.object({
46
- newValue: z2.string().describe(
47
- "The new value of the property. When the action is clear or resetOverride, this should be empty."
48
- ),
49
- treatNewValueAsJson: z2.boolean().describe("Whether the newValue is a JSON string"),
50
- summary: z2.string().describe(
51
- "A completion message to the user that summarizes the action taken. This should be 1 sentence, in English."
52
- ).optional(),
53
- action: z2.enum(["setValue", "clearValue", "resetOverride"]).describe(
54
- "setValue = update the value, clearValue = remove the value/set to empty, resetOverride = remove a pattern override and inherit the pattern value. Only use resetOverride if the prompt asks for it."
55
- ),
56
- success: z2.boolean().describe("Whether the edit could be completed successfully")
57
- }),
58
- runsAt: "server",
59
- timeout: 100,
60
- callable: true
61
- };
62
-
63
- // src/afterAIEdit.ts
64
- import { z as z3 } from "zod";
65
- var afterAIEditResultSchema = z3.strictObject({
66
- newValue: z3.unknown(),
67
- success: z3.boolean(),
68
- summary: z3.string().optional()
69
- });
70
- var afterAIEditContextSchema = z3.strictObject({
71
- editRequest: createPropertyEdit.inputSchema,
72
- invocationContext: invocationContextsSchema,
73
- userId: z3.string(),
74
- currentLocale: z3.string().optional(),
75
- projectId: z3.string(),
76
- currentValue: z3.unknown().optional(),
77
- newValue: z3.unknown(),
78
- result: z3.object({
79
- success: z3.boolean(),
80
- summary: z3.string().optional()
81
- })
82
- });
83
-
84
1
  // src/batchUtils.ts
85
2
  function convertBatchResultsToEdgehancerResult({
86
3
  batch,
@@ -140,22 +57,6 @@ var COLLECTION_DEFAULT_LIMIT = 20;
140
57
  var COLLECTION_MAX_LIMIT = 50;
141
58
  var COLLECTION_DEFAULT_OFFSET = 0;
142
59
 
143
- // src/createAIEdit.ts
144
- import { z as z4 } from "zod";
145
- var createAIEditContextSchema = z4.strictObject({
146
- editRequest: createPropertyEdit.inputSchema,
147
- invocationContext: invocationContextsSchema,
148
- userId: z4.string(),
149
- currentLocale: z4.string().optional(),
150
- projectId: z4.string()
151
- });
152
- var createAIEditResultSchema = z4.strictObject({
153
- outputJsonSchema: z4.record(z4.string(), z4.any()).describe("JSON schema (draft-07) for the edited content result"),
154
- instructions: z4.string().describe(
155
- "Instructions for the AI editor LLM to follow (e.g. conventions/rules, allowed values, etc). Just describe your value type, do not give guiding instructions. There is no need to worry about clearing or resetting values, that is automatically handled."
156
- )
157
- });
158
-
159
60
  // src/fetchUtils.ts
160
61
  function getDataResourceAsRequest(data) {
161
62
  var _a;
@@ -195,78 +96,78 @@ function copyKeyValuePairs(source, target) {
195
96
  }
196
97
 
197
98
  // src/preRequest.ts
198
- import { z as z6 } from "zod";
99
+ import { z as z2 } from "zod";
199
100
 
200
101
  // src/shared.ts
201
102
  import { assert } from "tsafe";
202
- import { z as z5 } from "zod";
203
- var parameterDefinitionSchema = z5.object({
204
- key: z5.string(),
205
- value: z5.string(),
206
- omitIfEmpty: z5.boolean().optional()
103
+ import { z } from "zod";
104
+ var parameterDefinitionSchema = z.object({
105
+ key: z.string(),
106
+ value: z.string(),
107
+ omitIfEmpty: z.boolean().optional()
207
108
  });
208
- var resolvingIssueSchema = z5.union([
209
- z5.string(),
210
- z5.object({
211
- message: z5.string(),
212
- subType: z5.enum(["unpublishedData", "configuration"]).optional(),
213
- issueReference: z5.string().optional(),
214
- deepLink: z5.string().optional()
109
+ var resolvingIssueSchema = z.union([
110
+ z.string(),
111
+ z.object({
112
+ message: z.string(),
113
+ subType: z.enum(["unpublishedData", "configuration"]).optional(),
114
+ issueReference: z.string().optional(),
115
+ deepLink: z.string().optional()
215
116
  })
216
117
  ]);
217
- var variableDefinitionSchema = z5.object({
218
- displayName: z5.string().optional(),
219
- type: z5.string().optional(),
220
- default: z5.string(),
221
- helpText: z5.string().optional(),
222
- order: z5.number().optional(),
223
- source: z5.string().optional()
118
+ var variableDefinitionSchema = z.object({
119
+ displayName: z.string().optional(),
120
+ type: z.string().optional(),
121
+ default: z.string(),
122
+ helpText: z.string().optional(),
123
+ order: z.number().optional(),
124
+ source: z.string().optional()
224
125
  });
225
- var customEdgehancerDefinitionSchema = z5.object({
226
- preRequest: z5.string().optional(),
227
- request: z5.string().optional()
126
+ var customEdgehancerDefinitionSchema = z.object({
127
+ preRequest: z.string().optional(),
128
+ request: z.string().optional()
228
129
  });
229
- var dataSourceVariantSchema = z5.intersection(
230
- z5.object({
231
- headers: z5.array(parameterDefinitionSchema).optional(),
232
- parameters: z5.array(parameterDefinitionSchema).optional(),
233
- variables: z5.record(variableDefinitionSchema).optional()
130
+ var dataSourceVariantSchema = z.intersection(
131
+ z.object({
132
+ headers: z.array(parameterDefinitionSchema).optional(),
133
+ parameters: z.array(parameterDefinitionSchema).optional(),
134
+ variables: z.record(variableDefinitionSchema).optional()
234
135
  }),
235
- z5.object({ url: z5.string() })
136
+ z.object({ url: z.string() })
236
137
  );
237
- var mergedDataTypeSchema = z5.object({
238
- id: z5.string(),
239
- displayName: z5.string(),
240
- archetype: z5.string().optional(),
241
- allowedOnComponents: z5.array(z5.string()).optional(),
242
- badgeIconUrl: z5.string().optional(),
243
- connectorType: z5.string(),
244
- url: z5.string(),
245
- headers: z5.array(parameterDefinitionSchema).optional(),
246
- parameters: z5.array(parameterDefinitionSchema).optional(),
247
- body: z5.string().optional(),
248
- method: z5.enum(["GET", "POST", "HEAD"]),
249
- variables: z5.record(variableDefinitionSchema).optional(),
250
- custom: z5.record(z5.unknown()).optional(),
251
- customPublic: z5.record(z5.unknown()).optional(),
252
- ttl: z5.number().optional(),
253
- purgeKey: z5.string().optional(),
254
- localeMapping: z5.record(z5.string()).optional(),
138
+ var mergedDataTypeSchema = z.object({
139
+ id: z.string(),
140
+ displayName: z.string(),
141
+ archetype: z.string().optional(),
142
+ allowedOnComponents: z.array(z.string()).optional(),
143
+ badgeIconUrl: z.string().optional(),
144
+ connectorType: z.string(),
145
+ url: z.string(),
146
+ headers: z.array(parameterDefinitionSchema).optional(),
147
+ parameters: z.array(parameterDefinitionSchema).optional(),
148
+ body: z.string().optional(),
149
+ method: z.enum(["GET", "POST", "HEAD"]),
150
+ variables: z.record(variableDefinitionSchema).optional(),
151
+ custom: z.record(z.unknown()).optional(),
152
+ customPublic: z.record(z.unknown()).optional(),
153
+ ttl: z.number().optional(),
154
+ purgeKey: z.string().optional(),
155
+ localeMapping: z.record(z.string()).optional(),
255
156
  edgehancer: customEdgehancerDefinitionSchema.optional(),
256
- uiBadgeText: z5.string().max(12).optional(),
257
- variants: z5.object({
157
+ uiBadgeText: z.string().max(12).optional(),
158
+ variants: z.object({
258
159
  unpublished: dataSourceVariantSchema.optional()
259
160
  }).optional(),
260
- enableUnpublishedMode: z5.boolean().optional()
161
+ enableUnpublishedMode: z.boolean().optional()
261
162
  });
262
163
  assert();
263
- var dataResourceSchema = z5.union([
264
- z5.string(),
265
- z5.object({}).catchall(z5.unknown()),
266
- z5.number(),
267
- z5.boolean(),
268
- z5.array(z5.unknown()),
269
- z5.undefined()
164
+ var dataResourceSchema = z.union([
165
+ z.string(),
166
+ z.object({}).catchall(z.unknown()),
167
+ z.number(),
168
+ z.boolean(),
169
+ z.array(z.unknown()),
170
+ z.undefined()
270
171
  ]);
271
172
 
272
173
  // src/preRequest.ts
@@ -279,43 +180,39 @@ var edgehancerMergedDataTypeSchema = mergedDataTypeSchema.omit({
279
180
  purgeKey: true,
280
181
  variables: true
281
182
  });
282
- var preRequestEdgehancerDataResourceResultSchema = z6.strictObject({
283
- errors: z6.array(resolvingIssueSchema).optional(),
284
- warnings: z6.array(resolvingIssueSchema).optional(),
285
- infos: z6.array(resolvingIssueSchema).optional(),
183
+ var preRequestEdgehancerDataResourceResultSchema = z2.strictObject({
184
+ errors: z2.array(resolvingIssueSchema).optional(),
185
+ warnings: z2.array(resolvingIssueSchema).optional(),
186
+ infos: z2.array(resolvingIssueSchema).optional(),
286
187
  dataResource: edgehancerMergedDataTypeSchema
287
188
  });
288
- var preRequestEdgehancerResultSchema = z6.strictObject({
289
- dataResources: z6.array(preRequestEdgehancerDataResourceResultSchema)
189
+ var preRequestEdgehancerResultSchema = z2.strictObject({
190
+ dataResources: z2.array(preRequestEdgehancerDataResourceResultSchema)
290
191
  });
291
192
 
292
193
  // src/request.ts
293
- import { z as z7 } from "zod";
294
- var requestEdgehancerDataResourceResolutionResultSchema = z7.strictObject({
295
- errors: z7.array(resolvingIssueSchema).optional().describe(
194
+ import { z as z3 } from "zod";
195
+ var requestEdgehancerDataResourceResolutionResultSchema = z3.strictObject({
196
+ errors: z3.array(resolvingIssueSchema).optional().describe(
296
197
  "Errors that occurred while running your code to return with the API response, if any. Unhandled exceptions will be captured automatically."
297
198
  ),
298
- warnings: z7.array(resolvingIssueSchema).optional().describe("Warnings that occurred while running your code to return with the API response, if any."),
299
- infos: z7.array(resolvingIssueSchema).optional().describe(
199
+ warnings: z3.array(resolvingIssueSchema).optional().describe("Warnings that occurred while running your code to return with the API response, if any."),
200
+ infos: z3.array(resolvingIssueSchema).optional().describe(
300
201
  "Informational messages that occurred while running your code to return with the API response, if any."
301
202
  ),
302
- surrogateKeys: z7.array(z7.string()).optional().describe(
203
+ surrogateKeys: z3.array(z3.string()).optional().describe(
303
204
  "Extra surrogate keys for the data that was fetched. These act as auxiliary cache keys that can allow granular purging of cached data."
304
205
  ),
305
206
  result: dataResourceSchema.describe("The result of fetching the data resource")
306
207
  });
307
- var requestEdgehancerResultSchema = z7.strictObject({
308
- results: z7.array(requestEdgehancerDataResourceResolutionResultSchema)
208
+ var requestEdgehancerResultSchema = z3.strictObject({
209
+ results: z3.array(requestEdgehancerDataResourceResolutionResultSchema)
309
210
  });
310
211
  export {
311
212
  COLLECTION_DEFAULT_LIMIT,
312
213
  COLLECTION_DEFAULT_OFFSET,
313
214
  COLLECTION_MAX_LIMIT,
314
- afterAIEditContextSchema,
315
- afterAIEditResultSchema,
316
215
  convertBatchResultsToEdgehancerResult,
317
- createAIEditContextSchema,
318
- createAIEditResultSchema,
319
216
  dataResourceSchema,
320
217
  edgehancerMergedDataTypeSchema,
321
218
  getDataResourceAsRequest,
package/dist/index.js CHANGED
@@ -23,11 +23,7 @@ __export(src_exports, {
23
23
  COLLECTION_DEFAULT_LIMIT: () => COLLECTION_DEFAULT_LIMIT,
24
24
  COLLECTION_DEFAULT_OFFSET: () => COLLECTION_DEFAULT_OFFSET,
25
25
  COLLECTION_MAX_LIMIT: () => COLLECTION_MAX_LIMIT,
26
- afterAIEditContextSchema: () => afterAIEditContextSchema,
27
- afterAIEditResultSchema: () => afterAIEditResultSchema,
28
26
  convertBatchResultsToEdgehancerResult: () => convertBatchResultsToEdgehancerResult,
29
- createAIEditContextSchema: () => createAIEditContextSchema,
30
- createAIEditResultSchema: () => createAIEditResultSchema,
31
27
  dataResourceSchema: () => dataResourceSchema,
32
28
  edgehancerMergedDataTypeSchema: () => edgehancerMergedDataTypeSchema,
33
29
  getDataResourceAsRequest: () => getDataResourceAsRequest,
@@ -44,89 +40,6 @@ __export(src_exports, {
44
40
  });
45
41
  module.exports = __toCommonJS(src_exports);
46
42
 
47
- // ../../lib/ai-sdk/src/InvocationContexts.ts
48
- var import_zod = require("zod");
49
- var invocationContextsSchema = import_zod.z.enum([
50
- "composition",
51
- "compositionPattern",
52
- "componentPattern",
53
- "entry",
54
- "entryPattern",
55
- "general"
56
- ]);
57
- var invocationContextInfoSchema = import_zod.z.object({
58
- context: invocationContextsSchema,
59
- id: import_zod.z.string(),
60
- displayName: import_zod.z.string().optional(),
61
- icon: import_zod.z.string().optional()
62
- });
63
- var invocationContextAnnotationSchema = import_zod.z.object({
64
- type: import_zod.z.literal("invocationContext"),
65
- value: invocationContextInfoSchema
66
- });
67
-
68
- // ../../lib/ai-sdk/src/toolDefinitions/editing/createPropertyEdit.ts
69
- var import_zod2 = require("zod");
70
- var createPropertyEdit = {
71
- displayName: "Create Property Edit",
72
- description: "Edits a property on a composition, entry, or pattern with AI. This is a callable tool NOT FOR AGENT USE - agents use applyPropertyEdit to broker client-side application of the edit.",
73
- inputSchema: import_zod2.z.object({
74
- edit: import_zod2.z.string().describe("Describe the edit to be made to the property"),
75
- currentValue: import_zod2.z.unknown().describe("Current value of the property (if any exists)").optional(),
76
- projectGuidance: import_zod2.z.string().describe("Guidance prompt for the project (if any exists)").optional(),
77
- componentGuidance: import_zod2.z.string().describe("Guidance prompt for the parent component").optional(),
78
- audienceGuidance: import_zod2.z.string().describe(
79
- "Guidance prompt for the target audience of a personalized variation. Omit for non-variation edits."
80
- ).optional(),
81
- propertyDefinition: import_zod2.z.object({
82
- id: import_zod2.z.string(),
83
- name: import_zod2.z.string(),
84
- type: import_zod2.z.string(),
85
- guidance: import_zod2.z.string().describe("Guidance prompt from the property definition (if any exists)").optional(),
86
- typeConfig: import_zod2.z.unknown().optional().describe("Type-specific configuration for the property")
87
- }),
88
- outputLocale: import_zod2.z.string().optional().describe("The locale to use when writing the edited value"),
89
- documentContext: import_zod2.z.string().describe("Content of the surrounding document the property is part of").optional()
90
- }),
91
- outputSchema: import_zod2.z.object({
92
- newValue: import_zod2.z.string().describe(
93
- "The new value of the property. When the action is clear or resetOverride, this should be empty."
94
- ),
95
- treatNewValueAsJson: import_zod2.z.boolean().describe("Whether the newValue is a JSON string"),
96
- summary: import_zod2.z.string().describe(
97
- "A completion message to the user that summarizes the action taken. This should be 1 sentence, in English."
98
- ).optional(),
99
- action: import_zod2.z.enum(["setValue", "clearValue", "resetOverride"]).describe(
100
- "setValue = update the value, clearValue = remove the value/set to empty, resetOverride = remove a pattern override and inherit the pattern value. Only use resetOverride if the prompt asks for it."
101
- ),
102
- success: import_zod2.z.boolean().describe("Whether the edit could be completed successfully")
103
- }),
104
- runsAt: "server",
105
- timeout: 100,
106
- callable: true
107
- };
108
-
109
- // src/afterAIEdit.ts
110
- var import_zod3 = require("zod");
111
- var afterAIEditResultSchema = import_zod3.z.strictObject({
112
- newValue: import_zod3.z.unknown(),
113
- success: import_zod3.z.boolean(),
114
- summary: import_zod3.z.string().optional()
115
- });
116
- var afterAIEditContextSchema = import_zod3.z.strictObject({
117
- editRequest: createPropertyEdit.inputSchema,
118
- invocationContext: invocationContextsSchema,
119
- userId: import_zod3.z.string(),
120
- currentLocale: import_zod3.z.string().optional(),
121
- projectId: import_zod3.z.string(),
122
- currentValue: import_zod3.z.unknown().optional(),
123
- newValue: import_zod3.z.unknown(),
124
- result: import_zod3.z.object({
125
- success: import_zod3.z.boolean(),
126
- summary: import_zod3.z.string().optional()
127
- })
128
- });
129
-
130
43
  // src/batchUtils.ts
131
44
  function convertBatchResultsToEdgehancerResult({
132
45
  batch,
@@ -186,22 +99,6 @@ var COLLECTION_DEFAULT_LIMIT = 20;
186
99
  var COLLECTION_MAX_LIMIT = 50;
187
100
  var COLLECTION_DEFAULT_OFFSET = 0;
188
101
 
189
- // src/createAIEdit.ts
190
- var import_zod4 = require("zod");
191
- var createAIEditContextSchema = import_zod4.z.strictObject({
192
- editRequest: createPropertyEdit.inputSchema,
193
- invocationContext: invocationContextsSchema,
194
- userId: import_zod4.z.string(),
195
- currentLocale: import_zod4.z.string().optional(),
196
- projectId: import_zod4.z.string()
197
- });
198
- var createAIEditResultSchema = import_zod4.z.strictObject({
199
- outputJsonSchema: import_zod4.z.record(import_zod4.z.string(), import_zod4.z.any()).describe("JSON schema (draft-07) for the edited content result"),
200
- instructions: import_zod4.z.string().describe(
201
- "Instructions for the AI editor LLM to follow (e.g. conventions/rules, allowed values, etc). Just describe your value type, do not give guiding instructions. There is no need to worry about clearing or resetting values, that is automatically handled."
202
- )
203
- });
204
-
205
102
  // src/fetchUtils.ts
206
103
  function getDataResourceAsRequest(data) {
207
104
  var _a;
@@ -241,78 +138,78 @@ function copyKeyValuePairs(source, target) {
241
138
  }
242
139
 
243
140
  // src/preRequest.ts
244
- var import_zod6 = require("zod");
141
+ var import_zod2 = require("zod");
245
142
 
246
143
  // src/shared.ts
247
144
  var import_tsafe = require("tsafe");
248
- var import_zod5 = require("zod");
249
- var parameterDefinitionSchema = import_zod5.z.object({
250
- key: import_zod5.z.string(),
251
- value: import_zod5.z.string(),
252
- omitIfEmpty: import_zod5.z.boolean().optional()
145
+ var import_zod = require("zod");
146
+ var parameterDefinitionSchema = import_zod.z.object({
147
+ key: import_zod.z.string(),
148
+ value: import_zod.z.string(),
149
+ omitIfEmpty: import_zod.z.boolean().optional()
253
150
  });
254
- var resolvingIssueSchema = import_zod5.z.union([
255
- import_zod5.z.string(),
256
- import_zod5.z.object({
257
- message: import_zod5.z.string(),
258
- subType: import_zod5.z.enum(["unpublishedData", "configuration"]).optional(),
259
- issueReference: import_zod5.z.string().optional(),
260
- deepLink: import_zod5.z.string().optional()
151
+ var resolvingIssueSchema = import_zod.z.union([
152
+ import_zod.z.string(),
153
+ import_zod.z.object({
154
+ message: import_zod.z.string(),
155
+ subType: import_zod.z.enum(["unpublishedData", "configuration"]).optional(),
156
+ issueReference: import_zod.z.string().optional(),
157
+ deepLink: import_zod.z.string().optional()
261
158
  })
262
159
  ]);
263
- var variableDefinitionSchema = import_zod5.z.object({
264
- displayName: import_zod5.z.string().optional(),
265
- type: import_zod5.z.string().optional(),
266
- default: import_zod5.z.string(),
267
- helpText: import_zod5.z.string().optional(),
268
- order: import_zod5.z.number().optional(),
269
- source: import_zod5.z.string().optional()
160
+ var variableDefinitionSchema = import_zod.z.object({
161
+ displayName: import_zod.z.string().optional(),
162
+ type: import_zod.z.string().optional(),
163
+ default: import_zod.z.string(),
164
+ helpText: import_zod.z.string().optional(),
165
+ order: import_zod.z.number().optional(),
166
+ source: import_zod.z.string().optional()
270
167
  });
271
- var customEdgehancerDefinitionSchema = import_zod5.z.object({
272
- preRequest: import_zod5.z.string().optional(),
273
- request: import_zod5.z.string().optional()
168
+ var customEdgehancerDefinitionSchema = import_zod.z.object({
169
+ preRequest: import_zod.z.string().optional(),
170
+ request: import_zod.z.string().optional()
274
171
  });
275
- var dataSourceVariantSchema = import_zod5.z.intersection(
276
- import_zod5.z.object({
277
- headers: import_zod5.z.array(parameterDefinitionSchema).optional(),
278
- parameters: import_zod5.z.array(parameterDefinitionSchema).optional(),
279
- variables: import_zod5.z.record(variableDefinitionSchema).optional()
172
+ var dataSourceVariantSchema = import_zod.z.intersection(
173
+ import_zod.z.object({
174
+ headers: import_zod.z.array(parameterDefinitionSchema).optional(),
175
+ parameters: import_zod.z.array(parameterDefinitionSchema).optional(),
176
+ variables: import_zod.z.record(variableDefinitionSchema).optional()
280
177
  }),
281
- import_zod5.z.object({ url: import_zod5.z.string() })
178
+ import_zod.z.object({ url: import_zod.z.string() })
282
179
  );
283
- var mergedDataTypeSchema = import_zod5.z.object({
284
- id: import_zod5.z.string(),
285
- displayName: import_zod5.z.string(),
286
- archetype: import_zod5.z.string().optional(),
287
- allowedOnComponents: import_zod5.z.array(import_zod5.z.string()).optional(),
288
- badgeIconUrl: import_zod5.z.string().optional(),
289
- connectorType: import_zod5.z.string(),
290
- url: import_zod5.z.string(),
291
- headers: import_zod5.z.array(parameterDefinitionSchema).optional(),
292
- parameters: import_zod5.z.array(parameterDefinitionSchema).optional(),
293
- body: import_zod5.z.string().optional(),
294
- method: import_zod5.z.enum(["GET", "POST", "HEAD"]),
295
- variables: import_zod5.z.record(variableDefinitionSchema).optional(),
296
- custom: import_zod5.z.record(import_zod5.z.unknown()).optional(),
297
- customPublic: import_zod5.z.record(import_zod5.z.unknown()).optional(),
298
- ttl: import_zod5.z.number().optional(),
299
- purgeKey: import_zod5.z.string().optional(),
300
- localeMapping: import_zod5.z.record(import_zod5.z.string()).optional(),
180
+ var mergedDataTypeSchema = import_zod.z.object({
181
+ id: import_zod.z.string(),
182
+ displayName: import_zod.z.string(),
183
+ archetype: import_zod.z.string().optional(),
184
+ allowedOnComponents: import_zod.z.array(import_zod.z.string()).optional(),
185
+ badgeIconUrl: import_zod.z.string().optional(),
186
+ connectorType: import_zod.z.string(),
187
+ url: import_zod.z.string(),
188
+ headers: import_zod.z.array(parameterDefinitionSchema).optional(),
189
+ parameters: import_zod.z.array(parameterDefinitionSchema).optional(),
190
+ body: import_zod.z.string().optional(),
191
+ method: import_zod.z.enum(["GET", "POST", "HEAD"]),
192
+ variables: import_zod.z.record(variableDefinitionSchema).optional(),
193
+ custom: import_zod.z.record(import_zod.z.unknown()).optional(),
194
+ customPublic: import_zod.z.record(import_zod.z.unknown()).optional(),
195
+ ttl: import_zod.z.number().optional(),
196
+ purgeKey: import_zod.z.string().optional(),
197
+ localeMapping: import_zod.z.record(import_zod.z.string()).optional(),
301
198
  edgehancer: customEdgehancerDefinitionSchema.optional(),
302
- uiBadgeText: import_zod5.z.string().max(12).optional(),
303
- variants: import_zod5.z.object({
199
+ uiBadgeText: import_zod.z.string().max(12).optional(),
200
+ variants: import_zod.z.object({
304
201
  unpublished: dataSourceVariantSchema.optional()
305
202
  }).optional(),
306
- enableUnpublishedMode: import_zod5.z.boolean().optional()
203
+ enableUnpublishedMode: import_zod.z.boolean().optional()
307
204
  });
308
205
  (0, import_tsafe.assert)();
309
- var dataResourceSchema = import_zod5.z.union([
310
- import_zod5.z.string(),
311
- import_zod5.z.object({}).catchall(import_zod5.z.unknown()),
312
- import_zod5.z.number(),
313
- import_zod5.z.boolean(),
314
- import_zod5.z.array(import_zod5.z.unknown()),
315
- import_zod5.z.undefined()
206
+ var dataResourceSchema = import_zod.z.union([
207
+ import_zod.z.string(),
208
+ import_zod.z.object({}).catchall(import_zod.z.unknown()),
209
+ import_zod.z.number(),
210
+ import_zod.z.boolean(),
211
+ import_zod.z.array(import_zod.z.unknown()),
212
+ import_zod.z.undefined()
316
213
  ]);
317
214
 
318
215
  // src/preRequest.ts
@@ -325,44 +222,40 @@ var edgehancerMergedDataTypeSchema = mergedDataTypeSchema.omit({
325
222
  purgeKey: true,
326
223
  variables: true
327
224
  });
328
- var preRequestEdgehancerDataResourceResultSchema = import_zod6.z.strictObject({
329
- errors: import_zod6.z.array(resolvingIssueSchema).optional(),
330
- warnings: import_zod6.z.array(resolvingIssueSchema).optional(),
331
- infos: import_zod6.z.array(resolvingIssueSchema).optional(),
225
+ var preRequestEdgehancerDataResourceResultSchema = import_zod2.z.strictObject({
226
+ errors: import_zod2.z.array(resolvingIssueSchema).optional(),
227
+ warnings: import_zod2.z.array(resolvingIssueSchema).optional(),
228
+ infos: import_zod2.z.array(resolvingIssueSchema).optional(),
332
229
  dataResource: edgehancerMergedDataTypeSchema
333
230
  });
334
- var preRequestEdgehancerResultSchema = import_zod6.z.strictObject({
335
- dataResources: import_zod6.z.array(preRequestEdgehancerDataResourceResultSchema)
231
+ var preRequestEdgehancerResultSchema = import_zod2.z.strictObject({
232
+ dataResources: import_zod2.z.array(preRequestEdgehancerDataResourceResultSchema)
336
233
  });
337
234
 
338
235
  // src/request.ts
339
- var import_zod7 = require("zod");
340
- var requestEdgehancerDataResourceResolutionResultSchema = import_zod7.z.strictObject({
341
- errors: import_zod7.z.array(resolvingIssueSchema).optional().describe(
236
+ var import_zod3 = require("zod");
237
+ var requestEdgehancerDataResourceResolutionResultSchema = import_zod3.z.strictObject({
238
+ errors: import_zod3.z.array(resolvingIssueSchema).optional().describe(
342
239
  "Errors that occurred while running your code to return with the API response, if any. Unhandled exceptions will be captured automatically."
343
240
  ),
344
- warnings: import_zod7.z.array(resolvingIssueSchema).optional().describe("Warnings that occurred while running your code to return with the API response, if any."),
345
- infos: import_zod7.z.array(resolvingIssueSchema).optional().describe(
241
+ warnings: import_zod3.z.array(resolvingIssueSchema).optional().describe("Warnings that occurred while running your code to return with the API response, if any."),
242
+ infos: import_zod3.z.array(resolvingIssueSchema).optional().describe(
346
243
  "Informational messages that occurred while running your code to return with the API response, if any."
347
244
  ),
348
- surrogateKeys: import_zod7.z.array(import_zod7.z.string()).optional().describe(
245
+ surrogateKeys: import_zod3.z.array(import_zod3.z.string()).optional().describe(
349
246
  "Extra surrogate keys for the data that was fetched. These act as auxiliary cache keys that can allow granular purging of cached data."
350
247
  ),
351
248
  result: dataResourceSchema.describe("The result of fetching the data resource")
352
249
  });
353
- var requestEdgehancerResultSchema = import_zod7.z.strictObject({
354
- results: import_zod7.z.array(requestEdgehancerDataResourceResolutionResultSchema)
250
+ var requestEdgehancerResultSchema = import_zod3.z.strictObject({
251
+ results: import_zod3.z.array(requestEdgehancerDataResourceResolutionResultSchema)
355
252
  });
356
253
  // Annotate the CommonJS export names for ESM import in node:
357
254
  0 && (module.exports = {
358
255
  COLLECTION_DEFAULT_LIMIT,
359
256
  COLLECTION_DEFAULT_OFFSET,
360
257
  COLLECTION_MAX_LIMIT,
361
- afterAIEditContextSchema,
362
- afterAIEditResultSchema,
363
258
  convertBatchResultsToEdgehancerResult,
364
- createAIEditContextSchema,
365
- createAIEditResultSchema,
366
259
  dataResourceSchema,
367
260
  edgehancerMergedDataTypeSchema,
368
261
  getDataResourceAsRequest,