@wix/auto_sdk_crm_pipelines 1.0.7 → 1.0.9

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 (45) hide show
  1. package/build/cjs/index.d.ts +12 -22
  2. package/build/cjs/index.js +23 -502
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +42 -7
  5. package/build/cjs/index.typings.js +7 -486
  6. package/build/cjs/index.typings.js.map +1 -1
  7. package/build/cjs/meta.d.ts +25 -2
  8. package/build/cjs/meta.js.map +1 -1
  9. package/build/cjs/schemas.d.ts +18 -0
  10. package/build/cjs/schemas.js +36 -0
  11. package/build/cjs/schemas.js.map +1 -1
  12. package/build/es/index.d.mts +12 -22
  13. package/build/es/index.mjs +23 -492
  14. package/build/es/index.mjs.map +1 -1
  15. package/build/es/index.typings.d.mts +42 -7
  16. package/build/es/index.typings.mjs +7 -476
  17. package/build/es/index.typings.mjs.map +1 -1
  18. package/build/es/meta.d.mts +25 -2
  19. package/build/es/meta.mjs.map +1 -1
  20. package/build/es/schemas.d.mts +18 -0
  21. package/build/es/schemas.mjs +36 -0
  22. package/build/es/schemas.mjs.map +1 -1
  23. package/build/internal/cjs/index.d.ts +12 -22
  24. package/build/internal/cjs/index.js +23 -502
  25. package/build/internal/cjs/index.js.map +1 -1
  26. package/build/internal/cjs/index.typings.d.ts +42 -7
  27. package/build/internal/cjs/index.typings.js +7 -486
  28. package/build/internal/cjs/index.typings.js.map +1 -1
  29. package/build/internal/cjs/meta.d.ts +25 -2
  30. package/build/internal/cjs/meta.js.map +1 -1
  31. package/build/internal/cjs/schemas.d.ts +18 -0
  32. package/build/internal/cjs/schemas.js +36 -0
  33. package/build/internal/cjs/schemas.js.map +1 -1
  34. package/build/internal/es/index.d.mts +12 -22
  35. package/build/internal/es/index.mjs +23 -492
  36. package/build/internal/es/index.mjs.map +1 -1
  37. package/build/internal/es/index.typings.d.mts +42 -7
  38. package/build/internal/es/index.typings.mjs +7 -476
  39. package/build/internal/es/index.typings.mjs.map +1 -1
  40. package/build/internal/es/meta.d.mts +25 -2
  41. package/build/internal/es/meta.mjs.map +1 -1
  42. package/build/internal/es/schemas.d.mts +18 -0
  43. package/build/internal/es/schemas.mjs +36 -0
  44. package/build/internal/es/schemas.mjs.map +1 -1
  45. package/package.json +2 -2
@@ -1,9 +1,7 @@
1
1
  "use strict";
2
- var __create = Object.create;
3
2
  var __defProp = Object.defineProperty;
4
3
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
4
  var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __getProtoOf = Object.getPrototypeOf;
7
5
  var __hasOwnProp = Object.prototype.hasOwnProperty;
8
6
  var __export = (target, all) => {
9
7
  for (var name in all)
@@ -17,14 +15,6 @@ var __copyProps = (to, from, except, desc) => {
17
15
  }
18
16
  return to;
19
17
  };
20
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
- // If the importer is in node compatibility mode or this is not an ESM
22
- // file that has been converted to a CommonJS file using a Babel-
23
- // compatible transform (i.e. "__esModule" has not been set), then set
24
- // "default" to the CommonJS "module.exports" for node compatibility.
25
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
- mod
27
- ));
28
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
19
 
30
20
  // index.ts
@@ -339,454 +329,6 @@ function bulkUpdatePipelineTagsByFilter(payload) {
339
329
 
340
330
  // src/crm-pipelines-v1-pipeline-pipelines.universal.ts
341
331
  var import_transform_paths2 = require("@wix/sdk-runtime/transformations/transform-paths");
342
-
343
- // src/crm-pipelines-v1-pipeline-pipelines.schemas.ts
344
- var z = __toESM(require("zod"));
345
- var CreatePipelineRequest = z.object({
346
- pipeline: z.object({
347
- _id: z.string().describe("Pipeline ID.").regex(
348
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
349
- "Must be a valid GUID"
350
- ).optional().nullable(),
351
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
352
- "Revision number, which increments by 1 each time the pipeline is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the pipeline.\n\nIgnored when creating a pipeline."
353
- ).optional().nullable(),
354
- _createdDate: z.date().describe(
355
- "Date and time the pipeline was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
356
- ).optional().nullable(),
357
- _updatedDate: z.date().describe(
358
- "Date and time the pipeline was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
359
- ).optional().nullable(),
360
- name: z.string().describe("Pipeline name.").min(1).max(60),
361
- currency: z.string().describe(
362
- "Currency code for monetary values in this pipeline. Must be a valid ISO 4217 currency code. For example, `USD`.\n\nDefault: Based on the site's currency settings."
363
- ).optional().nullable(),
364
- stages: z.array(
365
- z.object({
366
- _id: z.string().describe("Stage ID.").regex(
367
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
368
- "Must be a valid GUID"
369
- ).optional().nullable(),
370
- name: z.string().describe("Stage name.").min(1).max(40),
371
- staleDurationInHours: z.number().int().describe(
372
- "The duration (in hours) a card can remain in this stage before becoming stale.\nWhen a card exceeds this duration, it's marked as stale to indicate potential workflow delays."
373
- ).min(1).max(1e5).optional().nullable()
374
- })
375
- ).min(1).max(30),
376
- doneStage: z.object({
377
- _id: z.string().describe("Done stage ID.").regex(
378
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
379
- "Must be a valid GUID"
380
- ).optional().nullable(),
381
- name: z.string().describe("Done stage name.").min(1).max(40),
382
- allowedOutcomes: z.array(z.enum(["NONE", "WON", "LOST"])).min(1).max(3)
383
- }).describe(
384
- "The final pipeline stage where cards receive a final outcome."
385
- ),
386
- extendedFields: z.object({
387
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
388
- "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
389
- ).optional()
390
- }).describe("Extended fields data.").optional(),
391
- tags: z.object({
392
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
393
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
394
- ).optional()
395
- }).describe("Tags for organizing and categorizing pipelines.").optional()
396
- }).describe("Pipeline to create.")
397
- });
398
- var CreatePipelineResponse = z.object({
399
- _id: z.string().describe("Pipeline ID.").regex(
400
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
401
- "Must be a valid GUID"
402
- ).optional().nullable(),
403
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
404
- "Revision number, which increments by 1 each time the pipeline is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the pipeline.\n\nIgnored when creating a pipeline."
405
- ).optional().nullable(),
406
- _createdDate: z.date().describe(
407
- "Date and time the pipeline was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
408
- ).optional().nullable(),
409
- _updatedDate: z.date().describe(
410
- "Date and time the pipeline was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
411
- ).optional().nullable(),
412
- name: z.string().describe("Pipeline name.").min(1).max(60).optional().nullable(),
413
- currency: z.string().describe(
414
- "Currency code for monetary values in this pipeline. Must be a valid ISO 4217 currency code. For example, `USD`.\n\nDefault: Based on the site's currency settings."
415
- ).optional().nullable(),
416
- stages: z.array(
417
- z.object({
418
- _id: z.string().describe("Stage ID.").regex(
419
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
420
- "Must be a valid GUID"
421
- ).optional().nullable(),
422
- name: z.string().describe("Stage name.").min(1).max(40).optional().nullable(),
423
- staleDurationInHours: z.number().int().describe(
424
- "The duration (in hours) a card can remain in this stage before becoming stale.\nWhen a card exceeds this duration, it's marked as stale to indicate potential workflow delays."
425
- ).min(1).max(1e5).optional().nullable()
426
- })
427
- ).min(1).max(30).optional(),
428
- doneStage: z.object({
429
- _id: z.string().describe("Done stage ID.").regex(
430
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
431
- "Must be a valid GUID"
432
- ).optional().nullable(),
433
- name: z.string().describe("Done stage name.").min(1).max(40).optional().nullable(),
434
- allowedOutcomes: z.array(z.enum(["NONE", "WON", "LOST"])).min(1).max(3).optional()
435
- }).describe("The final pipeline stage where cards receive a final outcome.").optional(),
436
- extendedFields: z.object({
437
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
438
- "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
439
- ).optional()
440
- }).describe("Extended fields data.").optional(),
441
- tags: z.object({
442
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
443
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
444
- ).optional()
445
- }).describe("Tags for organizing and categorizing pipelines.").optional()
446
- });
447
- var GetPipelineRequest = z.object({
448
- pipelineId: z.string().describe("Pipeline ID to retrieve.").regex(
449
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
450
- "Must be a valid GUID"
451
- )
452
- });
453
- var GetPipelineResponse = z.object({
454
- _id: z.string().describe("Pipeline ID.").regex(
455
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
456
- "Must be a valid GUID"
457
- ).optional().nullable(),
458
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
459
- "Revision number, which increments by 1 each time the pipeline is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the pipeline.\n\nIgnored when creating a pipeline."
460
- ).optional().nullable(),
461
- _createdDate: z.date().describe(
462
- "Date and time the pipeline was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
463
- ).optional().nullable(),
464
- _updatedDate: z.date().describe(
465
- "Date and time the pipeline was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
466
- ).optional().nullable(),
467
- name: z.string().describe("Pipeline name.").min(1).max(60).optional().nullable(),
468
- currency: z.string().describe(
469
- "Currency code for monetary values in this pipeline. Must be a valid ISO 4217 currency code. For example, `USD`.\n\nDefault: Based on the site's currency settings."
470
- ).optional().nullable(),
471
- stages: z.array(
472
- z.object({
473
- _id: z.string().describe("Stage ID.").regex(
474
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
475
- "Must be a valid GUID"
476
- ).optional().nullable(),
477
- name: z.string().describe("Stage name.").min(1).max(40).optional().nullable(),
478
- staleDurationInHours: z.number().int().describe(
479
- "The duration (in hours) a card can remain in this stage before becoming stale.\nWhen a card exceeds this duration, it's marked as stale to indicate potential workflow delays."
480
- ).min(1).max(1e5).optional().nullable()
481
- })
482
- ).min(1).max(30).optional(),
483
- doneStage: z.object({
484
- _id: z.string().describe("Done stage ID.").regex(
485
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
486
- "Must be a valid GUID"
487
- ).optional().nullable(),
488
- name: z.string().describe("Done stage name.").min(1).max(40).optional().nullable(),
489
- allowedOutcomes: z.array(z.enum(["NONE", "WON", "LOST"])).min(1).max(3).optional()
490
- }).describe("The final pipeline stage where cards receive a final outcome.").optional(),
491
- extendedFields: z.object({
492
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
493
- "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
494
- ).optional()
495
- }).describe("Extended fields data.").optional(),
496
- tags: z.object({
497
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
498
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
499
- ).optional()
500
- }).describe("Tags for organizing and categorizing pipelines.").optional()
501
- });
502
- var UpdatePipelineRequest = z.object({
503
- _id: z.string().describe("Pipeline ID.").regex(
504
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
505
- "Must be a valid GUID"
506
- ),
507
- pipeline: z.object({
508
- _id: z.string().describe("Pipeline ID.").regex(
509
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
510
- "Must be a valid GUID"
511
- ).optional().nullable(),
512
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
513
- "Revision number, which increments by 1 each time the pipeline is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the pipeline.\n\nIgnored when creating a pipeline."
514
- ),
515
- _createdDate: z.date().describe(
516
- "Date and time the pipeline was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
517
- ).optional().nullable(),
518
- _updatedDate: z.date().describe(
519
- "Date and time the pipeline was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
520
- ).optional().nullable(),
521
- name: z.string().describe("Pipeline name.").min(1).max(60).optional().nullable(),
522
- currency: z.string().describe(
523
- "Currency code for monetary values in this pipeline. Must be a valid ISO 4217 currency code. For example, `USD`.\n\nDefault: Based on the site's currency settings."
524
- ).optional().nullable(),
525
- stages: z.array(
526
- z.object({
527
- _id: z.string().describe("Stage ID.").regex(
528
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
529
- "Must be a valid GUID"
530
- ).optional().nullable(),
531
- name: z.string().describe("Stage name.").min(1).max(40).optional().nullable(),
532
- staleDurationInHours: z.number().int().describe(
533
- "The duration (in hours) a card can remain in this stage before becoming stale.\nWhen a card exceeds this duration, it's marked as stale to indicate potential workflow delays."
534
- ).min(1).max(1e5).optional().nullable()
535
- })
536
- ).min(1).max(30).optional(),
537
- doneStage: z.object({
538
- _id: z.string().describe("Done stage ID.").regex(
539
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
540
- "Must be a valid GUID"
541
- ).optional().nullable(),
542
- name: z.string().describe("Done stage name.").min(1).max(40).optional().nullable(),
543
- allowedOutcomes: z.array(z.enum(["NONE", "WON", "LOST"])).min(1).max(3).optional()
544
- }).describe(
545
- "The final pipeline stage where cards receive a final outcome."
546
- ).optional(),
547
- extendedFields: z.object({
548
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
549
- "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
550
- ).optional()
551
- }).describe("Extended fields data.").optional(),
552
- tags: z.object({
553
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
554
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
555
- ).optional()
556
- }).describe("Tags for organizing and categorizing pipelines.").optional()
557
- }).describe("Pipeline to update, may be partial.")
558
- });
559
- var UpdatePipelineResponse = z.object({
560
- _id: z.string().describe("Pipeline ID.").regex(
561
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
562
- "Must be a valid GUID"
563
- ).optional().nullable(),
564
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
565
- "Revision number, which increments by 1 each time the pipeline is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the pipeline.\n\nIgnored when creating a pipeline."
566
- ).optional().nullable(),
567
- _createdDate: z.date().describe(
568
- "Date and time the pipeline was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
569
- ).optional().nullable(),
570
- _updatedDate: z.date().describe(
571
- "Date and time the pipeline was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
572
- ).optional().nullable(),
573
- name: z.string().describe("Pipeline name.").min(1).max(60).optional().nullable(),
574
- currency: z.string().describe(
575
- "Currency code for monetary values in this pipeline. Must be a valid ISO 4217 currency code. For example, `USD`.\n\nDefault: Based on the site's currency settings."
576
- ).optional().nullable(),
577
- stages: z.array(
578
- z.object({
579
- _id: z.string().describe("Stage ID.").regex(
580
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
581
- "Must be a valid GUID"
582
- ).optional().nullable(),
583
- name: z.string().describe("Stage name.").min(1).max(40).optional().nullable(),
584
- staleDurationInHours: z.number().int().describe(
585
- "The duration (in hours) a card can remain in this stage before becoming stale.\nWhen a card exceeds this duration, it's marked as stale to indicate potential workflow delays."
586
- ).min(1).max(1e5).optional().nullable()
587
- })
588
- ).min(1).max(30).optional(),
589
- doneStage: z.object({
590
- _id: z.string().describe("Done stage ID.").regex(
591
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
592
- "Must be a valid GUID"
593
- ).optional().nullable(),
594
- name: z.string().describe("Done stage name.").min(1).max(40).optional().nullable(),
595
- allowedOutcomes: z.array(z.enum(["NONE", "WON", "LOST"])).min(1).max(3).optional()
596
- }).describe("The final pipeline stage where cards receive a final outcome.").optional(),
597
- extendedFields: z.object({
598
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
599
- "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
600
- ).optional()
601
- }).describe("Extended fields data.").optional(),
602
- tags: z.object({
603
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
604
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
605
- ).optional()
606
- }).describe("Tags for organizing and categorizing pipelines.").optional()
607
- });
608
- var DeletePipelineRequest = z.object({
609
- pipelineId: z.string().describe("Pipeline ID.").regex(
610
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
611
- "Must be a valid GUID"
612
- )
613
- });
614
- var DeletePipelineResponse = z.object({});
615
- var QueryPipelinesRequest = z.object({
616
- query: z.intersection(
617
- z.object({
618
- filter: z.record(z.string(), z.any()).describe(
619
- "Filter object.\n\nLearn more about [filtering](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section)."
620
- ).optional().nullable(),
621
- sort: z.array(
622
- z.object({
623
- fieldName: z.string().describe("Name of the field to sort by.").max(512).optional(),
624
- order: z.enum(["ASC", "DESC"]).optional()
625
- })
626
- ).max(5).optional()
627
- }),
628
- z.xor([
629
- z.object({ cursorPaging: z.never().optional() }),
630
- z.object({
631
- cursorPaging: z.object({
632
- limit: z.number().int().describe("Maximum number of items to return.").min(0).max(100).optional().nullable(),
633
- cursor: z.string().describe(
634
- "Pointer to the next or previous page in the list of results.\n\nPass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\nNot relevant for the first request."
635
- ).max(16e3).optional().nullable()
636
- }).describe(
637
- "Cursor paging options.\n\nLearn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging)."
638
- )
639
- })
640
- ])
641
- ).describe("Query options.")
642
- });
643
- var QueryPipelinesResponse = z.object({
644
- pipelines: z.array(
645
- z.object({
646
- _id: z.string().describe("Pipeline ID.").regex(
647
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
648
- "Must be a valid GUID"
649
- ).optional().nullable(),
650
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
651
- "Revision number, which increments by 1 each time the pipeline is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the pipeline.\n\nIgnored when creating a pipeline."
652
- ).optional().nullable(),
653
- _createdDate: z.date().describe(
654
- "Date and time the pipeline was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
655
- ).optional().nullable(),
656
- _updatedDate: z.date().describe(
657
- "Date and time the pipeline was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#combined_date_and_time_representations) format."
658
- ).optional().nullable(),
659
- name: z.string().describe("Pipeline name.").min(1).max(60).optional().nullable(),
660
- currency: z.string().describe(
661
- "Currency code for monetary values in this pipeline. Must be a valid ISO 4217 currency code. For example, `USD`.\n\nDefault: Based on the site's currency settings."
662
- ).optional().nullable(),
663
- stages: z.array(
664
- z.object({
665
- _id: z.string().describe("Stage ID.").regex(
666
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
667
- "Must be a valid GUID"
668
- ).optional().nullable(),
669
- name: z.string().describe("Stage name.").min(1).max(40).optional().nullable(),
670
- staleDurationInHours: z.number().int().describe(
671
- "The duration (in hours) a card can remain in this stage before becoming stale.\nWhen a card exceeds this duration, it's marked as stale to indicate potential workflow delays."
672
- ).min(1).max(1e5).optional().nullable()
673
- })
674
- ).min(1).max(30).optional(),
675
- doneStage: z.object({
676
- _id: z.string().describe("Done stage ID.").regex(
677
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
678
- "Must be a valid GUID"
679
- ).optional().nullable(),
680
- name: z.string().describe("Done stage name.").min(1).max(40).optional().nullable(),
681
- allowedOutcomes: z.array(z.enum(["NONE", "WON", "LOST"])).min(1).max(3).optional()
682
- }).describe(
683
- "The final pipeline stage where cards receive a final outcome."
684
- ).optional(),
685
- extendedFields: z.object({
686
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
687
- "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
688
- ).optional()
689
- }).describe("Extended fields data.").optional(),
690
- tags: z.object({
691
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
692
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
693
- ).optional()
694
- }).describe("Tags for organizing and categorizing pipelines.").optional()
695
- })
696
- ).optional(),
697
- pagingMetadata: z.object({
698
- count: z.number().int().describe("Number of items returned in current page.").optional().nullable(),
699
- cursors: z.object({
700
- next: z.string().describe(
701
- "Cursor string pointing to the next page in the list of results."
702
- ).max(16e3).optional().nullable(),
703
- prev: z.string().describe(
704
- "Cursor pointing to the previous page in the list of results."
705
- ).max(16e3).optional().nullable()
706
- }).describe(
707
- "Cursor strings that point to the next page, previous page, or both."
708
- ).optional(),
709
- hasNext: z.boolean().describe(
710
- "Whether there are more pages to retrieve following the current page.\n\n+ `true`: Another page of results can be retrieved.\n+ `false`: This is the last page."
711
- ).optional().nullable()
712
- }).describe("Paging metadata.").optional()
713
- });
714
- var BulkUpdatePipelineTagsRequest = z.object({
715
- pipelineIds: z.array(z.string()).min(1).max(100),
716
- options: z.object({
717
- assignTags: z.object({
718
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
719
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
720
- ).optional()
721
- }).describe("List of tags to assign.").optional(),
722
- unassignTags: z.object({
723
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
724
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
725
- ).optional()
726
- }).describe("List of tags to unassign.").optional(),
727
- returnEntity: z.boolean().describe(
728
- "Whether to return the updated pipelines in the response.\n\nDefault: `false`"
729
- ).optional()
730
- }).optional()
731
- });
732
- var BulkUpdatePipelineTagsResponse = z.object({
733
- results: z.array(
734
- z.object({
735
- itemMetadata: z.object({
736
- _id: z.string().describe(
737
- "Item ID. Should always be available, unless it's impossible (for example, when failing to create an item)."
738
- ).regex(
739
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
740
- "Must be a valid GUID"
741
- ).optional().nullable(),
742
- originalIndex: z.number().int().describe(
743
- "Index of the item within the request array. Allows for correlation between request and response items."
744
- ).optional(),
745
- success: z.boolean().describe(
746
- "Whether the requested action was successful for this item. When `false`, the `error` field is populated."
747
- ).optional(),
748
- error: z.object({
749
- code: z.string().describe("Error code.").optional(),
750
- description: z.string().describe("Description of the error.").optional(),
751
- data: z.record(z.string(), z.any()).describe("Data related to the error.").optional().nullable()
752
- }).describe("Details about the error in case of failure.").optional()
753
- }).describe("Metadata about the individual updated pipeline.").optional()
754
- })
755
- ).min(1).max(100).optional(),
756
- bulkActionMetadata: z.object({
757
- totalSuccesses: z.number().int().describe("Number of items that were successfully processed.").optional(),
758
- totalFailures: z.number().int().describe("Number of items that couldn't be processed.").optional(),
759
- undetailedFailures: z.number().int().describe(
760
- "Number of failures without details because detailed failure threshold was exceeded."
761
- ).optional()
762
- }).describe("Metadata about the bulk update.").optional()
763
- });
764
- var BulkUpdatePipelineTagsByFilterRequest = z.object({
765
- filter: z.record(z.string(), z.any()).describe("Filter to select which pipelines to update."),
766
- options: z.object({
767
- assignTags: z.object({
768
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
769
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
770
- ).optional()
771
- }).describe("List of tags to assign.").optional(),
772
- unassignTags: z.object({
773
- privateTags: z.object({ tagIds: z.array(z.string()).max(100).optional() }).describe(
774
- "Tags that are exposed to anyone with access to the entity, including site members and visitors."
775
- ).optional()
776
- }).describe("List of tags to unassign.").optional(),
777
- returnEntity: z.boolean().describe(
778
- "Whether to return the updated pipelines in the response.\n\nDefault: `false`"
779
- ).optional()
780
- }).optional()
781
- });
782
- var BulkUpdatePipelineTagsByFilterResponse = z.object({
783
- jobId: z.string().describe("Job ID for tracking the asynchronous tag updates.").regex(
784
- /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
785
- "Must be a valid GUID"
786
- ).optional()
787
- });
788
-
789
- // src/crm-pipelines-v1-pipeline-pipelines.universal.ts
790
332
  var import_query_builder_utils = require("@wix/sdk-runtime/query-builder-utils");
791
333
  var Outcome = /* @__PURE__ */ ((Outcome2) => {
792
334
  Outcome2["NONE"] = "NONE";
@@ -813,10 +355,7 @@ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
813
355
  return WebhookIdentityType2;
814
356
  })(WebhookIdentityType || {});
815
357
  async function createPipeline2(pipeline) {
816
- const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
817
- if (validateRequestSchema) {
818
- CreatePipelineRequest.parse({ pipeline });
819
- }
358
+ const { httpClient, sideEffects } = arguments[1];
820
359
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ pipeline });
821
360
  const reqOpts = createPipeline(payload);
822
361
  sideEffects?.onSiteCall?.();
@@ -839,10 +378,7 @@ async function createPipeline2(pipeline) {
839
378
  }
840
379
  }
841
380
  async function getPipeline2(pipelineId) {
842
- const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
843
- if (validateRequestSchema) {
844
- GetPipelineRequest.parse({ pipelineId });
845
- }
381
+ const { httpClient, sideEffects } = arguments[1];
846
382
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
847
383
  pipelineId
848
384
  });
@@ -867,10 +403,7 @@ async function getPipeline2(pipelineId) {
867
403
  }
868
404
  }
869
405
  async function updatePipeline2(_id, pipeline) {
870
- const { httpClient, sideEffects, validateRequestSchema } = arguments[2];
871
- if (validateRequestSchema) {
872
- UpdatePipelineRequest.parse({ _id, pipeline });
873
- }
406
+ const { httpClient, sideEffects } = arguments[2];
874
407
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
875
408
  pipeline: { ...pipeline, id: _id }
876
409
  });
@@ -895,10 +428,7 @@ async function updatePipeline2(_id, pipeline) {
895
428
  }
896
429
  }
897
430
  async function deletePipeline2(pipelineId) {
898
- const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
899
- if (validateRequestSchema) {
900
- DeletePipelineRequest.parse({ pipelineId });
901
- }
431
+ const { httpClient, sideEffects } = arguments[1];
902
432
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
903
433
  pipelineId
904
434
  });
@@ -966,10 +496,7 @@ function queryPipelines2() {
966
496
  });
967
497
  }
968
498
  async function typedQueryPipelines(query) {
969
- const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
970
- if (validateRequestSchema) {
971
- QueryPipelinesRequest.parse({ query });
972
- }
499
+ const { httpClient, sideEffects } = arguments[1];
973
500
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ query });
974
501
  const reqOpts = queryPipelines(payload);
975
502
  sideEffects?.onSiteCall?.();
@@ -997,10 +524,7 @@ var utils = {
997
524
  }
998
525
  };
999
526
  async function bulkUpdatePipelineTags2(pipelineIds, options) {
1000
- const { httpClient, sideEffects, validateRequestSchema } = arguments[2];
1001
- if (validateRequestSchema) {
1002
- BulkUpdatePipelineTagsRequest.parse({ pipelineIds, options });
1003
- }
527
+ const { httpClient, sideEffects } = arguments[2];
1004
528
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1005
529
  pipelineIds,
1006
530
  assignTags: options?.assignTags,
@@ -1033,10 +557,7 @@ async function bulkUpdatePipelineTags2(pipelineIds, options) {
1033
557
  }
1034
558
  }
1035
559
  async function bulkUpdatePipelineTagsByFilter2(filter, options) {
1036
- const { httpClient, sideEffects, validateRequestSchema } = arguments[2];
1037
- if (validateRequestSchema) {
1038
- BulkUpdatePipelineTagsByFilterRequest.parse({ filter, options });
1039
- }
560
+ const { httpClient, sideEffects } = arguments[2];
1040
561
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1041
562
  filter,
1042
563
  assignTags: options?.assignTags,
@@ -1070,62 +591,62 @@ async function bulkUpdatePipelineTagsByFilter2(filter, options) {
1070
591
  }
1071
592
 
1072
593
  // src/crm-pipelines-v1-pipeline-pipelines.public.ts
1073
- function createPipeline3(httpClient, __options) {
594
+ function createPipeline3(httpClient) {
1074
595
  return (pipeline) => createPipeline2(
1075
596
  pipeline,
1076
597
  // @ts-ignore
1077
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
598
+ { httpClient }
1078
599
  );
1079
600
  }
1080
- function getPipeline3(httpClient, __options) {
601
+ function getPipeline3(httpClient) {
1081
602
  return (pipelineId) => getPipeline2(
1082
603
  pipelineId,
1083
604
  // @ts-ignore
1084
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
605
+ { httpClient }
1085
606
  );
1086
607
  }
1087
- function updatePipeline3(httpClient, __options) {
608
+ function updatePipeline3(httpClient) {
1088
609
  return (_id, pipeline) => updatePipeline2(
1089
610
  _id,
1090
611
  pipeline,
1091
612
  // @ts-ignore
1092
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
613
+ { httpClient }
1093
614
  );
1094
615
  }
1095
- function deletePipeline3(httpClient, __options) {
616
+ function deletePipeline3(httpClient) {
1096
617
  return (pipelineId) => deletePipeline2(
1097
618
  pipelineId,
1098
619
  // @ts-ignore
1099
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
620
+ { httpClient }
1100
621
  );
1101
622
  }
1102
- function queryPipelines3(httpClient, __options) {
623
+ function queryPipelines3(httpClient) {
1103
624
  return () => queryPipelines2(
1104
625
  // @ts-ignore
1105
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
626
+ { httpClient }
1106
627
  );
1107
628
  }
1108
- function typedQueryPipelines2(httpClient, __options) {
629
+ function typedQueryPipelines2(httpClient) {
1109
630
  return (query) => typedQueryPipelines(
1110
631
  query,
1111
632
  // @ts-ignore
1112
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
633
+ { httpClient }
1113
634
  );
1114
635
  }
1115
- function bulkUpdatePipelineTags3(httpClient, __options) {
636
+ function bulkUpdatePipelineTags3(httpClient) {
1116
637
  return (pipelineIds, options) => bulkUpdatePipelineTags2(
1117
638
  pipelineIds,
1118
639
  options,
1119
640
  // @ts-ignore
1120
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
641
+ { httpClient }
1121
642
  );
1122
643
  }
1123
- function bulkUpdatePipelineTagsByFilter3(httpClient, __options) {
644
+ function bulkUpdatePipelineTagsByFilter3(httpClient) {
1124
645
  return (filter, options) => bulkUpdatePipelineTagsByFilter2(
1125
646
  filter,
1126
647
  options,
1127
648
  // @ts-ignore
1128
- { httpClient, validateRequestSchema: __options?.validateRequestSchema }
649
+ { httpClient }
1129
650
  );
1130
651
  }
1131
652
  var onPipelineCreated = (0, import_sdk_types.EventDefinition)(