@simple-ai-lab/sdk 0.4.0 → 0.6.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/README.md +54 -1
- package/dist/actions.cjs +438 -0
- package/dist/actions.d.cts +336 -0
- package/dist/actions.d.ts +336 -0
- package/dist/actions.js +429 -0
- package/dist/agents.cjs +1054 -0
- package/dist/agents.d.cts +1016 -0
- package/dist/agents.d.ts +1016 -0
- package/dist/agents.js +1044 -0
- package/dist/built-in-actions.cjs +356 -0
- package/dist/built-in-actions.d.cts +41 -0
- package/dist/built-in-actions.d.ts +41 -0
- package/dist/built-in-actions.js +353 -0
- package/dist/client.cjs +29 -0
- package/dist/client.d.cts +15 -0
- package/dist/client.d.ts +15 -0
- package/dist/client.js +25 -0
- package/dist/code-action/defaults.cjs +11 -0
- package/dist/code-action/defaults.d.cts +7 -0
- package/dist/code-action/defaults.d.ts +7 -0
- package/dist/code-action/defaults.js +8 -0
- package/dist/code-action/define-action.cjs +74 -0
- package/dist/code-action/define-action.d.cts +94 -0
- package/dist/code-action/define-action.d.ts +94 -0
- package/dist/code-action/define-action.js +69 -0
- package/dist/code-action/index.cjs +11 -0
- package/dist/code-action/index.d.cts +4 -0
- package/dist/code-action/index.d.ts +4 -0
- package/dist/code-action/index.js +3 -0
- package/dist/code-action/types.cjs +13 -0
- package/dist/code-action/types.d.cts +13 -0
- package/dist/code-action/types.d.ts +13 -0
- package/dist/code-action/types.js +10 -0
- package/dist/code-action/workflow.cjs +29 -0
- package/dist/code-action/workflow.d.cts +53 -0
- package/dist/code-action/workflow.d.ts +53 -0
- package/dist/code-action/workflow.js +26 -0
- package/dist/data.cjs +98 -0
- package/dist/data.d.cts +44 -0
- package/dist/data.d.ts +44 -0
- package/dist/data.js +94 -0
- package/dist/http.cjs +65 -0
- package/dist/http.d.cts +14 -0
- package/dist/http.d.ts +14 -0
- package/dist/http.js +62 -0
- package/dist/index.cjs +68 -1597
- package/dist/index.d.cts +12 -780
- package/dist/index.d.ts +12 -780
- package/dist/index.js +10 -1311
- package/dist/projects.cjs +234 -0
- package/dist/projects.d.cts +24 -0
- package/dist/projects.d.ts +24 -0
- package/dist/projects.js +228 -0
- package/dist/schemas.cjs +50 -0
- package/dist/schemas.d.cts +81 -0
- package/dist/schemas.d.ts +81 -0
- package/dist/schemas.js +47 -0
- package/dist/shared/errors.cjs +31 -0
- package/dist/shared/errors.d.cts +22 -0
- package/dist/shared/errors.d.ts +22 -0
- package/dist/shared/errors.js +26 -0
- package/package.json +27 -31
- package/dist/chunk-V4E5PSKB.js +0 -267
- package/dist/chunk-V4E5PSKB.js.map +0 -1
- package/dist/code-action-CDt77m7I.d.cts +0 -191
- package/dist/code-action-CDt77m7I.d.ts +0 -191
- package/dist/code-action.cjs +0 -282
- package/dist/code-action.cjs.map +0 -1
- package/dist/code-action.d.cts +0 -2
- package/dist/code-action.d.ts +0 -2
- package/dist/code-action.js +0 -9
- package/dist/code-action.js.map +0 -1
- package/dist/index.cjs.map +0 -1
- package/dist/index.js.map +0 -1
|
@@ -0,0 +1,356 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BUILT_IN_ACTION_CONTRACTS = exports.VALIDATE_ADDRESS_OUTPUT_MAPPINGS = exports.VALIDATE_ADDRESS_OUTPUT_SCHEMA = exports.VALIDATE_ADDRESS_INPUT_SCHEMA = exports.SEND_TEXT_MESSAGE_OUTPUT_MAPPINGS = exports.SEND_TEXT_MESSAGE_OUTPUT_SCHEMA = exports.SEND_TEXT_MESSAGE_INPUT_SCHEMA = exports.SEND_EMAIL_OUTPUT_MAPPINGS = exports.SEND_EMAIL_OUTPUT_SCHEMA = exports.SEND_EMAIL_INPUT_SCHEMA = exports.builtInOperationSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
/*
|
|
6
|
+
* Agent v2 built-in Action schemas and output mappings, mirrored from
|
|
7
|
+
* `@simple-ai-lab/shared/public/built-in-actions`. Agent v2 requires these
|
|
8
|
+
* definitions to match when saving an Action version. SDK parity tests compare
|
|
9
|
+
* the definitions without adding a private dependency to the published SDK.
|
|
10
|
+
*/
|
|
11
|
+
const sendEmailOperationSchema = zod_1.z.strictObject({
|
|
12
|
+
type: zod_1.z.literal('send_email'),
|
|
13
|
+
sendingDomainUuid: zod_1.z.uuid(),
|
|
14
|
+
fromLocalPart: zod_1.z
|
|
15
|
+
.string()
|
|
16
|
+
.trim()
|
|
17
|
+
.min(1)
|
|
18
|
+
.max(64)
|
|
19
|
+
.regex(/^[A-Za-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[A-Za-z0-9!#$%&'*+/=?^_`{|}~-]+)*$/, {
|
|
20
|
+
message: 'From address may only contain letters, digits, and . _ % + - characters',
|
|
21
|
+
}),
|
|
22
|
+
fromDisplayName: zod_1.z
|
|
23
|
+
.string()
|
|
24
|
+
.trim()
|
|
25
|
+
.min(1)
|
|
26
|
+
.max(128)
|
|
27
|
+
.regex(/^[^\r\n]+$/, { message: 'Display name may not contain line breaks' })
|
|
28
|
+
.nullable(),
|
|
29
|
+
});
|
|
30
|
+
const sendTextMessageOperationSchema = zod_1.z.strictObject({
|
|
31
|
+
type: zod_1.z.literal('send_text_message'),
|
|
32
|
+
senderPhoneNumberUuid: zod_1.z.uuid(),
|
|
33
|
+
});
|
|
34
|
+
const validateAddressOperationSchema = zod_1.z.strictObject({
|
|
35
|
+
type: zod_1.z.literal('validate_address'),
|
|
36
|
+
});
|
|
37
|
+
/** Mirrors Agent v2 operation boundary; no private runtime dependency. */
|
|
38
|
+
exports.builtInOperationSchema = zod_1.z.discriminatedUnion('type', [
|
|
39
|
+
sendTextMessageOperationSchema,
|
|
40
|
+
sendEmailOperationSchema,
|
|
41
|
+
validateAddressOperationSchema,
|
|
42
|
+
]);
|
|
43
|
+
exports.SEND_EMAIL_INPUT_SCHEMA = {
|
|
44
|
+
type: 'object',
|
|
45
|
+
description: 'The recipient and content supplied each time the action runs. The sender is configured on the action.',
|
|
46
|
+
properties: {
|
|
47
|
+
to: {
|
|
48
|
+
type: 'string',
|
|
49
|
+
description: 'The recipient email address, or a comma-separated list of addresses.',
|
|
50
|
+
nullable: false,
|
|
51
|
+
},
|
|
52
|
+
subject: {
|
|
53
|
+
type: 'string',
|
|
54
|
+
description: 'The subject line. Input mappings may use Liquid templates.',
|
|
55
|
+
nullable: false,
|
|
56
|
+
},
|
|
57
|
+
body: {
|
|
58
|
+
type: 'string',
|
|
59
|
+
description: 'The plain-text body. Input mappings may use Liquid templates.',
|
|
60
|
+
nullable: false,
|
|
61
|
+
},
|
|
62
|
+
},
|
|
63
|
+
required: ['to', 'subject', 'body'],
|
|
64
|
+
additionalProperties: false,
|
|
65
|
+
};
|
|
66
|
+
exports.SEND_EMAIL_OUTPUT_SCHEMA = {
|
|
67
|
+
type: 'object',
|
|
68
|
+
description: 'The email provider acceptance result.',
|
|
69
|
+
properties: {
|
|
70
|
+
message_id: {
|
|
71
|
+
type: 'string',
|
|
72
|
+
description: 'The opaque provider message identifier.',
|
|
73
|
+
nullable: false,
|
|
74
|
+
},
|
|
75
|
+
status: {
|
|
76
|
+
type: 'string',
|
|
77
|
+
description: 'The provider acceptance status.',
|
|
78
|
+
nullable: false,
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
required: ['message_id', 'status'],
|
|
82
|
+
additionalProperties: false,
|
|
83
|
+
};
|
|
84
|
+
exports.SEND_EMAIL_OUTPUT_MAPPINGS = {
|
|
85
|
+
'/message_id': '{{ result.message_id }}',
|
|
86
|
+
'/status': '{{ result.status }}',
|
|
87
|
+
};
|
|
88
|
+
exports.SEND_TEXT_MESSAGE_INPUT_SCHEMA = {
|
|
89
|
+
type: 'object',
|
|
90
|
+
description: 'The recipient and content supplied each time the action runs. The sender is configured on the action.',
|
|
91
|
+
properties: {
|
|
92
|
+
to: {
|
|
93
|
+
type: 'string',
|
|
94
|
+
description: 'The recipient phone number in E.164 format.',
|
|
95
|
+
nullable: false,
|
|
96
|
+
},
|
|
97
|
+
message: {
|
|
98
|
+
type: 'string',
|
|
99
|
+
description: 'The message to send. Input mappings may use Liquid templates.',
|
|
100
|
+
nullable: false,
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
required: ['to', 'message'],
|
|
104
|
+
additionalProperties: false,
|
|
105
|
+
};
|
|
106
|
+
exports.SEND_TEXT_MESSAGE_OUTPUT_SCHEMA = {
|
|
107
|
+
type: 'object',
|
|
108
|
+
description: 'The messaging provider acceptance result.',
|
|
109
|
+
properties: {
|
|
110
|
+
message_id: {
|
|
111
|
+
type: 'string',
|
|
112
|
+
description: 'The opaque provider message identifier.',
|
|
113
|
+
nullable: false,
|
|
114
|
+
},
|
|
115
|
+
status: {
|
|
116
|
+
type: 'string',
|
|
117
|
+
description: 'The provider acceptance status.',
|
|
118
|
+
nullable: false,
|
|
119
|
+
},
|
|
120
|
+
channel: {
|
|
121
|
+
type: 'string',
|
|
122
|
+
description: "The delivery channel selected from the sender's messaging configuration.",
|
|
123
|
+
nullable: false,
|
|
124
|
+
},
|
|
125
|
+
},
|
|
126
|
+
required: ['message_id', 'status', 'channel'],
|
|
127
|
+
additionalProperties: false,
|
|
128
|
+
};
|
|
129
|
+
exports.SEND_TEXT_MESSAGE_OUTPUT_MAPPINGS = {
|
|
130
|
+
'/message_id': '{{ result.message_id }}',
|
|
131
|
+
'/status': '{{ result.status }}',
|
|
132
|
+
'/channel': '{{ result.channel }}',
|
|
133
|
+
};
|
|
134
|
+
exports.VALIDATE_ADDRESS_INPUT_SCHEMA = {
|
|
135
|
+
type: 'object',
|
|
136
|
+
description: 'The complete address to validate and standardize.',
|
|
137
|
+
properties: {
|
|
138
|
+
address_line_1: {
|
|
139
|
+
type: 'string',
|
|
140
|
+
description: 'The street address, or the complete unstructured address when no component hints are known.',
|
|
141
|
+
nullable: false,
|
|
142
|
+
},
|
|
143
|
+
address_line_2: {
|
|
144
|
+
type: 'string',
|
|
145
|
+
description: 'An apartment, suite, or secondary address line. Use null or an empty string when unknown.',
|
|
146
|
+
nullable: true,
|
|
147
|
+
},
|
|
148
|
+
city: {
|
|
149
|
+
type: 'string',
|
|
150
|
+
description: 'The city or locality used to narrow validation. Use null or an empty string when unknown.',
|
|
151
|
+
nullable: true,
|
|
152
|
+
},
|
|
153
|
+
region: {
|
|
154
|
+
type: 'string',
|
|
155
|
+
description: 'The state, province, or administrative area used to narrow validation. Use null or an empty string when unknown.',
|
|
156
|
+
nullable: true,
|
|
157
|
+
},
|
|
158
|
+
postal_code: {
|
|
159
|
+
type: 'string',
|
|
160
|
+
description: 'The postal code used to narrow validation. Use null or an empty string when unknown.',
|
|
161
|
+
nullable: true,
|
|
162
|
+
},
|
|
163
|
+
country_code: {
|
|
164
|
+
type: 'string',
|
|
165
|
+
description: 'The two-letter country code used to narrow validation. Use null or an empty string when unknown.',
|
|
166
|
+
nullable: true,
|
|
167
|
+
},
|
|
168
|
+
},
|
|
169
|
+
required: ['address_line_1', 'address_line_2', 'city', 'region', 'postal_code', 'country_code'],
|
|
170
|
+
additionalProperties: false,
|
|
171
|
+
};
|
|
172
|
+
const addressOutputProperties = {
|
|
173
|
+
formatted_address: {
|
|
174
|
+
type: 'string',
|
|
175
|
+
description: 'The complete standardized address formatted for display or confirmation.',
|
|
176
|
+
nullable: false,
|
|
177
|
+
},
|
|
178
|
+
address_line_1: {
|
|
179
|
+
type: 'string',
|
|
180
|
+
description: 'The standardized primary street-address line.',
|
|
181
|
+
nullable: false,
|
|
182
|
+
},
|
|
183
|
+
address_line_2: {
|
|
184
|
+
type: 'string',
|
|
185
|
+
description: 'The standardized apartment, suite, or secondary address line, or an empty string.',
|
|
186
|
+
nullable: false,
|
|
187
|
+
},
|
|
188
|
+
city: {
|
|
189
|
+
type: 'string',
|
|
190
|
+
description: 'The validated city.',
|
|
191
|
+
nullable: false,
|
|
192
|
+
},
|
|
193
|
+
region: {
|
|
194
|
+
type: 'string',
|
|
195
|
+
description: 'The standardized state, province, or administrative-area abbreviation.',
|
|
196
|
+
nullable: false,
|
|
197
|
+
},
|
|
198
|
+
postal_code: {
|
|
199
|
+
type: 'string',
|
|
200
|
+
description: 'The complete standardized postal code.',
|
|
201
|
+
nullable: false,
|
|
202
|
+
},
|
|
203
|
+
country_code: {
|
|
204
|
+
type: 'string',
|
|
205
|
+
description: 'The two-letter country code, or an empty string when unavailable.',
|
|
206
|
+
nullable: false,
|
|
207
|
+
},
|
|
208
|
+
latitude: {
|
|
209
|
+
type: 'number',
|
|
210
|
+
description: 'The validated latitude, or null when Google does not return a geocode.',
|
|
211
|
+
nullable: true,
|
|
212
|
+
},
|
|
213
|
+
longitude: {
|
|
214
|
+
type: 'number',
|
|
215
|
+
description: 'The validated longitude, or null when Google does not return a geocode.',
|
|
216
|
+
nullable: true,
|
|
217
|
+
},
|
|
218
|
+
validation_status: {
|
|
219
|
+
type: 'string',
|
|
220
|
+
description: 'Whether the address is confirmed, needs confirmation, is incomplete, or was not found.',
|
|
221
|
+
nullable: false,
|
|
222
|
+
},
|
|
223
|
+
recommended_action: {
|
|
224
|
+
type: 'string',
|
|
225
|
+
description: 'The next step the agent should take: use the address, confirm it, ask for missing information, or offer one suggestion and revalidate it after confirmation.',
|
|
226
|
+
nullable: false,
|
|
227
|
+
},
|
|
228
|
+
missing_components: {
|
|
229
|
+
type: 'array',
|
|
230
|
+
description: 'Address fields that are missing and should be requested from the user.',
|
|
231
|
+
nullable: false,
|
|
232
|
+
items: {
|
|
233
|
+
type: 'string',
|
|
234
|
+
description: 'A missing address field such as address_line_1, address_line_2, city, region, or postal_code.',
|
|
235
|
+
nullable: false,
|
|
236
|
+
},
|
|
237
|
+
},
|
|
238
|
+
unconfirmed_components: {
|
|
239
|
+
type: 'array',
|
|
240
|
+
description: 'Address fields that Google could not confidently confirm.',
|
|
241
|
+
nullable: false,
|
|
242
|
+
items: {
|
|
243
|
+
type: 'string',
|
|
244
|
+
description: 'An unconfirmed address field.',
|
|
245
|
+
nullable: false,
|
|
246
|
+
},
|
|
247
|
+
},
|
|
248
|
+
corrected_components: {
|
|
249
|
+
type: 'array',
|
|
250
|
+
description: 'Address fields that Google inferred, corrected, or replaced and that may need confirmation.',
|
|
251
|
+
nullable: false,
|
|
252
|
+
items: {
|
|
253
|
+
type: 'string',
|
|
254
|
+
description: 'A corrected address field.',
|
|
255
|
+
nullable: false,
|
|
256
|
+
},
|
|
257
|
+
},
|
|
258
|
+
unresolved_tokens: {
|
|
259
|
+
type: 'array',
|
|
260
|
+
description: 'Parts of the spoken or entered address that Google could not resolve.',
|
|
261
|
+
nullable: false,
|
|
262
|
+
items: {
|
|
263
|
+
type: 'string',
|
|
264
|
+
description: 'An unresolved address token.',
|
|
265
|
+
nullable: false,
|
|
266
|
+
},
|
|
267
|
+
},
|
|
268
|
+
suggestions: {
|
|
269
|
+
type: 'array',
|
|
270
|
+
description: 'Up to three ranked address suggestions to offer one at a time when validation fails. After confirmation, call this Action again with the selected formatted_address.',
|
|
271
|
+
nullable: false,
|
|
272
|
+
items: {
|
|
273
|
+
type: 'object',
|
|
274
|
+
description: 'A Google Places address suggestion.',
|
|
275
|
+
nullable: false,
|
|
276
|
+
properties: {
|
|
277
|
+
place_id: {
|
|
278
|
+
type: 'string',
|
|
279
|
+
description: 'The stable Google Place identifier for the suggestion.',
|
|
280
|
+
nullable: false,
|
|
281
|
+
},
|
|
282
|
+
formatted_address: {
|
|
283
|
+
type: 'string',
|
|
284
|
+
description: 'The complete suggestion text to read back to the user.',
|
|
285
|
+
nullable: false,
|
|
286
|
+
},
|
|
287
|
+
address_line_1: {
|
|
288
|
+
type: 'string',
|
|
289
|
+
description: 'The primary address text for the suggestion.',
|
|
290
|
+
nullable: false,
|
|
291
|
+
},
|
|
292
|
+
locality: {
|
|
293
|
+
type: 'string',
|
|
294
|
+
description: 'The city, region, postal code, or country context that distinguishes the suggestion.',
|
|
295
|
+
nullable: false,
|
|
296
|
+
},
|
|
297
|
+
},
|
|
298
|
+
required: ['place_id', 'formatted_address', 'address_line_1', 'locality'],
|
|
299
|
+
additionalProperties: false,
|
|
300
|
+
},
|
|
301
|
+
},
|
|
302
|
+
validation_issues: {
|
|
303
|
+
type: 'array',
|
|
304
|
+
description: 'Potential address issues to confirm with the user.',
|
|
305
|
+
nullable: false,
|
|
306
|
+
items: {
|
|
307
|
+
type: 'string',
|
|
308
|
+
description: 'A human-readable validation issue.',
|
|
309
|
+
nullable: false,
|
|
310
|
+
},
|
|
311
|
+
},
|
|
312
|
+
};
|
|
313
|
+
exports.VALIDATE_ADDRESS_OUTPUT_SCHEMA = {
|
|
314
|
+
type: 'object',
|
|
315
|
+
description: 'A standardized address and provider-neutral validation assessment.',
|
|
316
|
+
properties: addressOutputProperties,
|
|
317
|
+
required: Object.keys(addressOutputProperties),
|
|
318
|
+
additionalProperties: false,
|
|
319
|
+
};
|
|
320
|
+
exports.VALIDATE_ADDRESS_OUTPUT_MAPPINGS = {
|
|
321
|
+
'/formatted_address': '{{ result.formatted_address }}',
|
|
322
|
+
'/address_line_1': '{{ result.address_line_1 }}',
|
|
323
|
+
'/address_line_2': '{{ result.address_line_2 }}',
|
|
324
|
+
'/city': '{{ result.city }}',
|
|
325
|
+
'/region': '{{ result.region }}',
|
|
326
|
+
'/postal_code': '{{ result.postal_code }}',
|
|
327
|
+
'/country_code': '{{ result.country_code }}',
|
|
328
|
+
'/latitude': '{{ result.latitude }}',
|
|
329
|
+
'/longitude': '{{ result.longitude }}',
|
|
330
|
+
'/validation_status': '{{ result.validation_status }}',
|
|
331
|
+
'/recommended_action': '{{ result.recommended_action }}',
|
|
332
|
+
'/missing_components': '{{ result.missing_components }}',
|
|
333
|
+
'/unconfirmed_components': '{{ result.unconfirmed_components }}',
|
|
334
|
+
'/corrected_components': '{{ result.corrected_components }}',
|
|
335
|
+
'/unresolved_tokens': '{{ result.unresolved_tokens }}',
|
|
336
|
+
'/validation_issues': '{{ result.validation_issues }}',
|
|
337
|
+
'/suggestions': '{{ result.suggestions }}',
|
|
338
|
+
};
|
|
339
|
+
/** The fixed contract of each built-in operation, keyed by its wire `type`. */
|
|
340
|
+
exports.BUILT_IN_ACTION_CONTRACTS = {
|
|
341
|
+
send_email: {
|
|
342
|
+
inputSchema: exports.SEND_EMAIL_INPUT_SCHEMA,
|
|
343
|
+
outputSchema: exports.SEND_EMAIL_OUTPUT_SCHEMA,
|
|
344
|
+
outputMappings: exports.SEND_EMAIL_OUTPUT_MAPPINGS,
|
|
345
|
+
},
|
|
346
|
+
send_text_message: {
|
|
347
|
+
inputSchema: exports.SEND_TEXT_MESSAGE_INPUT_SCHEMA,
|
|
348
|
+
outputSchema: exports.SEND_TEXT_MESSAGE_OUTPUT_SCHEMA,
|
|
349
|
+
outputMappings: exports.SEND_TEXT_MESSAGE_OUTPUT_MAPPINGS,
|
|
350
|
+
},
|
|
351
|
+
validate_address: {
|
|
352
|
+
inputSchema: exports.VALIDATE_ADDRESS_INPUT_SCHEMA,
|
|
353
|
+
outputSchema: exports.VALIDATE_ADDRESS_OUTPUT_SCHEMA,
|
|
354
|
+
outputMappings: exports.VALIDATE_ADDRESS_OUTPUT_MAPPINGS,
|
|
355
|
+
},
|
|
356
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import type { ActionsIoSchema } from "./actions.cjs";
|
|
3
|
+
/** Mirrors Agent v2 operation boundary; no private runtime dependency. */
|
|
4
|
+
export declare const builtInOperationSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
5
|
+
type: z.ZodLiteral<"send_text_message">;
|
|
6
|
+
senderPhoneNumberUuid: z.ZodUUID;
|
|
7
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
8
|
+
type: z.ZodLiteral<"send_email">;
|
|
9
|
+
sendingDomainUuid: z.ZodUUID;
|
|
10
|
+
fromLocalPart: z.ZodString;
|
|
11
|
+
fromDisplayName: z.ZodNullable<z.ZodString>;
|
|
12
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
13
|
+
type: z.ZodLiteral<"validate_address">;
|
|
14
|
+
}, z.core.$strict>], "type">;
|
|
15
|
+
export declare const SEND_EMAIL_INPUT_SCHEMA: ActionsIoSchema;
|
|
16
|
+
export declare const SEND_EMAIL_OUTPUT_SCHEMA: ActionsIoSchema;
|
|
17
|
+
export declare const SEND_EMAIL_OUTPUT_MAPPINGS: Record<string, string>;
|
|
18
|
+
export declare const SEND_TEXT_MESSAGE_INPUT_SCHEMA: ActionsIoSchema;
|
|
19
|
+
export declare const SEND_TEXT_MESSAGE_OUTPUT_SCHEMA: ActionsIoSchema;
|
|
20
|
+
export declare const SEND_TEXT_MESSAGE_OUTPUT_MAPPINGS: Record<string, string>;
|
|
21
|
+
export declare const VALIDATE_ADDRESS_INPUT_SCHEMA: ActionsIoSchema;
|
|
22
|
+
export declare const VALIDATE_ADDRESS_OUTPUT_SCHEMA: ActionsIoSchema;
|
|
23
|
+
export declare const VALIDATE_ADDRESS_OUTPUT_MAPPINGS: Record<string, string>;
|
|
24
|
+
/** The fixed contract of each built-in operation, keyed by its wire `type`. */
|
|
25
|
+
export declare const BUILT_IN_ACTION_CONTRACTS: {
|
|
26
|
+
readonly send_email: {
|
|
27
|
+
readonly inputSchema: ActionsIoSchema;
|
|
28
|
+
readonly outputSchema: ActionsIoSchema;
|
|
29
|
+
readonly outputMappings: Record<string, string>;
|
|
30
|
+
};
|
|
31
|
+
readonly send_text_message: {
|
|
32
|
+
readonly inputSchema: ActionsIoSchema;
|
|
33
|
+
readonly outputSchema: ActionsIoSchema;
|
|
34
|
+
readonly outputMappings: Record<string, string>;
|
|
35
|
+
};
|
|
36
|
+
readonly validate_address: {
|
|
37
|
+
readonly inputSchema: ActionsIoSchema;
|
|
38
|
+
readonly outputSchema: ActionsIoSchema;
|
|
39
|
+
readonly outputMappings: Record<string, string>;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import type { ActionsIoSchema } from "./actions.js";
|
|
3
|
+
/** Mirrors Agent v2 operation boundary; no private runtime dependency. */
|
|
4
|
+
export declare const builtInOperationSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
5
|
+
type: z.ZodLiteral<"send_text_message">;
|
|
6
|
+
senderPhoneNumberUuid: z.ZodUUID;
|
|
7
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
8
|
+
type: z.ZodLiteral<"send_email">;
|
|
9
|
+
sendingDomainUuid: z.ZodUUID;
|
|
10
|
+
fromLocalPart: z.ZodString;
|
|
11
|
+
fromDisplayName: z.ZodNullable<z.ZodString>;
|
|
12
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
13
|
+
type: z.ZodLiteral<"validate_address">;
|
|
14
|
+
}, z.core.$strict>], "type">;
|
|
15
|
+
export declare const SEND_EMAIL_INPUT_SCHEMA: ActionsIoSchema;
|
|
16
|
+
export declare const SEND_EMAIL_OUTPUT_SCHEMA: ActionsIoSchema;
|
|
17
|
+
export declare const SEND_EMAIL_OUTPUT_MAPPINGS: Record<string, string>;
|
|
18
|
+
export declare const SEND_TEXT_MESSAGE_INPUT_SCHEMA: ActionsIoSchema;
|
|
19
|
+
export declare const SEND_TEXT_MESSAGE_OUTPUT_SCHEMA: ActionsIoSchema;
|
|
20
|
+
export declare const SEND_TEXT_MESSAGE_OUTPUT_MAPPINGS: Record<string, string>;
|
|
21
|
+
export declare const VALIDATE_ADDRESS_INPUT_SCHEMA: ActionsIoSchema;
|
|
22
|
+
export declare const VALIDATE_ADDRESS_OUTPUT_SCHEMA: ActionsIoSchema;
|
|
23
|
+
export declare const VALIDATE_ADDRESS_OUTPUT_MAPPINGS: Record<string, string>;
|
|
24
|
+
/** The fixed contract of each built-in operation, keyed by its wire `type`. */
|
|
25
|
+
export declare const BUILT_IN_ACTION_CONTRACTS: {
|
|
26
|
+
readonly send_email: {
|
|
27
|
+
readonly inputSchema: ActionsIoSchema;
|
|
28
|
+
readonly outputSchema: ActionsIoSchema;
|
|
29
|
+
readonly outputMappings: Record<string, string>;
|
|
30
|
+
};
|
|
31
|
+
readonly send_text_message: {
|
|
32
|
+
readonly inputSchema: ActionsIoSchema;
|
|
33
|
+
readonly outputSchema: ActionsIoSchema;
|
|
34
|
+
readonly outputMappings: Record<string, string>;
|
|
35
|
+
};
|
|
36
|
+
readonly validate_address: {
|
|
37
|
+
readonly inputSchema: ActionsIoSchema;
|
|
38
|
+
readonly outputSchema: ActionsIoSchema;
|
|
39
|
+
readonly outputMappings: Record<string, string>;
|
|
40
|
+
};
|
|
41
|
+
};
|