@adobe/aio-commerce-lib-app 1.6.0 → 1.8.0-beta-20260714082406

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.
Files changed (110) hide show
  1. package/CHANGELOG.md +106 -0
  2. package/dist/cjs/actions/app-config/index.cjs +205 -0
  3. package/dist/cjs/actions/{app-config.d.cts → app-config/index.d.cts} +10 -7
  4. package/dist/cjs/actions/association/index.cjs +85 -0
  5. package/dist/cjs/actions/association/index.d.cts +28 -0
  6. package/dist/cjs/actions/{config.cjs → config/index.cjs} +70 -53
  7. package/dist/{es/actions/config.d.mts → cjs/actions/config/index.d.cts} +10 -7
  8. package/dist/cjs/actions/{installation.cjs → installation/index.cjs} +106 -72
  9. package/dist/{es/actions/installation.d.mts → cjs/actions/installation/index.d.cts} +10 -8
  10. package/dist/cjs/actions/{scope-tree.cjs → scope-tree/index.cjs} +60 -22
  11. package/dist/cjs/actions/{scope-tree.d.cts → scope-tree/index.d.cts} +1 -1
  12. package/dist/cjs/app-D3P-Z6uY.d.cts +1679 -0
  13. package/dist/cjs/association-repository-BAs3-VkW.cjs +69 -0
  14. package/dist/cjs/commands/index.cjs +517 -309
  15. package/dist/cjs/commands/templates/admin-ui/tsconfig.json +14 -0
  16. package/dist/cjs/commands/templates/admin-ui/web-src/index.css +5 -0
  17. package/dist/cjs/commands/templates/admin-ui/web-src/index.html +17 -0
  18. package/dist/cjs/commands/templates/admin-ui/web-src/src/app.jsx +13 -0
  19. package/dist/cjs/commands/templates/admin-ui/web-src/src/components/welcome.jsx +12 -0
  20. package/dist/cjs/commands/templates/admin-ui/web-src/src/pages/main-page.jsx +10 -0
  21. package/dist/cjs/commands/templates/{admin-ui-sdk/registration.js.template → admin-ui/web-src-template.d.ts} +11 -6
  22. package/dist/cjs/commands/templates/app-management/app-config.js.template +1 -14
  23. package/dist/cjs/commands/templates/app-management/association.js.template +6 -0
  24. package/dist/cjs/commands/templates/app-management/installation.js.template +1 -13
  25. package/dist/cjs/commands/templates/business-configuration/config.js.template +2 -15
  26. package/dist/cjs/commands/templates/business-configuration/scope-tree.js.template +0 -12
  27. package/dist/cjs/config/index.browser.cjs +18 -0
  28. package/dist/cjs/config/index.browser.d.cts +16 -0
  29. package/dist/cjs/config/{index.cjs → index.node.cjs} +9 -8
  30. package/dist/cjs/config/index.node.d.cts +1603 -0
  31. package/dist/cjs/define-DBxAlJfN.d.cts +34 -0
  32. package/dist/cjs/define-hlcQw7Cv.cjs +41 -0
  33. package/dist/cjs/environment-B7EnozSg.cjs +135 -0
  34. package/dist/cjs/index-BXm8UbK7.d.cts +16 -0
  35. package/dist/cjs/{index-Dw2NvVOY.d.cts → index-CzReNwbF.d.cts} +177 -3
  36. package/dist/cjs/index.cjs +250 -0
  37. package/dist/cjs/index.d.cts +217 -0
  38. package/dist/cjs/{config-FNMclIFO.cjs → index.node-Dz4lV4qe.cjs} +119 -35
  39. package/dist/cjs/{logging-BVz3weoC.cjs → logging-udPuAJPt.cjs} +2 -2
  40. package/dist/cjs/management/index.cjs +1 -1
  41. package/dist/cjs/management/index.d.cts +1 -2
  42. package/dist/cjs/{management-Cvsz4VMf.cjs → management-B9ItB80R.cjs} +432 -591
  43. package/dist/cjs/openapi-CwytYdWl.cjs +2948 -0
  44. package/dist/cjs/{router-BOR7T6qR.cjs → router-hA_Y9gZ1.cjs} +42 -44
  45. package/dist/cjs/{schemas-FngDuIeo.cjs → schemas-mLxMh_ko.cjs} +2 -2
  46. package/dist/cjs/utils-DSCmZ_iJ.cjs +408 -0
  47. package/dist/cjs/{validate-DydOAZha.cjs → validate-BfxhZ5Wv.cjs} +63 -31
  48. package/dist/cjs/{webhooks-tbZy9G3p.cjs → webhooks-B5tb9NeF.cjs} +159 -151
  49. package/dist/es/actions/{app-config.d.mts → app-config/index.d.mts} +10 -7
  50. package/dist/es/actions/app-config/index.mjs +202 -0
  51. package/dist/es/actions/association/index.d.mts +28 -0
  52. package/dist/es/actions/association/index.mjs +82 -0
  53. package/dist/{cjs/actions/config.d.cts → es/actions/config/index.d.mts} +10 -7
  54. package/dist/es/actions/{config.mjs → config/index.mjs} +67 -50
  55. package/dist/{cjs/actions/installation.d.cts → es/actions/installation/index.d.mts} +10 -8
  56. package/dist/es/actions/{installation.mjs → installation/index.mjs} +104 -71
  57. package/dist/es/actions/{scope-tree.d.mts → scope-tree/index.d.mts} +1 -1
  58. package/dist/es/actions/{scope-tree.mjs → scope-tree/index.mjs} +58 -20
  59. package/dist/es/app-D3P-Z6uY.d.mts +1679 -0
  60. package/dist/es/association-repository-BbQv9WCl.mjs +52 -0
  61. package/dist/es/commands/index.mjs +550 -340
  62. package/dist/es/commands/templates/admin-ui/tsconfig.json +14 -0
  63. package/dist/es/commands/templates/admin-ui/web-src/index.css +5 -0
  64. package/dist/es/commands/templates/admin-ui/web-src/index.html +17 -0
  65. package/dist/es/commands/templates/admin-ui/web-src/src/app.jsx +13 -0
  66. package/dist/es/commands/templates/admin-ui/web-src/src/components/welcome.jsx +12 -0
  67. package/dist/es/commands/templates/admin-ui/web-src/src/pages/main-page.jsx +10 -0
  68. package/dist/es/commands/templates/{admin-ui-sdk/registration.js.template → admin-ui/web-src-template.d.ts} +11 -6
  69. package/dist/es/commands/templates/app-management/app-config.js.template +1 -14
  70. package/dist/es/commands/templates/app-management/association.js.template +6 -0
  71. package/dist/es/commands/templates/app-management/installation.js.template +1 -13
  72. package/dist/es/commands/templates/business-configuration/config.js.template +2 -15
  73. package/dist/es/commands/templates/business-configuration/scope-tree.js.template +0 -12
  74. package/dist/es/config/index.browser.d.mts +16 -0
  75. package/dist/es/config/index.browser.mjs +17 -0
  76. package/dist/es/config/index.node.d.mts +1604 -0
  77. package/dist/es/config/index.node.mjs +20 -0
  78. package/dist/es/define-EoYRZbpe.d.mts +34 -0
  79. package/dist/es/define-Z_Glf1-_.mjs +35 -0
  80. package/dist/es/environment-C84BPRJZ.mjs +104 -0
  81. package/dist/es/index-B0XqHwY5.d.mts +16 -0
  82. package/dist/es/{index-Bo0tQsVq.d.mts → index-D52xglhZ.d.mts} +177 -3
  83. package/dist/es/index.d.mts +217 -0
  84. package/dist/es/index.mjs +242 -0
  85. package/dist/es/{config-CcE0EBG7.mjs → index.node-CDH5gwJE.mjs} +94 -30
  86. package/dist/es/management/index.d.mts +1 -2
  87. package/dist/es/management/index.mjs +1 -1
  88. package/dist/es/{management-BZ4Y6lVp.mjs → management-B89ApQVY.mjs} +402 -562
  89. package/dist/es/openapi-CXonvevE.mjs +2900 -0
  90. package/dist/es/{router-D58JJHHA.mjs → router-B_h0cvjc.mjs} +40 -42
  91. package/dist/es/utils-_gj8L6eN.mjs +289 -0
  92. package/dist/es/{validate-Du3LhCre.mjs → validate-9cRZWGrA.mjs} +49 -29
  93. package/dist/es/{webhooks-B5oq9ULL.mjs → webhooks-BBPbY2mb.mjs} +150 -142
  94. package/package.json +52 -22
  95. package/dist/cjs/actions/app-config.cjs +0 -54
  96. package/dist/cjs/actions/registration.cjs +0 -40
  97. package/dist/cjs/actions/registration.d.cts +0 -32
  98. package/dist/cjs/admin-ui-sdk-DZZJCrdT.d.cts +0 -665
  99. package/dist/cjs/app-CakwxQvs.d.cts +0 -673
  100. package/dist/cjs/config/index.d.cts +0 -1975
  101. package/dist/cjs/step-CKVE0aJi.d.cts +0 -187
  102. package/dist/es/actions/app-config.mjs +0 -53
  103. package/dist/es/actions/registration.d.mts +0 -32
  104. package/dist/es/actions/registration.mjs +0 -39
  105. package/dist/es/admin-ui-sdk-hu6iWr0A.d.mts +0 -667
  106. package/dist/es/app-CakwxQvs.d.mts +0 -673
  107. package/dist/es/config/index.d.mts +0 -1975
  108. package/dist/es/config/index.mjs +0 -19
  109. package/dist/es/step-D64mMPrt.d.mts +0 -187
  110. /package/dist/cjs/{chunk-Cozy-1ZF.cjs → rolldown-runtime-Cozy-1ZF.cjs} +0 -0
@@ -1,1975 +0,0 @@
1
- /**
2
- * @license
3
- *
4
- * Copyright 2026 Adobe. All rights reserved.
5
- * This file is licensed to you under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License. You may obtain a copy
7
- * of the License at http://www.apache.org/licenses/LICENSE-2.0
8
- *
9
- * Unless required by applicable law or agreed to in writing, software distributed under
10
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
11
- * OF ANY KIND, either express or implied. See the License for the specific language
12
- * governing permissions and limitations under the License.
13
- */
14
-
15
- import { n as CommerceAppConfigOutputModel, t as CommerceAppConfig } from "../app-CakwxQvs.mjs";
16
- import { a as CustomerMassAction, c as OrderMassAction, d as hasAdminUiSdk, i as CustomFee, l as OrderViewButton, n as AdminUiSdkRegistration, o as GridColumns, r as BannerNotification, s as MenuItem, t as AdminUiSdkConfiguration, u as ProductMassAction } from "../admin-ui-sdk-hu6iWr0A.mjs";
17
- import * as v from "valibot";
18
- import { Get, SetRequiredDeep } from "type-fest";
19
-
20
- //#region source/config/lib/define.d.ts
21
- /**
22
- * Helper to type-safely define the app config.
23
- * @param config - The app config to define.
24
- *
25
- * @example
26
- * ```typescript
27
- * import { defineConfig } from "@adobe/aio-commerce-lib-app";
28
- *
29
- * // In app.commerce.config.js
30
- * export default defineConfig({
31
- * // You get autocompletion and type-safety for the config object.
32
- * businessConfig: { ... }
33
- * });
34
- */
35
- declare function defineConfig<const T extends CommerceAppConfig>(config: T): T;
36
- //#endregion
37
- //#region source/config/lib/parser.d.ts
38
- /**
39
- * Try to find (up to the nearest package.json file) the app config file.
40
- *
41
- * Searches for config files in the following order of priority:
42
- * 1. `app.commerce.config.js` - JavaScript (CommonJS or ESM)
43
- * 2. `app.commerce.config.ts` - TypeScript
44
- * 3. `app.commerce.config.cjs` - CommonJS
45
- * 4. `app.commerce.config.mjs` - ES Module
46
- * 5. `app.commerce.config.mts` - ES Module TypeScript
47
- * 6. `app.commerce.config.cts` - CommonJS TypeScript
48
- *
49
- * @param cwd The current working directory
50
- * @returns The path to the config file, or null if not found
51
- */
52
- declare function resolveCommerceAppConfig(cwd?: string): Promise<string | null>;
53
- /**
54
- * Read the commerce app config file as-is, without validating it.
55
- *
56
- * Supports multiple config file formats (see {@link resolveCommerceAppConfig} for the list).
57
- * The config file must export a default export with the configuration object.
58
- *
59
- * @param cwd The current working directory
60
- * @returns The raw config object from the file
61
- * @throws {Error} If no config file is found or if the file doesn't export a default export
62
- */
63
- declare function readCommerceAppConfig(cwd?: string): Promise<unknown>;
64
- /**
65
- * Read the commerce app config file and parse its contents into its schema.
66
- *
67
- * Supports multiple config file formats (see {@link resolveCommerceAppConfig} for the list).
68
- * The config file must export a default export with the configuration object.
69
- *
70
- * @param cwd The current working directory
71
- * @returns The validated and parsed config object
72
- * @throws {Error} If no config file is found, if the file doesn't export a default export, or if validation fails
73
- */
74
- declare function parseCommerceAppConfig(cwd?: string): Promise<{
75
- metadata: {
76
- id: string;
77
- displayName: string;
78
- description: string;
79
- version: string;
80
- };
81
- businessConfig?: {
82
- schema: ({
83
- selectionMode: "single";
84
- default: string;
85
- type: "list";
86
- options: {
87
- label: string;
88
- value: string;
89
- }[];
90
- name: string;
91
- label?: string | undefined;
92
- description?: string | undefined;
93
- env?: ("paas" | "saas")[] | undefined;
94
- } | {
95
- selectionMode: "multiple";
96
- default: string[];
97
- type: "list";
98
- options: {
99
- label: string;
100
- value: string;
101
- }[];
102
- name: string;
103
- label?: string | undefined;
104
- description?: string | undefined;
105
- env?: ("paas" | "saas")[] | undefined;
106
- } | {
107
- selectionMode: "single";
108
- default: (resolvedOptions: {
109
- label: string;
110
- value: string;
111
- }[]) => string;
112
- type: "dynamicList";
113
- options: (params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
114
- label: string;
115
- value: string;
116
- }[] | Promise<{
117
- label: string;
118
- value: string;
119
- }[]>;
120
- name: string;
121
- label?: string | undefined;
122
- description?: string | undefined;
123
- env?: ("paas" | "saas")[] | undefined;
124
- } | {
125
- selectionMode: "multiple";
126
- default?: ((resolvedOptions: {
127
- label: string;
128
- value: string;
129
- }[]) => string[]) | undefined;
130
- type: "dynamicList";
131
- options: (params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
132
- label: string;
133
- value: string;
134
- }[] | Promise<{
135
- label: string;
136
- value: string;
137
- }[]>;
138
- name: string;
139
- label?: string | undefined;
140
- description?: string | undefined;
141
- env?: ("paas" | "saas")[] | undefined;
142
- } | {
143
- type: "text";
144
- default: string;
145
- name: string;
146
- label?: string | undefined;
147
- description?: string | undefined;
148
- env?: ("paas" | "saas")[] | undefined;
149
- } | {
150
- type: "password";
151
- default: "";
152
- name: string;
153
- label?: string | undefined;
154
- description?: string | undefined;
155
- env?: ("paas" | "saas")[] | undefined;
156
- } | {
157
- type: "email";
158
- default: string;
159
- name: string;
160
- label?: string | undefined;
161
- description?: string | undefined;
162
- env?: ("paas" | "saas")[] | undefined;
163
- } | {
164
- type: "url";
165
- default: string;
166
- name: string;
167
- label?: string | undefined;
168
- description?: string | undefined;
169
- env?: ("paas" | "saas")[] | undefined;
170
- } | {
171
- type: "tel";
172
- default: string;
173
- name: string;
174
- label?: string | undefined;
175
- description?: string | undefined;
176
- env?: ("paas" | "saas")[] | undefined;
177
- } | {
178
- type: "boolean";
179
- default: boolean;
180
- name: string;
181
- label?: string | undefined;
182
- description?: string | undefined;
183
- env?: ("paas" | "saas")[] | undefined;
184
- })[];
185
- } | undefined;
186
- eventing?: {
187
- commerce?: {
188
- provider: {
189
- label: string;
190
- description: string;
191
- key?: string | undefined;
192
- };
193
- events: {
194
- name: string;
195
- fields: {
196
- name: string;
197
- source?: string | undefined;
198
- }[];
199
- rules?: {
200
- field: string;
201
- operator: "regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange";
202
- value: string;
203
- }[] | undefined;
204
- destination?: string | undefined;
205
- hipaa_audit_required?: boolean | undefined;
206
- priority?: boolean | undefined;
207
- force?: boolean | undefined;
208
- label: string;
209
- description: string;
210
- runtimeActions: string[];
211
- }[];
212
- }[] | undefined;
213
- external?: {
214
- provider: {
215
- label: string;
216
- description: string;
217
- key?: string | undefined;
218
- };
219
- events: {
220
- name: string;
221
- label: string;
222
- description: string;
223
- runtimeActions: string[];
224
- }[];
225
- }[] | undefined;
226
- } | undefined;
227
- adminUiSdk?: {
228
- registration: {
229
- menuItems?: {
230
- id: string;
231
- title?: string | undefined;
232
- parent?: string | undefined;
233
- sortOrder?: number | undefined;
234
- isSection?: boolean | undefined;
235
- sandbox?: string | undefined;
236
- }[] | undefined;
237
- order?: {
238
- massActions?: unknown[] | undefined;
239
- gridColumns?: {
240
- data: {
241
- meshId: string;
242
- };
243
- properties: {
244
- label: string;
245
- columnId: string;
246
- type: "string" | "boolean" | "date" | "float" | "integer";
247
- align: "left" | "right" | "center";
248
- }[];
249
- } | undefined;
250
- viewButtons?: unknown[] | undefined;
251
- customFees?: {
252
- id: string;
253
- label: string;
254
- value: number;
255
- orderMinimumAmount?: number | undefined;
256
- applyFeeOnLastInvoice?: boolean | undefined;
257
- applyFeeOnLastCreditMemo?: boolean | undefined;
258
- }[] | undefined;
259
- } | undefined;
260
- product?: {
261
- massActions?: unknown[] | undefined;
262
- gridColumns?: {
263
- data: {
264
- meshId: string;
265
- };
266
- properties: {
267
- label: string;
268
- columnId: string;
269
- type: "string" | "boolean" | "date" | "float" | "integer";
270
- align: "left" | "right" | "center";
271
- }[];
272
- } | undefined;
273
- } | undefined;
274
- customer?: {
275
- massActions?: unknown[] | undefined;
276
- gridColumns?: {
277
- data: {
278
- meshId: string;
279
- };
280
- properties: {
281
- label: string;
282
- columnId: string;
283
- type: "string" | "boolean" | "date" | "float" | "integer";
284
- align: "left" | "right" | "center";
285
- }[];
286
- } | undefined;
287
- } | undefined;
288
- bannerNotification?: {
289
- massActions?: {
290
- order?: {
291
- actionId: string;
292
- successMessage?: string | undefined;
293
- errorMessage?: string | undefined;
294
- }[] | undefined;
295
- product?: {
296
- actionId: string;
297
- successMessage?: string | undefined;
298
- errorMessage?: string | undefined;
299
- }[] | undefined;
300
- customer?: {
301
- actionId: string;
302
- successMessage?: string | undefined;
303
- errorMessage?: string | undefined;
304
- }[] | undefined;
305
- } | undefined;
306
- orderViewButtons?: {
307
- buttonId: string;
308
- successMessage?: string | undefined;
309
- errorMessage?: string | undefined;
310
- }[] | undefined;
311
- } | undefined;
312
- };
313
- } | undefined;
314
- installation?: {
315
- messages?: {
316
- preInstallation?: string | undefined;
317
- postInstallation?: string | undefined;
318
- } | undefined;
319
- customInstallationSteps?: {
320
- script: string;
321
- name: string;
322
- description: string;
323
- }[] | undefined;
324
- } | undefined;
325
- webhooks?: ({
326
- label: string;
327
- description: string;
328
- category?: "validation" | "append" | "modification" | undefined;
329
- runtimeAction: string;
330
- requireAdobeAuth?: boolean | undefined;
331
- webhook: {
332
- webhook_method: string;
333
- webhook_type: string;
334
- batch_name: string;
335
- batch_order?: number | undefined;
336
- hook_name: string;
337
- priority?: number | undefined;
338
- required?: boolean | undefined;
339
- soft_timeout?: number | undefined;
340
- timeout?: number | undefined;
341
- method: string;
342
- fallback_error_message?: string | undefined;
343
- ttl?: number | undefined;
344
- fields?: {
345
- name: string;
346
- source?: string | undefined;
347
- }[] | undefined;
348
- rules?: {
349
- field: string;
350
- operator: string;
351
- value: string;
352
- }[] | undefined;
353
- headers?: {
354
- name: string;
355
- value: string;
356
- }[] | undefined;
357
- };
358
- } | {
359
- label: string;
360
- description: string;
361
- category?: "validation" | "append" | "modification" | undefined;
362
- webhook: {
363
- url: string;
364
- webhook_method: string;
365
- webhook_type: string;
366
- batch_name: string;
367
- batch_order?: number | undefined;
368
- hook_name: string;
369
- priority?: number | undefined;
370
- required?: boolean | undefined;
371
- soft_timeout?: number | undefined;
372
- timeout?: number | undefined;
373
- method: string;
374
- fallback_error_message?: string | undefined;
375
- ttl?: number | undefined;
376
- fields?: {
377
- name: string;
378
- source?: string | undefined;
379
- }[] | undefined;
380
- rules?: {
381
- field: string;
382
- operator: string;
383
- value: string;
384
- }[] | undefined;
385
- headers?: {
386
- name: string;
387
- value: string;
388
- }[] | undefined;
389
- };
390
- })[] | undefined;
391
- } & {
392
- [key: string]: unknown;
393
- }>;
394
- //#endregion
395
- //#region source/config/schema/domains.d.ts
396
- /** The individual validatable domains of the app config. */
397
- declare const CommerceAppConfigSchemas: {
398
- readonly metadata: v.ObjectSchema<{
399
- readonly id: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 100, "The application id must not be longer than 100 characters">]>;
400
- readonly displayName: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string for the ${string}`>, v.NonEmptyAction<string, `The ${string} must not be empty`>]>, v.MaxLengthAction<string, 50, "The application display name must not be longer than 50 characters">]>;
401
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string for the ${string}`>, v.NonEmptyAction<string, `The ${string} must not be empty`>]>, v.MaxLengthAction<string, 255, "The metadata description must not be longer than 255 characters">]>;
402
- readonly version: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string for the ${string}`>, v.NonEmptyAction<string, `The ${string} must not be empty`>]>, v.RegexAction<string, "The version must follow semantic versioning (semver) format: Major.Minor.Patch (e.g., '1.0.0', '2.3.1')">]>;
403
- }, undefined>;
404
- readonly businessConfig: v.ObjectSchema<{
405
- readonly schema: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.VariantSchema<"type", [v.VariantSchema<"selectionMode", [v.ObjectSchema<{
406
- readonly selectionMode: v.LiteralSchema<"single", "Expected the selectionMode to be 'single'">;
407
- readonly default: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default value">, v.NonEmptyAction<string, "The default value must not be empty">]>;
408
- readonly type: v.LiteralSchema<"list", "Expected the type to be 'list'">;
409
- readonly options: v.ArraySchema<v.ObjectSchema<{
410
- readonly label: v.StringSchema<"Expected a string for the option label">;
411
- readonly value: v.StringSchema<"Expected a string for the option value">;
412
- }, undefined>, "Expected an array of list options">;
413
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
414
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
415
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
416
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
417
- }, undefined>, v.ObjectSchema<{
418
- readonly selectionMode: v.LiteralSchema<"multiple", "Expected the selectionMode to be 'multiple'">;
419
- readonly default: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for each default value">, v.NonEmptyAction<string, "Each default value must not be empty">]>, "Expected an array of default values">, readonly []>;
420
- readonly type: v.LiteralSchema<"list", "Expected the type to be 'list'">;
421
- readonly options: v.ArraySchema<v.ObjectSchema<{
422
- readonly label: v.StringSchema<"Expected a string for the option label">;
423
- readonly value: v.StringSchema<"Expected a string for the option value">;
424
- }, undefined>, "Expected an array of list options">;
425
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
426
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
427
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
428
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
429
- }, undefined>], undefined>, v.VariantSchema<"selectionMode", [v.ObjectSchema<{
430
- readonly selectionMode: v.LiteralSchema<"single", "Expected the selectionMode to be 'single'">;
431
- readonly default: v.CustomSchema<(resolvedOptions: {
432
- label: string;
433
- value: string;
434
- }[]) => string, v.ErrorMessage<v.CustomIssue> | undefined>;
435
- readonly type: v.LiteralSchema<"dynamicList", "Expected the type to be 'dynamicList'">;
436
- readonly options: v.CustomSchema<(params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
437
- label: string;
438
- value: string;
439
- }[] | Promise<{
440
- label: string;
441
- value: string;
442
- }[]>, v.ErrorMessage<v.CustomIssue> | undefined>;
443
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
444
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
445
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
446
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
447
- }, undefined>, v.ObjectSchema<{
448
- readonly selectionMode: v.LiteralSchema<"multiple", "Expected the selectionMode to be 'multiple'">;
449
- readonly default: v.OptionalSchema<v.CustomSchema<(resolvedOptions: {
450
- label: string;
451
- value: string;
452
- }[]) => string[], v.ErrorMessage<v.CustomIssue> | undefined>, undefined>;
453
- readonly type: v.LiteralSchema<"dynamicList", "Expected the type to be 'dynamicList'">;
454
- readonly options: v.CustomSchema<(params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
455
- label: string;
456
- value: string;
457
- }[] | Promise<{
458
- label: string;
459
- value: string;
460
- }[]>, v.ErrorMessage<v.CustomIssue> | undefined>;
461
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
462
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
463
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
464
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
465
- }, undefined>], undefined>, v.ObjectSchema<{
466
- readonly type: v.LiteralSchema<"text", "Expected the type to be 'text'">;
467
- readonly default: v.OptionalSchema<v.StringSchema<"Expected a string for the default value">, "">;
468
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
469
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
470
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
471
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
472
- }, undefined>, v.ObjectSchema<{
473
- readonly type: v.LiteralSchema<"password", "Expected the type to be 'password'">;
474
- readonly default: v.OptionalSchema<v.LiteralSchema<"", "Password fields do not have a default value">, "">;
475
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
476
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
477
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
478
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
479
- }, undefined>, v.ObjectSchema<{
480
- readonly type: v.LiteralSchema<"email", "Expected the type to be 'email'">;
481
- readonly default: v.OptionalSchema<v.UnionSchema<[v.LiteralSchema<"", undefined>, v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default email value">, v.EmailAction<string, "The email must be a valid email address">]>], undefined>, "">;
482
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
483
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
484
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
485
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
486
- }, undefined>, v.ObjectSchema<{
487
- readonly type: v.LiteralSchema<"url", "Expected the type to be 'url'">;
488
- readonly default: v.OptionalSchema<v.UnionSchema<[v.LiteralSchema<"", undefined>, v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default URL value">, v.UrlAction<string, "The URL must be a valid URL">]>], undefined>, "">;
489
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
490
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
491
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
492
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
493
- }, undefined>, v.ObjectSchema<{
494
- readonly type: v.LiteralSchema<"tel", "Expected the type to be 'tel'">;
495
- readonly default: v.OptionalSchema<v.UnionSchema<[v.LiteralSchema<"", undefined>, v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default phone number value">, v.RegexAction<string, "The phone number must contain only numbers and/or country codes">]>], undefined>, "">;
496
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
497
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
498
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
499
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
500
- }, undefined>, v.ObjectSchema<{
501
- readonly type: v.LiteralSchema<"boolean", "Expected the type to be 'boolean'">;
502
- readonly default: v.OptionalSchema<v.BooleanSchema<"Expected a boolean for the default value">, false>;
503
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
504
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
505
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
506
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
507
- }, undefined>], undefined>, "Expected an array of configuration fields">, v.MinLengthAction<({
508
- selectionMode: "single";
509
- default: string;
510
- type: "list";
511
- options: {
512
- label: string;
513
- value: string;
514
- }[];
515
- name: string;
516
- label?: string | undefined;
517
- description?: string | undefined;
518
- env?: ("paas" | "saas")[] | undefined;
519
- } | {
520
- selectionMode: "multiple";
521
- default: string[];
522
- type: "list";
523
- options: {
524
- label: string;
525
- value: string;
526
- }[];
527
- name: string;
528
- label?: string | undefined;
529
- description?: string | undefined;
530
- env?: ("paas" | "saas")[] | undefined;
531
- } | {
532
- selectionMode: "single";
533
- default: (resolvedOptions: {
534
- label: string;
535
- value: string;
536
- }[]) => string;
537
- type: "dynamicList";
538
- options: (params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
539
- label: string;
540
- value: string;
541
- }[] | Promise<{
542
- label: string;
543
- value: string;
544
- }[]>;
545
- name: string;
546
- label?: string | undefined;
547
- description?: string | undefined;
548
- env?: ("paas" | "saas")[] | undefined;
549
- } | {
550
- selectionMode: "multiple";
551
- default?: ((resolvedOptions: {
552
- label: string;
553
- value: string;
554
- }[]) => string[]) | undefined;
555
- type: "dynamicList";
556
- options: (params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
557
- label: string;
558
- value: string;
559
- }[] | Promise<{
560
- label: string;
561
- value: string;
562
- }[]>;
563
- name: string;
564
- label?: string | undefined;
565
- description?: string | undefined;
566
- env?: ("paas" | "saas")[] | undefined;
567
- } | {
568
- type: "text";
569
- default: string;
570
- name: string;
571
- label?: string | undefined;
572
- description?: string | undefined;
573
- env?: ("paas" | "saas")[] | undefined;
574
- } | {
575
- type: "password";
576
- default: "";
577
- name: string;
578
- label?: string | undefined;
579
- description?: string | undefined;
580
- env?: ("paas" | "saas")[] | undefined;
581
- } | {
582
- type: "email";
583
- default: string;
584
- name: string;
585
- label?: string | undefined;
586
- description?: string | undefined;
587
- env?: ("paas" | "saas")[] | undefined;
588
- } | {
589
- type: "url";
590
- default: string;
591
- name: string;
592
- label?: string | undefined;
593
- description?: string | undefined;
594
- env?: ("paas" | "saas")[] | undefined;
595
- } | {
596
- type: "tel";
597
- default: string;
598
- name: string;
599
- label?: string | undefined;
600
- description?: string | undefined;
601
- env?: ("paas" | "saas")[] | undefined;
602
- } | {
603
- type: "boolean";
604
- default: boolean;
605
- name: string;
606
- label?: string | undefined;
607
- description?: string | undefined;
608
- env?: ("paas" | "saas")[] | undefined;
609
- })[], 1, "At least one configuration parameter is required">]>, readonly []>;
610
- }, undefined>;
611
- readonly eventing: v.ObjectSchema<{
612
- readonly commerce: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
613
- readonly provider: v.ObjectSchema<{
614
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
615
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
616
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
617
- }, undefined>;
618
- readonly events: v.ArraySchema<v.ObjectSchema<{
619
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must start with \"plugin.\" or \"observer.\" followed by one or more dot-separated lowercase segments containing letters and underscores only (e.g., \"observer.order_placed\", \"plugin.sales.api.order_management.place\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
620
- readonly fields: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
621
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Field name must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), dashes (-), dots (.), and square brackets ([, ]), or be exactly \"*\"">]>;
622
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
623
- }, undefined>, "Expected an array of event field objects with a 'name' property">, v.MinLengthAction<{
624
- name: string;
625
- source?: string | undefined;
626
- }[], 1, "The Commerce event configuration must define at least one field">]>;
627
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
628
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
629
- readonly operator: v.UnionSchema<v.LiteralSchema<"regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange", undefined>[], `Operator must be one of: ${string}`>;
630
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
631
- }, undefined>, "Expected an array of event rules with field, operator, and value">, undefined>;
632
- readonly destination: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
633
- readonly hipaa_audit_required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
634
- readonly priority: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
635
- readonly force: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
636
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
637
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
638
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
639
- }, undefined>, "Expected an array of Commerce events">;
640
- }, undefined>, "Expected an array of Commerce event sources">, v.CheckAction<{
641
- provider: {
642
- label: string;
643
- description: string;
644
- key?: string | undefined;
645
- };
646
- events: {
647
- name: string;
648
- fields: {
649
- name: string;
650
- source?: string | undefined;
651
- }[];
652
- rules?: {
653
- field: string;
654
- operator: "regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange";
655
- value: string;
656
- }[] | undefined;
657
- destination?: string | undefined;
658
- hipaa_audit_required?: boolean | undefined;
659
- priority?: boolean | undefined;
660
- force?: boolean | undefined;
661
- label: string;
662
- description: string;
663
- runtimeActions: string[];
664
- }[];
665
- }[], "Commerce provider labels must be unique">]>, undefined>;
666
- readonly external: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
667
- readonly provider: v.ObjectSchema<{
668
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
669
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
670
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
671
- }, undefined>;
672
- readonly events: v.ArraySchema<v.ObjectSchema<{
673
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must contain only letters, digits, underscores, hyphens, and dots (e.g., \"external_event\", \"webhook.received\", \"my-event_123\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
674
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
675
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
676
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
677
- }, undefined>, "Expected an array of external events">;
678
- }, undefined>, "Expected an array of external event sources">, v.CheckAction<{
679
- provider: {
680
- label: string;
681
- description: string;
682
- key?: string | undefined;
683
- };
684
- events: {
685
- name: string;
686
- label: string;
687
- description: string;
688
- runtimeActions: string[];
689
- }[];
690
- }[], "External provider labels must be unique">]>, undefined>;
691
- }, undefined>;
692
- readonly installation: v.ObjectSchema<{
693
- readonly messages: v.OptionalSchema<v.ObjectSchema<{
694
- readonly preInstallation: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.MaxLengthAction<string, 1000, "The preInstallation message must not be longer than 1000 characters">]>, undefined>;
695
- readonly postInstallation: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.MaxLengthAction<string, 1000, "The postInstallation message must not be longer than 1000 characters">]>, undefined>;
696
- }, undefined>, undefined>;
697
- readonly customInstallationSteps: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
698
- readonly script: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Script path must end with .js (e.g., \"./setup.js\", \"./scripts/setup.js\", or \"../../scripts/setup.js\")">]>;
699
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.MaxLengthAction<string, 255, "The step name must not be longer than 255 characters">]>;
700
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.MaxLengthAction<string, 255, "The step description must not be longer than 255 characters">]>;
701
- }, undefined>, "Expected an array of custom installation steps">, undefined>, v.CheckAction<{
702
- script: string;
703
- name: string;
704
- description: string;
705
- }[] | undefined, "Duplicate step names detected in custom installation steps. Each step must have a unique name.">]>;
706
- }, undefined>;
707
- readonly webhooks: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.ObjectSchema<{
708
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
709
- readonly description: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
710
- readonly category: v.OptionalSchema<v.PicklistSchema<readonly ["validation", "append", "modification"], `Webhook category must be one of: ${string}`>, undefined>;
711
- readonly runtimeAction: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
712
- readonly requireAdobeAuth: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
713
- readonly webhook: v.ObjectSchema<{
714
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
715
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
716
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
717
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
718
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
719
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
720
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
721
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
722
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
723
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
724
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
725
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
726
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
727
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
728
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
729
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
730
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
731
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
732
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
733
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
734
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
735
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
736
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
737
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
738
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
739
- }, undefined>;
740
- }, undefined>, v.ObjectSchema<{
741
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
742
- readonly description: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
743
- readonly category: v.OptionalSchema<v.PicklistSchema<readonly ["validation", "append", "modification"], `Webhook category must be one of: ${string}`>, undefined>;
744
- readonly webhook: v.ObjectSchema<{
745
- readonly url: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.UrlAction<string, "The 'url' field must be a valid absolute URL (e.g., 'https://example.com/webhook')">]>;
746
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
747
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
748
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
749
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
750
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
751
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
752
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
753
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
754
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
755
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
756
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
757
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
758
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
759
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
760
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
761
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
762
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
763
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
764
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
765
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
766
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
767
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
768
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
769
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
770
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
771
- }, undefined>;
772
- }, undefined>], "Each webhook entry must define either a 'runtimeAction' (to resolve the URL from a runtime action) or an explicit 'url' inside the 'webhook' object, but not both">, "Expected an array of webhook entries">, v.MinLengthAction<({
773
- label: string;
774
- description: string;
775
- category?: "validation" | "append" | "modification" | undefined;
776
- runtimeAction: string;
777
- requireAdobeAuth?: boolean | undefined;
778
- webhook: {
779
- webhook_method: string;
780
- webhook_type: string;
781
- batch_name: string;
782
- batch_order?: number | undefined;
783
- hook_name: string;
784
- priority?: number | undefined;
785
- required?: boolean | undefined;
786
- soft_timeout?: number | undefined;
787
- timeout?: number | undefined;
788
- method: string;
789
- fallback_error_message?: string | undefined;
790
- ttl?: number | undefined;
791
- fields?: {
792
- name: string;
793
- source?: string | undefined;
794
- }[] | undefined;
795
- rules?: {
796
- field: string;
797
- operator: string;
798
- value: string;
799
- }[] | undefined;
800
- headers?: {
801
- name: string;
802
- value: string;
803
- }[] | undefined;
804
- };
805
- } | {
806
- label: string;
807
- description: string;
808
- category?: "validation" | "append" | "modification" | undefined;
809
- webhook: {
810
- url: string;
811
- webhook_method: string;
812
- webhook_type: string;
813
- batch_name: string;
814
- batch_order?: number | undefined;
815
- hook_name: string;
816
- priority?: number | undefined;
817
- required?: boolean | undefined;
818
- soft_timeout?: number | undefined;
819
- timeout?: number | undefined;
820
- method: string;
821
- fallback_error_message?: string | undefined;
822
- ttl?: number | undefined;
823
- fields?: {
824
- name: string;
825
- source?: string | undefined;
826
- }[] | undefined;
827
- rules?: {
828
- field: string;
829
- operator: string;
830
- value: string;
831
- }[] | undefined;
832
- headers?: {
833
- name: string;
834
- value: string;
835
- }[] | undefined;
836
- };
837
- })[], 1, "webhooks array must contain at least one webhook when present">]>, undefined>;
838
- readonly "businessConfig.schema": v.SchemaWithPipe<readonly [v.ArraySchema<v.VariantSchema<"type", [v.VariantSchema<"selectionMode", [v.ObjectSchema<{
839
- readonly selectionMode: v.LiteralSchema<"single", "Expected the selectionMode to be 'single'">;
840
- readonly default: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default value">, v.NonEmptyAction<string, "The default value must not be empty">]>;
841
- readonly type: v.LiteralSchema<"list", "Expected the type to be 'list'">;
842
- readonly options: v.ArraySchema<v.ObjectSchema<{
843
- readonly label: v.StringSchema<"Expected a string for the option label">;
844
- readonly value: v.StringSchema<"Expected a string for the option value">;
845
- }, undefined>, "Expected an array of list options">;
846
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
847
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
848
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
849
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
850
- }, undefined>, v.ObjectSchema<{
851
- readonly selectionMode: v.LiteralSchema<"multiple", "Expected the selectionMode to be 'multiple'">;
852
- readonly default: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for each default value">, v.NonEmptyAction<string, "Each default value must not be empty">]>, "Expected an array of default values">, readonly []>;
853
- readonly type: v.LiteralSchema<"list", "Expected the type to be 'list'">;
854
- readonly options: v.ArraySchema<v.ObjectSchema<{
855
- readonly label: v.StringSchema<"Expected a string for the option label">;
856
- readonly value: v.StringSchema<"Expected a string for the option value">;
857
- }, undefined>, "Expected an array of list options">;
858
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
859
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
860
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
861
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
862
- }, undefined>], undefined>, v.VariantSchema<"selectionMode", [v.ObjectSchema<{
863
- readonly selectionMode: v.LiteralSchema<"single", "Expected the selectionMode to be 'single'">;
864
- readonly default: v.CustomSchema<(resolvedOptions: {
865
- label: string;
866
- value: string;
867
- }[]) => string, v.ErrorMessage<v.CustomIssue> | undefined>;
868
- readonly type: v.LiteralSchema<"dynamicList", "Expected the type to be 'dynamicList'">;
869
- readonly options: v.CustomSchema<(params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
870
- label: string;
871
- value: string;
872
- }[] | Promise<{
873
- label: string;
874
- value: string;
875
- }[]>, v.ErrorMessage<v.CustomIssue> | undefined>;
876
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
877
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
878
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
879
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
880
- }, undefined>, v.ObjectSchema<{
881
- readonly selectionMode: v.LiteralSchema<"multiple", "Expected the selectionMode to be 'multiple'">;
882
- readonly default: v.OptionalSchema<v.CustomSchema<(resolvedOptions: {
883
- label: string;
884
- value: string;
885
- }[]) => string[], v.ErrorMessage<v.CustomIssue> | undefined>, undefined>;
886
- readonly type: v.LiteralSchema<"dynamicList", "Expected the type to be 'dynamicList'">;
887
- readonly options: v.CustomSchema<(params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
888
- label: string;
889
- value: string;
890
- }[] | Promise<{
891
- label: string;
892
- value: string;
893
- }[]>, v.ErrorMessage<v.CustomIssue> | undefined>;
894
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
895
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
896
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
897
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
898
- }, undefined>], undefined>, v.ObjectSchema<{
899
- readonly type: v.LiteralSchema<"text", "Expected the type to be 'text'">;
900
- readonly default: v.OptionalSchema<v.StringSchema<"Expected a string for the default value">, "">;
901
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
902
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
903
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
904
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
905
- }, undefined>, v.ObjectSchema<{
906
- readonly type: v.LiteralSchema<"password", "Expected the type to be 'password'">;
907
- readonly default: v.OptionalSchema<v.LiteralSchema<"", "Password fields do not have a default value">, "">;
908
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
909
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
910
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
911
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
912
- }, undefined>, v.ObjectSchema<{
913
- readonly type: v.LiteralSchema<"email", "Expected the type to be 'email'">;
914
- readonly default: v.OptionalSchema<v.UnionSchema<[v.LiteralSchema<"", undefined>, v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default email value">, v.EmailAction<string, "The email must be a valid email address">]>], undefined>, "">;
915
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
916
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
917
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
918
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
919
- }, undefined>, v.ObjectSchema<{
920
- readonly type: v.LiteralSchema<"url", "Expected the type to be 'url'">;
921
- readonly default: v.OptionalSchema<v.UnionSchema<[v.LiteralSchema<"", undefined>, v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default URL value">, v.UrlAction<string, "The URL must be a valid URL">]>], undefined>, "">;
922
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
923
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
924
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
925
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
926
- }, undefined>, v.ObjectSchema<{
927
- readonly type: v.LiteralSchema<"tel", "Expected the type to be 'tel'">;
928
- readonly default: v.OptionalSchema<v.UnionSchema<[v.LiteralSchema<"", undefined>, v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the default phone number value">, v.RegexAction<string, "The phone number must contain only numbers and/or country codes">]>], undefined>, "">;
929
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
930
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
931
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
932
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
933
- }, undefined>, v.ObjectSchema<{
934
- readonly type: v.LiteralSchema<"boolean", "Expected the type to be 'boolean'">;
935
- readonly default: v.OptionalSchema<v.BooleanSchema<"Expected a boolean for the default value">, false>;
936
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field name">, v.NonEmptyAction<string, "The field name must not be empty">]>;
937
- readonly label: v.OptionalSchema<v.StringSchema<"Expected a string for the field label">, undefined>;
938
- readonly description: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string for the field description">, v.CheckAction<string, "Field description contains an invalid markdown URL.">]>, undefined>;
939
- readonly env: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["paas", "saas"], `Expected one of: ${string}`>, "Expected an array of commerce environments for the field \"env\"">, v.NonEmptyAction<("paas" | "saas")[], "The \"env\" array must contain at least one commerce environment">]>, undefined>;
940
- }, undefined>], undefined>, "Expected an array of configuration fields">, v.MinLengthAction<({
941
- selectionMode: "single";
942
- default: string;
943
- type: "list";
944
- options: {
945
- label: string;
946
- value: string;
947
- }[];
948
- name: string;
949
- label?: string | undefined;
950
- description?: string | undefined;
951
- env?: ("paas" | "saas")[] | undefined;
952
- } | {
953
- selectionMode: "multiple";
954
- default: string[];
955
- type: "list";
956
- options: {
957
- label: string;
958
- value: string;
959
- }[];
960
- name: string;
961
- label?: string | undefined;
962
- description?: string | undefined;
963
- env?: ("paas" | "saas")[] | undefined;
964
- } | {
965
- selectionMode: "single";
966
- default: (resolvedOptions: {
967
- label: string;
968
- value: string;
969
- }[]) => string;
970
- type: "dynamicList";
971
- options: (params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
972
- label: string;
973
- value: string;
974
- }[] | Promise<{
975
- label: string;
976
- value: string;
977
- }[]>;
978
- name: string;
979
- label?: string | undefined;
980
- description?: string | undefined;
981
- env?: ("paas" | "saas")[] | undefined;
982
- } | {
983
- selectionMode: "multiple";
984
- default?: ((resolvedOptions: {
985
- label: string;
986
- value: string;
987
- }[]) => string[]) | undefined;
988
- type: "dynamicList";
989
- options: (params: import("@adobe/aio-commerce-lib-core/params").RuntimeActionParams) => {
990
- label: string;
991
- value: string;
992
- }[] | Promise<{
993
- label: string;
994
- value: string;
995
- }[]>;
996
- name: string;
997
- label?: string | undefined;
998
- description?: string | undefined;
999
- env?: ("paas" | "saas")[] | undefined;
1000
- } | {
1001
- type: "text";
1002
- default: string;
1003
- name: string;
1004
- label?: string | undefined;
1005
- description?: string | undefined;
1006
- env?: ("paas" | "saas")[] | undefined;
1007
- } | {
1008
- type: "password";
1009
- default: "";
1010
- name: string;
1011
- label?: string | undefined;
1012
- description?: string | undefined;
1013
- env?: ("paas" | "saas")[] | undefined;
1014
- } | {
1015
- type: "email";
1016
- default: string;
1017
- name: string;
1018
- label?: string | undefined;
1019
- description?: string | undefined;
1020
- env?: ("paas" | "saas")[] | undefined;
1021
- } | {
1022
- type: "url";
1023
- default: string;
1024
- name: string;
1025
- label?: string | undefined;
1026
- description?: string | undefined;
1027
- env?: ("paas" | "saas")[] | undefined;
1028
- } | {
1029
- type: "tel";
1030
- default: string;
1031
- name: string;
1032
- label?: string | undefined;
1033
- description?: string | undefined;
1034
- env?: ("paas" | "saas")[] | undefined;
1035
- } | {
1036
- type: "boolean";
1037
- default: boolean;
1038
- name: string;
1039
- label?: string | undefined;
1040
- description?: string | undefined;
1041
- env?: ("paas" | "saas")[] | undefined;
1042
- })[], 1, "At least one configuration parameter is required">]>;
1043
- readonly "eventing.commerce": v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1044
- readonly provider: v.ObjectSchema<{
1045
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
1046
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
1047
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
1048
- }, undefined>;
1049
- readonly events: v.ArraySchema<v.ObjectSchema<{
1050
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must start with \"plugin.\" or \"observer.\" followed by one or more dot-separated lowercase segments containing letters and underscores only (e.g., \"observer.order_placed\", \"plugin.sales.api.order_management.place\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1051
- readonly fields: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1052
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Field name must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), dashes (-), dots (.), and square brackets ([, ]), or be exactly \"*\"">]>;
1053
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1054
- }, undefined>, "Expected an array of event field objects with a 'name' property">, v.MinLengthAction<{
1055
- name: string;
1056
- source?: string | undefined;
1057
- }[], 1, "The Commerce event configuration must define at least one field">]>;
1058
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1059
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1060
- readonly operator: v.UnionSchema<v.LiteralSchema<"regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange", undefined>[], `Operator must be one of: ${string}`>;
1061
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1062
- }, undefined>, "Expected an array of event rules with field, operator, and value">, undefined>;
1063
- readonly destination: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1064
- readonly hipaa_audit_required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1065
- readonly priority: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1066
- readonly force: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1067
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1068
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1069
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1070
- }, undefined>, "Expected an array of Commerce events">;
1071
- }, undefined>, "Expected an array of Commerce event sources">, v.CheckAction<{
1072
- provider: {
1073
- label: string;
1074
- description: string;
1075
- key?: string | undefined;
1076
- };
1077
- events: {
1078
- name: string;
1079
- fields: {
1080
- name: string;
1081
- source?: string | undefined;
1082
- }[];
1083
- rules?: {
1084
- field: string;
1085
- operator: "regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange";
1086
- value: string;
1087
- }[] | undefined;
1088
- destination?: string | undefined;
1089
- hipaa_audit_required?: boolean | undefined;
1090
- priority?: boolean | undefined;
1091
- force?: boolean | undefined;
1092
- label: string;
1093
- description: string;
1094
- runtimeActions: string[];
1095
- }[];
1096
- }[], "Commerce provider labels must be unique">]>;
1097
- readonly "eventing.external": v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1098
- readonly provider: v.ObjectSchema<{
1099
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
1100
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
1101
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
1102
- }, undefined>;
1103
- readonly events: v.ArraySchema<v.ObjectSchema<{
1104
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must contain only letters, digits, underscores, hyphens, and dots (e.g., \"external_event\", \"webhook.received\", \"my-event_123\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1105
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1106
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1107
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1108
- }, undefined>, "Expected an array of external events">;
1109
- }, undefined>, "Expected an array of external event sources">, v.CheckAction<{
1110
- provider: {
1111
- label: string;
1112
- description: string;
1113
- key?: string | undefined;
1114
- };
1115
- events: {
1116
- name: string;
1117
- label: string;
1118
- description: string;
1119
- runtimeActions: string[];
1120
- }[];
1121
- }[], "External provider labels must be unique">]>;
1122
- readonly "installation.customInstallationSteps": v.ArraySchema<v.ObjectSchema<{
1123
- readonly script: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Script path must end with .js (e.g., \"./setup.js\", \"./scripts/setup.js\", or \"../../scripts/setup.js\")">]>;
1124
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.MaxLengthAction<string, 255, "The step name must not be longer than 255 characters">]>;
1125
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.MaxLengthAction<string, 255, "The step description must not be longer than 255 characters">]>;
1126
- }, undefined>, "Expected an array of custom installation steps">;
1127
- readonly adminUiSdk: v.ObjectSchema<{
1128
- readonly registration: v.ObjectSchema<{
1129
- readonly menuItems: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1130
- readonly id: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1131
- readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1132
- readonly parent: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1133
- readonly sortOrder: v.OptionalSchema<v.NumberSchema<undefined>, undefined>;
1134
- readonly isSection: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1135
- readonly sandbox: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string value for \"sandbox\"">, v.CheckAction<string, `sandbox must contain only single-space-separated values from: ${string}`>]>, undefined>;
1136
- }, undefined>, undefined>, undefined>;
1137
- readonly order: v.OptionalSchema<v.ObjectSchema<{
1138
- readonly massActions: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1139
- readonly displayIframe: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1140
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1141
- readonly sandbox: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string value for \"sandbox\"">, v.CheckAction<string, `sandbox must contain only single-space-separated values from: ${string}`>]>, undefined>;
1142
- readonly actionId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1143
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1144
- readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1145
- readonly confirm: v.OptionalSchema<v.ObjectSchema<{
1146
- readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1147
- readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1148
- }, undefined>, undefined>;
1149
- readonly path: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1150
- } & {
1151
- selectionLimit: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1152
- }, undefined>, v.PipeItem<{
1153
- displayIframe?: boolean | undefined;
1154
- timeout?: number | undefined;
1155
- sandbox?: string | undefined;
1156
- actionId: string;
1157
- label: string;
1158
- title?: string | undefined;
1159
- confirm?: {
1160
- title?: string | undefined;
1161
- message?: string | undefined;
1162
- } | undefined;
1163
- path: string;
1164
- selectionLimit?: number | undefined;
1165
- }, unknown, v.BaseIssue<unknown>>]>, undefined>, undefined>;
1166
- readonly gridColumns: v.OptionalSchema<v.ObjectSchema<{
1167
- readonly data: v.ObjectSchema<{
1168
- readonly meshId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1169
- }, undefined>;
1170
- readonly properties: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1171
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1172
- readonly columnId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1173
- readonly type: v.PicklistSchema<["boolean", "date", "float", "integer", "string"], undefined>;
1174
- readonly align: v.PicklistSchema<["left", "right", "center"], undefined>;
1175
- }, undefined>, undefined>, v.MinLengthAction<{
1176
- label: string;
1177
- columnId: string;
1178
- type: "string" | "boolean" | "date" | "float" | "integer";
1179
- align: "left" | "right" | "center";
1180
- }[], 1, "At least one grid column property is required">]>;
1181
- }, undefined>, undefined>;
1182
- readonly viewButtons: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1183
- readonly displayIframe: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1184
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1185
- readonly sandbox: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string value for \"sandbox\"">, v.CheckAction<string, `sandbox must contain only single-space-separated values from: ${string}`>]>, undefined>;
1186
- readonly buttonId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1187
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1188
- readonly confirm: v.OptionalSchema<v.ObjectSchema<{
1189
- readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1190
- }, undefined>, undefined>;
1191
- readonly path: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1192
- readonly level: v.OptionalSchema<v.PicklistSchema<[-1, 0, 1], undefined>, undefined>;
1193
- readonly sortOrder: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1194
- }, undefined>, v.PipeItem<{
1195
- displayIframe?: boolean | undefined;
1196
- timeout?: number | undefined;
1197
- sandbox?: string | undefined;
1198
- buttonId: string;
1199
- label: string;
1200
- confirm?: {
1201
- message?: string | undefined;
1202
- } | undefined;
1203
- path: string;
1204
- level?: 0 | 1 | -1 | undefined;
1205
- sortOrder?: number | undefined;
1206
- }, unknown, v.BaseIssue<unknown>>]>, undefined>, undefined>;
1207
- readonly customFees: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1208
- readonly id: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1209
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1210
- readonly value: v.NumberSchema<"Custom fee value must be a number">;
1211
- readonly orderMinimumAmount: v.OptionalSchema<v.NumberSchema<"orderMinimumAmount must be a number">, undefined>;
1212
- readonly applyFeeOnLastInvoice: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1213
- readonly applyFeeOnLastCreditMemo: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1214
- }, undefined>, undefined>, undefined>;
1215
- }, undefined>, undefined>;
1216
- readonly product: v.OptionalSchema<v.ObjectSchema<{
1217
- readonly massActions: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1218
- readonly displayIframe: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1219
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1220
- readonly sandbox: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string value for \"sandbox\"">, v.CheckAction<string, `sandbox must contain only single-space-separated values from: ${string}`>]>, undefined>;
1221
- readonly actionId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1222
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1223
- readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1224
- readonly confirm: v.OptionalSchema<v.ObjectSchema<{
1225
- readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1226
- readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1227
- }, undefined>, undefined>;
1228
- readonly path: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1229
- } & {
1230
- productSelectLimit: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1231
- }, undefined>, v.PipeItem<{
1232
- displayIframe?: boolean | undefined;
1233
- timeout?: number | undefined;
1234
- sandbox?: string | undefined;
1235
- actionId: string;
1236
- label: string;
1237
- title?: string | undefined;
1238
- confirm?: {
1239
- title?: string | undefined;
1240
- message?: string | undefined;
1241
- } | undefined;
1242
- path: string;
1243
- productSelectLimit?: number | undefined;
1244
- }, unknown, v.BaseIssue<unknown>>]>, undefined>, undefined>;
1245
- readonly gridColumns: v.OptionalSchema<v.ObjectSchema<{
1246
- readonly data: v.ObjectSchema<{
1247
- readonly meshId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1248
- }, undefined>;
1249
- readonly properties: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1250
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1251
- readonly columnId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1252
- readonly type: v.PicklistSchema<["boolean", "date", "float", "integer", "string"], undefined>;
1253
- readonly align: v.PicklistSchema<["left", "right", "center"], undefined>;
1254
- }, undefined>, undefined>, v.MinLengthAction<{
1255
- label: string;
1256
- columnId: string;
1257
- type: "string" | "boolean" | "date" | "float" | "integer";
1258
- align: "left" | "right" | "center";
1259
- }[], 1, "At least one grid column property is required">]>;
1260
- }, undefined>, undefined>;
1261
- }, undefined>, undefined>;
1262
- readonly customer: v.OptionalSchema<v.ObjectSchema<{
1263
- readonly massActions: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
1264
- readonly displayIframe: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1265
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1266
- readonly sandbox: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<"Expected a string value for \"sandbox\"">, v.CheckAction<string, `sandbox must contain only single-space-separated values from: ${string}`>]>, undefined>;
1267
- readonly actionId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1268
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1269
- readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1270
- readonly confirm: v.OptionalSchema<v.ObjectSchema<{
1271
- readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1272
- readonly message: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1273
- }, undefined>, undefined>;
1274
- readonly path: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1275
- } & {
1276
- customerSelectLimit: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1277
- }, undefined>, v.PipeItem<{
1278
- displayIframe?: boolean | undefined;
1279
- timeout?: number | undefined;
1280
- sandbox?: string | undefined;
1281
- actionId: string;
1282
- label: string;
1283
- title?: string | undefined;
1284
- confirm?: {
1285
- title?: string | undefined;
1286
- message?: string | undefined;
1287
- } | undefined;
1288
- path: string;
1289
- customerSelectLimit?: number | undefined;
1290
- }, unknown, v.BaseIssue<unknown>>]>, undefined>, undefined>;
1291
- readonly gridColumns: v.OptionalSchema<v.ObjectSchema<{
1292
- readonly data: v.ObjectSchema<{
1293
- readonly meshId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1294
- }, undefined>;
1295
- readonly properties: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1296
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1297
- readonly columnId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1298
- readonly type: v.PicklistSchema<["boolean", "date", "float", "integer", "string"], undefined>;
1299
- readonly align: v.PicklistSchema<["left", "right", "center"], undefined>;
1300
- }, undefined>, undefined>, v.MinLengthAction<{
1301
- label: string;
1302
- columnId: string;
1303
- type: "string" | "boolean" | "date" | "float" | "integer";
1304
- align: "left" | "right" | "center";
1305
- }[], 1, "At least one grid column property is required">]>;
1306
- }, undefined>, undefined>;
1307
- }, undefined>, undefined>;
1308
- readonly bannerNotification: v.OptionalSchema<v.ObjectSchema<{
1309
- readonly massActions: v.OptionalSchema<v.ObjectSchema<{
1310
- readonly order: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1311
- readonly actionId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1312
- readonly successMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1313
- readonly errorMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1314
- }, undefined>, undefined>, undefined>;
1315
- readonly product: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1316
- readonly actionId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1317
- readonly successMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1318
- readonly errorMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1319
- }, undefined>, undefined>, undefined>;
1320
- readonly customer: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1321
- readonly actionId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1322
- readonly successMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1323
- readonly errorMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1324
- }, undefined>, undefined>, undefined>;
1325
- }, undefined>, undefined>;
1326
- readonly orderViewButtons: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1327
- readonly buttonId: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1328
- readonly successMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1329
- readonly errorMessage: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1330
- }, undefined>, undefined>, undefined>;
1331
- }, undefined>, undefined>;
1332
- }, undefined>;
1333
- }, undefined>;
1334
- };
1335
- /** Individual validatable domains of the commerce app config. */
1336
- type CommerceAppConfigDomain = keyof typeof CommerceAppConfigSchemas;
1337
- /**
1338
- * Get the config domains that are present in the config.
1339
- * @param config - The configuration to check.
1340
- */
1341
- declare function getConfigDomains(config: CommerceAppConfigOutputModel): Set<CommerceAppConfigDomain>;
1342
- /**
1343
- * Check if the config has a specific domain.
1344
- * @param config - The configuration to check.
1345
- * @param domain - The domain to check.
1346
- */
1347
- declare function hasConfigDomain(config: CommerceAppConfigOutputModel, domain: CommerceAppConfigDomain): boolean;
1348
- //#endregion
1349
- //#region source/config/lib/validate.d.ts
1350
- /**
1351
- * Validates a complete commerce app configuration object against the schema.
1352
- *
1353
- * @param config - The configuration object to validate.
1354
- * @returns The validated and typed configuration output model.
1355
- *
1356
- * @throws {CommerceSdkValidationError} If the configuration is invalid, with
1357
- * detailed validation issues included.
1358
- *
1359
- * @example
1360
- * ```typescript
1361
- * const config = {
1362
- * businessConfiguration: {
1363
- * // ... configuration data
1364
- * }
1365
- * };
1366
- *
1367
- * try {
1368
- * const validatedConfig = validateCommerceAppConfig(config);
1369
- * // Use validatedConfig safely
1370
- * } catch (error) {
1371
- * if (error instanceof CommerceSdkValidationError) {
1372
- * console.error('Validation failed:', error.display());
1373
- * }
1374
- * }
1375
- * ```
1376
- */
1377
- declare function validateCommerceAppConfig(config: unknown): CommerceAppConfigOutputModel;
1378
- /**
1379
- * Validates a specific domain configuration within the commerce app config.
1380
- *
1381
- * This function validates only a specific domain's configuration rather than
1382
- * the entire commerce app configuration object. It first validates that the
1383
- * domain name is valid, then validates the configuration data against the
1384
- * schema for that specific domain.
1385
- *
1386
- * @template T - The type of the domain, constrained to valid domain names.
1387
- *
1388
- * @param config - The domain configuration object to validate.
1389
- * @param domain - The name of the domain to validate (e.g., 'businessConfiguration').
1390
- * @returns The validated and typed configuration for the specified domain.
1391
- *
1392
- * @throws {CommerceSdkValidationError} If the domain name is invalid or if the
1393
- * configuration doesn't match the domain's schema.
1394
- *
1395
- * @example
1396
- * ```typescript
1397
- * const businessConfig = {
1398
- * fields: [
1399
- * {
1400
- * name: 'category',
1401
- * type: 'dropdown',
1402
- * // ... field configuration
1403
- * }
1404
- * ]
1405
- * };
1406
- *
1407
- * try {
1408
- * const validatedConfig = validateCommerceAppConfigDomain(
1409
- * businessConfig,
1410
- * 'businessConfig'
1411
- * );
1412
- * // Use validatedConfig safely
1413
- * } catch (error) {
1414
- * if (error instanceof CommerceSdkValidationError) {
1415
- * console.error('Domain validation failed:', error.issues);
1416
- * }
1417
- * }
1418
- * ```
1419
- */
1420
- declare function validateCommerceAppConfigDomain<T extends CommerceAppConfigDomain>(config: unknown, domain: T): NonNullable<Get<CommerceAppConfigOutputModel, T>>;
1421
- //#endregion
1422
- //#region source/config/schema/business-configuration.d.ts
1423
- /** Any commerce app config — input contract or validated output. */
1424
- type AnyCommerceAppConfig = CommerceAppConfig | CommerceAppConfigOutputModel;
1425
- /** Config type when business config is present. */
1426
- type AppConfigWithBusinessConfig<T extends AnyCommerceAppConfig> = T & {
1427
- businessConfig: NonNullable<T["businessConfig"]>;
1428
- };
1429
- /** Config type when business config schema is present. */
1430
- type AppConfigWithBusinessConfigSchema<T extends AnyCommerceAppConfig> = T & {
1431
- businessConfig: NonNullable<T["businessConfig"]> & {
1432
- schema: NonNullable<NonNullable<T["businessConfig"]>["schema"]>;
1433
- };
1434
- };
1435
- /**
1436
- * Check if config has business config.
1437
- * @param config - The configuration to check.
1438
- */
1439
- declare function hasBusinessConfig<T extends AnyCommerceAppConfig>(config: T): config is T & AppConfigWithBusinessConfig<T>;
1440
- /**
1441
- * Check if config has business config schema.
1442
- * @param config - The configuration to check.
1443
- */
1444
- declare function hasBusinessConfigSchema<T extends AnyCommerceAppConfig>(config: T): config is T & AppConfigWithBusinessConfigSchema<T>;
1445
- //#endregion
1446
- //#region source/config/schema/eventing.d.ts
1447
- /** Schema for event provider configuration */
1448
- declare const ProviderSchema: v.ObjectSchema<{
1449
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
1450
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
1451
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
1452
- }, undefined>;
1453
- /** Schema for Commerce event configuration */
1454
- declare const CommerceEventSchema: v.ObjectSchema<{
1455
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must start with \"plugin.\" or \"observer.\" followed by one or more dot-separated lowercase segments containing letters and underscores only (e.g., \"observer.order_placed\", \"plugin.sales.api.order_management.place\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1456
- readonly fields: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1457
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Field name must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), dashes (-), dots (.), and square brackets ([, ]), or be exactly \"*\"">]>;
1458
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1459
- }, undefined>, "Expected an array of event field objects with a 'name' property">, v.MinLengthAction<{
1460
- name: string;
1461
- source?: string | undefined;
1462
- }[], 1, "The Commerce event configuration must define at least one field">]>;
1463
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1464
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1465
- readonly operator: v.UnionSchema<v.LiteralSchema<"regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange", undefined>[], `Operator must be one of: ${string}`>;
1466
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1467
- }, undefined>, "Expected an array of event rules with field, operator, and value">, undefined>;
1468
- readonly destination: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1469
- readonly hipaa_audit_required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1470
- readonly priority: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1471
- readonly force: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1472
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1473
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1474
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1475
- }, undefined>;
1476
- /** Schema for external event configuration */
1477
- declare const ExternalEventSchema: v.ObjectSchema<{
1478
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must contain only letters, digits, underscores, hyphens, and dots (e.g., \"external_event\", \"webhook.received\", \"my-event_123\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1479
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1480
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1481
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1482
- }, undefined>;
1483
- /** Schema for Commerce event source configuration */
1484
- declare const CommerceEventSourceSchema: v.ObjectSchema<{
1485
- readonly provider: v.ObjectSchema<{
1486
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
1487
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
1488
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
1489
- }, undefined>;
1490
- readonly events: v.ArraySchema<v.ObjectSchema<{
1491
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must start with \"plugin.\" or \"observer.\" followed by one or more dot-separated lowercase segments containing letters and underscores only (e.g., \"observer.order_placed\", \"plugin.sales.api.order_management.place\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1492
- readonly fields: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1493
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Field name must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), dashes (-), dots (.), and square brackets ([, ]), or be exactly \"*\"">]>;
1494
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1495
- }, undefined>, "Expected an array of event field objects with a 'name' property">, v.MinLengthAction<{
1496
- name: string;
1497
- source?: string | undefined;
1498
- }[], 1, "The Commerce event configuration must define at least one field">]>;
1499
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1500
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1501
- readonly operator: v.UnionSchema<v.LiteralSchema<"regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange", undefined>[], `Operator must be one of: ${string}`>;
1502
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1503
- }, undefined>, "Expected an array of event rules with field, operator, and value">, undefined>;
1504
- readonly destination: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1505
- readonly hipaa_audit_required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1506
- readonly priority: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1507
- readonly force: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1508
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1509
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1510
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1511
- }, undefined>, "Expected an array of Commerce events">;
1512
- }, undefined>;
1513
- /** Schema for external event source configuration */
1514
- declare const ExternalEventSourceSchema: v.ObjectSchema<{
1515
- readonly provider: v.ObjectSchema<{
1516
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
1517
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
1518
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
1519
- }, undefined>;
1520
- readonly events: v.ArraySchema<v.ObjectSchema<{
1521
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must contain only letters, digits, underscores, hyphens, and dots (e.g., \"external_event\", \"webhook.received\", \"my-event_123\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1522
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1523
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1524
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1525
- }, undefined>, "Expected an array of external events">;
1526
- }, undefined>;
1527
- /** Schema for eventing configuration with separate commerce and external arrays */
1528
- declare const EventingSchema: v.ObjectSchema<{
1529
- readonly commerce: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1530
- readonly provider: v.ObjectSchema<{
1531
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
1532
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
1533
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
1534
- }, undefined>;
1535
- readonly events: v.ArraySchema<v.ObjectSchema<{
1536
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must start with \"plugin.\" or \"observer.\" followed by one or more dot-separated lowercase segments containing letters and underscores only (e.g., \"observer.order_placed\", \"plugin.sales.api.order_management.place\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1537
- readonly fields: v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1538
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Field name must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), dashes (-), dots (.), and square brackets ([, ]), or be exactly \"*\"">]>;
1539
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1540
- }, undefined>, "Expected an array of event field objects with a 'name' property">, v.MinLengthAction<{
1541
- name: string;
1542
- source?: string | undefined;
1543
- }[], 1, "The Commerce event configuration must define at least one field">]>;
1544
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1545
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1546
- readonly operator: v.UnionSchema<v.LiteralSchema<"regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange", undefined>[], `Operator must be one of: ${string}`>;
1547
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1548
- }, undefined>, "Expected an array of event rules with field, operator, and value">, undefined>;
1549
- readonly destination: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, undefined>;
1550
- readonly hipaa_audit_required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1551
- readonly priority: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1552
- readonly force: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1553
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1554
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1555
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1556
- }, undefined>, "Expected an array of Commerce events">;
1557
- }, undefined>, "Expected an array of Commerce event sources">, v.CheckAction<{
1558
- provider: {
1559
- label: string;
1560
- description: string;
1561
- key?: string | undefined;
1562
- };
1563
- events: {
1564
- name: string;
1565
- fields: {
1566
- name: string;
1567
- source?: string | undefined;
1568
- }[];
1569
- rules?: {
1570
- field: string;
1571
- operator: "regex" | "greaterThan" | "lessThan" | "equal" | "in" | "onChange";
1572
- value: string;
1573
- }[] | undefined;
1574
- destination?: string | undefined;
1575
- hipaa_audit_required?: boolean | undefined;
1576
- priority?: boolean | undefined;
1577
- force?: boolean | undefined;
1578
- label: string;
1579
- description: string;
1580
- runtimeActions: string[];
1581
- }[];
1582
- }[], "Commerce provider labels must be unique">]>, undefined>;
1583
- readonly external: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.ObjectSchema<{
1584
- readonly provider: v.ObjectSchema<{
1585
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The provider label must not be longer than 100 characters">]>;
1586
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The provider description must not be longer than 255 characters">]>;
1587
- readonly key: v.OptionalSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 50, "The provider key must not be longer than 50 characters">]>, undefined>;
1588
- }, undefined>;
1589
- readonly events: v.ArraySchema<v.ObjectSchema<{
1590
- readonly name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Event name must contain only letters, digits, underscores, hyphens, and dots (e.g., \"external_event\", \"webhook.received\", \"my-event_123\")">, v.MaxLengthAction<string, 180, "The event name must not be longer than 180 characters">]>;
1591
- readonly label: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 100, "The event label must not be longer than 100 characters">]>;
1592
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, `${string} can only contain letters, numbers, spaces, underscores, hyphens, dots, colons, parentheses, commas, @, and /`>, v.MaxLengthAction<string, 255, "The event description must not be longer than 255 characters">]>;
1593
- readonly runtimeActions: v.ArraySchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "Runtime action must be in the format \"<package>/<action>\" (e.g., \"my-package/my-action\")">]>, "Expected an array of runtime actions in the format <package>/<action>">;
1594
- }, undefined>, "Expected an array of external events">;
1595
- }, undefined>, "Expected an array of external event sources">, v.CheckAction<{
1596
- provider: {
1597
- label: string;
1598
- description: string;
1599
- key?: string | undefined;
1600
- };
1601
- events: {
1602
- name: string;
1603
- label: string;
1604
- description: string;
1605
- runtimeActions: string[];
1606
- }[];
1607
- }[], "External provider labels must be unique">]>, undefined>;
1608
- }, undefined>;
1609
- /** The eventing configuration for an Adobe Commerce application */
1610
- type EventingConfiguration = v.InferInput<typeof EventingSchema>;
1611
- /** Commerce event source configuration */
1612
- type CommerceEventSource = v.InferInput<typeof CommerceEventSourceSchema>;
1613
- /** External event source configuration */
1614
- type ExternalEventSource = v.InferInput<typeof ExternalEventSourceSchema>;
1615
- /** Commerce event configuration */
1616
- type CommerceEvent = v.InferInput<typeof CommerceEventSchema>;
1617
- /** External event configuration */
1618
- type ExternalEvent = v.InferInput<typeof ExternalEventSchema>;
1619
- /** Union type of all supported event configurations */
1620
- type AppEvent = CommerceEvent | ExternalEvent;
1621
- /** Event provider configuration */
1622
- type EventProvider = v.InferInput<typeof ProviderSchema>;
1623
- /** Config type when eventing is present. */
1624
- type EventsConfig = CommerceAppConfigOutputModel & {
1625
- eventing: NonNullable<CommerceAppConfigOutputModel["eventing"]>;
1626
- };
1627
- /** Config type when commerce event sources are present. */
1628
- type CommerceEventsConfig = SetRequiredDeep<EventsConfig, "eventing.commerce">;
1629
- /** Config type when external event sources are present. */
1630
- type ExternalEventsConfig = SetRequiredDeep<EventsConfig, "eventing.external">;
1631
- /**
1632
- * Check if config has commerce event sources.
1633
- * @param config - The configuration to check.
1634
- */
1635
- declare function hasCommerceEvents(config: CommerceAppConfigOutputModel): config is CommerceEventsConfig;
1636
- /**
1637
- * Check if config has external event sources.
1638
- * @param config - The configuration to check.
1639
- */
1640
- declare function hasExternalEvents(config: CommerceAppConfigOutputModel): config is ExternalEventsConfig;
1641
- /**
1642
- * Check if config has any eventing configuration.
1643
- * @param config - The configuration to check.
1644
- */
1645
- declare function hasEventing(config: CommerceAppConfigOutputModel): config is EventsConfig;
1646
- //#endregion
1647
- //#region source/config/schema/installation.d.ts
1648
- type InstallationConfig = CommerceAppConfigOutputModel & {
1649
- installation: NonNullable<CommerceAppConfigOutputModel["installation"]>;
1650
- };
1651
- /** Config type when custom installation steps are present. */
1652
- type ConfigWithInstallationSteps = SetRequiredDeep<InstallationConfig, "installation.customInstallationSteps">;
1653
- /**
1654
- * Check if config has custom installation settings.
1655
- * @param config - The configuration to check.
1656
- */
1657
- declare function hasCustomInstallation(config: CommerceAppConfigOutputModel): config is InstallationConfig;
1658
- /**
1659
- * Check if config has custom installation steps.
1660
- * @param config - The configuration to check.
1661
- */
1662
- declare function hasCustomInstallationSteps(config: CommerceAppConfigOutputModel): config is ConfigWithInstallationSteps;
1663
- //#endregion
1664
- //#region source/config/schema/metadata.d.ts
1665
- /** The schema for the metadata of the application. */
1666
- declare const MetadataSchema: v.ObjectSchema<{
1667
- readonly id: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.RegexAction<string, `Only alphanumeric characters and hyphens are allowed in string value of "${string}"${string}`>]>, v.MaxLengthAction<string, 100, "The application id must not be longer than 100 characters">]>;
1668
- readonly displayName: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string for the ${string}`>, v.NonEmptyAction<string, `The ${string} must not be empty`>]>, v.MaxLengthAction<string, 50, "The application display name must not be longer than 50 characters">]>;
1669
- readonly description: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string for the ${string}`>, v.NonEmptyAction<string, `The ${string} must not be empty`>]>, v.MaxLengthAction<string, 255, "The metadata description must not be longer than 255 characters">]>;
1670
- readonly version: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string for the ${string}`>, v.NonEmptyAction<string, `The ${string} must not be empty`>]>, v.RegexAction<string, "The version must follow semantic versioning (semver) format: Major.Minor.Patch (e.g., '1.0.0', '2.3.1')">]>;
1671
- }, undefined>;
1672
- /** The metadata associated to an Adobe Commerce application. */
1673
- type ApplicationMetadata = v.InferInput<typeof MetadataSchema>;
1674
- /**
1675
- * Check if config has metadata.
1676
- * @param config - The configuration to check.
1677
- */
1678
- declare function hasMetadata(config: CommerceAppConfigOutputModel): boolean;
1679
- //#endregion
1680
- //#region source/config/schema/webhooks.d.ts
1681
- /** Schema for webhook field configuration (name and optional source). */
1682
- declare const WebhookFieldSchema: v.ObjectSchema<{
1683
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1684
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1685
- }, undefined>;
1686
- /** Schema for webhook rule configuration (field, operator, value). */
1687
- declare const WebhookRuleSchema: v.ObjectSchema<{
1688
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1689
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1690
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1691
- }, undefined>;
1692
- /** Schema for webhook header configuration (name, value). */
1693
- declare const WebhookHeaderSchema: v.ObjectSchema<{
1694
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1695
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1696
- }, undefined>;
1697
- /** Schema for the nested webhook payload without url — used when runtimeAction resolves the URL at runtime. */
1698
- declare const WebhookDefinitionBaseSchema: v.ObjectSchema<{
1699
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1700
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1701
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
1702
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1703
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
1704
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1705
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1706
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1707
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1708
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1709
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1710
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1711
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1712
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1713
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1714
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
1715
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1716
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1717
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1718
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1719
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
1720
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1721
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1722
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1723
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
1724
- }, undefined>;
1725
- /** Schema for the nested webhook payload with a required url. */
1726
- declare const WebhookDefinitionWithUrlSchema: v.ObjectSchema<{
1727
- readonly url: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.UrlAction<string, "The 'url' field must be a valid absolute URL (e.g., 'https://example.com/webhook')">]>;
1728
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1729
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1730
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
1731
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1732
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
1733
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1734
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1735
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1736
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1737
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1738
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1739
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1740
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1741
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1742
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1743
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
1744
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1745
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1746
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1747
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1748
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
1749
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1750
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1751
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1752
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
1753
- }, undefined>;
1754
- /** Schema for a single webhook entry — either runtimeAction (no url) or explicit url (no runtimeAction). */
1755
- declare const WebhookEntrySchema: v.UnionSchema<[v.ObjectSchema<{
1756
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1757
- readonly description: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1758
- readonly category: v.OptionalSchema<v.PicklistSchema<readonly ["validation", "append", "modification"], `Webhook category must be one of: ${string}`>, undefined>;
1759
- readonly runtimeAction: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1760
- readonly requireAdobeAuth: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1761
- readonly webhook: v.ObjectSchema<{
1762
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1763
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1764
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
1765
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1766
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
1767
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1768
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1769
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1770
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1771
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1772
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1773
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1774
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1775
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1776
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1777
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
1778
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1779
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1780
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1781
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1782
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
1783
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1784
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1785
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1786
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
1787
- }, undefined>;
1788
- }, undefined>, v.ObjectSchema<{
1789
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1790
- readonly description: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1791
- readonly category: v.OptionalSchema<v.PicklistSchema<readonly ["validation", "append", "modification"], `Webhook category must be one of: ${string}`>, undefined>;
1792
- readonly webhook: v.ObjectSchema<{
1793
- readonly url: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.UrlAction<string, "The 'url' field must be a valid absolute URL (e.g., 'https://example.com/webhook')">]>;
1794
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1795
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1796
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
1797
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1798
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
1799
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1800
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1801
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1802
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1803
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1804
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1805
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1806
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1807
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1808
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1809
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
1810
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1811
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1812
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1813
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1814
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
1815
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1816
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1817
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1818
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
1819
- }, undefined>;
1820
- }, undefined>], "Each webhook entry must define either a 'runtimeAction' (to resolve the URL from a runtime action) or an explicit 'url' inside the 'webhook' object, but not both">;
1821
- /** Schema for the optional webhooks array (when present, must have at least one item). */
1822
- declare const WebhooksSchema: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.ObjectSchema<{
1823
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1824
- readonly description: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1825
- readonly category: v.OptionalSchema<v.PicklistSchema<readonly ["validation", "append", "modification"], `Webhook category must be one of: ${string}`>, undefined>;
1826
- readonly runtimeAction: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1827
- readonly requireAdobeAuth: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1828
- readonly webhook: v.ObjectSchema<{
1829
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1830
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1831
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
1832
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1833
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
1834
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1835
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1836
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1837
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1838
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1839
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1840
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1841
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1842
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1843
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1844
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
1845
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1846
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1847
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1848
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1849
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
1850
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1851
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1852
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1853
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
1854
- }, undefined>;
1855
- }, undefined>, v.ObjectSchema<{
1856
- readonly label: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1857
- readonly description: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1858
- readonly category: v.OptionalSchema<v.PicklistSchema<readonly ["validation", "append", "modification"], `Webhook category must be one of: ${string}`>, undefined>;
1859
- readonly webhook: v.ObjectSchema<{
1860
- readonly url: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.UrlAction<string, "The 'url' field must be a valid absolute URL (e.g., 'https://example.com/webhook')">]>;
1861
- readonly webhook_method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1862
- readonly webhook_type: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1863
- readonly batch_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "batch_name must contain only letters, numbers, and underscores">]>;
1864
- readonly batch_order: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1865
- readonly hook_name: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>, v.RegexAction<string, "hook_name must contain only letters, numbers, and underscores">]>;
1866
- readonly priority: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1867
- readonly required: v.OptionalSchema<v.BooleanSchema<`Expected a boolean value for '${string}'`>, undefined>;
1868
- readonly soft_timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1869
- readonly timeout: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1870
- readonly method: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1871
- readonly fallback_error_message: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1872
- readonly ttl: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<`Expected a number value for '${string}'`>, v.MinValueAction<number, 0, `The value of ${string} must be a non-negative number`>]>, undefined>;
1873
- readonly fields: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1874
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1875
- readonly source: v.OptionalSchema<v.StringSchema<`Expected a string value for '${string}'`>, undefined>;
1876
- }, undefined>, "Expected an array of webhook field objects">, undefined>;
1877
- readonly rules: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1878
- readonly field: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1879
- readonly operator: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1880
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1881
- }, undefined>, "Expected an array of webhook rule objects">, undefined>;
1882
- readonly headers: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1883
- readonly name: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1884
- readonly value: v.SchemaWithPipe<readonly [v.StringSchema<`Expected a string value for '${string}'`>, v.NonEmptyAction<string, `The value of "${string}" must not be empty`>]>;
1885
- }, undefined>, "Expected an array of webhook header objects">, undefined>;
1886
- }, undefined>;
1887
- }, undefined>], "Each webhook entry must define either a 'runtimeAction' (to resolve the URL from a runtime action) or an explicit 'url' inside the 'webhook' object, but not both">, "Expected an array of webhook entries">, v.MinLengthAction<({
1888
- label: string;
1889
- description: string;
1890
- category?: "validation" | "append" | "modification" | undefined;
1891
- runtimeAction: string;
1892
- requireAdobeAuth?: boolean | undefined;
1893
- webhook: {
1894
- webhook_method: string;
1895
- webhook_type: string;
1896
- batch_name: string;
1897
- batch_order?: number | undefined;
1898
- hook_name: string;
1899
- priority?: number | undefined;
1900
- required?: boolean | undefined;
1901
- soft_timeout?: number | undefined;
1902
- timeout?: number | undefined;
1903
- method: string;
1904
- fallback_error_message?: string | undefined;
1905
- ttl?: number | undefined;
1906
- fields?: {
1907
- name: string;
1908
- source?: string | undefined;
1909
- }[] | undefined;
1910
- rules?: {
1911
- field: string;
1912
- operator: string;
1913
- value: string;
1914
- }[] | undefined;
1915
- headers?: {
1916
- name: string;
1917
- value: string;
1918
- }[] | undefined;
1919
- };
1920
- } | {
1921
- label: string;
1922
- description: string;
1923
- category?: "validation" | "append" | "modification" | undefined;
1924
- webhook: {
1925
- url: string;
1926
- webhook_method: string;
1927
- webhook_type: string;
1928
- batch_name: string;
1929
- batch_order?: number | undefined;
1930
- hook_name: string;
1931
- priority?: number | undefined;
1932
- required?: boolean | undefined;
1933
- soft_timeout?: number | undefined;
1934
- timeout?: number | undefined;
1935
- method: string;
1936
- fallback_error_message?: string | undefined;
1937
- ttl?: number | undefined;
1938
- fields?: {
1939
- name: string;
1940
- source?: string | undefined;
1941
- }[] | undefined;
1942
- rules?: {
1943
- field: string;
1944
- operator: string;
1945
- value: string;
1946
- }[] | undefined;
1947
- headers?: {
1948
- name: string;
1949
- value: string;
1950
- }[] | undefined;
1951
- };
1952
- })[], 1, "webhooks array must contain at least one webhook when present">]>, undefined>;
1953
- /** Webhook field configuration */
1954
- type WebhookField = v.InferInput<typeof WebhookFieldSchema>;
1955
- /** Webhook rule configuration */
1956
- type WebhookRule = v.InferInput<typeof WebhookRuleSchema>;
1957
- /** Webhook header configuration */
1958
- type WebhookHeader = v.InferInput<typeof WebhookHeaderSchema>;
1959
- /** Nested webhook payload (webhook_method, fields, etc.) — union of base shape and url-carrying shape. */
1960
- type WebhookDefinition = v.InferInput<typeof WebhookDefinitionBaseSchema> | v.InferInput<typeof WebhookDefinitionWithUrlSchema>;
1961
- /** Single webhook entry — either runtimeAction-based or url-based (mutually exclusive at the type level). */
1962
- type WebhookEntry = v.InferInput<typeof WebhookEntrySchema>;
1963
- /** Webhooks configuration (array of webhook entries). */
1964
- type WebhooksConfiguration = v.InferInput<typeof WebhooksSchema>;
1965
- /** Config type when webhooks are present (non-empty array). */
1966
- type WebhooksConfig = CommerceAppConfigOutputModel & {
1967
- webhooks: NonNullable<CommerceAppConfigOutputModel["webhooks"]>;
1968
- };
1969
- /**
1970
- * Check if config has webhooks (non-empty array).
1971
- * @param config - The configuration to check.
1972
- */
1973
- declare function hasWebhooks(config: CommerceAppConfigOutputModel): config is WebhooksConfig;
1974
- //#endregion
1975
- export { type AdminUiSdkConfiguration, type AdminUiSdkRegistration, type AppConfigWithBusinessConfig, type AppConfigWithBusinessConfigSchema, type AppEvent, type ApplicationMetadata, type BannerNotification, type CommerceAppConfig, type CommerceAppConfigDomain, CommerceAppConfigSchemas, type CommerceEvent, type CommerceEventSource, type CommerceEventSourceSchema, type CommerceEventsConfig, type CustomFee, type CustomerMassAction, type EventProvider, type EventingConfiguration, type EventingSchema, type EventsConfig, type ExternalEvent, type ExternalEventSource, type ExternalEventSourceSchema, type ExternalEventsConfig, type GridColumns, type MenuItem, type OrderMassAction, type OrderViewButton, type ProductMassAction, type WebhookDefinition, type WebhookEntry, type WebhookField, type WebhookHeader, type WebhookRule, type WebhooksConfig, type WebhooksConfiguration, type WebhooksSchema, defineConfig, getConfigDomains, hasAdminUiSdk, hasBusinessConfig, hasBusinessConfigSchema, hasCommerceEvents, hasConfigDomain, hasCustomInstallation, hasCustomInstallationSteps, hasEventing, hasExternalEvents, hasMetadata, hasWebhooks, parseCommerceAppConfig, readCommerceAppConfig, resolveCommerceAppConfig, validateCommerceAppConfig, validateCommerceAppConfigDomain };