@wix/auto_sdk_pricing-plans_orders 1.0.113 → 1.0.114

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 (49) hide show
  1. package/build/cjs/index.d.ts +155 -155
  2. package/build/cjs/index.js +452 -452
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +498 -498
  5. package/build/cjs/index.typings.js +323 -323
  6. package/build/cjs/index.typings.js.map +1 -1
  7. package/build/cjs/meta.d.ts +268 -268
  8. package/build/cjs/meta.js +334 -334
  9. package/build/cjs/meta.js.map +1 -1
  10. package/build/cjs/schemas.d.ts +30 -30
  11. package/build/cjs/schemas.js +59 -59
  12. package/build/cjs/schemas.js.map +1 -1
  13. package/build/es/index.d.mts +155 -155
  14. package/build/es/index.mjs +452 -452
  15. package/build/es/index.mjs.map +1 -1
  16. package/build/es/index.typings.d.mts +498 -498
  17. package/build/es/index.typings.mjs +323 -323
  18. package/build/es/index.typings.mjs.map +1 -1
  19. package/build/es/meta.d.mts +268 -268
  20. package/build/es/meta.mjs +334 -334
  21. package/build/es/meta.mjs.map +1 -1
  22. package/build/es/schemas.d.mts +30 -30
  23. package/build/es/schemas.mjs +59 -59
  24. package/build/es/schemas.mjs.map +1 -1
  25. package/build/internal/cjs/index.d.ts +155 -155
  26. package/build/internal/cjs/index.js +452 -452
  27. package/build/internal/cjs/index.js.map +1 -1
  28. package/build/internal/cjs/index.typings.d.ts +498 -498
  29. package/build/internal/cjs/index.typings.js +323 -323
  30. package/build/internal/cjs/index.typings.js.map +1 -1
  31. package/build/internal/cjs/meta.d.ts +268 -268
  32. package/build/internal/cjs/meta.js +334 -334
  33. package/build/internal/cjs/meta.js.map +1 -1
  34. package/build/internal/cjs/schemas.d.ts +30 -30
  35. package/build/internal/cjs/schemas.js +59 -59
  36. package/build/internal/cjs/schemas.js.map +1 -1
  37. package/build/internal/es/index.d.mts +155 -155
  38. package/build/internal/es/index.mjs +452 -452
  39. package/build/internal/es/index.mjs.map +1 -1
  40. package/build/internal/es/index.typings.d.mts +498 -498
  41. package/build/internal/es/index.typings.mjs +323 -323
  42. package/build/internal/es/index.typings.mjs.map +1 -1
  43. package/build/internal/es/meta.d.mts +268 -268
  44. package/build/internal/es/meta.mjs +334 -334
  45. package/build/internal/es/meta.mjs.map +1 -1
  46. package/build/internal/es/schemas.d.mts +30 -30
  47. package/build/internal/es/schemas.mjs +59 -59
  48. package/build/internal/es/schemas.mjs.map +1 -1
  49. package/package.json +2 -2
@@ -1,4 +1,4 @@
1
- import { GetOrderRequest as GetOrderRequest$1, GetOrderResponse as GetOrderResponse$1, ListOrdersRequest as ListOrdersRequest$1, ListOrdersResponse as ListOrdersResponse$1, PostponeEndDateRequest as PostponeEndDateRequest$1, PostponeEndDateResponse as PostponeEndDateResponse$1, CancelOrderRequest as CancelOrderRequest$1, CancelOrderResponse as CancelOrderResponse$1, MarkAsPaidRequest as MarkAsPaidRequest$1, MarkAsPaidResponse as MarkAsPaidResponse$1, PauseOrderRequest as PauseOrderRequest$1, PauseOrderResponse as PauseOrderResponse$1, ResumeOrderRequest as ResumeOrderRequest$1, ResumeOrderResponse as ResumeOrderResponse$1, CreateOnlineOrderRequest as CreateOnlineOrderRequest$1, CreateOnlineOrderResponse as CreateOnlineOrderResponse$1, CreateOfflineOrderRequest as CreateOfflineOrderRequest$1, CreateOfflineOrderResponse as CreateOfflineOrderResponse$1, GetOnlineOrderPreviewRequest as GetOnlineOrderPreviewRequest$1, GetOnlineOrderPreviewResponse as GetOnlineOrderPreviewResponse$1, GetOfflineOrderPreviewRequest as GetOfflineOrderPreviewRequest$1, GetOfflineOrderPreviewResponse as GetOfflineOrderPreviewResponse$1, GetPricePreviewRequest as GetPricePreviewRequest$1, GetPricePreviewResponse as GetPricePreviewResponse$1, MemberGetOrderRequest as MemberGetOrderRequest$1, MemberGetOrderResponse as MemberGetOrderResponse$1, MemberListOrdersRequest as MemberListOrdersRequest$1, MemberListOrdersResponse as MemberListOrdersResponse$1, RequestCancellationRequest as RequestCancellationRequest$1, RequestCancellationResponse as RequestCancellationResponse$1 } from './index.typings.js';
1
+ import { MemberGetOrderRequest as MemberGetOrderRequest$1, MemberGetOrderResponse as MemberGetOrderResponse$1, MemberListOrdersRequest as MemberListOrdersRequest$1, MemberListOrdersResponse as MemberListOrdersResponse$1, RequestCancellationRequest as RequestCancellationRequest$1, RequestCancellationResponse as RequestCancellationResponse$1, CreateOnlineOrderRequest as CreateOnlineOrderRequest$1, CreateOnlineOrderResponse as CreateOnlineOrderResponse$1, CreateOfflineOrderRequest as CreateOfflineOrderRequest$1, CreateOfflineOrderResponse as CreateOfflineOrderResponse$1, GetOnlineOrderPreviewRequest as GetOnlineOrderPreviewRequest$1, GetOnlineOrderPreviewResponse as GetOnlineOrderPreviewResponse$1, GetOfflineOrderPreviewRequest as GetOfflineOrderPreviewRequest$1, GetOfflineOrderPreviewResponse as GetOfflineOrderPreviewResponse$1, GetPricePreviewRequest as GetPricePreviewRequest$1, GetPricePreviewResponse as GetPricePreviewResponse$1, GetOrderRequest as GetOrderRequest$1, GetOrderResponse as GetOrderResponse$1, ListOrdersRequest as ListOrdersRequest$1, ListOrdersResponse as ListOrdersResponse$1, PostponeEndDateRequest as PostponeEndDateRequest$1, PostponeEndDateResponse as PostponeEndDateResponse$1, CancelOrderRequest as CancelOrderRequest$1, CancelOrderResponse as CancelOrderResponse$1, MarkAsPaidRequest as MarkAsPaidRequest$1, MarkAsPaidResponse as MarkAsPaidResponse$1, PauseOrderRequest as PauseOrderRequest$1, PauseOrderResponse as PauseOrderResponse$1, ResumeOrderRequest as ResumeOrderRequest$1, ResumeOrderResponse as ResumeOrderResponse$1 } from './index.typings.js';
2
2
  import '@wix/sdk-types';
3
3
 
4
4
  /**
@@ -637,35 +637,7 @@ interface ActionEvent {
637
637
  }
638
638
  interface Empty {
639
639
  }
640
- interface OrderPurchased {
641
- /** Order that was paid for. If a free or an offline order, the order that was created. */
642
- order?: Order;
643
- }
644
- interface OrderStarted {
645
- /** Order that reached its `startDate`. */
646
- order?: Order;
647
- }
648
- /**
649
- * Triggered at the start of a new payment cycle for an existing order.
650
- *
651
- * This webhook does not trigger at the initial start of an offline order.
652
- */
653
- interface OrderCycleStarted {
654
- /** Order whose new cycle started. */
655
- order?: Order;
656
- /** Number of the payment cycle will be 0 when the order is in the free trial period. In other cases, the cycle number starts from 1. */
657
- cycleNumber?: number;
658
- }
659
- /** Emitted when a recurring order is canceled for the next payment cycle */
660
- interface OrderAutoRenewCanceled {
661
- /** Order that is canceled, effective at the end of the current payment cycle. */
662
- order?: Order;
663
- }
664
- interface OrderEnded {
665
- /** Order that ended. */
666
- order?: Order;
667
- }
668
- interface GetOrderRequest {
640
+ interface MemberGetOrderRequest {
669
641
  /**
670
642
  * Order ID.
671
643
  * @format GUID
@@ -688,44 +660,31 @@ declare enum Set {
688
660
  }
689
661
  /** @enumType */
690
662
  type SetWithLiterals = Set | 'UNKNOWN_SET' | 'BASIC' | 'FULL';
691
- interface GetOrderResponse {
692
- /** Order. */
663
+ interface MemberGetOrderResponse {
664
+ /** Requested order. */
693
665
  order?: Order;
694
666
  }
695
- interface ListOrdersRequest {
696
- /**
697
- * Filter by a buyer's member ID, from the Members API.
698
- * @format GUID
699
- */
700
- buyerIds?: string[];
667
+ interface MemberListOrdersRequest {
701
668
  /**
702
- * Filter by plan IDs, from the Plans API.
669
+ * Filter by plan IDs.
703
670
  * @format GUID
704
671
  */
705
672
  planIds?: string[];
706
- /** Filter by whether or not the auto-renewal of recurring orders was canceled. */
673
+ /** Filter for orders where auto renewal was canceled. */
707
674
  autoRenewCanceled?: boolean | null;
708
675
  /** Filter by order status. */
709
676
  orderStatuses?: OrderStatusWithLiterals[];
710
677
  /** Filter by payment status. */
711
678
  paymentStatuses?: PaymentStatusWithLiterals[];
712
679
  /**
713
- * Number of orders to return. See Sorting and Paging for more information.
714
- *
715
- * Max: `50`
680
+ * Limit the number of pricing plans returned. Default limit is 50.
716
681
  * @min 1
717
682
  * @max 50
718
683
  */
719
684
  limit?: number | null;
720
- /** Number of orders to skip in the current sort order. */
685
+ /** Number of entries to offset. */
721
686
  offset?: number | null;
722
- /**
723
- * Sort order.
724
- *
725
- * Use `ASC` for ascending order or `DESC` for descending order.
726
- *
727
- * Default: `DESC`.
728
- */
687
+ /** Sorting direction (defaults to ASC) and field to sort by. */
729
688
  sorting?: Sorting;
730
689
  /**
731
690
  * Predefined set of fields to return.
@@ -749,8 +708,8 @@ declare enum SortOrder {
749
708
  }
750
709
  /** @enumType */
751
710
  type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';
752
- interface ListOrdersResponse {
753
- /** List of orders. */
711
+ interface MemberListOrdersResponse {
712
+ /** Requested orders. */
754
713
  orders?: Order[];
755
714
  /** Object containing paging-related data (number of orders returned, offset). */
756
715
  pagingMetadata?: PagingMetadataV2;
@@ -779,7 +738,11 @@ interface Cursors {
779
738
  */
780
739
  prev?: string | null;
781
740
  }
782
- interface OrdersQueryOrdersRequest {
741
+ /**
742
+ * TODO: Write orders filter and sort docs page
743
+ * Retrieves a list of up to 1,000 orders, based on the provided paging, sorting, and filtering.
744
+ */
745
+ interface QueryOrdersRequest {
783
746
  /** Query filter. */
784
747
  query?: QueryV2;
785
748
  }
@@ -833,84 +796,22 @@ interface CursorPaging {
833
796
  */
834
797
  cursor?: string | null;
835
798
  }
836
- interface OrdersQueryOrdersResponse {
837
- /** Retrieved orders. */
799
+ interface QueryOrdersResponse {
800
+ /** Order data. */
838
801
  plans?: Order[];
839
802
  /** Paging-related data (number of orders returned, offset). */
840
803
  pagingMetadata?: PagingMetadataV2;
841
804
  }
842
- interface GetOrdersStatsRequest {
843
- }
844
- interface GetOrdersStatsResponse {
845
- /** Total number of orders. */
846
- totalOrderCount?: number;
847
- /** Number of active orders. */
848
- activeOrderCount?: number;
849
- }
850
- interface GetAvailableOrderActionsRequest {
851
- /**
852
- * Order ID.
853
- * @format GUID
854
- */
855
- id?: string;
856
- }
857
- interface GetAvailableOrderActionsResponse {
858
- /** Whether the order can be suspended. */
859
- suspendable?: boolean;
860
- /** If the order cannot be suspended, a reason is returned here. */
861
- notSuspendableReason?: ReasonNotSuspendableWithLiterals;
862
- /** Whether the order can be canceled by the buyer. */
863
- cancelableByBuyer?: boolean;
864
- }
865
- declare enum ReasonNotSuspendable {
866
- /** Undefined reason. */
867
- UNDEFINED = "UNDEFINED",
868
- /** Saved in the database but is awaiting payment. Non-active orders can't be suspended. */
869
- PENDING = "PENDING",
870
- /** Trial orders can't be suspended. */
871
- TRIAL = "TRIAL",
872
- /** Canceled orders can't be suspended. */
873
- CANCELED = "CANCELED",
874
- /** Ended orders can't be suspended. */
875
- ENDED = "ENDED",
876
- /** Paid for orders with future start dates can't be suspended. */
877
- NOT_STARTED = "NOT_STARTED",
878
- /** Order is already suspended. */
879
- ALREADY_SUSPENDED = "ALREADY_SUSPENDED",
880
- /** Orders based on recurring payments using older stripe versions can't be suspended. */
881
- OLD_STRIPE = "OLD_STRIPE"
882
- }
883
- /** @enumType */
884
- type ReasonNotSuspendableWithLiterals = ReasonNotSuspendable | 'UNDEFINED' | 'PENDING' | 'TRIAL' | 'CANCELED' | 'ENDED' | 'NOT_STARTED' | 'ALREADY_SUSPENDED' | 'OLD_STRIPE';
885
- interface PostponeEndDateRequest {
886
- /**
887
- * Order ID.
888
- * @format GUID
889
- */
890
- id: string;
891
- /**
892
- * New end date and time.
893
- *
894
- * Must be later than the current end date and time.
895
- */
896
- endDate: Date | null;
897
- }
898
- interface PostponeEndDateResponse {
899
- }
900
- interface OrderEndDatePostponed {
901
- /** Order whose `endDate` was postponed. */
902
- order?: Order;
903
- }
904
- interface CancelOrderRequest {
805
+ interface RequestCancellationRequest {
905
806
  /**
906
807
  * Order ID.
907
808
  * @format GUID
908
809
  */
909
810
  id: string;
910
- /** __Required.__ When the order will be canceled. One-time orders can only be canceled `IMMEDIATELY`. */
811
+ /** Required. Whether to cancel the order effective immediately or at the next payment date. One-time orders can only be canceled immediately. */
911
812
  effectiveAt: CancellationEffectiveAtWithLiterals;
912
813
  }
913
- interface CancelOrderResponse {
814
+ interface RequestCancellationResponse {
914
815
  }
915
816
  /**
916
817
  * Emitted when an order is canceled immediately or when cycle ends for an order with canceled auto renewal
@@ -921,111 +822,6 @@ interface OrderCanceled {
921
822
  /** Canceled order. */
922
823
  order?: Order;
923
824
  }
924
- interface MarkAsPaidRequest {
925
- /**
926
- * Order ID.
927
- * @format GUID
928
- */
929
- id: string;
930
- }
931
- interface MarkAsPaidResponse {
932
- }
933
- interface OrderMarkedAsPaid {
934
- /** Order that was marked as paid. */
935
- order?: Order;
936
- }
937
- interface PauseOrderRequest {
938
- /**
939
- * Order ID.
940
- * @format GUID
941
- */
942
- id: string;
943
- }
944
- interface PauseOrderResponse {
945
- }
946
- interface OrderPaused {
947
- /** Paused order. */
948
- order?: Order;
949
- }
950
- interface BulkPauseOrderRequest {
951
- /**
952
- * List of Order IDs.
953
- * @format GUID
954
- * @minSize 1
955
- * @maxSize 100
956
- */
957
- ids?: string[];
958
- /** Set to true to return Order entity in response. */
959
- returnFullEntity?: boolean;
960
- }
961
- interface BulkPauseOrderResponse {
962
- /** Orders that were paused. */
963
- results?: BulkOrderResult[];
964
- /** Bulk action metadata. */
965
- bulkActionMetadata?: BulkActionMetadata;
966
- }
967
- interface BulkOrderResult {
968
- /** Item metadata */
969
- itemMetadata?: ItemMetadata;
970
- /** The order. */
971
- order?: Order;
972
- }
973
- interface ItemMetadata {
974
- /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
975
- id?: string | null;
976
- /** Index of the item within the request array. Allows for correlation between request and response items. */
977
- originalIndex?: number;
978
- /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
979
- success?: boolean;
980
- /** Details about the error in case of failure. */
981
- error?: ApplicationError;
982
- }
983
- interface ApplicationError {
984
- /** Error code. */
985
- code?: string;
986
- /** Description of the error. */
987
- description?: string;
988
- /** Data related to the error. */
989
- data?: Record<string, any> | null;
990
- }
991
- interface BulkActionMetadata {
992
- /** Number of items that were successfully processed. */
993
- totalSuccesses?: number;
994
- /** Number of items that couldn't be processed. */
995
- totalFailures?: number;
996
- /** Number of failures without details because detailed failure threshold was exceeded. */
997
- undetailedFailures?: number;
998
- }
999
- interface ResumeOrderRequest {
1000
- /**
1001
- * Order ID.
1002
- * @format GUID
1003
- */
1004
- id: string;
1005
- }
1006
- interface ResumeOrderResponse {
1007
- }
1008
- interface OrderResumed {
1009
- /** Resumed order. */
1010
- order?: Order;
1011
- }
1012
- interface BulkResumeOrderRequest {
1013
- /**
1014
- * List of Order IDs.
1015
- * @format GUID
1016
- * @minSize 1
1017
- * @maxSize 100
1018
- */
1019
- ids?: string[];
1020
- /** Set to true to return Order entity in response. */
1021
- returnFullEntity?: boolean;
1022
- }
1023
- interface BulkResumeOrderResponse {
1024
- /** Orders that were resumed. */
1025
- results?: BulkOrderResult[];
1026
- /** Bulk action metadata. */
1027
- bulkActionMetadata?: BulkActionMetadata;
1028
- }
1029
825
  interface MessageEnvelope {
1030
826
  /**
1031
827
  * App instance ID.
@@ -1427,44 +1223,85 @@ interface SetSubmissionResponse {
1427
1223
  /** Order with submission id */
1428
1224
  order?: Order;
1429
1225
  }
1430
- interface MemberGetOrderRequest {
1431
- /**
1432
- * Order ID.
1433
- * @format GUID
1434
- */
1435
- id: string;
1436
- /**
1437
- * Predefined set of fields to return.
1438
- *
1439
- * Default: If `fieldSet` is omitted, no order form submission data is returned.
1226
+ interface OrderPurchased {
1227
+ /** Order that was paid for. If a free or an offline order, the order that was created. */
1228
+ order?: Order;
1229
+ }
1230
+ interface OrderStarted {
1231
+ /** Order that reached its `startDate`. */
1232
+ order?: Order;
1233
+ }
1234
+ /**
1235
+ * Triggered at the start of a new payment cycle for an existing order.
1236
+ *
1237
+ * This webhook does not trigger at the initial start of an offline order.
1238
+ */
1239
+ interface OrderCycleStarted {
1240
+ /** Order whose new cycle started. */
1241
+ order?: Order;
1242
+ /** Number of the payment cycle will be 0 when the order is in the free trial period. In other cases, the cycle number starts from 1. */
1243
+ cycleNumber?: number;
1244
+ }
1245
+ /** Emitted when a recurring order is canceled for the next payment cycle */
1246
+ interface OrderAutoRenewCanceled {
1247
+ /** Order that is canceled, effective at the end of the current payment cycle. */
1248
+ order?: Order;
1249
+ }
1250
+ interface OrderEnded {
1251
+ /** Order that ended. */
1252
+ order?: Order;
1253
+ }
1254
+ interface GetOrderRequest {
1255
+ /**
1256
+ * Order ID.
1257
+ * @format GUID
1258
+ */
1259
+ id: string;
1260
+ /**
1261
+ * Predefined set of fields to return.
1262
+ *
1263
+ * Default: If `fieldSet` is omitted, no order form submission data is returned.
1440
1264
  */
1441
1265
  fieldSet?: SetWithLiterals;
1442
1266
  }
1443
- interface MemberGetOrderResponse {
1444
- /** Requested order. */
1267
+ interface GetOrderResponse {
1268
+ /** Order. */
1445
1269
  order?: Order;
1446
1270
  }
1447
- interface MemberListOrdersRequest {
1271
+ interface ListOrdersRequest {
1448
1272
  /**
1449
- * Filter by plan IDs.
1273
+ * Filter by a buyer's member ID, from the Members API.
1274
+ * @format GUID
1275
+ */
1276
+ buyerIds?: string[];
1277
+ /**
1278
+ * Filter by plan IDs, from the Plans API.
1450
1279
  * @format GUID
1451
1280
  */
1452
1281
  planIds?: string[];
1453
- /** Filter for orders where auto renewal was canceled. */
1282
+ /** Filter by whether or not the auto-renewal of recurring orders was canceled. */
1454
1283
  autoRenewCanceled?: boolean | null;
1455
1284
  /** Filter by order status. */
1456
1285
  orderStatuses?: OrderStatusWithLiterals[];
1457
1286
  /** Filter by payment status. */
1458
1287
  paymentStatuses?: PaymentStatusWithLiterals[];
1459
1288
  /**
1460
- * Limit the number of pricing plans returned. Default limit is 50.
1289
+ * Number of orders to return. See Sorting and Paging for more information.
1290
+ *
1291
+ * Max: `50`
1461
1292
  * @min 1
1462
1293
  * @max 50
1463
1294
  */
1464
1295
  limit?: number | null;
1465
- /** Number of entries to offset. */
1296
+ /** Number of orders to skip in the current sort order. */
1466
1297
  offset?: number | null;
1467
- /** Sorting direction (defaults to ASC) and field to sort by. */
1298
+ /**
1299
+ * Sort order.
1300
+ *
1301
+ * Use `ASC` for ascending order or `DESC` for descending order.
1302
+ *
1303
+ * Default: `DESC`.
1304
+ */
1468
1305
  sorting?: Sorting;
1469
1306
  /**
1470
1307
  * Predefined set of fields to return.
@@ -1473,36 +1310,199 @@ interface MemberListOrdersRequest {
1473
1310
  */
1474
1311
  fieldSet?: SetWithLiterals;
1475
1312
  }
1476
- interface MemberListOrdersResponse {
1477
- /** Requested orders. */
1313
+ interface ListOrdersResponse {
1314
+ /** List of orders. */
1478
1315
  orders?: Order[];
1479
1316
  /** Object containing paging-related data (number of orders returned, offset). */
1480
1317
  pagingMetadata?: PagingMetadataV2;
1481
1318
  }
1482
- /**
1483
- * TODO: Write orders filter and sort docs page
1484
- * Retrieves a list of up to 1,000 orders, based on the provided paging, sorting, and filtering.
1485
- */
1486
- interface QueryOrdersRequest {
1319
+ interface OrdersQueryOrdersRequest {
1487
1320
  /** Query filter. */
1488
1321
  query?: QueryV2;
1489
1322
  }
1490
- interface QueryOrdersResponse {
1491
- /** Order data. */
1323
+ interface OrdersQueryOrdersResponse {
1324
+ /** Retrieved orders. */
1492
1325
  plans?: Order[];
1493
1326
  /** Paging-related data (number of orders returned, offset). */
1494
1327
  pagingMetadata?: PagingMetadataV2;
1495
1328
  }
1496
- interface RequestCancellationRequest {
1329
+ interface GetOrdersStatsRequest {
1330
+ }
1331
+ interface GetOrdersStatsResponse {
1332
+ /** Total number of orders. */
1333
+ totalOrderCount?: number;
1334
+ /** Number of active orders. */
1335
+ activeOrderCount?: number;
1336
+ }
1337
+ interface GetAvailableOrderActionsRequest {
1338
+ /**
1339
+ * Order ID.
1340
+ * @format GUID
1341
+ */
1342
+ id?: string;
1343
+ }
1344
+ interface GetAvailableOrderActionsResponse {
1345
+ /** Whether the order can be suspended. */
1346
+ suspendable?: boolean;
1347
+ /** If the order cannot be suspended, a reason is returned here. */
1348
+ notSuspendableReason?: ReasonNotSuspendableWithLiterals;
1349
+ /** Whether the order can be canceled by the buyer. */
1350
+ cancelableByBuyer?: boolean;
1351
+ }
1352
+ declare enum ReasonNotSuspendable {
1353
+ /** Undefined reason. */
1354
+ UNDEFINED = "UNDEFINED",
1355
+ /** Saved in the database but is awaiting payment. Non-active orders can't be suspended. */
1356
+ PENDING = "PENDING",
1357
+ /** Trial orders can't be suspended. */
1358
+ TRIAL = "TRIAL",
1359
+ /** Canceled orders can't be suspended. */
1360
+ CANCELED = "CANCELED",
1361
+ /** Ended orders can't be suspended. */
1362
+ ENDED = "ENDED",
1363
+ /** Paid for orders with future start dates can't be suspended. */
1364
+ NOT_STARTED = "NOT_STARTED",
1365
+ /** Order is already suspended. */
1366
+ ALREADY_SUSPENDED = "ALREADY_SUSPENDED",
1367
+ /** Orders based on recurring payments using older stripe versions can't be suspended. */
1368
+ OLD_STRIPE = "OLD_STRIPE"
1369
+ }
1370
+ /** @enumType */
1371
+ type ReasonNotSuspendableWithLiterals = ReasonNotSuspendable | 'UNDEFINED' | 'PENDING' | 'TRIAL' | 'CANCELED' | 'ENDED' | 'NOT_STARTED' | 'ALREADY_SUSPENDED' | 'OLD_STRIPE';
1372
+ interface PostponeEndDateRequest {
1497
1373
  /**
1498
1374
  * Order ID.
1499
1375
  * @format GUID
1500
1376
  */
1501
1377
  id: string;
1502
- /** Required. Whether to cancel the order effective immediately or at the next payment date. One-time orders can only be canceled immediately. */
1378
+ /**
1379
+ * New end date and time.
1380
+ *
1381
+ * Must be later than the current end date and time.
1382
+ */
1383
+ endDate: Date | null;
1384
+ }
1385
+ interface PostponeEndDateResponse {
1386
+ }
1387
+ interface OrderEndDatePostponed {
1388
+ /** Order whose `endDate` was postponed. */
1389
+ order?: Order;
1390
+ }
1391
+ interface CancelOrderRequest {
1392
+ /**
1393
+ * Order ID.
1394
+ * @format GUID
1395
+ */
1396
+ id: string;
1397
+ /** __Required.__ When the order will be canceled. One-time orders can only be canceled `IMMEDIATELY`. */
1503
1398
  effectiveAt: CancellationEffectiveAtWithLiterals;
1504
1399
  }
1505
- interface RequestCancellationResponse {
1400
+ interface CancelOrderResponse {
1401
+ }
1402
+ interface MarkAsPaidRequest {
1403
+ /**
1404
+ * Order ID.
1405
+ * @format GUID
1406
+ */
1407
+ id: string;
1408
+ }
1409
+ interface MarkAsPaidResponse {
1410
+ }
1411
+ interface OrderMarkedAsPaid {
1412
+ /** Order that was marked as paid. */
1413
+ order?: Order;
1414
+ }
1415
+ interface PauseOrderRequest {
1416
+ /**
1417
+ * Order ID.
1418
+ * @format GUID
1419
+ */
1420
+ id: string;
1421
+ }
1422
+ interface PauseOrderResponse {
1423
+ }
1424
+ interface OrderPaused {
1425
+ /** Paused order. */
1426
+ order?: Order;
1427
+ }
1428
+ interface BulkPauseOrderRequest {
1429
+ /**
1430
+ * List of Order IDs.
1431
+ * @format GUID
1432
+ * @minSize 1
1433
+ * @maxSize 100
1434
+ */
1435
+ ids?: string[];
1436
+ /** Set to true to return Order entity in response. */
1437
+ returnFullEntity?: boolean;
1438
+ }
1439
+ interface BulkPauseOrderResponse {
1440
+ /** Orders that were paused. */
1441
+ results?: BulkOrderResult[];
1442
+ /** Bulk action metadata. */
1443
+ bulkActionMetadata?: BulkActionMetadata;
1444
+ }
1445
+ interface BulkOrderResult {
1446
+ /** Item metadata */
1447
+ itemMetadata?: ItemMetadata;
1448
+ /** The order. */
1449
+ order?: Order;
1450
+ }
1451
+ interface ItemMetadata {
1452
+ /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
1453
+ id?: string | null;
1454
+ /** Index of the item within the request array. Allows for correlation between request and response items. */
1455
+ originalIndex?: number;
1456
+ /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
1457
+ success?: boolean;
1458
+ /** Details about the error in case of failure. */
1459
+ error?: ApplicationError;
1460
+ }
1461
+ interface ApplicationError {
1462
+ /** Error code. */
1463
+ code?: string;
1464
+ /** Description of the error. */
1465
+ description?: string;
1466
+ /** Data related to the error. */
1467
+ data?: Record<string, any> | null;
1468
+ }
1469
+ interface BulkActionMetadata {
1470
+ /** Number of items that were successfully processed. */
1471
+ totalSuccesses?: number;
1472
+ /** Number of items that couldn't be processed. */
1473
+ totalFailures?: number;
1474
+ /** Number of failures without details because detailed failure threshold was exceeded. */
1475
+ undetailedFailures?: number;
1476
+ }
1477
+ interface ResumeOrderRequest {
1478
+ /**
1479
+ * Order ID.
1480
+ * @format GUID
1481
+ */
1482
+ id: string;
1483
+ }
1484
+ interface ResumeOrderResponse {
1485
+ }
1486
+ interface OrderResumed {
1487
+ /** Resumed order. */
1488
+ order?: Order;
1489
+ }
1490
+ interface BulkResumeOrderRequest {
1491
+ /**
1492
+ * List of Order IDs.
1493
+ * @format GUID
1494
+ * @minSize 1
1495
+ * @maxSize 100
1496
+ */
1497
+ ids?: string[];
1498
+ /** Set to true to return Order entity in response. */
1499
+ returnFullEntity?: boolean;
1500
+ }
1501
+ interface BulkResumeOrderResponse {
1502
+ /** Orders that were resumed. */
1503
+ results?: BulkOrderResult[];
1504
+ /** Bulk action metadata. */
1505
+ bulkActionMetadata?: BulkActionMetadata;
1506
1506
  }
1507
1507
  /** @docsIgnore */
1508
1508
  type CreateOnlineOrderApplicationErrors = {
@@ -1811,6 +1811,18 @@ type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q
1811
1811
  __responseType: Q;
1812
1812
  __originalResponseType: R;
1813
1813
  };
1814
+ declare function memberGetOrder(): __PublicMethodMetaInfo<'GET', {
1815
+ id: string;
1816
+ }, MemberGetOrderRequest$1, MemberGetOrderRequest, MemberGetOrderResponse$1, MemberGetOrderResponse>;
1817
+ declare function memberListOrders(): __PublicMethodMetaInfo<'GET', {}, MemberListOrdersRequest$1, MemberListOrdersRequest, MemberListOrdersResponse$1, MemberListOrdersResponse>;
1818
+ declare function requestCancellation(): __PublicMethodMetaInfo<'POST', {
1819
+ id: string;
1820
+ }, RequestCancellationRequest$1, RequestCancellationRequest, RequestCancellationResponse$1, RequestCancellationResponse>;
1821
+ declare function createOnlineOrder(): __PublicMethodMetaInfo<'POST', {}, CreateOnlineOrderRequest$1, CreateOnlineOrderRequest, CreateOnlineOrderResponse$1, CreateOnlineOrderResponse>;
1822
+ declare function createOfflineOrder(): __PublicMethodMetaInfo<'POST', {}, CreateOfflineOrderRequest$1, CreateOfflineOrderRequest, CreateOfflineOrderResponse$1, CreateOfflineOrderResponse>;
1823
+ declare function getOnlineOrderPreview(): __PublicMethodMetaInfo<'POST', {}, GetOnlineOrderPreviewRequest$1, GetOnlineOrderPreviewRequest, GetOnlineOrderPreviewResponse$1, GetOnlineOrderPreviewResponse>;
1824
+ declare function getOfflineOrderPreview(): __PublicMethodMetaInfo<'POST', {}, GetOfflineOrderPreviewRequest$1, GetOfflineOrderPreviewRequest, GetOfflineOrderPreviewResponse$1, GetOfflineOrderPreviewResponse>;
1825
+ declare function getPricePreview(): __PublicMethodMetaInfo<'POST', {}, GetPricePreviewRequest$1, GetPricePreviewRequest, GetPricePreviewResponse$1, GetPricePreviewResponse>;
1814
1826
  declare function managementGetOrder(): __PublicMethodMetaInfo<'GET', {
1815
1827
  id: string;
1816
1828
  }, GetOrderRequest$1, GetOrderRequest, GetOrderResponse$1, GetOrderResponse>;
@@ -1830,17 +1842,5 @@ declare function pauseOrder(): __PublicMethodMetaInfo<'POST', {
1830
1842
  declare function resumeOrder(): __PublicMethodMetaInfo<'POST', {
1831
1843
  id: string;
1832
1844
  }, ResumeOrderRequest$1, ResumeOrderRequest, ResumeOrderResponse$1, ResumeOrderResponse>;
1833
- declare function createOnlineOrder(): __PublicMethodMetaInfo<'POST', {}, CreateOnlineOrderRequest$1, CreateOnlineOrderRequest, CreateOnlineOrderResponse$1, CreateOnlineOrderResponse>;
1834
- declare function createOfflineOrder(): __PublicMethodMetaInfo<'POST', {}, CreateOfflineOrderRequest$1, CreateOfflineOrderRequest, CreateOfflineOrderResponse$1, CreateOfflineOrderResponse>;
1835
- declare function getOnlineOrderPreview(): __PublicMethodMetaInfo<'POST', {}, GetOnlineOrderPreviewRequest$1, GetOnlineOrderPreviewRequest, GetOnlineOrderPreviewResponse$1, GetOnlineOrderPreviewResponse>;
1836
- declare function getOfflineOrderPreview(): __PublicMethodMetaInfo<'POST', {}, GetOfflineOrderPreviewRequest$1, GetOfflineOrderPreviewRequest, GetOfflineOrderPreviewResponse$1, GetOfflineOrderPreviewResponse>;
1837
- declare function getPricePreview(): __PublicMethodMetaInfo<'POST', {}, GetPricePreviewRequest$1, GetPricePreviewRequest, GetPricePreviewResponse$1, GetPricePreviewResponse>;
1838
- declare function memberGetOrder(): __PublicMethodMetaInfo<'GET', {
1839
- id: string;
1840
- }, MemberGetOrderRequest$1, MemberGetOrderRequest, MemberGetOrderResponse$1, MemberGetOrderResponse>;
1841
- declare function memberListOrders(): __PublicMethodMetaInfo<'GET', {}, MemberListOrdersRequest$1, MemberListOrdersRequest, MemberListOrdersResponse$1, MemberListOrdersResponse>;
1842
- declare function requestCancellation(): __PublicMethodMetaInfo<'POST', {
1843
- id: string;
1844
- }, RequestCancellationRequest$1, RequestCancellationRequest, RequestCancellationResponse$1, RequestCancellationResponse>;
1845
1845
 
1846
1846
  export { type AccountInfo as AccountInfoOriginal, type ActionEvent as ActionEventOriginal, type ApplicationError as ApplicationErrorOriginal, type ApplyCouponRequest as ApplyCouponRequestOriginal, type ApplyCouponResponse as ApplyCouponResponseOriginal, type BulkActionMetadata as BulkActionMetadataOriginal, type BulkOrderResult as BulkOrderResultOriginal, type BulkPauseOrderRequest as BulkPauseOrderRequestOriginal, type BulkPauseOrderResponse as BulkPauseOrderResponseOriginal, type BulkResumeOrderRequest as BulkResumeOrderRequestOriginal, type BulkResumeOrderResponse as BulkResumeOrderResponseOriginal, type Buyer as BuyerOriginal, type CancelOrderRequest as CancelOrderRequestOriginal, type CancelOrderResponse as CancelOrderResponseOriginal, CancellationCause as CancellationCauseOriginal, type CancellationCauseWithLiterals as CancellationCauseWithLiteralsOriginal, CancellationEffectiveAt as CancellationEffectiveAtOriginal, type CancellationEffectiveAtWithLiterals as CancellationEffectiveAtWithLiteralsOriginal, type Cancellation as CancellationOriginal, type Captcha as CaptchaOriginal, type ChangeStartDateRequest as ChangeStartDateRequestOriginal, type ChangeStartDateResponse as ChangeStartDateResponseOriginal, type Coupon as CouponOriginal, type CouponsError as CouponsErrorOriginal, type CreateExternalOrderRequest as CreateExternalOrderRequestOriginal, type CreateExternalOrderResponse as CreateExternalOrderResponseOriginal, type CreateGuestOnlineOrderRequest as CreateGuestOnlineOrderRequestOriginal, type CreateGuestOnlineOrderResponse as CreateGuestOnlineOrderResponseOriginal, type CreateOfflineOrderApplicationErrors as CreateOfflineOrderApplicationErrorsOriginal, type CreateOfflineOrderRequest as CreateOfflineOrderRequestOriginal, type CreateOfflineOrderResponse as CreateOfflineOrderResponseOriginal, type CreateOfflineOrderValidationErrors as CreateOfflineOrderValidationErrorsOriginal, type CreateOnlineOrderApplicationErrors as CreateOnlineOrderApplicationErrorsOriginal, type CreateOnlineOrderRequest as CreateOnlineOrderRequestOriginal, type CreateOnlineOrderResponse as CreateOnlineOrderResponseOriginal, type CreateOnlineOrderValidationErrors as CreateOnlineOrderValidationErrorsOriginal, type CurrentCycle as CurrentCycleOriginal, type CursorPaging as CursorPagingOriginal, type Cursors as CursorsOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type Duration as DurationOriginal, type Empty as EmptyOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type Fee as FeeOriginal, type FormData as FormDataOriginal, type GetAvailableOrderActionsRequest as GetAvailableOrderActionsRequestOriginal, type GetAvailableOrderActionsResponse as GetAvailableOrderActionsResponseOriginal, type GetGuestOnlineOrderPreviewRequest as GetGuestOnlineOrderPreviewRequestOriginal, type GetGuestOnlineOrderPreviewResponse as GetGuestOnlineOrderPreviewResponseOriginal, type GetOfflineOrderPreviewApplicationErrors as GetOfflineOrderPreviewApplicationErrorsOriginal, type GetOfflineOrderPreviewRequest as GetOfflineOrderPreviewRequestOriginal, type GetOfflineOrderPreviewResponse as GetOfflineOrderPreviewResponseOriginal, type GetOfflineOrderPreviewValidationErrors as GetOfflineOrderPreviewValidationErrorsOriginal, type GetOnlineOrderPreviewApplicationErrors as GetOnlineOrderPreviewApplicationErrorsOriginal, type GetOnlineOrderPreviewRequest as GetOnlineOrderPreviewRequestOriginal, type GetOnlineOrderPreviewResponse as GetOnlineOrderPreviewResponseOriginal, type GetOnlineOrderPreviewValidationErrors as GetOnlineOrderPreviewValidationErrorsOriginal, type GetOrderRequest as GetOrderRequestOriginal, type GetOrderResponse as GetOrderResponseOriginal, type GetOrdersStatsRequest as GetOrdersStatsRequestOriginal, type GetOrdersStatsResponse as GetOrdersStatsResponseOriginal, type GetPricePreviewApplicationErrors as GetPricePreviewApplicationErrorsOriginal, type GetPricePreviewRequest as GetPricePreviewRequestOriginal, type GetPricePreviewResponse as GetPricePreviewResponseOriginal, type Guest as GuestOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, type ItemMetadata as ItemMetadataOriginal, type ListOrdersRequest as ListOrdersRequestOriginal, type ListOrdersResponse as ListOrdersResponseOriginal, type MarkAsPaidRequest as MarkAsPaidRequestOriginal, type MarkAsPaidResponse as MarkAsPaidResponseOriginal, type MemberGetOrderRequest as MemberGetOrderRequestOriginal, type MemberGetOrderResponse as MemberGetOrderResponseOriginal, type MemberListOrdersRequest as MemberListOrdersRequestOriginal, type MemberListOrdersResponse as MemberListOrdersResponseOriginal, type MessageEnvelope as MessageEnvelopeOriginal, type OnBehalf as OnBehalfOriginal, type OrderAutoRenewCanceled as OrderAutoRenewCanceledOriginal, type OrderCanceled as OrderCanceledOriginal, type OrderCycle as OrderCycleOriginal, type OrderCycleStarted as OrderCycleStartedOriginal, type OrderEndDatePostponed as OrderEndDatePostponedOriginal, type OrderEnded as OrderEndedOriginal, type OrderMarkedAsPaid as OrderMarkedAsPaidOriginal, OrderMethod as OrderMethodOriginal, type OrderMethodWithLiterals as OrderMethodWithLiteralsOriginal, type Order as OrderOriginal, type OrderPaused as OrderPausedOriginal, type OrderPurchased as OrderPurchasedOriginal, type OrderResumed as OrderResumedOriginal, type OrderStartDateChanged as OrderStartDateChangedOriginal, type OrderStarted as OrderStartedOriginal, OrderStatus as OrderStatusOriginal, type OrderStatusWithLiterals as OrderStatusWithLiteralsOriginal, OrderType as OrderTypeOriginal, type OrderTypeWithLiterals as OrderTypeWithLiteralsOriginal, type OrdersQueryOrdersRequest as OrdersQueryOrdersRequestOriginal, type OrdersQueryOrdersResponse as OrdersQueryOrdersResponseOriginal, type PagingMetadataV2 as PagingMetadataV2Original, type Paging as PagingOriginal, type PauseOrderRequest as PauseOrderRequestOriginal, type PauseOrderResponse as PauseOrderResponseOriginal, type PausePeriod as PausePeriodOriginal, PaymentStatus as PaymentStatusOriginal, type PaymentStatusWithLiterals as PaymentStatusWithLiteralsOriginal, PeriodUnit as PeriodUnitOriginal, type PeriodUnitWithLiterals as PeriodUnitWithLiteralsOriginal, type PostponeEndDateRequest as PostponeEndDateRequestOriginal, type PostponeEndDateResponse as PostponeEndDateResponseOriginal, type PriceDetails as PriceDetailsOriginal, type PriceDetailsPricingModelOneOf as PriceDetailsPricingModelOneOfOriginal, type PriceDuration as PriceDurationOriginal, type Price as PriceOriginal, type PricingDetails as PricingDetailsOriginal, type PricingDetailsPricingModelOneOf as PricingDetailsPricingModelOneOfOriginal, type QueryOrdersRequest as QueryOrdersRequestOriginal, type QueryOrdersResponse as QueryOrdersResponseOriginal, type QueryV2 as QueryV2Original, type QueryV2PagingMethodOneOf as QueryV2PagingMethodOneOfOriginal, ReasonNotSuspendable as ReasonNotSuspendableOriginal, type ReasonNotSuspendableWithLiterals as ReasonNotSuspendableWithLiteralsOriginal, type Recurrence as RecurrenceOriginal, type RequestCancellationRequest as RequestCancellationRequestOriginal, type RequestCancellationResponse as RequestCancellationResponseOriginal, type RestoreInfo as RestoreInfoOriginal, type ResumeOrderRequest as ResumeOrderRequestOriginal, type ResumeOrderResponse as ResumeOrderResponseOriginal, Set as SetOriginal, type SetSubmissionRequest as SetSubmissionRequestOriginal, type SetSubmissionResponse as SetSubmissionResponseOriginal, type SetWithLiterals as SetWithLiteralsOriginal, SortOrder as SortOrderOriginal, type SortOrderWithLiterals as SortOrderWithLiteralsOriginal, type Sorting as SortingOriginal, type SpannedPrice as SpannedPriceOriginal, Status as StatusOriginal, type StatusWithLiterals as StatusWithLiteralsOriginal, type Tax as TaxOriginal, WebhookIdentityType as WebhookIdentityTypeOriginal, type WebhookIdentityTypeWithLiterals as WebhookIdentityTypeWithLiteralsOriginal, type __PublicMethodMetaInfo, cancelOrder, createOfflineOrder, createOnlineOrder, getOfflineOrderPreview, getOnlineOrderPreview, getPricePreview, managementGetOrder, managementListOrders, markAsPaid, memberGetOrder, memberListOrders, pauseOrder, postponeEndDate, requestCancellation, resumeOrder };