rebilly-js-sdk 62.69.0 → 62.71.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
- ## [62.69.0](https://github.com/Rebilly/rebilly/compare/rebilly-js-sdk-v62.68.0...rebilly-js-sdk-v62.69.0) (2026-03-14)
1
+ ## [62.71.0](https://github.com/Rebilly/rebilly/compare/rebilly-js-sdk-v62.70.0...rebilly-js-sdk-v62.71.0) (2026-03-19)
2
2
 
3
3
 
4
4
  ### Features
5
5
 
6
- * **storefront-payment-form:** Add amplitude tracking to dcc page ([#19491](https://github.com/Rebilly/rebilly/issues/19491)) ([60e7365](https://github.com/Rebilly/rebilly/commit/60e73656e157112be02a68df4e3f457eca2d5944))
6
+ * **api-metadata, rebilly-js-sdk:** Update resources based on latest api definitions ([#19814](https://github.com/Rebilly/rebilly/issues/19814)) ([dd8f1de](https://github.com/Rebilly/rebilly/commit/dd8f1dede76bd9ce1e8e2d2285eb5d2adef8db6b))
@@ -6133,20 +6133,21 @@ export interface coreComponents {
6133
6133
  /** HTTP status code. */
6134
6134
  status?: number;
6135
6135
  } & coreComponents["schemas"]["BaseProblem"];
6136
+ /** Invalid field details. */
6137
+ InvalidFields: {
6138
+ /**
6139
+ * Name of the field.
6140
+ * Dot notation is used for nested object field names.
6141
+ */
6142
+ field?: string;
6143
+ /** Message field. */
6144
+ message?: string;
6145
+ }[];
6136
6146
  ValidationError: { [key: string]: any } & {
6137
6147
  /** HTTP status code. */
6138
6148
  status?: number;
6139
6149
  } & coreComponents["schemas"]["BaseProblem"] & {
6140
- /** Invalid field details. */
6141
- invalidFields?: {
6142
- /**
6143
- * Name of the field.
6144
- * Dot notation is used for nested object field names.
6145
- */
6146
- field?: string;
6147
- /** Message field. */
6148
- message?: string;
6149
- }[];
6150
+ invalidFields?: coreComponents["schemas"]["InvalidFields"];
6150
6151
  };
6151
6152
  /** RFC-7807 [problem details](https://tools.ietf.org/html/rfc7807) JSON object. */
6152
6153
  TooManyRequests: {
@@ -9737,7 +9738,13 @@ export interface coreComponents {
9737
9738
  tax?: coreComponents["schemas"]["CreditMemoTaxItem"] | null;
9738
9739
  }[];
9739
9740
  /** Status of the credit memo. */
9740
- status?: "draft" | "issued" | "applied" | "partially-applied" | "voided";
9741
+ status?:
9742
+ | "draft"
9743
+ | "quotation"
9744
+ | "issued"
9745
+ | "applied"
9746
+ | "partially-applied"
9747
+ | "voided";
9741
9748
  /** Reason for the credit memo. */
9742
9749
  reason?:
9743
9750
  | "return"
@@ -13913,6 +13920,8 @@ export interface coreComponents {
13913
13920
  revision?: number;
13914
13921
  /** Date and time when the next subscription in this recurring order renews. */
13915
13922
  renewalTime?: string | null;
13923
+ /** Specifies if the order is a new order. */
13924
+ isNew?: boolean;
13916
13925
  createdTime?: coreComponents["schemas"]["CreatedTime"];
13917
13926
  updatedTime?: coreComponents["schemas"]["UpdatedTime"];
13918
13927
  _links?: coreComponents["schemas"]["SelfLink"];
@@ -14012,6 +14021,8 @@ export interface coreComponents {
14012
14021
  * change takes precedence over the current representation.
14013
14022
  */
14014
14023
  revision?: number;
14024
+ /** Specifies if the order is a new order. */
14025
+ isNew?: boolean;
14015
14026
  createdTime?: coreComponents["schemas"]["CreatedTime"];
14016
14027
  updatedTime?: coreComponents["schemas"]["UpdatedTime"];
14017
14028
  _links?: coreComponents["schemas"]["SelfLink"];
@@ -20593,6 +20604,8 @@ export interface coreComponents {
20593
20604
  applicationFeePercentage?: number;
20594
20605
  /** Specifies whether to include payment card network in the request to Stripe. */
20595
20606
  includeCardNetwork?: boolean;
20607
+ /** Name of the transaction custom field that holds the Radar Session ID. */
20608
+ radarSessionCustomField?: string;
20596
20609
  };
20597
20610
  /** Stripe Integrated. */
20598
20611
  threeDSecureServer?: {
@@ -21786,7 +21799,7 @@ export interface coreComponents {
21786
21799
  allocations?: {
21787
21800
  /** ID of the transaction to which the payout request is allocated. */
21788
21801
  transactionId?: coreComponents["schemas"]["TransactionId"];
21789
- /** Result of a transaction. */
21802
+ /** Result of the transaction. */
21790
21803
  transactionResult?:
21791
21804
  | "abandoned"
21792
21805
  | "approved"
@@ -21832,6 +21845,8 @@ export interface coreComponents {
21832
21845
  batchId?: string | null;
21833
21846
  /** ID of the payment instrument allocated to the payout request. */
21834
21847
  paymentInstrumentId: string;
21848
+ /** Payment method of the allocation. */
21849
+ paymentMethod?: coreComponents["schemas"]["PaymentMethod"];
21835
21850
  /** ID of the gateway account to use for processing this allocation. */
21836
21851
  gatewayAccountId: string;
21837
21852
  /** Name of the gateway account to use for processing this allocation. */
@@ -21851,6 +21866,30 @@ export interface coreComponents {
21851
21866
  | "declined";
21852
21867
  /** ID of the transaction that is created when processing this allocation, if applicable. */
21853
21868
  transactionId?: string | null;
21869
+ /** Result of the transaction created for this allocation, if applicable. */
21870
+ transactionResult?:
21871
+ | ("abandoned" | "approved" | "canceled" | "declined" | "unknown")
21872
+ | null;
21873
+ /** Status of the transaction created for this allocation, if applicable. */
21874
+ transactionStatus?:
21875
+ | (
21876
+ | "completed"
21877
+ | "conn-error"
21878
+ | "disputed"
21879
+ | "never-sent"
21880
+ | "offsite"
21881
+ | "partially-refunded"
21882
+ | "pending"
21883
+ | "refunded"
21884
+ | "sending"
21885
+ | "timeout"
21886
+ | "voided"
21887
+ | "waiting-approval"
21888
+ | "waiting-capture"
21889
+ | "waiting-gateway"
21890
+ | "waiting-refund"
21891
+ )
21892
+ | null;
21854
21893
  /** Date and time when the allocation for the payout request was created. */
21855
21894
  createdTime?: coreComponents["schemas"]["CreatedTime"];
21856
21895
  updatedTime?: coreComponents["schemas"]["UpdatedTime"];
@@ -23208,6 +23247,11 @@ export interface coreComponents {
23208
23247
  value?: number;
23209
23248
  }[];
23210
23249
  };
23250
+ BadRequest: { [key: string]: any } & {
23251
+ /** HTTP status code. */
23252
+ status?: number;
23253
+ invalidFields?: coreComponents["schemas"]["InvalidFields"];
23254
+ } & coreComponents["schemas"]["BaseProblem"];
23211
23255
  ApiLogSummary: {
23212
23256
  /** API log summary data. */
23213
23257
  data?: {
@@ -25404,6 +25448,7 @@ export interface coreComponents {
25404
25448
  /** Embedded objects that are requested by the `expand` query parameter. */
25405
25449
  _embedded?: {
25406
25450
  customer?: { [key: string]: any };
25451
+ creditMemos?: { [key: string]: any }[];
25407
25452
  website?: { [key: string]: any };
25408
25453
  order?: { [key: string]: any };
25409
25454
  invoice?: { [key: string]: any };
@@ -25602,6 +25647,7 @@ export interface coreComponents {
25602
25647
  /** Embedded objects that are requested by the `expand` query parameter. */
25603
25648
  _embedded?: {
25604
25649
  customer?: { [key: string]: any };
25650
+ creditMemos?: { [key: string]: any }[];
25605
25651
  website?: { [key: string]: any };
25606
25652
  order?: { [key: string]: any };
25607
25653
  invoice?: { [key: string]: any };
@@ -26274,6 +26320,7 @@ export interface coreComponents {
26274
26320
  /** Embedded objects that are requested by the `expand` query parameter. */
26275
26321
  _embedded?: {
26276
26322
  customer?: { [key: string]: any };
26323
+ creditMemos?: { [key: string]: any }[];
26277
26324
  website?: { [key: string]: any };
26278
26325
  order?: { [key: string]: any };
26279
26326
  invoice?: { [key: string]: any };
@@ -26699,6 +26746,12 @@ export interface coreComponents {
26699
26746
  * No response body returned.
26700
26747
  */
26701
26748
  NoContent: unknown;
26749
+ /** Server could not understand the request due to invalid syntax. */
26750
+ BadRequest: {
26751
+ content: {
26752
+ "application/json": coreComponents["schemas"]["BadRequest"];
26753
+ };
26754
+ };
26702
26755
  };
26703
26756
  parameters: {
26704
26757
  /** Limits the number of collection items to be returned. */
@@ -43552,20 +43605,21 @@ export interface storefrontComponents {
43552
43605
  /** HTTP status code. */
43553
43606
  status?: number;
43554
43607
  } & storefrontComponents["schemas"]["BaseProblem"];
43608
+ /** Invalid field details. */
43609
+ InvalidFields: {
43610
+ /**
43611
+ * Name of the field.
43612
+ * Dot notation is used for nested object field names.
43613
+ */
43614
+ field?: string;
43615
+ /** Message field. */
43616
+ message?: string;
43617
+ }[];
43555
43618
  ValidationError: { [key: string]: any } & {
43556
43619
  /** HTTP status code. */
43557
43620
  status?: number;
43558
43621
  } & storefrontComponents["schemas"]["BaseProblem"] & {
43559
- /** Invalid field details. */
43560
- invalidFields?: {
43561
- /**
43562
- * Name of the field.
43563
- * Dot notation is used for nested object field names.
43564
- */
43565
- field?: string;
43566
- /** Message field. */
43567
- message?: string;
43568
- }[];
43622
+ invalidFields?: storefrontComponents["schemas"]["InvalidFields"];
43569
43623
  };
43570
43624
  /** RFC-7807 [problem details](https://tools.ietf.org/html/rfc7807) JSON object. */
43571
43625
  TooManyRequests: {
@@ -47156,7 +47210,13 @@ export interface storefrontComponents {
47156
47210
  tax?: storefrontComponents["schemas"]["CreditMemoTaxItem"] | null;
47157
47211
  }[];
47158
47212
  /** Status of the credit memo. */
47159
- status?: "draft" | "issued" | "applied" | "partially-applied" | "voided";
47213
+ status?:
47214
+ | "draft"
47215
+ | "quotation"
47216
+ | "issued"
47217
+ | "applied"
47218
+ | "partially-applied"
47219
+ | "voided";
47160
47220
  /** Reason for the credit memo. */
47161
47221
  reason?:
47162
47222
  | "return"
@@ -51332,6 +51392,8 @@ export interface storefrontComponents {
51332
51392
  revision?: number;
51333
51393
  /** Date and time when the next subscription in this recurring order renews. */
51334
51394
  renewalTime?: string | null;
51395
+ /** Specifies if the order is a new order. */
51396
+ isNew?: boolean;
51335
51397
  createdTime?: storefrontComponents["schemas"]["CreatedTime"];
51336
51398
  updatedTime?: storefrontComponents["schemas"]["UpdatedTime"];
51337
51399
  _links?: storefrontComponents["schemas"]["SelfLink"];
@@ -51431,6 +51493,8 @@ export interface storefrontComponents {
51431
51493
  * change takes precedence over the current representation.
51432
51494
  */
51433
51495
  revision?: number;
51496
+ /** Specifies if the order is a new order. */
51497
+ isNew?: boolean;
51434
51498
  createdTime?: storefrontComponents["schemas"]["CreatedTime"];
51435
51499
  updatedTime?: storefrontComponents["schemas"]["UpdatedTime"];
51436
51500
  _links?: storefrontComponents["schemas"]["SelfLink"];
@@ -58012,6 +58076,8 @@ export interface storefrontComponents {
58012
58076
  applicationFeePercentage?: number;
58013
58077
  /** Specifies whether to include payment card network in the request to Stripe. */
58014
58078
  includeCardNetwork?: boolean;
58079
+ /** Name of the transaction custom field that holds the Radar Session ID. */
58080
+ radarSessionCustomField?: string;
58015
58081
  };
58016
58082
  /** Stripe Integrated. */
58017
58083
  threeDSecureServer?: {
@@ -59205,7 +59271,7 @@ export interface storefrontComponents {
59205
59271
  allocations?: {
59206
59272
  /** ID of the transaction to which the payout request is allocated. */
59207
59273
  transactionId?: storefrontComponents["schemas"]["TransactionId"];
59208
- /** Result of a transaction. */
59274
+ /** Result of the transaction. */
59209
59275
  transactionResult?:
59210
59276
  | "abandoned"
59211
59277
  | "approved"
@@ -59251,6 +59317,8 @@ export interface storefrontComponents {
59251
59317
  batchId?: string | null;
59252
59318
  /** ID of the payment instrument allocated to the payout request. */
59253
59319
  paymentInstrumentId: string;
59320
+ /** Payment method of the allocation. */
59321
+ paymentMethod?: storefrontComponents["schemas"]["PaymentMethod"];
59254
59322
  /** ID of the gateway account to use for processing this allocation. */
59255
59323
  gatewayAccountId: string;
59256
59324
  /** Name of the gateway account to use for processing this allocation. */
@@ -59270,6 +59338,30 @@ export interface storefrontComponents {
59270
59338
  | "declined";
59271
59339
  /** ID of the transaction that is created when processing this allocation, if applicable. */
59272
59340
  transactionId?: string | null;
59341
+ /** Result of the transaction created for this allocation, if applicable. */
59342
+ transactionResult?:
59343
+ | ("abandoned" | "approved" | "canceled" | "declined" | "unknown")
59344
+ | null;
59345
+ /** Status of the transaction created for this allocation, if applicable. */
59346
+ transactionStatus?:
59347
+ | (
59348
+ | "completed"
59349
+ | "conn-error"
59350
+ | "disputed"
59351
+ | "never-sent"
59352
+ | "offsite"
59353
+ | "partially-refunded"
59354
+ | "pending"
59355
+ | "refunded"
59356
+ | "sending"
59357
+ | "timeout"
59358
+ | "voided"
59359
+ | "waiting-approval"
59360
+ | "waiting-capture"
59361
+ | "waiting-gateway"
59362
+ | "waiting-refund"
59363
+ )
59364
+ | null;
59273
59365
  /** Date and time when the allocation for the payout request was created. */
59274
59366
  createdTime?: storefrontComponents["schemas"]["CreatedTime"];
59275
59367
  updatedTime?: storefrontComponents["schemas"]["UpdatedTime"];
@@ -60627,6 +60719,11 @@ export interface storefrontComponents {
60627
60719
  value?: number;
60628
60720
  }[];
60629
60721
  };
60722
+ BadRequest: { [key: string]: any } & {
60723
+ /** HTTP status code. */
60724
+ status?: number;
60725
+ invalidFields?: storefrontComponents["schemas"]["InvalidFields"];
60726
+ } & storefrontComponents["schemas"]["BaseProblem"];
60630
60727
  ApiLogSummary: {
60631
60728
  /** API log summary data. */
60632
60729
  data?: {
@@ -62823,6 +62920,7 @@ export interface storefrontComponents {
62823
62920
  /** Embedded objects that are requested by the `expand` query parameter. */
62824
62921
  _embedded?: {
62825
62922
  customer?: { [key: string]: any };
62923
+ creditMemos?: { [key: string]: any }[];
62826
62924
  website?: { [key: string]: any };
62827
62925
  order?: { [key: string]: any };
62828
62926
  invoice?: { [key: string]: any };
@@ -63021,6 +63119,7 @@ export interface storefrontComponents {
63021
63119
  /** Embedded objects that are requested by the `expand` query parameter. */
63022
63120
  _embedded?: {
63023
63121
  customer?: { [key: string]: any };
63122
+ creditMemos?: { [key: string]: any }[];
63024
63123
  website?: { [key: string]: any };
63025
63124
  order?: { [key: string]: any };
63026
63125
  invoice?: { [key: string]: any };
@@ -63693,6 +63792,7 @@ export interface storefrontComponents {
63693
63792
  /** Embedded objects that are requested by the `expand` query parameter. */
63694
63793
  _embedded?: {
63695
63794
  customer?: { [key: string]: any };
63795
+ creditMemos?: { [key: string]: any }[];
63696
63796
  website?: { [key: string]: any };
63697
63797
  order?: { [key: string]: any };
63698
63798
  invoice?: { [key: string]: any };
@@ -64118,6 +64218,12 @@ export interface storefrontComponents {
64118
64218
  * No response body returned.
64119
64219
  */
64120
64220
  NoContent: unknown;
64221
+ /** Server could not understand the request due to invalid syntax. */
64222
+ BadRequest: {
64223
+ content: {
64224
+ "application/json": storefrontComponents["schemas"]["BadRequest"];
64225
+ };
64226
+ };
64121
64227
  };
64122
64228
  parameters: {
64123
64229
  /** Limits the number of collection items to be returned. */
@@ -68570,20 +68676,21 @@ export interface reportsComponents {
68570
68676
  /** HTTP status code. */
68571
68677
  status?: number;
68572
68678
  } & reportsComponents["schemas"]["BaseProblem"];
68679
+ /** Invalid field details. */
68680
+ InvalidFields: {
68681
+ /**
68682
+ * Name of the field.
68683
+ * Dot notation is used for nested object field names.
68684
+ */
68685
+ field?: string;
68686
+ /** Message field. */
68687
+ message?: string;
68688
+ }[];
68573
68689
  ValidationError: { [key: string]: any } & {
68574
68690
  /** HTTP status code. */
68575
68691
  status?: number;
68576
68692
  } & reportsComponents["schemas"]["BaseProblem"] & {
68577
- /** Invalid field details. */
68578
- invalidFields?: {
68579
- /**
68580
- * Name of the field.
68581
- * Dot notation is used for nested object field names.
68582
- */
68583
- field?: string;
68584
- /** Message field. */
68585
- message?: string;
68586
- }[];
68693
+ invalidFields?: reportsComponents["schemas"]["InvalidFields"];
68587
68694
  };
68588
68695
  /** RFC-7807 [problem details](https://tools.ietf.org/html/rfc7807) JSON object. */
68589
68696
  TooManyRequests: {
@@ -72174,7 +72281,13 @@ export interface reportsComponents {
72174
72281
  tax?: reportsComponents["schemas"]["CreditMemoTaxItem"] | null;
72175
72282
  }[];
72176
72283
  /** Status of the credit memo. */
72177
- status?: "draft" | "issued" | "applied" | "partially-applied" | "voided";
72284
+ status?:
72285
+ | "draft"
72286
+ | "quotation"
72287
+ | "issued"
72288
+ | "applied"
72289
+ | "partially-applied"
72290
+ | "voided";
72178
72291
  /** Reason for the credit memo. */
72179
72292
  reason?:
72180
72293
  | "return"
@@ -76350,6 +76463,8 @@ export interface reportsComponents {
76350
76463
  revision?: number;
76351
76464
  /** Date and time when the next subscription in this recurring order renews. */
76352
76465
  renewalTime?: string | null;
76466
+ /** Specifies if the order is a new order. */
76467
+ isNew?: boolean;
76353
76468
  createdTime?: reportsComponents["schemas"]["CreatedTime"];
76354
76469
  updatedTime?: reportsComponents["schemas"]["UpdatedTime"];
76355
76470
  _links?: reportsComponents["schemas"]["SelfLink"];
@@ -76449,6 +76564,8 @@ export interface reportsComponents {
76449
76564
  * change takes precedence over the current representation.
76450
76565
  */
76451
76566
  revision?: number;
76567
+ /** Specifies if the order is a new order. */
76568
+ isNew?: boolean;
76452
76569
  createdTime?: reportsComponents["schemas"]["CreatedTime"];
76453
76570
  updatedTime?: reportsComponents["schemas"]["UpdatedTime"];
76454
76571
  _links?: reportsComponents["schemas"]["SelfLink"];
@@ -83030,6 +83147,8 @@ export interface reportsComponents {
83030
83147
  applicationFeePercentage?: number;
83031
83148
  /** Specifies whether to include payment card network in the request to Stripe. */
83032
83149
  includeCardNetwork?: boolean;
83150
+ /** Name of the transaction custom field that holds the Radar Session ID. */
83151
+ radarSessionCustomField?: string;
83033
83152
  };
83034
83153
  /** Stripe Integrated. */
83035
83154
  threeDSecureServer?: {
@@ -84223,7 +84342,7 @@ export interface reportsComponents {
84223
84342
  allocations?: {
84224
84343
  /** ID of the transaction to which the payout request is allocated. */
84225
84344
  transactionId?: reportsComponents["schemas"]["TransactionId"];
84226
- /** Result of a transaction. */
84345
+ /** Result of the transaction. */
84227
84346
  transactionResult?:
84228
84347
  | "abandoned"
84229
84348
  | "approved"
@@ -84269,6 +84388,8 @@ export interface reportsComponents {
84269
84388
  batchId?: string | null;
84270
84389
  /** ID of the payment instrument allocated to the payout request. */
84271
84390
  paymentInstrumentId: string;
84391
+ /** Payment method of the allocation. */
84392
+ paymentMethod?: reportsComponents["schemas"]["PaymentMethod"];
84272
84393
  /** ID of the gateway account to use for processing this allocation. */
84273
84394
  gatewayAccountId: string;
84274
84395
  /** Name of the gateway account to use for processing this allocation. */
@@ -84288,6 +84409,30 @@ export interface reportsComponents {
84288
84409
  | "declined";
84289
84410
  /** ID of the transaction that is created when processing this allocation, if applicable. */
84290
84411
  transactionId?: string | null;
84412
+ /** Result of the transaction created for this allocation, if applicable. */
84413
+ transactionResult?:
84414
+ | ("abandoned" | "approved" | "canceled" | "declined" | "unknown")
84415
+ | null;
84416
+ /** Status of the transaction created for this allocation, if applicable. */
84417
+ transactionStatus?:
84418
+ | (
84419
+ | "completed"
84420
+ | "conn-error"
84421
+ | "disputed"
84422
+ | "never-sent"
84423
+ | "offsite"
84424
+ | "partially-refunded"
84425
+ | "pending"
84426
+ | "refunded"
84427
+ | "sending"
84428
+ | "timeout"
84429
+ | "voided"
84430
+ | "waiting-approval"
84431
+ | "waiting-capture"
84432
+ | "waiting-gateway"
84433
+ | "waiting-refund"
84434
+ )
84435
+ | null;
84291
84436
  /** Date and time when the allocation for the payout request was created. */
84292
84437
  createdTime?: reportsComponents["schemas"]["CreatedTime"];
84293
84438
  updatedTime?: reportsComponents["schemas"]["UpdatedTime"];
@@ -85645,6 +85790,11 @@ export interface reportsComponents {
85645
85790
  value?: number;
85646
85791
  }[];
85647
85792
  };
85793
+ BadRequest: { [key: string]: any } & {
85794
+ /** HTTP status code. */
85795
+ status?: number;
85796
+ invalidFields?: reportsComponents["schemas"]["InvalidFields"];
85797
+ } & reportsComponents["schemas"]["BaseProblem"];
85648
85798
  ApiLogSummary: {
85649
85799
  /** API log summary data. */
85650
85800
  data?: {
@@ -87841,6 +87991,7 @@ export interface reportsComponents {
87841
87991
  /** Embedded objects that are requested by the `expand` query parameter. */
87842
87992
  _embedded?: {
87843
87993
  customer?: { [key: string]: any };
87994
+ creditMemos?: { [key: string]: any }[];
87844
87995
  website?: { [key: string]: any };
87845
87996
  order?: { [key: string]: any };
87846
87997
  invoice?: { [key: string]: any };
@@ -88039,6 +88190,7 @@ export interface reportsComponents {
88039
88190
  /** Embedded objects that are requested by the `expand` query parameter. */
88040
88191
  _embedded?: {
88041
88192
  customer?: { [key: string]: any };
88193
+ creditMemos?: { [key: string]: any }[];
88042
88194
  website?: { [key: string]: any };
88043
88195
  order?: { [key: string]: any };
88044
88196
  invoice?: { [key: string]: any };
@@ -88711,6 +88863,7 @@ export interface reportsComponents {
88711
88863
  /** Embedded objects that are requested by the `expand` query parameter. */
88712
88864
  _embedded?: {
88713
88865
  customer?: { [key: string]: any };
88866
+ creditMemos?: { [key: string]: any }[];
88714
88867
  website?: { [key: string]: any };
88715
88868
  order?: { [key: string]: any };
88716
88869
  invoice?: { [key: string]: any };
@@ -89136,6 +89289,12 @@ export interface reportsComponents {
89136
89289
  * No response body returned.
89137
89290
  */
89138
89291
  NoContent: unknown;
89292
+ /** Server could not understand the request due to invalid syntax. */
89293
+ BadRequest: {
89294
+ content: {
89295
+ "application/json": reportsComponents["schemas"]["BadRequest"];
89296
+ };
89297
+ };
89139
89298
  };
89140
89299
  parameters: {
89141
89300
  /** Limits the number of collection items to be returned. */
@@ -91539,6 +91698,7 @@ export interface operations {
91539
91698
  "application/json": reportsComponents["schemas"]["HistogramData"];
91540
91699
  };
91541
91700
  };
91701
+ 400: reportsComponents["responses"]["BadRequest"];
91542
91702
  403: reportsComponents["responses"]["Forbidden"];
91543
91703
  };
91544
91704
  };
@@ -91596,6 +91756,7 @@ export interface operations {
91596
91756
  "application/json": reportsComponents["schemas"]["HistogramData"];
91597
91757
  };
91598
91758
  };
91759
+ 400: reportsComponents["responses"]["BadRequest"];
91599
91760
  403: reportsComponents["responses"]["Forbidden"];
91600
91761
  };
91601
91762
  };
@@ -91635,6 +91796,7 @@ export interface operations {
91635
91796
  "application/json": reportsComponents["schemas"]["ApiLogSummary"];
91636
91797
  };
91637
91798
  };
91799
+ 400: reportsComponents["responses"]["BadRequest"];
91638
91800
  401: reportsComponents["responses"]["Unauthorized"];
91639
91801
  403: reportsComponents["responses"]["Forbidden"];
91640
91802
  };
@@ -91675,6 +91837,7 @@ export interface operations {
91675
91837
  "application/json": reportsComponents["schemas"]["ReportAmlChecks"];
91676
91838
  };
91677
91839
  };
91840
+ 400: reportsComponents["responses"]["BadRequest"];
91678
91841
  401: reportsComponents["responses"]["Unauthorized"];
91679
91842
  403: reportsComponents["responses"]["Forbidden"];
91680
91843
  };
@@ -91717,6 +91880,7 @@ export interface operations {
91717
91880
  "application/json": reportsComponents["schemas"]["CumulativeSubscriptions"];
91718
91881
  };
91719
91882
  };
91883
+ 400: reportsComponents["responses"]["BadRequest"];
91720
91884
  401: reportsComponents["responses"]["Unauthorized"];
91721
91885
  403: reportsComponents["responses"]["Forbidden"];
91722
91886
  };
@@ -91748,6 +91912,7 @@ export interface operations {
91748
91912
  "application/json": reportsComponents["schemas"]["DashboardResponse"];
91749
91913
  };
91750
91914
  };
91915
+ 400: reportsComponents["responses"]["BadRequest"];
91751
91916
  401: reportsComponents["responses"]["Unauthorized"];
91752
91917
  403: reportsComponents["responses"]["Forbidden"];
91753
91918
  };
@@ -91797,6 +91962,7 @@ export interface operations {
91797
91962
  "application/json": reportsComponents["schemas"]["DccMarkup"];
91798
91963
  };
91799
91964
  };
91965
+ 400: reportsComponents["responses"]["BadRequest"];
91800
91966
  401: reportsComponents["responses"]["Unauthorized"];
91801
91967
  403: reportsComponents["responses"]["Forbidden"];
91802
91968
  };
@@ -91844,6 +92010,7 @@ export interface operations {
91844
92010
  "application/json": reportsComponents["schemas"]["ReportDeclinedTransactions"];
91845
92011
  };
91846
92012
  };
92013
+ 400: reportsComponents["responses"]["BadRequest"];
91847
92014
  401: reportsComponents["responses"]["Unauthorized"];
91848
92015
  403: reportsComponents["responses"]["Forbidden"];
91849
92016
  };
@@ -91892,6 +92059,7 @@ export interface operations {
91892
92059
  "application/json": reportsComponents["schemas"]["ReportDeferredRevenue"];
91893
92060
  };
91894
92061
  };
92062
+ 400: reportsComponents["responses"]["BadRequest"];
91895
92063
  401: reportsComponents["responses"]["Unauthorized"];
91896
92064
  403: reportsComponents["responses"]["Forbidden"];
91897
92065
  };
@@ -91938,6 +92106,7 @@ export interface operations {
91938
92106
  "application/json": reportsComponents["schemas"]["ReportDisputes"];
91939
92107
  };
91940
92108
  };
92109
+ 400: reportsComponents["responses"]["BadRequest"];
91941
92110
  401: reportsComponents["responses"]["Unauthorized"];
91942
92111
  403: reportsComponents["responses"]["Forbidden"];
91943
92112
  };
@@ -91970,6 +92139,7 @@ export interface operations {
91970
92139
  "application/json": reportsComponents["schemas"]["ReportEventsTriggeredSummary"];
91971
92140
  };
91972
92141
  };
92142
+ 400: reportsComponents["responses"]["BadRequest"];
91973
92143
  401: reportsComponents["responses"]["Unauthorized"];
91974
92144
  403: reportsComponents["responses"]["Forbidden"];
91975
92145
  };
@@ -92006,6 +92176,7 @@ export interface operations {
92006
92176
  "application/json": reportsComponents["schemas"]["ReportRulesMatchedSummary"];
92007
92177
  };
92008
92178
  };
92179
+ 400: reportsComponents["responses"]["BadRequest"];
92009
92180
  401: reportsComponents["responses"]["Unauthorized"];
92010
92181
  403: reportsComponents["responses"]["Forbidden"];
92011
92182
  };
@@ -92040,6 +92211,7 @@ export interface operations {
92040
92211
  "application/json": reportsComponents["schemas"]["FutureRenewals"];
92041
92212
  };
92042
92213
  };
92214
+ 400: reportsComponents["responses"]["BadRequest"];
92043
92215
  401: reportsComponents["responses"]["Unauthorized"];
92044
92216
  403: reportsComponents["responses"]["Forbidden"];
92045
92217
  };
@@ -92248,6 +92420,7 @@ export interface operations {
92248
92420
  };
92249
92421
  };
92250
92422
  };
92423
+ 400: reportsComponents["responses"]["BadRequest"];
92251
92424
  401: reportsComponents["responses"]["Unauthorized"];
92252
92425
  403: reportsComponents["responses"]["Forbidden"];
92253
92426
  };
@@ -92347,9 +92520,9 @@ export interface operations {
92347
92520
  "application/json": reportsComponents["schemas"]["ReportMonthlyRecurringRevenue"];
92348
92521
  };
92349
92522
  };
92523
+ 400: reportsComponents["responses"]["BadRequest"];
92350
92524
  401: reportsComponents["responses"]["Unauthorized"];
92351
92525
  403: reportsComponents["responses"]["Forbidden"];
92352
- 422: reportsComponents["responses"]["ValidationError"];
92353
92526
  };
92354
92527
  };
92355
92528
  /**
@@ -92391,9 +92564,9 @@ export interface operations {
92391
92564
  "application/json": reportsComponents["schemas"]["ReportAnnualRecurringRevenue"];
92392
92565
  };
92393
92566
  };
92567
+ 400: reportsComponents["responses"]["BadRequest"];
92394
92568
  401: reportsComponents["responses"]["Unauthorized"];
92395
92569
  403: reportsComponents["responses"]["Forbidden"];
92396
- 422: reportsComponents["responses"]["ValidationError"];
92397
92570
  };
92398
92571
  };
92399
92572
  /** Retrieves a renewal sales report. */
@@ -92878,6 +93051,7 @@ export interface operations {
92878
93051
  "application/json": reportsComponents["schemas"]["ReportTransactions"];
92879
93052
  };
92880
93053
  };
93054
+ 400: reportsComponents["responses"]["BadRequest"];
92881
93055
  401: reportsComponents["responses"]["Unauthorized"];
92882
93056
  403: reportsComponents["responses"]["Forbidden"];
92883
93057
  };
@@ -458,7 +458,7 @@ function C({ options: e }) {
458
458
  }
459
459
  function o() {
460
460
  const i = {
461
- "REB-API-CONSUMER": `${["Rebilly", e.appName, "js-sdk"].filter((g) => g).join("/")}@60e7365`
461
+ "REB-API-CONSUMER": `${["Rebilly", e.appName, "js-sdk"].filter((g) => g).join("/")}@dd8f1de`
462
462
  };
463
463
  return e.apiKey && (i["REB-APIKEY"] = e.apiKey), i;
464
464
  }
@@ -13,4 +13,4 @@
13
13
  *
14
14
  * Copyright (c) 2014-2017, Jon Schlinkert.
15
15
  * Released under the MIT License.
16
- */var Ie=de;function L(t){return Ie(t)===!0&&Object.prototype.toString.call(t)==="[object Object]"}var Se=function(e){var s,n;return!(L(e)===!1||(s=e.constructor,typeof s!="function")||(n=s.prototype,L(n)===!1)||n.hasOwnProperty("isPrototypeOf")===!1)};const Ee=Te,xe=B,Pe=Se;function E(t,e){switch(xe(t)){case"object":return Ce(t,e);case"array":return je(t,e);default:return Ee(t)}}function Ce(t,e){if(typeof e=="function")return e(t);if(e||Pe(t)){const s=new t.constructor;for(let n in t)s[n]=E(t[n],e);return s}return t}function je(t,e){const s=new t.constructor(t.length);for(let n=0;n<t.length;n++)s[n]=E(t[n],e);return s}var De=E;const Me=ce(De);let Oe="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",Fe=(t=21)=>{let e="",s=t|0;for(;s--;)e+=Oe[Math.random()*64|0];return e};class Be{constructor({id:e=null,created:s=null}={}){this.id=e||Fe(),this.created=s||new Date().getTime(),this.cancelSource=$.CancelToken.source(),this.cancel=this.cancelSource.cancel,this.cancelToken=this.cancelSource.token,y(this,{exclude:["cancelSource","cancelToken","cancel"]})}}let Ke=class S{constructor(){if(S.instance)return S.instance;this.requests={},S.instance=this}getAll(){return Object.values(this.requests)}getById(e){return this.requests[e]}deleteById(e){this.requests[e]&&delete this.requests[e]}save(){const e=new Be;return this.requests[e.id]=e,{id:e.id,cancelToken:e.cancelToken}}};const q=new Ke;class d{}M(d,"cancelById",(e,s)=>{try{q.getById(e).cancel(s),q.deleteById(e)}catch{}}),M(d,"cancelAll",async e=>{for(const s of q.getAll())await s.cancel(e),q.deleteById(s.id)});const Ne={cancelAll:async(...t)=>await d.cancelAll(...t)},b={request:"request",response:"response"},z=t=>{if(!Object.values(b).includes(t))throw new Error(`There is no such interceptor type as "${t}"`);return!0};function x({options:t}){const e=s();function s(){return $.create(r())}function n(){return e}function r(){return{baseURL:u(),timeout:t.requestTimeout,headers:o()}}function u(){let c=t.isSandbox?t.apiEndpoints.sandbox:t.apiEndpoints.live;return t.apiVersion&&(c=`${c}/${t.apiVersion}`),t.organizationId&&(c=`${c}/organizations/${t.organizationId}`),`${c}`}function o(){const i={"REB-API-CONSUMER":`${["Rebilly",t.appName,"js-sdk"].filter(g=>g).join("/")}@60e7365`};return t.apiKey&&(i["REB-APIKEY"]=t.apiKey),i}function l(){return Me(e.defaults.headers)}function a(c){t.requestTimeout=Number(c),e.defaults.timeout=t.requestTimeout}function p(c=t.jwt){const i=l();t.apiKey=null,t.jwt=c,delete i.common["REB-APIKEY"],i.common.Authorization=`Bearer ${c}`,e.defaults.headers=i}function k(c=t.publishableKey){const i=l();t.publishableKey=c,i.common.Authorization=`${c}`,e.defaults.headers=i}function j({host:c,port:i,auth:g}){e.defaults.proxy={host:c,port:i,auth:g}}function D({live:c=null,sandbox:i=null}){c&&(t.apiEndpoints.live=c),i&&(t.apiEndpoints.sandbox=i),e.defaults.baseURL=u()}function V(c,{thenDelegate:i,catchDelegate:g=()=>{}}){return z(c)&&e.interceptors[b[c]].use(i,g)}function J(c,i){return z(c)&&e.interceptors[b[c]].eject(i)}function rn({thenDelegate:c,catchDelegate:i=()=>{}}){return V(b.request,{thenDelegate:c,catchDelegate:i})}function un(c){J(b.request,c)}function on({thenDelegate:c,catchDelegate:i=()=>{}}){return V(b.response,{thenDelegate:c,catchDelegate:i})}function ln(c){J(b.response,c)}function v({request:c,isCollection:i,config:g}){const f=G(g),{id:R,cancelToken:yn}=q.save();f.cancelToken=yn;const X=async function(){try{const T=await c(f);return cn({response:T,isCollection:i,config:f})}catch(T){return W({error:T})}finally{q.deleteById(R)}}();return X.cancel=T=>d.cancelById(R,T),X}function cn({response:c,isCollection:i,config:g}){return i?new Z(c,g):new O(c,g)}function W({error:c}){if($.isCancel(c))throw new h.RebillyCanceledError(c);if(c.response)switch(Number(c.response.status)){case 401:throw new h.RebillyForbiddenError(c);case 404:throw new h.RebillyNotFoundError(c);case 405:throw new h.RebillyMethodNotAllowedError(c);case 409:throw new h.RebillyConflictError(c);case 422:throw new h.RebillyValidationError(c);default:throw new h.RebillyRequestError(c)}throw c.code==="ECONNABORTED"?new h.RebillyTimeoutError(c):new h.RebillyRequestError(c)}function gn(c){return c.params!==void 0&&(c.params=Object.keys(c.params).filter(i=>c.params[i]!==null&&c.params[i]!=="").reduce((i,g)=>(i[g]=c.params[g],i),{})),c}function G(c={}){return{...gn(c)}}function Y(c,i={}){return v({request:g=>e.get(c,g),config:{params:i}})}function an(c,i){return v({request:g=>e.get(c,g),config:{params:i},isCollection:!0})}function Q(c,i,g={}){let f={};return g.authenticate===!1&&(f={headers:l()},delete f.headers.common["REB-APIKEY"],delete f.headers.common.Authorization),g.params&&(f.params={...g.params}),v({request:R=>e.post(c,i,R),config:f})}function _(c,i,g={}){return v({request:f=>e.put(c,i,f),config:{params:g}})}function mn(c,i){return v({request:g=>e.patch(c,i,g),config:{}})}function fn(c){return v({request:i=>e.delete(c,i),config:{}})}function $n(c,i){return v({request:g=>e.delete(c,g),config:{data:{...i}}})}async function pn(c,i,g,f={}){if(i==="")return Q(c,g,{params:f});try{if((await Y(c)).response.status===200)throw new h.RebillyConflictError({message:"A resource already exists with this ID. Please use a different ID."})}catch(R){if(R.name==="RebillyNotFoundError")return _(c,g,f);throw R}}async function hn(c,i){const g=G(i);try{const f=await e.get(c,g);return new H(f,g)}catch(f){return W({error:f})}}return{getInstance:n,addRequestInterceptor:rn,removeRequestInterceptor:un,addResponseInterceptor:on,removeResponseInterceptor:ln,setTimeout:a,setProxyAgent:j,setSessionToken:p,setPublishableKey:k,setEndpoints:D,get:Y,getAll:an,post:Q,put:_,patch:mn,delete:fn,deleteAll:$n,create:pn,download:hn}}function Le({apiHandler:t}){return{forgotPassword({data:e}){return t.post("forgot-password",e,{authenticate:!1})}}}function ze({apiHandler:t}){return{getAllowlistCollection({filter:e=null,sort:s=null,limit:n=null,offset:r=null}={}){const u={filter:e,sort:s,limit:n,offset:r};return t.getAll("allowlists",u)},storeAllowlist({data:e}){return t.post("allowlists",e)},getAllowlist({id:e}){return t.get(`allowlists/${e}`)},delete({id:e}){return t.delete(`allowlists/${e}`)}}}function Ue({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("aml-checks",o)},get({id:e}){return t.get(`aml-checks/${e}`)},startReview({id:e}){return t.post(`aml-checks/${e}/start-review`)},stopReview({id:e}){return t.post(`aml-checks/${e}/stop-review`)},review({id:e,data:s}){return t.post(`aml-checks/${e}/review`,s)}}}function Ve({apiHandler:t}){return{getAmlSettings(){return t.get("aml-settings")},putAmlSettings({data:e}){return t.put("aml-settings",e)}}}function Je({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null}={}){const u={filter:e,sort:s,limit:n,offset:r};return t.getAll("api-keys",u)},create({id:e="",data:s}){return t.create(`api-keys/${e}`,e,s)},get({id:e}){return t.get(`api-keys/${e}`)},update({id:e,data:s}){return t.put(`api-keys/${e}`,s)},delete({id:e}){return t.delete(`api-keys/${e}`)}}}function We({apiHandler:t}){return{get({applicationId:e}){return t.get(`application-instances/${e}`)},upsert({applicationId:e,data:s}){return t.put(`application-instances/${e}`,s)},delete({applicationId:e}){return t.delete(`application-instances/${e}`)},getConfiguration({applicationId:e}){return t.get(`application-instances/${e}/configuration`)},upsertConfiguration({applicationId:e,data:s}){return t.put(`application-instances/${e}/configuration`,s)}}}function Ge({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,expand:u=null,fields:o=null,sort:l=null}={}){const a={limit:e,offset:s,filter:n,q:r,expand:u,fields:o,sort:l};return t.getAll("applications",a)},create({data:e}){return t.post("applications",e)},get({id:e}){return t.get(`applications/${e}`)},getInstances({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`applications/${e}/instances`,r)},getInstance({id:e,organizationId:s}){return t.get(`applications/${e}/instances/${s}`)}}}function Ye({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("balance-transactions",u)},get({id:e}){return t.get(`balance-transactions/${e}`)}}}function Qe({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("billing-portals",o)},create({id:e="",data:s}){return t.create(`billing-portals/${e}`,e,s)},get({id:e}){return t.get(`billing-portals/${e}`)},update({id:e,data:s}){return t.put(`billing-portals/${e}`,s)},delete({id:e}){return t.delete(`billing-portals/${e}`)}}}function _e({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("blocklists",o)},create({id:e="",data:s}){return t.create(`blocklists/${e}`,e,s)},get({id:e}){return t.get(`blocklists/${e}`)},delete({id:e}){return t.delete(`blocklists/${e}`)}}}function Xe({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null}={}){const u={limit:e,offset:s,sort:n,filter:r};return t.getAll("broadcast-messages",u)},create({data:e}){return t.post("broadcast-messages",e)},get({id:e}){return t.get(`broadcast-messages/${e}`)},delete({id:e}){return t.delete(`broadcast-messages/${e}`)},update({id:e,data:s}){return t.patch(`broadcast-messages/${e}`,s)}}}function Ze({apiHandler:t}){return{create({data:e}){return t.post("cashiers",e)},get({id:e}){return t.get(`cashiers/${e}`)}}}function He({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("checkout-forms",o)},create({id:e="",data:s}){return t.create(`checkout-forms/${e}`,e,s)},get({id:e}){return t.get(`checkout-forms/${e}`)},update({id:e,data:s}){return t.put(`checkout-forms/${e}`,s)},delete({id:e}){return t.delete(`checkout-forms/${e}`)}}}function et({apiHandler:t}){return{getAllRedemptions({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("coupons-redemptions",o)},redeem({data:e}){return t.post("coupons-redemptions",e)},getRedemption({id:e}){return t.get(`coupons-redemptions/${e}`)},cancelRedemption({id:e}){return t.post(`coupons-redemptions/${e}/cancel`)},getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("coupons",o)},create({id:e="",data:s}){return t.create(`coupons/${e}`,e,s)},get({id:e}){return t.get(`coupons/${e}`)},update({id:e,data:s}){return t.put(`coupons/${e}`,s)},setExpiration({id:e,data:s}){return t.post(`coupons/${e}/expiration`,s)}}}function tt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("credit-memos",l)},create({id:e="",data:s}){return t.create(`credit-memos/${e}`,e,s)},get({id:e}){return t.get(`credit-memos/${e}`)},update({id:e,data:s}){return t.put(`credit-memos/${e}`,s)},patch({id:e,data:s}){return t.patch(`credit-memos/${e}`,s)},void({id:e}){return t.post(`credit-memos/${e}/void`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`credit-memos/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`credit-memos/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`credit-memos/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`credit-memos/${e}/timeline/${s}`)}}}function st({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("custom-domains",o)},create({data:e}){return t.post("custom-domains",e)},get({domain:e}){return t.get(`custom-domains/${e}`)},delete({domain:e}){return t.delete(`custom-domains/${e}`)}}}function nt({apiHandler:t}){return{getAll({resource:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`custom-fields/${e}`,r)},get({resource:e,name:s}){return t.get(`custom-fields/${e}/${s}`)},create({resource:e,name:s,data:n}){return t.put(`custom-fields/${e}/${s}`,n)},update({resource:e,name:s,data:n}){return t.put(`custom-fields/${e}/${s}`,n)}}}function rt({apiHandler:t}){return{getAuthOptions(){return t.get("authentication-options")},updateAuthOptions({data:e}){return t.put("authentication-options",e)},getAllAuthTokens({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("authentication-tokens",n)},login({data:e}){return t.post("authentication-tokens",e)},verify({token:e}){return t.get(`authentication-tokens/${e}`)},logout({token:e}){return t.delete(`authentication-tokens/${e}`)},exchangeToken({token:e,data:s}){return t.post(`authentication-tokens/${e}/exchange`,s)},getAllCredentials({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("credentials",n)},createCredential({id:e="",data:s}){return t.create(`credentials/${e}`,e,s)},getCredential({id:e}){return t.get(`credentials/${e}`)},updateCredential({id:e,data:s}){return t.put(`credentials/${e}`,s)},deleteCredential({id:e}){return t.delete(`credentials/${e}`)},getAllResetPasswordTokens({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("password-tokens",n)},createResetPasswordToken({data:e}){return t.post("password-tokens",e)},getResetPasswordToken({id:e}){return t.get(`password-tokens/${e}`)},deleteResetPasswordToken({id:e}){return t.delete(`password-tokens/${e}`)}}}function ut({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,expand:u=null,fields:o=null,sort:l=null}={}){const a={limit:e,offset:s,filter:n,q:r,expand:u,fields:o,sort:l};return t.getAll("customers",a)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`customers/${e}`,e,s,r)},get({id:e,expand:s=null,fields:n=null}){const r={expand:s,fields:n};return t.get(`customers/${e}`,r)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`customers/${e}`,s,r)},merge({id:e,targetCustomerId:s}){return t.delete(`customers/${e}?targetCustomerId=${s}`)},getLeadSource({id:e}){return t.get(`customers/${e}/lead-source`)},createLeadSource({id:e,data:s}){return t.put(`customers/${e}/lead-source`,s)},updateLeadSource({id:e,data:s}){return t.put(`customers/${e}/lead-source`,s)},deleteLeadSource({id:e}){return t.delete(`customers/${e}/lead-source`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`customers/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`customers/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`customers/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`customers/${e}/timeline/${s}`)},getCustomerEddScore({id:e}){return t.get(`customers/${e}/edd-score`)},getEddTimelineCollection({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`customers/${e}/edd-timeline`,l)},getEddTimelineMessage({id:e,messageId:s}){return t.get(`customers/${e}/edd-timeline/${s}`)},getAllEddSearchResults({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`customers/${e}/edd-search-results`,r)},getEddSearchResult({id:e,searchResultId:s}){return t.get(`customers/${e}/edd-search-results/${s}`)}}}function ot({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("deposit-custom-property-sets",u)},create({id:e="",data:s}){return t.create(`deposit-custom-property-sets/${e}`,e,s)},get({id:e}){return t.get(`deposit-custom-property-sets/${e}`)},update({id:e,data:s}){return t.put(`deposit-custom-property-sets/${e}`,s)},delete({id:e}){return t.delete(`deposit-custom-property-sets/${e}`)}}}function lt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("deposit-requests",o)},create({data:e}){return t.post("deposit-requests",e)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`deposit-requests/${e}`,n)}}}function ct({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("deposit-strategies",u)},create({id:e="",data:s}){return t.create(`deposit-strategies/${e}`,e,s)},get({id:e}){return t.get(`deposit-strategies/${e}`)},update({id:e,data:s}){return t.put(`deposit-strategies/${e}`,s)},delete({id:e}){return t.delete(`deposit-strategies/${e}`)}}}function it({apiHandler:t}){return{validate({data:e}){return t.post("digital-wallets/validation",e)},create({data:e}){return t.post("digital-wallets/onboarding/apple-pay",e)}}}function gt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("disputes",l)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`disputes/${e}`,e,s,r)},get({id:e}){return t.get(`disputes/${e}`)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`disputes/${e}`,s,r)}}}function at({apiHandler:t}){return{verify({token:e}){return t.put(`email-delivery-setting-verifications/${e}`)},getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,q:u};return t.getAll("email-delivery-settings",o)},create({data:e}){return t.post("email-delivery-settings",e)},get({id:e}){return t.get(`email-delivery-settings/${e}`)},delete({id:e}){return t.delete(`email-delivery-settings/${e}`)},update({id:e,data:s}){return t.patch(`email-delivery-settings/${e}`,s)},resendVerification({id:e}){return t.post(`email-delivery-settings/${e}/resend-email-verification`)}}}function mt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,q:n=null,sort:r=null,filter:u=null}={}){const o={limit:e,offset:s,q:n,sort:r,filter:u};return t.getAll("email-messages",o)},create({data:e}){return t.post("email-messages",e)},get({id:e}){return t.get(`email-messages/${e}`)},delete({id:e}){return t.delete(`email-messages/${e}`)},send({id:e,data:s={status:"outbox"}}){return t.patch(`email-messages/${e}`,s)}}}function ft({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("email-notifications",n)}}}function $t({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null}={}){const u={limit:e,offset:s,filter:n,q:r};return t.getAll("events",u)},get({eventType:e}){return t.get(`events/${e}`)},getRules({eventType:e}){return t.get(`events/${e}/rules`)},createRules({eventType:e,data:s}){return t.put(`events/${e}/rules`,s)},updateRules({eventType:e,data:s}){return t.put(`events/${e}/rules`,s)},getAllTimelineMessages({eventType:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`events/${e}/timeline`,l)},createTimelineComment({eventType:e,data:s}){return t.post(`events/${e}/timeline`,s)},getTimelineMessage({eventType:e,messageId:s}){return t.get(`events/${e}/timeline/${s}`)},deleteTimelineMessage({eventType:e,messageId:s}){return t.delete(`events/${e}/timeline/${s}`)},getRulesHistory({eventType:e,limit:s=null,offset:n=null,filter:r=null,q:u=null,sort:o=null,fields:l=null}){const a={limit:s,offset:n,filter:r,q:u,sort:o,fields:l};return t.getAll(`events/${e}/rules/history`,a)},getRulesVersionNumber({eventType:e,version:s,fields:n=null}){const r={fields:n};return t.get(`events/${e}/rules/history/${s}`,r)},getRulesVersionDetail({eventType:e,version:s,fields:n=null}){const r={fields:n};return t.get(`events/${e}/rules/versions/${s}`,r)},getAllDraftRulesets({eventType:e,limit:s=null,offset:n=null,filter:r=null,q:u=null,sort:o=null,fields:l=null}){const a={limit:s,offset:n,filter:r,q:u,sort:o,fields:l};return t.getAll(`events/${e}/rules/drafts`,a)},createDraftRuleset({eventType:e,data:s}){return t.post(`events/${e}/rules/drafts`,s)},getDraftRuleset({eventType:e,id:s,fields:n=null}){const r={fields:n};return t.get(`events/${e}/rules/drafts/${s}`,r)},updateDraftRuleset({eventType:e,id:s,data:n}){return t.put(`events/${e}/rules/drafts/${s}`,n)},deleteDraftRuleset({eventType:e,id:s}){return t.delete(`events/${e}/rules/drafts/${s}`)}}}function pt({apiHandler:t}){return{get({resource:e,resourceId:s,service:n}){return t.get(`${e}/${s}/external-identifiers/${n}`)},sync({resource:e,resourceId:s,service:n}){return t.post(`${e}/${s}/external-identifiers/${n}`)},update({resource:e,resourceId:s,service:n,data:r}){return t.put(`${e}/${s}/external-identifiers/${n}`,r)},delete({resource:e,resourceId:s,service:n}){return t.delete(`${e}/${s}/external-identifiers/${n}`)}}}function ht({apiHandler:t}){return{getExternalServiceSettings(){return t.get("external-services-settings")},updateExternalServiceSettings({data:e}){return t.put("external-services-settings",e)}}}function yt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("fees",u)},create({id:e="",data:s}){return t.create(`fees/${e}`,e,s)},get({id:e}){return t.get(`fees/${e}`)},upsert({id:e,data:s}){return t.put(`fees/${e}`,s)},delete({id:e}){return t.delete(`fees/${e}`)},patch({id:e,data:s}){return t.patch(`fees/${e}`,s)}}}function At({apiHandler:t}){return{getAllAttachments({limit:e=null,offset:s=null,filter:n=null,q:r=null,expand:u=null,fields:o=null,sort:l=null}={}){const a={limit:e,offset:s,filter:n,q:r,expand:u,fields:o,sort:l};return t.getAll("attachments",a)},attach({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`attachments/${e}`,e,s,r)},getAttachment({id:e}){return t.get(`attachments/${e}`)},updateAttachment({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`attachments/${e}`,s,r)},detach({id:e}){return t.delete(`attachments/${e}`)},getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,fields:u=null,sort:o=null}={}){const l={limit:e,offset:s,filter:n,q:r,fields:u,sort:o};return t.getAll("files",l)},upload({fileObject:e}){return t.post("files",e)},get({id:e}){return t.get(`files/${e}`)},update({id:e,data:s}){return t.put(`files/${e}`,s)},delete({id:e}){return t.delete(`files/${e}`)},download({id:e}){const s={responseType:"arraybuffer"};return t.download(`files/${e}/download`,s)},detachAndDelete({id:e}){const s={filter:`fileId:${e}`};let n=[];const u=(async()=>{const o=this.getAllAttachments(s);n.push(o);const a=(await o).items.map(k=>this.detach({id:k.fields.id}));n=[...n,a],await Promise.all(a);const p=t.delete(`files/${e}`);return n.push(p),p})();return u.cancel=()=>{n.forEach(o=>o.cancel())},u},uploadAndUpdate({fileObject:e,data:s={description:"",tags:[""]}}){const n=[],u=(async()=>{const o=this.upload({fileObject:e});n.push(o),await o;const l={name:o.name,extension:o.extension,description:s.description,tags:s.tags,url:""},a=this.update({id:o.fields.id,data:l});return n.push(a),a})();return u.cancel=()=>{n.forEach(o=>o.cancel())},u}}}function Rt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null,fields:o=null}={}){const l={limit:e,offset:s,sort:n,filter:r,q:u,fields:o};return t.getAll("gateway-accounts",l)},create({id:e="",data:s}){return t.create(`gateway-accounts/${e}`,e,s)},get({id:e}){return t.get(`gateway-accounts/${e}`)},upsert({id:e,data:s}){return t.put(`gateway-accounts/${e}`,s)},delete({id:e}){return t.delete(`gateway-accounts/${e}`)},update({id:e,data:s}){return t.patch(`gateway-accounts/${e}`,s)},close({id:e}){return t.post(`gateway-accounts/${e}/close`)},disable({id:e}){return t.post(`gateway-accounts/${e}/disable`)},getAllDowntimeSchedules({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null}){const o={limit:s,offset:n,filter:r,sort:u};return t.getAll(`gateway-accounts/${e}/downtime-schedules`,o)},createDowntimeSchedule({id:e,data:s}){return t.post(`gateway-accounts/${e}/downtime-schedules`,s)},getDowntimeSchedule({id:e,downtimeId:s}){return t.get(`gateway-accounts/${e}/downtime-schedules/${s}`)},updateDowntimeSchedule({id:e,downtimeId:s,data:n}){return t.put(`gateway-accounts/${e}/downtime-schedules/${s}`,n)},deleteDowntimeSchedule({id:e,downtimeId:s}){return t.delete(`gateway-accounts/${e}/downtime-schedules/${s}`)},enable({id:e}){return t.post(`gateway-accounts/${e}/enable`)},getAllVolumeLimits({id:e}){return t.getAll(`gateway-accounts/${e}/limits`)},getVolumeLimit({id:e,limitId:s}){return t.get(`gateway-accounts/${e}/limits/${s}`)},updateVolumeLimit({id:e,limitId:s,data:n}){return t.put(`gateway-accounts/${e}/limits/${s}`,n)},deleteVolumeLimit({id:e,limitId:s}){return t.delete(`gateway-accounts/${e}/limits/${s}`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`gateway-accounts/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`gateway-accounts/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`gateway-accounts/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`gateway-accounts/${e}/timeline/${s}`)},checkCredentials({id:e}){return t.post(`gateway-accounts/${e}/check-credentials`)},getFinancialSettings({id:e}){return t.get(`gateway-accounts/${e}/financial-settings`)},setFinancialSettings({id:e,data:s}){return t.put(`gateway-accounts/${e}/financial-settings`,s)}}}function bt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("integrations",n)},get({label:e}){return t.get(`integrations/${e}`)}}}const I={Accept:"application/pdf"};function wt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("invoices",l)},create({id:e="",data:s}){return t.create(`invoices/${e}`,e,s)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`invoices/${e}`,n)},update({id:e,data:s}){return t.put(`invoices/${e}`,s)},getAllInvoiceItems({id:e,limit:s=null,offset:n=null,expand:r=null}){const u={limit:s,offset:n,expand:r};return t.getAll(`invoices/${e}/items`,u)},createInvoiceItem({id:e,data:s}){return t.post(`invoices/${e}/items`,s)},getInvoiceItem({id:e,itemId:s}){return t.get(`invoices/${e}/items/${s}`)},updateInvoiceItem({id:e,itemId:s,data:n}){return t.put(`invoices/${e}/items/${s}`,n)},deleteInvoiceItem({id:e,itemId:s}){return t.delete(`invoices/${e}/items/${s}`)},issue({id:e,data:s}){return t.post(`invoices/${e}/issue`,s)},abandon({id:e}){return t.post(`invoices/${e}/abandon`)},void({id:e}){return t.post(`invoices/${e}/void`)},recalculate({id:e}){return t.post(`invoices/${e}/recalculate`)},reissue({id:e,data:s}){return t.post(`invoices/${e}/reissue`,s)},getAllTransactionAllocations({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`invoices/${e}/transaction-allocations`,r)},applyTransaction({id:e,data:s}){return t.post(`invoices/${e}/transaction`,s)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`invoices/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`invoices/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`invoices/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`invoices/${e}/timeline/${s}`)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`invoices/${e}`,s)}}}function kt({apiHandler:t}){return{getAllAccounts({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("journal-accounts",u)},createAccount({id:e="",data:s}){return t.create(`journal-accounts/${e}`,e,s)},getAccount({id:e}){return t.get(`journal-accounts/${e}`)},updateAccount({id:e,data:s}){return t.put(`journal-accounts/${e}`,s)}}}function vt({apiHandler:t}){return{getAllEntries({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("journal-entries",u)},createEntry({id:e="",data:s}){return t.create(`journal-entries/${e}`,e,s)},getEntry({id:e}){return t.get(`journal-entries/${e}`)},updateEntry({id:e,data:s}){return t.put(`journal-entries/${e}`,s)}}}function qt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("journal-records",o)},create({id:e="",data:s}){return t.create(`journal-records/${e}`,e,s)},get({id:e}){return t.get(`journal-records/${e}`)},update({id:e,data:s}){return t.put(`journal-records/${e}`,s)},delete({id:e}){return t.delete(`journal-records/${e}`)}}}function Tt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("kyc-documents",o)},create({id:e="",data:s}){return t.create(`kyc-documents/${e}`,e,s)},get({id:e}){return t.get(`kyc-documents/${e}`)},update({id:e,data:s}){return t.put(`kyc-documents/${e}`,s)},accept({id:e}){return t.post(`kyc-documents/${e}/acceptance`)},matches({id:e,data:s}){return t.post(`kyc-documents/${e}/matches`,s)},reject({id:e,data:s}){return t.post(`kyc-documents/${e}/rejection`,s)},review({id:e}){return t.post(`kyc-documents/${e}/review`)},startReview({id:e}){return t.post(`kyc-documents/${e}/start-review`)},stopReview({id:e}){return t.post(`kyc-documents/${e}/stop-review`)}}}function dt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("kyc-requests",o)},create({data:e}){return t.post("kyc-requests",e)},get({id:e}){return t.get(`kyc-requests/${e}`)},delete({id:e}){return t.delete(`kyc-requests/${e}`)},update({id:e,data:s}){return t.patch(`kyc-requests/${e}`,s)}}}function It({apiHandler:t}){return{getKycSettings(){return t.get("kyc-settings")},updateKycSettings({data:e}){return t.put("kyc-settings",e)}}}function St({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,fields:u=null,q:o=null}={}){const l={limit:e,offset:s,filter:n,sort:r,fields:u,q:o};return t.getAll("lists",l)},create({id:e="",data:s}){return t.create(`lists/${e}`,e,s)},getLatestVersion({id:e}){return t.get(`lists/${e}`)},update({id:e,data:s}){return t.put(`lists/${e}`,s)},delete({id:e}){return t.delete(`lists/${e}`)},getByVersion({id:e,version:s}){return t.get(`lists/${e}/${s}`)}}}function Et({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("memberships",u)},get({organizationId:e,userId:s}){return t.get(`memberships/${e}/${s}`)},update({organizationId:e,userId:s,data:n}){return t.put(`memberships/${e}/${s}`,n)},delete({organizationId:e,userId:s}){return t.delete(`memberships/${e}/${s}`)}}}function xt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("order-cancellations",u)},create({id:e="",data:s}){return t.create(`order-cancellations/${e}`,e,s)},get({id:e}){return t.get(`order-cancellations/${e}`)},update({id:e,data:s}){return t.put(`order-cancellations/${e}`,s)},delete({id:e}){return t.delete(`order-cancellations/${e}`)},patch({id:e,data:s}){return t.patch(`order-cancellations/${e}`,s)}}}function Pt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("order-pauses",u)},pause({id:e="",data:s}){return t.create(`order-pauses/${e}`,e,s)},get({id:e}){return t.get(`order-pauses/${e}`)},update({id:e,data:s}){return t.put(`order-pauses/${e}`,s)},delete({id:e}){return t.delete(`order-pauses/${e}`)}}}function Ct({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("order-reactivations",u)},reactivate({data:e}){return t.post("order-reactivations",e)},get({id:e}){return t.get(`order-reactivations/${e}`)}}}function jt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("orders",o)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`orders/${e}`,e,s,r)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}`,n)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`orders/${e}`,s,r)},getUpcomingInvoice({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}/upcoming-invoice`,n)},void({id:e}){return t.post(`orders/${e}/void`)},changeItems({id:e,data:s,expand:n=null}){const r={expand:n};return t.post(`orders/${e}/change-items`,s,r)},updateItem({id:e,itemId:s,data:n}){return t.patch(`orders/${e}/items/${s}`,n)},createInterimInvoice({id:e,data:s}){return t.post(`orders/${e}/interim-invoice`,s)},issueEarlyUpcomingInvoice({id:e,data:s}){return t.post(`orders/${e}/upcoming-invoice/issue`,s)}}}function Dt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("organization-exports",o)},create({data:e}){return t.post("organization-exports",e)},get({id:e}){return t.get(`organization-exports/${e}`)}}}function Mt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,q:u};return t.getAll("organizations",o)},create({data:e}){return t.post("organizations",e)},get({id:e}){return t.get(`organizations/${e}`)},update({id:e,data:s}){return t.patch(`organizations/${e}`,s)}}}function Ot({apiHandler:t}){return{getAll({limit:e=null,q:s=null}={}){const n={limit:e,q:s};return t.getAll("payment-cards-bank-names",n)}}}function Ft({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("payment-instruments",l)},create({data:e}){return t.post("payment-instruments",e)},get({id:e}){return t.get(`payment-instruments/${e}`)},update({id:e,data:s}){return t.patch(`payment-instruments/${e}`,s)},deactivate({id:e}){return t.post(`payment-instruments/${e}/deactivation`)},nameInquiry({id:e,data:s}){return t.post(`payment-instruments/${e}/name-inquiry`,s)}}}function Bt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("payment-methods",n)},get({apiName:e}){return t.get(`payment-methods/${e}`)}}}function Kt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("tokens",n)},create({data:e}){return t.post("tokens",e)},get({token:e}){return t.get(`tokens/${e}`)}}}function Nt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("payout-request-allocations",u)},create({data:e}){return t.post("payout-request-allocations",e)},autoAllocate({data:e}){return t.post("payout-request-allocations/auto",e)},get({id:e}){return t.get(`payout-request-allocations/${e}`)},update({id:e,data:s}){return t.patch(`payout-request-allocations/${e}`,s)},process({data:e}){return t.post("payout-request-allocations/process",e)}}}function Lt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("payout-request-batches",u)},create({data:e}){return t.post("payout-request-batches",e)},get({id:e}){return t.get(`payout-request-batches/${e}`)},autoAllocate({id:e}){return t.post(`payout-request-batches/${e}/auto-allocate`)},approve({id:e}){return t.post(`payout-request-batches/${e}/approve`)},block({id:e,data:s}){return t.post(`payout-request-batches/${e}/block`,s)},preview({filter:e=null}){const s={filter:e};return t.get("payout-request-batches/preview",s)}}}function zt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("payout-requests",u)},create({id:e="",data:s}){return t.create(`payout-requests/${e}`,e,s)},get({id:e}){return t.get(`payout-requests/${e}`)},update({id:e,data:s}){return t.put(`payout-requests/${e}`,s)},patch({id:e,data:s}){return t.patch(`payout-requests/${e}`,s)},cancel({id:e,data:s}){return t.post(`payout-requests/${e}/cancel`,s)},split({id:e,data:s}){return t.post(`payout-requests/${e}/split`,s)},getPaymentInstruments({id:e}){return t.get(`payout-requests/${e}/payment-instruments`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`payout-requests/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`payout-requests/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`payout-requests/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`payout-requests/${e}/timeline/${s}`)}}}function Ut({apiHandler:t}){return{getV2({id:e}){return t.get(`payout-requests-v2/${e}`)},getPaymentInstrumentsV2({id:e}){return t.get(`payout-requests-v2/${e}/payment-instruments`)}}}function Vt({apiHandler:t}){return{create({data:e}){return t.post("payouts",e)}}}function Jt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("plans",o)},create({id:e="",data:s}){return t.create(`plans/${e}`,e,s)},get({id:e}){return t.get(`plans/${e}`)},update({id:e,data:s}){return t.put(`plans/${e}`,s)},delete({id:e}){return t.delete(`plans/${e}`)}}}function Wt({apiHandler:t}){return{order({data:e}){return t.post("previews/orders",e)},sendEmailRuleAction({data:e}){return t.post("previews/rule-actions/send-email",e)},webhook({data:e}){return t.post("previews/webhooks",e)}}}function Gt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("products",o)},create({id:e="",data:s}){return t.create(`products/${e}`,e,s)},get({id:e}){return t.get(`products/${e}`)},update({id:e,data:s}){return t.put(`products/${e}`,s)},delete({id:e}){return t.delete(`products/${e}`)}}}function Yt({apiHandler:t}){return{startPermissionsEmulation({data:e}){return t.post("permissions-emulation",e)},stopPermissionsEmulation(){return t.delete("permissions-emulation")},get(){return t.get("profile")},update({data:e}){return t.put("profile",e)},getMfa(){return t.get("profile/mfa")},updateMfa(){return t.post("profile/mfa")},deleteMfa(){return t.delete("profile/mfa")}}}function Qt({apiHandler:t}){return{readyToPay({data:e}){return t.post("ready-to-pay",e)}}}function _t({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,expand:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,expand:u};return t.getAll("quotes",o)},create({id:e="",data:s}){return t.create(`quotes/${e}`,e,s)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`quotes/${e}`,n)},update({id:e,data:s}){return t.put(`quotes/${e}`,s)},patch({id:e,data:s}){return t.patch(`quotes/${e}`,s)},accept({id:e}){return t.post(`quotes/${e}/accept`)},cancel({id:e}){return t.post(`quotes/${e}/cancel`)},issue({id:e}){return t.post(`quotes/${e}/issue`)},recall({id:e}){return t.post(`quotes/${e}/recall`)},reject({id:e}){return t.post(`quotes/${e}/reject`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`quotes/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`quotes/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`quotes/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`quotes/${e}/timeline/${s}`)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`quotes/${e}`,s)}}}function Xt({apiHandler:t}){return{get({resource:e,resourceId:s,service:n}){return t.get(`${e}/${s}/external-identifiers/${n}`)},sync({resource:e,resourceId:s,service:n}){return t.post(`${e}/${s}/external-identifiers/${n}`)},update({resource:e,resourceId:s,service:n,data:r}){return t.put(`${e}/${s}/external-identifiers/${n}`,r)},delete({resource:e,resourceId:s,service:n}){return t.delete(`${e}/${s}/external-identifiers/${n}`)}}}function Zt({apiHandler:t}){return{getAll(){return t.get("risk-score-rules")},updateRiskScoreRules({data:e}){return t.put("risk-score-rules",e)},getAllBlocklistRules(){return t.get("risk-score-rules/blocklists")},updateRiskScoreBlocklistRules({data:e}){return t.put("risk-score-rules/blocklists",e)}}}function Ht({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null,expand:o=null}={}){const l={limit:e,offset:s,filter:n,sort:r,q:u,expand:o};return t.getAll("roles",l)},create({id:e="",data:s}){return t.create(`roles/${e}`,e,s)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`roles/${e}`,n)},update({id:e,data:s}){return t.put(`roles/${e}`,s)},delete({id:e}){return t.delete(`roles/${e}`)}}}function es({apiHandler:t}){return{get({sort:e=null,limit:s=null,offset:n=null,q:r=null}){const u={sort:e,limit:s,offset:n,q:r};return t.get("search",u)}}}function ts({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("grid-segments",o)},create({id:e="",data:s}){return t.create(`grid-segments/${e}`,e,s)},get({id:e}){return t.get(`grid-segments/${e}`)},update({id:e,data:s}){return t.put(`grid-segments/${e}`,s)},delete({id:e}){return t.delete(`grid-segments/${e}`)}}}function ss({apiHandler:t}){return{getAll({eventType:e}){return t.getAll(`send-through-attribution/${e}`)}}}function ns({apiHandler:t}){return{getAll({type:e,filter:s=null,limit:n=null,offset:r=null,sort:u=null,q:o=null}){const l={filter:s,limit:n,offset:r,sort:u,q:o};return t.getAll(`service-credentials/${e}`,l)},create({type:e,data:s}){return t.post(`service-credentials/${e}`,s)},get({type:e,id:s}){return t.get(`service-credentials/${e}/${s}`)},update({type:e,id:s,data:n}){return t.patch(`service-credentials/${e}/${s}`,n)},getItems({type:e,id:s,limit:n=null,offset:r=null,filter:u=null,q:o=null,fields:l=null,sort:a=null}){const p={limit:n,offset:r,filter:u,q:o,fields:l,sort:a};return t.getAll(`service-credentials/${e}/${s}/items`,p)}}}function rs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,q:u};return t.getAll("shipping-rates",o)},create({id:e="",data:s}){return t.create(`shipping-rates/${e}`,e,s)},get({id:e}){return t.get(`shipping-rates/${e}`)},update({id:e,data:s}){return t.put(`shipping-rates/${e}`,s)},delete({id:e}){return t.delete(`shipping-rates/${e}`)}}}function us({apiHandler:t}){return{get(){return t.get("status")}}}function os({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("subscription-cancellations",u)},create({id:e="",data:s}){return t.create(`subscription-cancellations/${e}`,e,s)},get({id:e}){return t.get(`subscription-cancellations/${e}`)},delete({id:e}){return t.delete(`subscription-cancellations/${e}`)},patch({id:e,data:s}){return t.patch(`subscription-cancellations/${e}`,s)}}}function ls({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("subscription-pauses",u)},pause({id:e="",data:s}){return t.create(`subscription-pauses/${e}`,e,s)},get({id:e}){return t.get(`subscription-pauses/${e}`)},update({id:e,data:s}){return t.put(`subscription-pauses/${e}`,s)},delete({id:e}){return t.delete(`subscription-pauses/${e}`)}}}function cs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("subscription-reactivations",u)},reactivate({data:e}){return t.post("subscription-reactivations",e)},get({id:e}){return t.get(`subscription-reactivations/${e}`)}}}function is({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("subscriptions",l)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`subscriptions/${e}`,e,s,r)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`subscriptions/${e}`,n)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`subscriptions/${e}`,s,r)},delete({id:e}){return t.delete(`subscriptions/${e}`)},void({id:e}){return t.post(`subscriptions/${e}/void`)},changeItems({id:e,data:s,expand:n=null}){const r={expand:n};return t.post(`subscriptions/${e}/change-items`,s,r)},updateItem({id:e,itemId:s,data:n}){return t.patch(`subscriptions/${e}/items/${s}`,n)},createInterimInvoice({id:e,data:s}){return t.post(`subscriptions/${e}/interim-invoice`,s)},getAllUpcomingInvoices({id:e,expand:s=null}){const n={expand:s};return t.getAll(`subscriptions/${e}/upcoming-invoices`,n)},getUpcomingInvoice({id:e,expand:s=null}){const n={expand:s};return t.get(`subscriptions/${e}/upcoming-invoice`,n)},issueEarlyUpcomingInvoice({id:e,data:s}){return t.post(`subscriptions/${e}/upcoming-invoice/issue`,s)},issueUpcomingInvoice({id:e,invoiceId:s,data:n}){return t.post(`subscriptions/${e}/upcoming-invoices/${s}/issue`,n)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`subscriptions/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`subscriptions/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`subscriptions/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`subscriptions/${e}/timeline/${s}`)}}}function gs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("tags",o)},create({data:e}){return t.post("tags",e)},get({tag:e}){return t.get(`tags/${e}`)},delete({tag:e}){return t.delete(`tags/${e}`)},update({tag:e,data:s}){return t.patch(`tags/${e}`,s)},tagCustomers({tag:e,data:s}){return t.post(`tags/${e}/customers`,s)},untagCustomers({tag:e,data:s}){return t.delete(`tags/${e}/customers`,s)},tagCustomer({tag:e,customerId:s}){return t.post(`tags/${e}/customers/${s}`)},untagCustomer({tag:e,customerId:s}){return t.delete(`tags/${e}/customers/${s}`)},tagKycDocuments({tag:e,data:s}){return t.post(`tags/${e}/kyc-documents`,s)},untagKycDocuments({tag:e,data:s}){return t.delete(`tags/${e}/kyc-documents`,s)},tagKycDocument({tag:e,kycDocumentId:s}){return t.post(`tags/${e}/kyc-documents/${s}`)},untagKycDocument({tag:e,kycDocumentId:s}){return t.delete(`tags/${e}/kyc-documents/${s}`)},tagAmlChecks({tag:e,data:s}){return t.post(`tags/${e}/aml-checks`,s)},untagAmlChecks({tag:e,data:s}){return t.delete(`tags/${e}/aml-checks`,s)},tagAmlCheck({tag:e,amlCheckId:s}){return t.post(`tags/${e}/aml-checks/${s}`)},untagAmlCheck({tag:e,amlCheckId:s}){return t.delete(`tags/${e}/aml-checks/${s}`)}}}function as({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tags-rules",o)},create({id:e="",data:s}){return t.create(`tags-rules/${e}`,e,s)},get({id:e}){return t.get(`tags-rules/${e}`)},update({id:e,data:s}){return t.put(`tags-rules/${e}`,s)},delete({id:e}){return t.delete(`tags-rules/${e}`)}}}function ms({apiHandler:t}){return{getAllApiLogs({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null,expand:o=null}={}){const l={limit:e,offset:s,sort:n,filter:r,q:u,expand:o};return t.getAll("tracking/api",l)},getApiLog({id:e}){return t.get(`tracking/api/${e}`)},getAllTaxTrackingLogs({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tracking/taxes",o)},getTaxTrackingLog({id:e}){return t.get(`tracking/taxes/${e}`)},getAllListsChangesHistory({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tracking/lists",o)},getAllWebhookTrackingLogs({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tracking/webhooks",o)},getWebhookTrackingLog({id:e}){return t.get(`tracking/webhooks/${e}`)},resendWebhook({id:e}){return t.post(`tracking/webhooks/${e}/resend`)}}}function fs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null,expand:o=null}={}){const l={limit:e,offset:s,filter:n,q:r,sort:u,expand:o};return t.getAll("transactions",l)},create({data:e,expand:s=null}){const n={expand:s};return t.post("transactions",e,n)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`transactions/${e}`,n)},patch({id:e,data:s}){return t.patch(`transactions/${e}`,s)},query({id:e}){return t.post(`transactions/${e}/query`)},update({id:e,data:s}){return t.post(`transactions/${e}/update`,s)},refund({id:e,data:s,expand:n=null}){const r={expand:n};return t.post(`transactions/${e}/refund`,s,r)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`transactions/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`transactions/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`transactions/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`transactions/${e}/timeline/${s}`)}}}function $s({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("usages",o)},create({data:e}){return t.post("usages",e)},get({id:e}){return t.get(`usages/${e}`)},delete({id:e}){return t.delete(`usages/${e}`)}}}function ps({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("users",o)},create({id:e="",data:s}){return t.create(`users/${e}`,e,s)},get({id:e}){return t.get(`users/${e}`)},update({id:e,data:s}){return t.put(`users/${e}`,s)},getMfa({id:e}){return t.get(`users/${e}/mfa`)}}}function hs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null}={}){const r={limit:e,offset:s,filter:n};return t.getAll("webhooks",r)},create({id:e="",data:s}){return t.create(`webhooks/${e}`,e,s)},get({id:e}){return t.get(`webhooks/${e}`)},update({id:e,data:s}){return t.put(`webhooks/${e}`,s)},delete({id:e}){return t.delete(`webhooks/${e}`)}}}function ys({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,q:n=null,filter:r=null,sort:u=null}={}){const o={limit:e,offset:s,q:n,filter:r,sort:u};return t.getAll("websites",o)},create({id:e="",data:s}){return t.create(`websites/${e}`,e,s)},get({id:e}){return t.get(`websites/${e}`)},update({id:e,data:s}){return t.put(`websites/${e}`,s)},delete({id:e}){return t.delete(`websites/${e}`)}}}class As{constructor({apiHandler:e}){this.account=Le({apiHandler:e}),this.allowlists=ze({apiHandler:e}),this.amlChecks=Ue({apiHandler:e}),this.amlSettings=Ve({apiHandler:e}),this.apiKeys=Je({apiHandler:e}),this.applicationInstances=We({apiHandler:e}),this.applications=Ge({apiHandler:e}),this.balanceTransactions=Ye({apiHandler:e}),this.billingPortals=Qe({apiHandler:e}),this.blocklists=_e({apiHandler:e}),this.broadcastMessages=Xe({apiHandler:e}),this.cashiers=Ze({apiHandler:e}),this.checkoutForms=He({apiHandler:e}),this.coupons=et({apiHandler:e}),this.creditMemos=tt({apiHandler:e}),this.customDomains=st({apiHandler:e}),this.customFields=nt({apiHandler:e}),this.customerAuthentication=rt({apiHandler:e}),this.customers=ut({apiHandler:e}),this.depositCustomPropertySets=ot({apiHandler:e}),this.depositRequests=lt({apiHandler:e}),this.depositStrategies=ct({apiHandler:e}),this.digitalWallets=it({apiHandler:e}),this.disputes=gt({apiHandler:e}),this.emailDeliverySettings=at({apiHandler:e}),this.emailMessages=mt({apiHandler:e}),this.emailNotifications=ft({apiHandler:e}),this.events=$t({apiHandler:e}),this.externalIdentifiers=pt({apiHandler:e}),this.externalServicesSettings=ht({apiHandler:e}),this.fees=yt({apiHandler:e}),this.files=At({apiHandler:e}),this.gatewayAccounts=Rt({apiHandler:e}),this.integrations=bt({apiHandler:e}),this.invoices=wt({apiHandler:e}),this.journalAccounts=kt({apiHandler:e}),this.journalEntries=vt({apiHandler:e}),this.journalRecords=qt({apiHandler:e}),this.kycDocuments=Tt({apiHandler:e}),this.kycRequests=dt({apiHandler:e}),this.kycSettings=It({apiHandler:e}),this.lists=St({apiHandler:e}),this.memberships=Et({apiHandler:e}),this.orderCancellations=xt({apiHandler:e}),this.orderPauses=Pt({apiHandler:e}),this.orderReactivations=Ct({apiHandler:e}),this.orders=jt({apiHandler:e}),this.organizationExports=Dt({apiHandler:e}),this.organizations=Mt({apiHandler:e}),this.paymentCardsBankNames=Ot({apiHandler:e}),this.paymentInstruments=Ft({apiHandler:e}),this.paymentMethods=Bt({apiHandler:e}),this.paymentTokens=Kt({apiHandler:e}),this.payoutRequestAllocations=Nt({apiHandler:e}),this.payoutRequestBatches=Lt({apiHandler:e}),this.payoutRequests=zt({apiHandler:e}),this.payoutRequestsV2=Ut({apiHandler:e}),this.payouts=Vt({apiHandler:e}),this.plans=Jt({apiHandler:e}),this.previews=Wt({apiHandler:e}),this.products=Gt({apiHandler:e}),this.profile=Yt({apiHandler:e}),this.purchase=Qt({apiHandler:e}),this.quotes=_t({apiHandler:e}),this.resource=Xt({apiHandler:e}),this.riskScoreRules=Zt({apiHandler:e}),this.roles=Ht({apiHandler:e}),this.search=es({apiHandler:e}),this.segments=ts({apiHandler:e}),this.sendThroughAttribution=ss({apiHandler:e}),this.serviceCredentials=ns({apiHandler:e}),this.shippingRates=rs({apiHandler:e}),this.status=us({apiHandler:e}),this.subscriptionCancellations=os({apiHandler:e}),this.subscriptionPauses=ls({apiHandler:e}),this.subscriptionReactivations=cs({apiHandler:e}),this.subscriptions=is({apiHandler:e}),this.tags=gs({apiHandler:e}),this.tagsRules=as({apiHandler:e}),this.tracking=ms({apiHandler:e}),this.transactions=fs({apiHandler:e}),this.usages=$s({apiHandler:e}),this.users=ps({apiHandler:e}),this.webhooks=hs({apiHandler:e}),this.websites=ys({apiHandler:e}),this.addRequestInterceptor=e.addRequestInterceptor,this.removeRequestInterceptor=e.removeRequestInterceptor,this.addResponseInterceptor=e.addResponseInterceptor,this.removeResponseInterceptor=e.removeResponseInterceptor,this.setTimeout=e.setTimeout,this.setProxyAgent=e.setProxyAgent,this.setSessionToken=e.setSessionToken,this.setPublishableKey=e.setPublishableKey,this.setEndpoints=e.setEndpoints,this.getCancellationToken=e.getCancellationToken,this.generateSignature=e.generateSignature}}function Rs({apiHandler:t}){return{getCustomerLifetimeSummaryMetrics({customerId:e}){return t.get(`customers/${e}/summary-metrics`)}}}function bs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,expand:r=null,filter:u=null,q:o=null,criteria:l=null}={}){const a={limit:e,offset:s,sort:n,expand:r,filter:u,q:o,criteria:l};return t.getAll("data-exports",a)},queue({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`data-exports/${e}`,e,s,r)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`data-exports/${e}`,n)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`data-exports/${e}`,s,r)},delete({id:e}){return t.delete(`data-exports/${e}`)}}}function ws({apiHandler:t}){return{getAmlCheckHistogramReport({periodStart:e=null,periodEnd:s=null,aggregationPeriod:n=null,metric:r=null,includePropagatedResults:u=null,filter:o=null}){const l={periodStart:e,periodEnd:s,aggregationPeriod:n,metric:r,includePropagatedResults:u,filter:o};return t.get("histograms/aml-checks",l)},getTransactionHistogramReport({periodStart:e=null,periodEnd:s=null,aggregationPeriod:n=null,metric:r=null,filter:u=null}){const o={periodStart:e,periodEnd:s,aggregationPeriod:n,metric:r,filter:u};return t.get("histograms/transactions",o)}}}function ks({apiHandler:t}){return{getApiLogSummary({periodStart:e=null,periodEnd:s=null,filter:n=null,limit:r=null,offset:u=null}){const o={periodStart:e,periodEnd:s,filter:n,limit:r,offset:u};return t.get("reports/api-log-summary",o)},getAmlChecks({periodStart:e=null,periodEnd:s=null,metric:n=null,includePropagatedResults:r=null,filter:u=null}){const o={periodStart:e,periodEnd:s,metric:n,includePropagatedResults:r,filter:u};return t.get("reports/aml-checks",o)},getCumulativeSubscriptions({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/cumulative-subscriptions",l)},getDashboardMetrics({periodStart:e=null,periodEnd:s=null,metrics:n=null,segments:r=null}){const u={periodStart:e,periodEnd:s,metrics:n,segments:r};return t.get("reports/dashboard",u)},getDccMarkup({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/dcc-markup",l)},getDeclinedTransactions({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/declined-transactions",l)},getDeferredRevenue({currency:e=null,asOfDate:s=null,limit:n=null,offset:r=null,filter:u=null}){const o={currency:e,asOfDate:s,limit:n,offset:r,filter:u};return t.get("reports/deferred-revenue",o)},getDisputes({aggregationField:e=null,periodMonth:s=null,limit:n=null,offset:r=null,filter:u=null}){const o={aggregationField:e,periodMonth:s,limit:n,offset:r,filter:u};return t.get("reports/disputes",o)},getEventsTriggeredSummary({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/events-triggered",u)},getTriggeredEventRuleReport({eventType:e,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null}){const o={periodStart:s,periodEnd:n,limit:r,offset:u};return t.get(`reports/events-triggered/${e}/rules`,o)},getFutureRenewals({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/future-renewals",u)},getJournal({currency:e=null,bookedFrom:s=null,bookedTo:n=null,recognizedAt:r=null,aggregationField:u=null,limit:o=null,offset:l=null,filter:a=null}){const p={currency:e,bookedFrom:s,bookedTo:n,recognizedAt:r,aggregationField:u,limit:o,offset:l,filter:a};return t.get("reports/journal",p)},getJournalSummary({periodStart:e=null,periodEnd:s=null,currency:n=null,aggregationField:r=null,amountField:u=null,journalAccountIds:o=null}){const l={periodStart:e,periodEnd:s,currency:n,aggregationField:r,amountField:u,journalAccountIds:o};return t.get("reports/journal-summary",l)},getKycAcceptanceSummary({periodStart:e=null,periodEnd:s=null}){const n={periodStart:e,periodEnd:s};return t.get("reports/kyc-acceptance-summary",n)},getKycRejectionSummary({periodStart:e=null,periodEnd:s=null}){const n={periodStart:e,periodEnd:s};return t.get("reports/kyc-rejection-summary",n)},getKycRequestSummary({periodStart:e=null,periodEnd:s=null}){const n={periodStart:e,periodEnd:s};return t.get("reports/kyc-request-summary",n)},getMonthlyRecurringRevenue({currency:e,periodStart:s,periodEnd:n,limit:r=null,offset:u=null}){const o={currency:e,periodStart:s,periodEnd:n,limit:r,offset:u};return t.get("reports/monthly-recurring-revenue",o)},getAnnualRecurringRevenue({currency:e,periodStart:s,periodEnd:n,limit:r=null,offset:u=null}){const o={currency:e,periodStart:s,periodEnd:n,limit:r,offset:u};return t.get("reports/annual-recurring-revenue",o)},getRenewalSales({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/renewal-sales",u)},getRetentionPercentage({aggregationField:e=null,aggregationPeriod:s=null,includeSwitchedSubscriptions:n=null,periodStart:r=null,periodEnd:u=null,limit:o=null,offset:l=null,filter:a=null,criteria:p=null}){const k={aggregationField:e,aggregationPeriod:s,includeSwitchedSubscriptions:n,periodStart:r,periodEnd:u,limit:o,offset:l,filter:a,criteria:p};return t.get("reports/retention-percentage",k)},getRetentionValue({aggregationField:e=null,aggregationPeriod:s=null,includeRefunds:n=null,includeDisputes:r=null,periodStart:u=null,periodEnd:o=null,limit:l=null,offset:a=null,filter:p=null,sort:k=null,criteria:j=null}){const D={aggregationField:e,aggregationPeriod:s,includeRefunds:n,includeDisputes:r,periodStart:u,periodEnd:o,limit:l,offset:a,filter:p,sort:k,criteria:j};return t.get("reports/retention-value",D)},getRevenueWaterfall({currency:e,issuedFrom:s=null,issuedTo:n=null,recognizedTo:r=null}){const u={currency:e,issuedFrom:s,issuedTo:n,recognizedTo:r};return t.get("reports/revenue-waterfall",u)},getSubscriptionCancellation({periodStart:e=null,periodEnd:s=null,aggregationField:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={periodStart:e,periodEnd:s,aggregationField:n,limit:r,offset:u,filter:o};return t.get("reports/subscription-cancellation",l)},getSubscriptionRenewal({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/subscription-renewal",u)},getTax({periodStart:e=null,periodEnd:s=null,accountingMethod:n=null,limit:r=null,offset:u=null}){const o={periodStart:e,periodEnd:s,accountingMethod:n,limit:r,offset:u};return t.get("reports/tax",o)},getTimeSeriesTransaction({type:e=null,subaggregate:s=null,periodStart:n=null,periodEnd:r=null,limit:u=null,offset:o=null}){const l={type:e,subaggregate:s,periodStart:n,periodEnd:r,limit:u,offset:o};return t.get("reports/time-series-transaction",l)},getTransactionsTimeDispute({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/transactions-time-dispute",l)},getTransactions({periodStart:e=null,periodEnd:s=null,aggregationField:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={periodStart:e,periodEnd:s,aggregationField:n,limit:r,offset:u,filter:o};return t.get("reports/transactions",l)}}}function vs({apiHandler:t}){return{getSubscriptionSummaryMetrics({subscriptionId:e}){return t.get(`subscriptions/${e}/summary-metrics`)}}}function qs({apiHandler:t}){return{getActivityFeed({eventTypes:e=null,limit:s=1e3,offset:n=0}){const r={eventTypes:e,limit:s,offset:n};return t.getAll("activity-feed",r)},getTransaction({id:e="",eventTypes:s=null,limit:n=1e3,offset:r=0}){const u={eventTypes:s,limit:n,offset:r};return t.getAll(`transactions/${e}/timeline`,u)},getCustomer({id:e="",eventTypes:s=null,limit:n=1e3,offset:r=0}){const u={eventTypes:s,limit:n,offset:r};return t.getAll(`customers/${e}/timeline`,u)}}}function Ts({apiHandler:t}){return{query(){return t.get("location")}}}const w={CustomersResource:Rs,DataExportsResource:bs,HistogramsResource:ws,ReportsResource:ks,SubscriptionsResource:vs,TimelinesResource:qs,LocationResource:Ts};class ds{constructor({apiHandler:e}){this.customers=w.CustomersResource({apiHandler:e}),this.dataExports=w.DataExportsResource({apiHandler:e}),this.histograms=w.HistogramsResource({apiHandler:e}),this.reports=w.ReportsResource({apiHandler:e}),this.subscriptions=w.SubscriptionsResource({apiHandler:e}),this.timelines=w.TimelinesResource({apiHandler:e}),this.location=w.LocationResource({apiHandler:e}),this.addRequestInterceptor=e.addRequestInterceptor,this.removeRequestInterceptor=e.removeRequestInterceptor,this.addResponseInterceptor=e.addResponseInterceptor,this.removeResponseInterceptor=e.removeResponseInterceptor,this.setTimeout=e.setTimeout,this.setProxyAgent=e.setProxyAgent,this.setSessionToken=e.setSessionToken,this.setEndpoints=e.setEndpoints,this.getCancellationToken=e.getCancellationToken}}function Is({apiHandler:t}){return{get({expand:e=null}={}){const s={expand:e};return t.get("account",s)},update({data:e}){return t.patch("account",e)},requestPasswordReset({data:e}){return t.post("account/forgot-password",e)},changePassword({data:e}){return t.patch("account/password",e)},resendEmailVerification({data:e}){return t.post("account/resend-verification",e)},confirmPasswordReset({token:e,data:s}){return t.post(`account/reset-password/${e}`,s)},verifyEmail({token:e}){return t.post(`account/verification/${e}`)},register({data:e}){return t.post("register",e)}}}function Ss({apiHandler:t}){return{login({data:e}){return t.post("login",e)},logout(){return t.post("logout")}}}function Es({apiHandler:t}){return{get({slug:e}){return t.get(`billing-portals/${e}`)}}}function xs({apiHandler:t}){return{get({id:e}){return t.get(`cashiers/${e}`)},cancelPayoutRequests({id:e,data:s}){return t.post(`cashiers/${e}/cancel-payout-requests`,s)}}}function Ps({apiHandler:t}){return{get({id:e}){return t.get(`checkout-forms/${e}`)}}}function Cs({apiHandler:t}){return{getAll({resource:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`custom-fields/${e}`,r)}}}function js({apiHandler:t}){return{get({id:e,expand:s=null}){const n={expand:s};return t.get(`deposit-requests/${e}`,n)}}}function Ds({apiHandler:t}){return{create({data:e}){return t.post("deposit",e)}}}function Ms({apiHandler:t}){return{get({id:e}){return t.get(`deposit-strategies/${e}`)}}}function Os({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("invoices",l)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`invoices/${e}`,n)},update({id:e,data:s}){return t.patch(`invoices/${e}`,s)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`invoices/${e}`,s)}}}function Fs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("kyc-documents",n)},create({data:e}){return t.post("kyc-documents",e)},get({id:e}){return t.get(`kyc-documents/${e}`)},update({id:e,data:s}){return t.patch(`kyc-documents/${e}`,s)}}}function Bs({apiHandler:t}){return{create({data:e}){return t.post("kyc-liveness-sessions",e)},get({id:e}){return t.get(`kyc-liveness-sessions/${e}`)},finish({id:e}){return t.post(`kyc-liveness-sessions/${e}/finish`)}}}function Ks({apiHandler:t}){return{get({id:e,expand:s=null}){const n={expand:s};return t.get(`kyc-requests/${e}`,n)}}}function Ns({apiHandler:t}){return{getUpcomingInvoice({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}/upcoming-invoice`,n)},getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("orders",l)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}`,n)},update({id:e,data:s}){return t.patch(`orders/${e}`,s)},cancel({id:e,data:s}){return t.post(`orders/${e}/cancellation`,s)},pause({id:e,data:s}){return t.post(`orders/${e}/pause`,s)}}}function Ls({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("payment-instruments",o)},create({data:e}){return t.post("payment-instruments",e)},get({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.get(`payment-instruments/${e}`,r)},update({id:e,data:s}){return t.patch(`payment-instruments/${e}`,s)},deactivate({id:e}){return t.post(`payment-instruments/${e}/deactivation`)},getSetupTransaction({id:e}){return t.get(`payment-instruments/${e}/setup`)},setup({id:e,data:s}){return t.post(`payment-instruments/${e}/setup`,s)}}}function zs({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("payout-requests",o)},create({data:e}){return t.post("payout-requests",e)},get({id:e}){return t.get(`payout-requests/${e}`)},update({id:e,data:s}){return t.patch(`payout-requests/${e}`,s)}}}function Us({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("plans",l)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`plans/${e}`,n)}}}function Vs({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("products",o)},get({id:e}){return t.get(`products/${e}`)}}}function Js({apiHandler:t}){return{payment({data:e}){return t.post("payment",e)},purchase({data:e}){return t.post("purchase",e)},preview({data:e}){return t.post("preview-purchase",e)},readyToPay({data:e}){return t.post("ready-to-pay",e)}}}function Ws({apiHandler:t}){return{get({id:e,expand:s=null}){const n={expand:s};return t.get(`quotes/${e}`,n)},accept({id:e}){return t.post(`quotes/${e}/accept`)},reject({id:e}){return t.post(`quotes/${e}/reject`)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`quotes/${e}`,s)}}}function Gs({apiHandler:t}){return{readyToPayout({data:e}){return t.post("ready-to-payout",e)}}}function Ys({apiHandler:t}){return{reactivation({data:e}){return t.post("subscription-reactivations",e)}}}function Qs({apiHandler:t}){return{changeItems({id:e,data:s}){return t.post(`subscriptions/${e}/change-items`,s)},create({data:e}){return t.post("subscriptions",e)}}}function _s({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("transactions",o)},get({id:e}){return t.get(`transactions/${e}`)},getDcc({id:e}){return t.get(`transactions/${e}/dcc`)},updateDcc({id:e,data:s}){return t.patch(`transactions/${e}/dcc`,s)},finishKyc({id:e,token:s}){return t.post(`transactions/${e}/${s}/continue`)},skipKyc({id:e,token:s}){return t.post(`transactions/${e}/${s}/bypass`)},update({id:e,data:s}){return t.patch(`transactions/${e}`,s)}}}function Xs({apiHandler:t}){return{get({id:e}){return t.get(`websites/${e}`)}}}class Zs{constructor({apiHandler:e}){this.account=Is({apiHandler:e}),this.authorization=Ss({apiHandler:e}),this.billingPortals=Es({apiHandler:e}),this.cashiers=xs({apiHandler:e}),this.checkoutForms=Ps({apiHandler:e}),this.customFields=Cs({apiHandler:e}),this.depositRequests=js({apiHandler:e}),this.deposit=Ds({apiHandler:e}),this.depositStrategies=Ms({apiHandler:e}),this.invoices=Os({apiHandler:e}),this.kycDocuments=Fs({apiHandler:e}),this.kycLivenessSessions=Bs({apiHandler:e}),this.kycRequests=Ks({apiHandler:e}),this.orders=Ns({apiHandler:e}),this.paymentInstruments=Ls({apiHandler:e}),this.payoutRequests=zs({apiHandler:e}),this.plans=Us({apiHandler:e}),this.products=Vs({apiHandler:e}),this.purchase=Js({apiHandler:e}),this.quotes=Ws({apiHandler:e}),this.readyToPayout=Gs({apiHandler:e}),this.subscriptionReactivations=Ys({apiHandler:e}),this.subscriptions=Qs({apiHandler:e}),this.transactions=_s({apiHandler:e}),this.websites=Xs({apiHandler:e}),this.checkoutForm=this.checkoutForms,this.billingPortal=this.billingPortals,this.addRequestInterceptor=e.addRequestInterceptor,this.removeRequestInterceptor=e.removeRequestInterceptor,this.addResponseInterceptor=e.addResponseInterceptor,this.removeResponseInterceptor=e.removeResponseInterceptor,this.setTimeout=e.setTimeout,this.setProxyAgent=e.setProxyAgent,this.setSessionToken=e.setSessionToken,this.setPublishableKey=e.setPublishableKey,this.setEndpoints=e.setEndpoints,this.getCancellationToken=e.getCancellationToken,this.generateSignature=e.generateSignature}}function Hs({apiHandler:t}){return new As({apiHandler:t})}function en({apiHandler:t}){return new ds({apiHandler:t})}function tn({apiHandler:t}){return new Zs({apiHandler:t})}const P={live:"https://api.rebilly.com",sandbox:"https://api-sandbox.rebilly.com"},C=6e3;function U({apiKey:t=null,sandbox:e=!1,timeout:s=C,organizationId:n=null,urls:r=P,internalOptions:u=null}={}){if(!r.live||!r.sandbox)throw new Error("RebillyAPI urls config must include a key for both `live` and `sandbox`");if(typeof r.live!="string"||typeof r.sandbox!="string")throw new Error("RebillyAPI urls config `live` and `sandbox` must be strings");const o={apiEndpoints:r,apiKey:t,apiVersion:"",isSandbox:e,requestTimeout:s,jwt:null,organizationId:n,appName:(u==null?void 0:u.appName)??null},l=x({options:o});return Hs({apiHandler:l})}function sn({apiKey:t=null,sandbox:e=!1,timeout:s=C,organizationId:n=null,urls:r=P,internalOptions:u=null}={}){if(!r.live||!r.sandbox)throw new Error("RebillyAPI urls config must include a key for both `live` and `sandbox`");if(typeof r.live!="string"||typeof r.sandbox!="string")throw new Error("RebillyAPI urls config `live` and `sandbox` must be strings");const o={apiEndpoints:r,apiKey:t,apiVersion:"experimental",isSandbox:e,requestTimeout:s,jwt:null,organizationId:n,appName:(u==null?void 0:u.appName)??null},l=x({options:o});return en({apiHandler:l})}function nn({publishableKey:t=null,jwt:e=null,sandbox:s=!1,timeout:n=C,organizationId:r=null,urls:u=P,internalOptions:o=null}={}){if(!u.live||!u.sandbox)throw new Error("RebillyAPI urls config must include a key for both `live` and `sandbox`");if(typeof u.live!="string"||typeof u.sandbox!="string")throw new Error("RebillyAPI urls config `live` and `sandbox` must be strings");const l={apiEndpoints:u,publishableKey:t,jwt:e,apiVersion:"storefront",isSandbox:s,requestTimeout:n,organizationId:r,appName:(o==null?void 0:o.appName)??null},a=x({options:l});return a.setSessionToken(l.jwt),tn({apiHandler:a})}m.RebillyAPI=U,m.RebillyErrors=h,m.RebillyExperimentalAPI=sn,m.RebillyStorefrontAPI=nn,m.cancellation=Ne,m.default=U,Object.defineProperties(m,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
16
+ */var Ie=de;function L(t){return Ie(t)===!0&&Object.prototype.toString.call(t)==="[object Object]"}var Se=function(e){var s,n;return!(L(e)===!1||(s=e.constructor,typeof s!="function")||(n=s.prototype,L(n)===!1)||n.hasOwnProperty("isPrototypeOf")===!1)};const Ee=Te,xe=B,Pe=Se;function E(t,e){switch(xe(t)){case"object":return Ce(t,e);case"array":return je(t,e);default:return Ee(t)}}function Ce(t,e){if(typeof e=="function")return e(t);if(e||Pe(t)){const s=new t.constructor;for(let n in t)s[n]=E(t[n],e);return s}return t}function je(t,e){const s=new t.constructor(t.length);for(let n=0;n<t.length;n++)s[n]=E(t[n],e);return s}var De=E;const Me=ce(De);let Oe="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",Fe=(t=21)=>{let e="",s=t|0;for(;s--;)e+=Oe[Math.random()*64|0];return e};class Be{constructor({id:e=null,created:s=null}={}){this.id=e||Fe(),this.created=s||new Date().getTime(),this.cancelSource=$.CancelToken.source(),this.cancel=this.cancelSource.cancel,this.cancelToken=this.cancelSource.token,y(this,{exclude:["cancelSource","cancelToken","cancel"]})}}let Ke=class S{constructor(){if(S.instance)return S.instance;this.requests={},S.instance=this}getAll(){return Object.values(this.requests)}getById(e){return this.requests[e]}deleteById(e){this.requests[e]&&delete this.requests[e]}save(){const e=new Be;return this.requests[e.id]=e,{id:e.id,cancelToken:e.cancelToken}}};const q=new Ke;class d{}M(d,"cancelById",(e,s)=>{try{q.getById(e).cancel(s),q.deleteById(e)}catch{}}),M(d,"cancelAll",async e=>{for(const s of q.getAll())await s.cancel(e),q.deleteById(s.id)});const Ne={cancelAll:async(...t)=>await d.cancelAll(...t)},b={request:"request",response:"response"},z=t=>{if(!Object.values(b).includes(t))throw new Error(`There is no such interceptor type as "${t}"`);return!0};function x({options:t}){const e=s();function s(){return $.create(r())}function n(){return e}function r(){return{baseURL:u(),timeout:t.requestTimeout,headers:o()}}function u(){let c=t.isSandbox?t.apiEndpoints.sandbox:t.apiEndpoints.live;return t.apiVersion&&(c=`${c}/${t.apiVersion}`),t.organizationId&&(c=`${c}/organizations/${t.organizationId}`),`${c}`}function o(){const i={"REB-API-CONSUMER":`${["Rebilly",t.appName,"js-sdk"].filter(g=>g).join("/")}@dd8f1de`};return t.apiKey&&(i["REB-APIKEY"]=t.apiKey),i}function l(){return Me(e.defaults.headers)}function a(c){t.requestTimeout=Number(c),e.defaults.timeout=t.requestTimeout}function p(c=t.jwt){const i=l();t.apiKey=null,t.jwt=c,delete i.common["REB-APIKEY"],i.common.Authorization=`Bearer ${c}`,e.defaults.headers=i}function k(c=t.publishableKey){const i=l();t.publishableKey=c,i.common.Authorization=`${c}`,e.defaults.headers=i}function j({host:c,port:i,auth:g}){e.defaults.proxy={host:c,port:i,auth:g}}function D({live:c=null,sandbox:i=null}){c&&(t.apiEndpoints.live=c),i&&(t.apiEndpoints.sandbox=i),e.defaults.baseURL=u()}function V(c,{thenDelegate:i,catchDelegate:g=()=>{}}){return z(c)&&e.interceptors[b[c]].use(i,g)}function J(c,i){return z(c)&&e.interceptors[b[c]].eject(i)}function rn({thenDelegate:c,catchDelegate:i=()=>{}}){return V(b.request,{thenDelegate:c,catchDelegate:i})}function un(c){J(b.request,c)}function on({thenDelegate:c,catchDelegate:i=()=>{}}){return V(b.response,{thenDelegate:c,catchDelegate:i})}function ln(c){J(b.response,c)}function v({request:c,isCollection:i,config:g}){const f=G(g),{id:R,cancelToken:yn}=q.save();f.cancelToken=yn;const X=async function(){try{const T=await c(f);return cn({response:T,isCollection:i,config:f})}catch(T){return W({error:T})}finally{q.deleteById(R)}}();return X.cancel=T=>d.cancelById(R,T),X}function cn({response:c,isCollection:i,config:g}){return i?new Z(c,g):new O(c,g)}function W({error:c}){if($.isCancel(c))throw new h.RebillyCanceledError(c);if(c.response)switch(Number(c.response.status)){case 401:throw new h.RebillyForbiddenError(c);case 404:throw new h.RebillyNotFoundError(c);case 405:throw new h.RebillyMethodNotAllowedError(c);case 409:throw new h.RebillyConflictError(c);case 422:throw new h.RebillyValidationError(c);default:throw new h.RebillyRequestError(c)}throw c.code==="ECONNABORTED"?new h.RebillyTimeoutError(c):new h.RebillyRequestError(c)}function gn(c){return c.params!==void 0&&(c.params=Object.keys(c.params).filter(i=>c.params[i]!==null&&c.params[i]!=="").reduce((i,g)=>(i[g]=c.params[g],i),{})),c}function G(c={}){return{...gn(c)}}function Y(c,i={}){return v({request:g=>e.get(c,g),config:{params:i}})}function an(c,i){return v({request:g=>e.get(c,g),config:{params:i},isCollection:!0})}function Q(c,i,g={}){let f={};return g.authenticate===!1&&(f={headers:l()},delete f.headers.common["REB-APIKEY"],delete f.headers.common.Authorization),g.params&&(f.params={...g.params}),v({request:R=>e.post(c,i,R),config:f})}function _(c,i,g={}){return v({request:f=>e.put(c,i,f),config:{params:g}})}function mn(c,i){return v({request:g=>e.patch(c,i,g),config:{}})}function fn(c){return v({request:i=>e.delete(c,i),config:{}})}function $n(c,i){return v({request:g=>e.delete(c,g),config:{data:{...i}}})}async function pn(c,i,g,f={}){if(i==="")return Q(c,g,{params:f});try{if((await Y(c)).response.status===200)throw new h.RebillyConflictError({message:"A resource already exists with this ID. Please use a different ID."})}catch(R){if(R.name==="RebillyNotFoundError")return _(c,g,f);throw R}}async function hn(c,i){const g=G(i);try{const f=await e.get(c,g);return new H(f,g)}catch(f){return W({error:f})}}return{getInstance:n,addRequestInterceptor:rn,removeRequestInterceptor:un,addResponseInterceptor:on,removeResponseInterceptor:ln,setTimeout:a,setProxyAgent:j,setSessionToken:p,setPublishableKey:k,setEndpoints:D,get:Y,getAll:an,post:Q,put:_,patch:mn,delete:fn,deleteAll:$n,create:pn,download:hn}}function Le({apiHandler:t}){return{forgotPassword({data:e}){return t.post("forgot-password",e,{authenticate:!1})}}}function ze({apiHandler:t}){return{getAllowlistCollection({filter:e=null,sort:s=null,limit:n=null,offset:r=null}={}){const u={filter:e,sort:s,limit:n,offset:r};return t.getAll("allowlists",u)},storeAllowlist({data:e}){return t.post("allowlists",e)},getAllowlist({id:e}){return t.get(`allowlists/${e}`)},delete({id:e}){return t.delete(`allowlists/${e}`)}}}function Ue({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("aml-checks",o)},get({id:e}){return t.get(`aml-checks/${e}`)},startReview({id:e}){return t.post(`aml-checks/${e}/start-review`)},stopReview({id:e}){return t.post(`aml-checks/${e}/stop-review`)},review({id:e,data:s}){return t.post(`aml-checks/${e}/review`,s)}}}function Ve({apiHandler:t}){return{getAmlSettings(){return t.get("aml-settings")},putAmlSettings({data:e}){return t.put("aml-settings",e)}}}function Je({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null}={}){const u={filter:e,sort:s,limit:n,offset:r};return t.getAll("api-keys",u)},create({id:e="",data:s}){return t.create(`api-keys/${e}`,e,s)},get({id:e}){return t.get(`api-keys/${e}`)},update({id:e,data:s}){return t.put(`api-keys/${e}`,s)},delete({id:e}){return t.delete(`api-keys/${e}`)}}}function We({apiHandler:t}){return{get({applicationId:e}){return t.get(`application-instances/${e}`)},upsert({applicationId:e,data:s}){return t.put(`application-instances/${e}`,s)},delete({applicationId:e}){return t.delete(`application-instances/${e}`)},getConfiguration({applicationId:e}){return t.get(`application-instances/${e}/configuration`)},upsertConfiguration({applicationId:e,data:s}){return t.put(`application-instances/${e}/configuration`,s)}}}function Ge({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,expand:u=null,fields:o=null,sort:l=null}={}){const a={limit:e,offset:s,filter:n,q:r,expand:u,fields:o,sort:l};return t.getAll("applications",a)},create({data:e}){return t.post("applications",e)},get({id:e}){return t.get(`applications/${e}`)},getInstances({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`applications/${e}/instances`,r)},getInstance({id:e,organizationId:s}){return t.get(`applications/${e}/instances/${s}`)}}}function Ye({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("balance-transactions",u)},get({id:e}){return t.get(`balance-transactions/${e}`)}}}function Qe({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("billing-portals",o)},create({id:e="",data:s}){return t.create(`billing-portals/${e}`,e,s)},get({id:e}){return t.get(`billing-portals/${e}`)},update({id:e,data:s}){return t.put(`billing-portals/${e}`,s)},delete({id:e}){return t.delete(`billing-portals/${e}`)}}}function _e({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("blocklists",o)},create({id:e="",data:s}){return t.create(`blocklists/${e}`,e,s)},get({id:e}){return t.get(`blocklists/${e}`)},delete({id:e}){return t.delete(`blocklists/${e}`)}}}function Xe({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null}={}){const u={limit:e,offset:s,sort:n,filter:r};return t.getAll("broadcast-messages",u)},create({data:e}){return t.post("broadcast-messages",e)},get({id:e}){return t.get(`broadcast-messages/${e}`)},delete({id:e}){return t.delete(`broadcast-messages/${e}`)},update({id:e,data:s}){return t.patch(`broadcast-messages/${e}`,s)}}}function Ze({apiHandler:t}){return{create({data:e}){return t.post("cashiers",e)},get({id:e}){return t.get(`cashiers/${e}`)}}}function He({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("checkout-forms",o)},create({id:e="",data:s}){return t.create(`checkout-forms/${e}`,e,s)},get({id:e}){return t.get(`checkout-forms/${e}`)},update({id:e,data:s}){return t.put(`checkout-forms/${e}`,s)},delete({id:e}){return t.delete(`checkout-forms/${e}`)}}}function et({apiHandler:t}){return{getAllRedemptions({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("coupons-redemptions",o)},redeem({data:e}){return t.post("coupons-redemptions",e)},getRedemption({id:e}){return t.get(`coupons-redemptions/${e}`)},cancelRedemption({id:e}){return t.post(`coupons-redemptions/${e}/cancel`)},getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("coupons",o)},create({id:e="",data:s}){return t.create(`coupons/${e}`,e,s)},get({id:e}){return t.get(`coupons/${e}`)},update({id:e,data:s}){return t.put(`coupons/${e}`,s)},setExpiration({id:e,data:s}){return t.post(`coupons/${e}/expiration`,s)}}}function tt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("credit-memos",l)},create({id:e="",data:s}){return t.create(`credit-memos/${e}`,e,s)},get({id:e}){return t.get(`credit-memos/${e}`)},update({id:e,data:s}){return t.put(`credit-memos/${e}`,s)},patch({id:e,data:s}){return t.patch(`credit-memos/${e}`,s)},void({id:e}){return t.post(`credit-memos/${e}/void`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`credit-memos/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`credit-memos/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`credit-memos/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`credit-memos/${e}/timeline/${s}`)}}}function st({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("custom-domains",o)},create({data:e}){return t.post("custom-domains",e)},get({domain:e}){return t.get(`custom-domains/${e}`)},delete({domain:e}){return t.delete(`custom-domains/${e}`)}}}function nt({apiHandler:t}){return{getAll({resource:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`custom-fields/${e}`,r)},get({resource:e,name:s}){return t.get(`custom-fields/${e}/${s}`)},create({resource:e,name:s,data:n}){return t.put(`custom-fields/${e}/${s}`,n)},update({resource:e,name:s,data:n}){return t.put(`custom-fields/${e}/${s}`,n)}}}function rt({apiHandler:t}){return{getAuthOptions(){return t.get("authentication-options")},updateAuthOptions({data:e}){return t.put("authentication-options",e)},getAllAuthTokens({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("authentication-tokens",n)},login({data:e}){return t.post("authentication-tokens",e)},verify({token:e}){return t.get(`authentication-tokens/${e}`)},logout({token:e}){return t.delete(`authentication-tokens/${e}`)},exchangeToken({token:e,data:s}){return t.post(`authentication-tokens/${e}/exchange`,s)},getAllCredentials({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("credentials",n)},createCredential({id:e="",data:s}){return t.create(`credentials/${e}`,e,s)},getCredential({id:e}){return t.get(`credentials/${e}`)},updateCredential({id:e,data:s}){return t.put(`credentials/${e}`,s)},deleteCredential({id:e}){return t.delete(`credentials/${e}`)},getAllResetPasswordTokens({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("password-tokens",n)},createResetPasswordToken({data:e}){return t.post("password-tokens",e)},getResetPasswordToken({id:e}){return t.get(`password-tokens/${e}`)},deleteResetPasswordToken({id:e}){return t.delete(`password-tokens/${e}`)}}}function ut({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,expand:u=null,fields:o=null,sort:l=null}={}){const a={limit:e,offset:s,filter:n,q:r,expand:u,fields:o,sort:l};return t.getAll("customers",a)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`customers/${e}`,e,s,r)},get({id:e,expand:s=null,fields:n=null}){const r={expand:s,fields:n};return t.get(`customers/${e}`,r)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`customers/${e}`,s,r)},merge({id:e,targetCustomerId:s}){return t.delete(`customers/${e}?targetCustomerId=${s}`)},getLeadSource({id:e}){return t.get(`customers/${e}/lead-source`)},createLeadSource({id:e,data:s}){return t.put(`customers/${e}/lead-source`,s)},updateLeadSource({id:e,data:s}){return t.put(`customers/${e}/lead-source`,s)},deleteLeadSource({id:e}){return t.delete(`customers/${e}/lead-source`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`customers/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`customers/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`customers/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`customers/${e}/timeline/${s}`)},getCustomerEddScore({id:e}){return t.get(`customers/${e}/edd-score`)},getEddTimelineCollection({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`customers/${e}/edd-timeline`,l)},getEddTimelineMessage({id:e,messageId:s}){return t.get(`customers/${e}/edd-timeline/${s}`)},getAllEddSearchResults({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`customers/${e}/edd-search-results`,r)},getEddSearchResult({id:e,searchResultId:s}){return t.get(`customers/${e}/edd-search-results/${s}`)}}}function ot({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("deposit-custom-property-sets",u)},create({id:e="",data:s}){return t.create(`deposit-custom-property-sets/${e}`,e,s)},get({id:e}){return t.get(`deposit-custom-property-sets/${e}`)},update({id:e,data:s}){return t.put(`deposit-custom-property-sets/${e}`,s)},delete({id:e}){return t.delete(`deposit-custom-property-sets/${e}`)}}}function lt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("deposit-requests",o)},create({data:e}){return t.post("deposit-requests",e)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`deposit-requests/${e}`,n)}}}function ct({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("deposit-strategies",u)},create({id:e="",data:s}){return t.create(`deposit-strategies/${e}`,e,s)},get({id:e}){return t.get(`deposit-strategies/${e}`)},update({id:e,data:s}){return t.put(`deposit-strategies/${e}`,s)},delete({id:e}){return t.delete(`deposit-strategies/${e}`)}}}function it({apiHandler:t}){return{validate({data:e}){return t.post("digital-wallets/validation",e)},create({data:e}){return t.post("digital-wallets/onboarding/apple-pay",e)}}}function gt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("disputes",l)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`disputes/${e}`,e,s,r)},get({id:e}){return t.get(`disputes/${e}`)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`disputes/${e}`,s,r)}}}function at({apiHandler:t}){return{verify({token:e}){return t.put(`email-delivery-setting-verifications/${e}`)},getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,q:u};return t.getAll("email-delivery-settings",o)},create({data:e}){return t.post("email-delivery-settings",e)},get({id:e}){return t.get(`email-delivery-settings/${e}`)},delete({id:e}){return t.delete(`email-delivery-settings/${e}`)},update({id:e,data:s}){return t.patch(`email-delivery-settings/${e}`,s)},resendVerification({id:e}){return t.post(`email-delivery-settings/${e}/resend-email-verification`)}}}function mt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,q:n=null,sort:r=null,filter:u=null}={}){const o={limit:e,offset:s,q:n,sort:r,filter:u};return t.getAll("email-messages",o)},create({data:e}){return t.post("email-messages",e)},get({id:e}){return t.get(`email-messages/${e}`)},delete({id:e}){return t.delete(`email-messages/${e}`)},send({id:e,data:s={status:"outbox"}}){return t.patch(`email-messages/${e}`,s)}}}function ft({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("email-notifications",n)}}}function $t({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null}={}){const u={limit:e,offset:s,filter:n,q:r};return t.getAll("events",u)},get({eventType:e}){return t.get(`events/${e}`)},getRules({eventType:e}){return t.get(`events/${e}/rules`)},createRules({eventType:e,data:s}){return t.put(`events/${e}/rules`,s)},updateRules({eventType:e,data:s}){return t.put(`events/${e}/rules`,s)},getAllTimelineMessages({eventType:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`events/${e}/timeline`,l)},createTimelineComment({eventType:e,data:s}){return t.post(`events/${e}/timeline`,s)},getTimelineMessage({eventType:e,messageId:s}){return t.get(`events/${e}/timeline/${s}`)},deleteTimelineMessage({eventType:e,messageId:s}){return t.delete(`events/${e}/timeline/${s}`)},getRulesHistory({eventType:e,limit:s=null,offset:n=null,filter:r=null,q:u=null,sort:o=null,fields:l=null}){const a={limit:s,offset:n,filter:r,q:u,sort:o,fields:l};return t.getAll(`events/${e}/rules/history`,a)},getRulesVersionNumber({eventType:e,version:s,fields:n=null}){const r={fields:n};return t.get(`events/${e}/rules/history/${s}`,r)},getRulesVersionDetail({eventType:e,version:s,fields:n=null}){const r={fields:n};return t.get(`events/${e}/rules/versions/${s}`,r)},getAllDraftRulesets({eventType:e,limit:s=null,offset:n=null,filter:r=null,q:u=null,sort:o=null,fields:l=null}){const a={limit:s,offset:n,filter:r,q:u,sort:o,fields:l};return t.getAll(`events/${e}/rules/drafts`,a)},createDraftRuleset({eventType:e,data:s}){return t.post(`events/${e}/rules/drafts`,s)},getDraftRuleset({eventType:e,id:s,fields:n=null}){const r={fields:n};return t.get(`events/${e}/rules/drafts/${s}`,r)},updateDraftRuleset({eventType:e,id:s,data:n}){return t.put(`events/${e}/rules/drafts/${s}`,n)},deleteDraftRuleset({eventType:e,id:s}){return t.delete(`events/${e}/rules/drafts/${s}`)}}}function pt({apiHandler:t}){return{get({resource:e,resourceId:s,service:n}){return t.get(`${e}/${s}/external-identifiers/${n}`)},sync({resource:e,resourceId:s,service:n}){return t.post(`${e}/${s}/external-identifiers/${n}`)},update({resource:e,resourceId:s,service:n,data:r}){return t.put(`${e}/${s}/external-identifiers/${n}`,r)},delete({resource:e,resourceId:s,service:n}){return t.delete(`${e}/${s}/external-identifiers/${n}`)}}}function ht({apiHandler:t}){return{getExternalServiceSettings(){return t.get("external-services-settings")},updateExternalServiceSettings({data:e}){return t.put("external-services-settings",e)}}}function yt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("fees",u)},create({id:e="",data:s}){return t.create(`fees/${e}`,e,s)},get({id:e}){return t.get(`fees/${e}`)},upsert({id:e,data:s}){return t.put(`fees/${e}`,s)},delete({id:e}){return t.delete(`fees/${e}`)},patch({id:e,data:s}){return t.patch(`fees/${e}`,s)}}}function At({apiHandler:t}){return{getAllAttachments({limit:e=null,offset:s=null,filter:n=null,q:r=null,expand:u=null,fields:o=null,sort:l=null}={}){const a={limit:e,offset:s,filter:n,q:r,expand:u,fields:o,sort:l};return t.getAll("attachments",a)},attach({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`attachments/${e}`,e,s,r)},getAttachment({id:e}){return t.get(`attachments/${e}`)},updateAttachment({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`attachments/${e}`,s,r)},detach({id:e}){return t.delete(`attachments/${e}`)},getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,fields:u=null,sort:o=null}={}){const l={limit:e,offset:s,filter:n,q:r,fields:u,sort:o};return t.getAll("files",l)},upload({fileObject:e}){return t.post("files",e)},get({id:e}){return t.get(`files/${e}`)},update({id:e,data:s}){return t.put(`files/${e}`,s)},delete({id:e}){return t.delete(`files/${e}`)},download({id:e}){const s={responseType:"arraybuffer"};return t.download(`files/${e}/download`,s)},detachAndDelete({id:e}){const s={filter:`fileId:${e}`};let n=[];const u=(async()=>{const o=this.getAllAttachments(s);n.push(o);const a=(await o).items.map(k=>this.detach({id:k.fields.id}));n=[...n,a],await Promise.all(a);const p=t.delete(`files/${e}`);return n.push(p),p})();return u.cancel=()=>{n.forEach(o=>o.cancel())},u},uploadAndUpdate({fileObject:e,data:s={description:"",tags:[""]}}){const n=[],u=(async()=>{const o=this.upload({fileObject:e});n.push(o),await o;const l={name:o.name,extension:o.extension,description:s.description,tags:s.tags,url:""},a=this.update({id:o.fields.id,data:l});return n.push(a),a})();return u.cancel=()=>{n.forEach(o=>o.cancel())},u}}}function Rt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null,fields:o=null}={}){const l={limit:e,offset:s,sort:n,filter:r,q:u,fields:o};return t.getAll("gateway-accounts",l)},create({id:e="",data:s}){return t.create(`gateway-accounts/${e}`,e,s)},get({id:e}){return t.get(`gateway-accounts/${e}`)},upsert({id:e,data:s}){return t.put(`gateway-accounts/${e}`,s)},delete({id:e}){return t.delete(`gateway-accounts/${e}`)},update({id:e,data:s}){return t.patch(`gateway-accounts/${e}`,s)},close({id:e}){return t.post(`gateway-accounts/${e}/close`)},disable({id:e}){return t.post(`gateway-accounts/${e}/disable`)},getAllDowntimeSchedules({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null}){const o={limit:s,offset:n,filter:r,sort:u};return t.getAll(`gateway-accounts/${e}/downtime-schedules`,o)},createDowntimeSchedule({id:e,data:s}){return t.post(`gateway-accounts/${e}/downtime-schedules`,s)},getDowntimeSchedule({id:e,downtimeId:s}){return t.get(`gateway-accounts/${e}/downtime-schedules/${s}`)},updateDowntimeSchedule({id:e,downtimeId:s,data:n}){return t.put(`gateway-accounts/${e}/downtime-schedules/${s}`,n)},deleteDowntimeSchedule({id:e,downtimeId:s}){return t.delete(`gateway-accounts/${e}/downtime-schedules/${s}`)},enable({id:e}){return t.post(`gateway-accounts/${e}/enable`)},getAllVolumeLimits({id:e}){return t.getAll(`gateway-accounts/${e}/limits`)},getVolumeLimit({id:e,limitId:s}){return t.get(`gateway-accounts/${e}/limits/${s}`)},updateVolumeLimit({id:e,limitId:s,data:n}){return t.put(`gateway-accounts/${e}/limits/${s}`,n)},deleteVolumeLimit({id:e,limitId:s}){return t.delete(`gateway-accounts/${e}/limits/${s}`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`gateway-accounts/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`gateway-accounts/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`gateway-accounts/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`gateway-accounts/${e}/timeline/${s}`)},checkCredentials({id:e}){return t.post(`gateway-accounts/${e}/check-credentials`)},getFinancialSettings({id:e}){return t.get(`gateway-accounts/${e}/financial-settings`)},setFinancialSettings({id:e,data:s}){return t.put(`gateway-accounts/${e}/financial-settings`,s)}}}function bt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("integrations",n)},get({label:e}){return t.get(`integrations/${e}`)}}}const I={Accept:"application/pdf"};function wt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("invoices",l)},create({id:e="",data:s}){return t.create(`invoices/${e}`,e,s)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`invoices/${e}`,n)},update({id:e,data:s}){return t.put(`invoices/${e}`,s)},getAllInvoiceItems({id:e,limit:s=null,offset:n=null,expand:r=null}){const u={limit:s,offset:n,expand:r};return t.getAll(`invoices/${e}/items`,u)},createInvoiceItem({id:e,data:s}){return t.post(`invoices/${e}/items`,s)},getInvoiceItem({id:e,itemId:s}){return t.get(`invoices/${e}/items/${s}`)},updateInvoiceItem({id:e,itemId:s,data:n}){return t.put(`invoices/${e}/items/${s}`,n)},deleteInvoiceItem({id:e,itemId:s}){return t.delete(`invoices/${e}/items/${s}`)},issue({id:e,data:s}){return t.post(`invoices/${e}/issue`,s)},abandon({id:e}){return t.post(`invoices/${e}/abandon`)},void({id:e}){return t.post(`invoices/${e}/void`)},recalculate({id:e}){return t.post(`invoices/${e}/recalculate`)},reissue({id:e,data:s}){return t.post(`invoices/${e}/reissue`,s)},getAllTransactionAllocations({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`invoices/${e}/transaction-allocations`,r)},applyTransaction({id:e,data:s}){return t.post(`invoices/${e}/transaction`,s)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`invoices/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`invoices/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`invoices/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`invoices/${e}/timeline/${s}`)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`invoices/${e}`,s)}}}function kt({apiHandler:t}){return{getAllAccounts({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("journal-accounts",u)},createAccount({id:e="",data:s}){return t.create(`journal-accounts/${e}`,e,s)},getAccount({id:e}){return t.get(`journal-accounts/${e}`)},updateAccount({id:e,data:s}){return t.put(`journal-accounts/${e}`,s)}}}function vt({apiHandler:t}){return{getAllEntries({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("journal-entries",u)},createEntry({id:e="",data:s}){return t.create(`journal-entries/${e}`,e,s)},getEntry({id:e}){return t.get(`journal-entries/${e}`)},updateEntry({id:e,data:s}){return t.put(`journal-entries/${e}`,s)}}}function qt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("journal-records",o)},create({id:e="",data:s}){return t.create(`journal-records/${e}`,e,s)},get({id:e}){return t.get(`journal-records/${e}`)},update({id:e,data:s}){return t.put(`journal-records/${e}`,s)},delete({id:e}){return t.delete(`journal-records/${e}`)}}}function Tt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("kyc-documents",o)},create({id:e="",data:s}){return t.create(`kyc-documents/${e}`,e,s)},get({id:e}){return t.get(`kyc-documents/${e}`)},update({id:e,data:s}){return t.put(`kyc-documents/${e}`,s)},accept({id:e}){return t.post(`kyc-documents/${e}/acceptance`)},matches({id:e,data:s}){return t.post(`kyc-documents/${e}/matches`,s)},reject({id:e,data:s}){return t.post(`kyc-documents/${e}/rejection`,s)},review({id:e}){return t.post(`kyc-documents/${e}/review`)},startReview({id:e}){return t.post(`kyc-documents/${e}/start-review`)},stopReview({id:e}){return t.post(`kyc-documents/${e}/stop-review`)}}}function dt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,expand:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,expand:u};return t.getAll("kyc-requests",o)},create({data:e}){return t.post("kyc-requests",e)},get({id:e}){return t.get(`kyc-requests/${e}`)},delete({id:e}){return t.delete(`kyc-requests/${e}`)},update({id:e,data:s}){return t.patch(`kyc-requests/${e}`,s)}}}function It({apiHandler:t}){return{getKycSettings(){return t.get("kyc-settings")},updateKycSettings({data:e}){return t.put("kyc-settings",e)}}}function St({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,fields:u=null,q:o=null}={}){const l={limit:e,offset:s,filter:n,sort:r,fields:u,q:o};return t.getAll("lists",l)},create({id:e="",data:s}){return t.create(`lists/${e}`,e,s)},getLatestVersion({id:e}){return t.get(`lists/${e}`)},update({id:e,data:s}){return t.put(`lists/${e}`,s)},delete({id:e}){return t.delete(`lists/${e}`)},getByVersion({id:e,version:s}){return t.get(`lists/${e}/${s}`)}}}function Et({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("memberships",u)},get({organizationId:e,userId:s}){return t.get(`memberships/${e}/${s}`)},update({organizationId:e,userId:s,data:n}){return t.put(`memberships/${e}/${s}`,n)},delete({organizationId:e,userId:s}){return t.delete(`memberships/${e}/${s}`)}}}function xt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("order-cancellations",u)},create({id:e="",data:s}){return t.create(`order-cancellations/${e}`,e,s)},get({id:e}){return t.get(`order-cancellations/${e}`)},update({id:e,data:s}){return t.put(`order-cancellations/${e}`,s)},delete({id:e}){return t.delete(`order-cancellations/${e}`)},patch({id:e,data:s}){return t.patch(`order-cancellations/${e}`,s)}}}function Pt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("order-pauses",u)},pause({id:e="",data:s}){return t.create(`order-pauses/${e}`,e,s)},get({id:e}){return t.get(`order-pauses/${e}`)},update({id:e,data:s}){return t.put(`order-pauses/${e}`,s)},delete({id:e}){return t.delete(`order-pauses/${e}`)}}}function Ct({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("order-reactivations",u)},reactivate({data:e}){return t.post("order-reactivations",e)},get({id:e}){return t.get(`order-reactivations/${e}`)}}}function jt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("orders",o)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`orders/${e}`,e,s,r)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}`,n)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`orders/${e}`,s,r)},getUpcomingInvoice({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}/upcoming-invoice`,n)},void({id:e}){return t.post(`orders/${e}/void`)},changeItems({id:e,data:s,expand:n=null}){const r={expand:n};return t.post(`orders/${e}/change-items`,s,r)},updateItem({id:e,itemId:s,data:n}){return t.patch(`orders/${e}/items/${s}`,n)},createInterimInvoice({id:e,data:s}){return t.post(`orders/${e}/interim-invoice`,s)},issueEarlyUpcomingInvoice({id:e,data:s}){return t.post(`orders/${e}/upcoming-invoice/issue`,s)}}}function Dt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("organization-exports",o)},create({data:e}){return t.post("organization-exports",e)},get({id:e}){return t.get(`organization-exports/${e}`)}}}function Mt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,q:u};return t.getAll("organizations",o)},create({data:e}){return t.post("organizations",e)},get({id:e}){return t.get(`organizations/${e}`)},update({id:e,data:s}){return t.patch(`organizations/${e}`,s)}}}function Ot({apiHandler:t}){return{getAll({limit:e=null,q:s=null}={}){const n={limit:e,q:s};return t.getAll("payment-cards-bank-names",n)}}}function Ft({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("payment-instruments",l)},create({data:e}){return t.post("payment-instruments",e)},get({id:e}){return t.get(`payment-instruments/${e}`)},update({id:e,data:s}){return t.patch(`payment-instruments/${e}`,s)},deactivate({id:e}){return t.post(`payment-instruments/${e}/deactivation`)},nameInquiry({id:e,data:s}){return t.post(`payment-instruments/${e}/name-inquiry`,s)}}}function Bt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("payment-methods",n)},get({apiName:e}){return t.get(`payment-methods/${e}`)}}}function Kt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("tokens",n)},create({data:e}){return t.post("tokens",e)},get({token:e}){return t.get(`tokens/${e}`)}}}function Nt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("payout-request-allocations",u)},create({data:e}){return t.post("payout-request-allocations",e)},autoAllocate({data:e}){return t.post("payout-request-allocations/auto",e)},get({id:e}){return t.get(`payout-request-allocations/${e}`)},update({id:e,data:s}){return t.patch(`payout-request-allocations/${e}`,s)},process({data:e}){return t.post("payout-request-allocations/process",e)}}}function Lt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("payout-request-batches",u)},create({data:e}){return t.post("payout-request-batches",e)},get({id:e}){return t.get(`payout-request-batches/${e}`)},autoAllocate({id:e}){return t.post(`payout-request-batches/${e}/auto-allocate`)},approve({id:e}){return t.post(`payout-request-batches/${e}/approve`)},block({id:e,data:s}){return t.post(`payout-request-batches/${e}/block`,s)},preview({filter:e=null}){const s={filter:e};return t.get("payout-request-batches/preview",s)}}}function zt({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("payout-requests",u)},create({id:e="",data:s}){return t.create(`payout-requests/${e}`,e,s)},get({id:e}){return t.get(`payout-requests/${e}`)},update({id:e,data:s}){return t.put(`payout-requests/${e}`,s)},patch({id:e,data:s}){return t.patch(`payout-requests/${e}`,s)},cancel({id:e,data:s}){return t.post(`payout-requests/${e}/cancel`,s)},split({id:e,data:s}){return t.post(`payout-requests/${e}/split`,s)},getPaymentInstruments({id:e}){return t.get(`payout-requests/${e}/payment-instruments`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`payout-requests/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`payout-requests/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`payout-requests/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`payout-requests/${e}/timeline/${s}`)}}}function Ut({apiHandler:t}){return{getV2({id:e}){return t.get(`payout-requests-v2/${e}`)},getPaymentInstrumentsV2({id:e}){return t.get(`payout-requests-v2/${e}/payment-instruments`)}}}function Vt({apiHandler:t}){return{create({data:e}){return t.post("payouts",e)}}}function Jt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("plans",o)},create({id:e="",data:s}){return t.create(`plans/${e}`,e,s)},get({id:e}){return t.get(`plans/${e}`)},update({id:e,data:s}){return t.put(`plans/${e}`,s)},delete({id:e}){return t.delete(`plans/${e}`)}}}function Wt({apiHandler:t}){return{order({data:e}){return t.post("previews/orders",e)},sendEmailRuleAction({data:e}){return t.post("previews/rule-actions/send-email",e)},webhook({data:e}){return t.post("previews/webhooks",e)}}}function Gt({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("products",o)},create({id:e="",data:s}){return t.create(`products/${e}`,e,s)},get({id:e}){return t.get(`products/${e}`)},update({id:e,data:s}){return t.put(`products/${e}`,s)},delete({id:e}){return t.delete(`products/${e}`)}}}function Yt({apiHandler:t}){return{startPermissionsEmulation({data:e}){return t.post("permissions-emulation",e)},stopPermissionsEmulation(){return t.delete("permissions-emulation")},get(){return t.get("profile")},update({data:e}){return t.put("profile",e)},getMfa(){return t.get("profile/mfa")},updateMfa(){return t.post("profile/mfa")},deleteMfa(){return t.delete("profile/mfa")}}}function Qt({apiHandler:t}){return{readyToPay({data:e}){return t.post("ready-to-pay",e)}}}function _t({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,expand:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,expand:u};return t.getAll("quotes",o)},create({id:e="",data:s}){return t.create(`quotes/${e}`,e,s)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`quotes/${e}`,n)},update({id:e,data:s}){return t.put(`quotes/${e}`,s)},patch({id:e,data:s}){return t.patch(`quotes/${e}`,s)},accept({id:e}){return t.post(`quotes/${e}/accept`)},cancel({id:e}){return t.post(`quotes/${e}/cancel`)},issue({id:e}){return t.post(`quotes/${e}/issue`)},recall({id:e}){return t.post(`quotes/${e}/recall`)},reject({id:e}){return t.post(`quotes/${e}/reject`)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`quotes/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`quotes/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`quotes/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`quotes/${e}/timeline/${s}`)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`quotes/${e}`,s)}}}function Xt({apiHandler:t}){return{get({resource:e,resourceId:s,service:n}){return t.get(`${e}/${s}/external-identifiers/${n}`)},sync({resource:e,resourceId:s,service:n}){return t.post(`${e}/${s}/external-identifiers/${n}`)},update({resource:e,resourceId:s,service:n,data:r}){return t.put(`${e}/${s}/external-identifiers/${n}`,r)},delete({resource:e,resourceId:s,service:n}){return t.delete(`${e}/${s}/external-identifiers/${n}`)}}}function Zt({apiHandler:t}){return{getAll(){return t.get("risk-score-rules")},updateRiskScoreRules({data:e}){return t.put("risk-score-rules",e)},getAllBlocklistRules(){return t.get("risk-score-rules/blocklists")},updateRiskScoreBlocklistRules({data:e}){return t.put("risk-score-rules/blocklists",e)}}}function Ht({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null,expand:o=null}={}){const l={limit:e,offset:s,filter:n,sort:r,q:u,expand:o};return t.getAll("roles",l)},create({id:e="",data:s}){return t.create(`roles/${e}`,e,s)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`roles/${e}`,n)},update({id:e,data:s}){return t.put(`roles/${e}`,s)},delete({id:e}){return t.delete(`roles/${e}`)}}}function es({apiHandler:t}){return{get({sort:e=null,limit:s=null,offset:n=null,q:r=null}){const u={sort:e,limit:s,offset:n,q:r};return t.get("search",u)}}}function ts({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("grid-segments",o)},create({id:e="",data:s}){return t.create(`grid-segments/${e}`,e,s)},get({id:e}){return t.get(`grid-segments/${e}`)},update({id:e,data:s}){return t.put(`grid-segments/${e}`,s)},delete({id:e}){return t.delete(`grid-segments/${e}`)}}}function ss({apiHandler:t}){return{getAll({eventType:e}){return t.getAll(`send-through-attribution/${e}`)}}}function ns({apiHandler:t}){return{getAll({type:e,filter:s=null,limit:n=null,offset:r=null,sort:u=null,q:o=null}){const l={filter:s,limit:n,offset:r,sort:u,q:o};return t.getAll(`service-credentials/${e}`,l)},create({type:e,data:s}){return t.post(`service-credentials/${e}`,s)},get({type:e,id:s}){return t.get(`service-credentials/${e}/${s}`)},update({type:e,id:s,data:n}){return t.patch(`service-credentials/${e}/${s}`,n)},getItems({type:e,id:s,limit:n=null,offset:r=null,filter:u=null,q:o=null,fields:l=null,sort:a=null}){const p={limit:n,offset:r,filter:u,q:o,fields:l,sort:a};return t.getAll(`service-credentials/${e}/${s}/items`,p)}}}function rs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null,q:u=null}={}){const o={limit:e,offset:s,filter:n,sort:r,q:u};return t.getAll("shipping-rates",o)},create({id:e="",data:s}){return t.create(`shipping-rates/${e}`,e,s)},get({id:e}){return t.get(`shipping-rates/${e}`)},update({id:e,data:s}){return t.put(`shipping-rates/${e}`,s)},delete({id:e}){return t.delete(`shipping-rates/${e}`)}}}function us({apiHandler:t}){return{get(){return t.get("status")}}}function os({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("subscription-cancellations",u)},create({id:e="",data:s}){return t.create(`subscription-cancellations/${e}`,e,s)},get({id:e}){return t.get(`subscription-cancellations/${e}`)},delete({id:e}){return t.delete(`subscription-cancellations/${e}`)},patch({id:e,data:s}){return t.patch(`subscription-cancellations/${e}`,s)}}}function ls({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("subscription-pauses",u)},pause({id:e="",data:s}){return t.create(`subscription-pauses/${e}`,e,s)},get({id:e}){return t.get(`subscription-pauses/${e}`)},update({id:e,data:s}){return t.put(`subscription-pauses/${e}`,s)},delete({id:e}){return t.delete(`subscription-pauses/${e}`)}}}function cs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,sort:r=null}={}){const u={limit:e,offset:s,filter:n,sort:r};return t.getAll("subscription-reactivations",u)},reactivate({data:e}){return t.post("subscription-reactivations",e)},get({id:e}){return t.get(`subscription-reactivations/${e}`)}}}function is({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("subscriptions",l)},create({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`subscriptions/${e}`,e,s,r)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`subscriptions/${e}`,n)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`subscriptions/${e}`,s,r)},delete({id:e}){return t.delete(`subscriptions/${e}`)},void({id:e}){return t.post(`subscriptions/${e}/void`)},changeItems({id:e,data:s,expand:n=null}){const r={expand:n};return t.post(`subscriptions/${e}/change-items`,s,r)},updateItem({id:e,itemId:s,data:n}){return t.patch(`subscriptions/${e}/items/${s}`,n)},createInterimInvoice({id:e,data:s}){return t.post(`subscriptions/${e}/interim-invoice`,s)},getAllUpcomingInvoices({id:e,expand:s=null}){const n={expand:s};return t.getAll(`subscriptions/${e}/upcoming-invoices`,n)},getUpcomingInvoice({id:e,expand:s=null}){const n={expand:s};return t.get(`subscriptions/${e}/upcoming-invoice`,n)},issueEarlyUpcomingInvoice({id:e,data:s}){return t.post(`subscriptions/${e}/upcoming-invoice/issue`,s)},issueUpcomingInvoice({id:e,invoiceId:s,data:n}){return t.post(`subscriptions/${e}/upcoming-invoices/${s}/issue`,n)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`subscriptions/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`subscriptions/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`subscriptions/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`subscriptions/${e}/timeline/${s}`)}}}function gs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("tags",o)},create({data:e}){return t.post("tags",e)},get({tag:e}){return t.get(`tags/${e}`)},delete({tag:e}){return t.delete(`tags/${e}`)},update({tag:e,data:s}){return t.patch(`tags/${e}`,s)},tagCustomers({tag:e,data:s}){return t.post(`tags/${e}/customers`,s)},untagCustomers({tag:e,data:s}){return t.delete(`tags/${e}/customers`,s)},tagCustomer({tag:e,customerId:s}){return t.post(`tags/${e}/customers/${s}`)},untagCustomer({tag:e,customerId:s}){return t.delete(`tags/${e}/customers/${s}`)},tagKycDocuments({tag:e,data:s}){return t.post(`tags/${e}/kyc-documents`,s)},untagKycDocuments({tag:e,data:s}){return t.delete(`tags/${e}/kyc-documents`,s)},tagKycDocument({tag:e,kycDocumentId:s}){return t.post(`tags/${e}/kyc-documents/${s}`)},untagKycDocument({tag:e,kycDocumentId:s}){return t.delete(`tags/${e}/kyc-documents/${s}`)},tagAmlChecks({tag:e,data:s}){return t.post(`tags/${e}/aml-checks`,s)},untagAmlChecks({tag:e,data:s}){return t.delete(`tags/${e}/aml-checks`,s)},tagAmlCheck({tag:e,amlCheckId:s}){return t.post(`tags/${e}/aml-checks/${s}`)},untagAmlCheck({tag:e,amlCheckId:s}){return t.delete(`tags/${e}/aml-checks/${s}`)}}}function as({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tags-rules",o)},create({id:e="",data:s}){return t.create(`tags-rules/${e}`,e,s)},get({id:e}){return t.get(`tags-rules/${e}`)},update({id:e,data:s}){return t.put(`tags-rules/${e}`,s)},delete({id:e}){return t.delete(`tags-rules/${e}`)}}}function ms({apiHandler:t}){return{getAllApiLogs({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null,expand:o=null}={}){const l={limit:e,offset:s,sort:n,filter:r,q:u,expand:o};return t.getAll("tracking/api",l)},getApiLog({id:e}){return t.get(`tracking/api/${e}`)},getAllTaxTrackingLogs({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tracking/taxes",o)},getTaxTrackingLog({id:e}){return t.get(`tracking/taxes/${e}`)},getAllListsChangesHistory({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tracking/lists",o)},getAllWebhookTrackingLogs({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("tracking/webhooks",o)},getWebhookTrackingLog({id:e}){return t.get(`tracking/webhooks/${e}`)},resendWebhook({id:e}){return t.post(`tracking/webhooks/${e}/resend`)}}}function fs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null,expand:o=null}={}){const l={limit:e,offset:s,filter:n,q:r,sort:u,expand:o};return t.getAll("transactions",l)},create({data:e,expand:s=null}){const n={expand:s};return t.post("transactions",e,n)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`transactions/${e}`,n)},patch({id:e,data:s}){return t.patch(`transactions/${e}`,s)},query({id:e}){return t.post(`transactions/${e}/query`)},update({id:e,data:s}){return t.post(`transactions/${e}/update`,s)},refund({id:e,data:s,expand:n=null}){const r={expand:n};return t.post(`transactions/${e}/refund`,s,r)},getAllTimelineMessages({id:e,limit:s=null,offset:n=null,filter:r=null,sort:u=null,q:o=null}){const l={limit:s,offset:n,filter:r,sort:u,q:o};return t.getAll(`transactions/${e}/timeline`,l)},createTimelineComment({id:e,data:s}){return t.post(`transactions/${e}/timeline`,s)},getTimelineMessage({id:e,messageId:s}){return t.get(`transactions/${e}/timeline/${s}`)},deleteTimelineMessage({id:e,messageId:s}){return t.delete(`transactions/${e}/timeline/${s}`)}}}function $s({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("usages",o)},create({data:e}){return t.post("usages",e)},get({id:e}){return t.get(`usages/${e}`)},delete({id:e}){return t.delete(`usages/${e}`)}}}function ps({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,filter:r=null,q:u=null}={}){const o={limit:e,offset:s,sort:n,filter:r,q:u};return t.getAll("users",o)},create({id:e="",data:s}){return t.create(`users/${e}`,e,s)},get({id:e}){return t.get(`users/${e}`)},update({id:e,data:s}){return t.put(`users/${e}`,s)},getMfa({id:e}){return t.get(`users/${e}/mfa`)}}}function hs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null}={}){const r={limit:e,offset:s,filter:n};return t.getAll("webhooks",r)},create({id:e="",data:s}){return t.create(`webhooks/${e}`,e,s)},get({id:e}){return t.get(`webhooks/${e}`)},update({id:e,data:s}){return t.put(`webhooks/${e}`,s)},delete({id:e}){return t.delete(`webhooks/${e}`)}}}function ys({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,q:n=null,filter:r=null,sort:u=null}={}){const o={limit:e,offset:s,q:n,filter:r,sort:u};return t.getAll("websites",o)},create({id:e="",data:s}){return t.create(`websites/${e}`,e,s)},get({id:e}){return t.get(`websites/${e}`)},update({id:e,data:s}){return t.put(`websites/${e}`,s)},delete({id:e}){return t.delete(`websites/${e}`)}}}class As{constructor({apiHandler:e}){this.account=Le({apiHandler:e}),this.allowlists=ze({apiHandler:e}),this.amlChecks=Ue({apiHandler:e}),this.amlSettings=Ve({apiHandler:e}),this.apiKeys=Je({apiHandler:e}),this.applicationInstances=We({apiHandler:e}),this.applications=Ge({apiHandler:e}),this.balanceTransactions=Ye({apiHandler:e}),this.billingPortals=Qe({apiHandler:e}),this.blocklists=_e({apiHandler:e}),this.broadcastMessages=Xe({apiHandler:e}),this.cashiers=Ze({apiHandler:e}),this.checkoutForms=He({apiHandler:e}),this.coupons=et({apiHandler:e}),this.creditMemos=tt({apiHandler:e}),this.customDomains=st({apiHandler:e}),this.customFields=nt({apiHandler:e}),this.customerAuthentication=rt({apiHandler:e}),this.customers=ut({apiHandler:e}),this.depositCustomPropertySets=ot({apiHandler:e}),this.depositRequests=lt({apiHandler:e}),this.depositStrategies=ct({apiHandler:e}),this.digitalWallets=it({apiHandler:e}),this.disputes=gt({apiHandler:e}),this.emailDeliverySettings=at({apiHandler:e}),this.emailMessages=mt({apiHandler:e}),this.emailNotifications=ft({apiHandler:e}),this.events=$t({apiHandler:e}),this.externalIdentifiers=pt({apiHandler:e}),this.externalServicesSettings=ht({apiHandler:e}),this.fees=yt({apiHandler:e}),this.files=At({apiHandler:e}),this.gatewayAccounts=Rt({apiHandler:e}),this.integrations=bt({apiHandler:e}),this.invoices=wt({apiHandler:e}),this.journalAccounts=kt({apiHandler:e}),this.journalEntries=vt({apiHandler:e}),this.journalRecords=qt({apiHandler:e}),this.kycDocuments=Tt({apiHandler:e}),this.kycRequests=dt({apiHandler:e}),this.kycSettings=It({apiHandler:e}),this.lists=St({apiHandler:e}),this.memberships=Et({apiHandler:e}),this.orderCancellations=xt({apiHandler:e}),this.orderPauses=Pt({apiHandler:e}),this.orderReactivations=Ct({apiHandler:e}),this.orders=jt({apiHandler:e}),this.organizationExports=Dt({apiHandler:e}),this.organizations=Mt({apiHandler:e}),this.paymentCardsBankNames=Ot({apiHandler:e}),this.paymentInstruments=Ft({apiHandler:e}),this.paymentMethods=Bt({apiHandler:e}),this.paymentTokens=Kt({apiHandler:e}),this.payoutRequestAllocations=Nt({apiHandler:e}),this.payoutRequestBatches=Lt({apiHandler:e}),this.payoutRequests=zt({apiHandler:e}),this.payoutRequestsV2=Ut({apiHandler:e}),this.payouts=Vt({apiHandler:e}),this.plans=Jt({apiHandler:e}),this.previews=Wt({apiHandler:e}),this.products=Gt({apiHandler:e}),this.profile=Yt({apiHandler:e}),this.purchase=Qt({apiHandler:e}),this.quotes=_t({apiHandler:e}),this.resource=Xt({apiHandler:e}),this.riskScoreRules=Zt({apiHandler:e}),this.roles=Ht({apiHandler:e}),this.search=es({apiHandler:e}),this.segments=ts({apiHandler:e}),this.sendThroughAttribution=ss({apiHandler:e}),this.serviceCredentials=ns({apiHandler:e}),this.shippingRates=rs({apiHandler:e}),this.status=us({apiHandler:e}),this.subscriptionCancellations=os({apiHandler:e}),this.subscriptionPauses=ls({apiHandler:e}),this.subscriptionReactivations=cs({apiHandler:e}),this.subscriptions=is({apiHandler:e}),this.tags=gs({apiHandler:e}),this.tagsRules=as({apiHandler:e}),this.tracking=ms({apiHandler:e}),this.transactions=fs({apiHandler:e}),this.usages=$s({apiHandler:e}),this.users=ps({apiHandler:e}),this.webhooks=hs({apiHandler:e}),this.websites=ys({apiHandler:e}),this.addRequestInterceptor=e.addRequestInterceptor,this.removeRequestInterceptor=e.removeRequestInterceptor,this.addResponseInterceptor=e.addResponseInterceptor,this.removeResponseInterceptor=e.removeResponseInterceptor,this.setTimeout=e.setTimeout,this.setProxyAgent=e.setProxyAgent,this.setSessionToken=e.setSessionToken,this.setPublishableKey=e.setPublishableKey,this.setEndpoints=e.setEndpoints,this.getCancellationToken=e.getCancellationToken,this.generateSignature=e.generateSignature}}function Rs({apiHandler:t}){return{getCustomerLifetimeSummaryMetrics({customerId:e}){return t.get(`customers/${e}/summary-metrics`)}}}function bs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,sort:n=null,expand:r=null,filter:u=null,q:o=null,criteria:l=null}={}){const a={limit:e,offset:s,sort:n,expand:r,filter:u,q:o,criteria:l};return t.getAll("data-exports",a)},queue({id:e="",data:s,expand:n=null}){const r={expand:n};return t.create(`data-exports/${e}`,e,s,r)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`data-exports/${e}`,n)},update({id:e,data:s,expand:n=null}){const r={expand:n};return t.put(`data-exports/${e}`,s,r)},delete({id:e}){return t.delete(`data-exports/${e}`)}}}function ws({apiHandler:t}){return{getAmlCheckHistogramReport({periodStart:e=null,periodEnd:s=null,aggregationPeriod:n=null,metric:r=null,includePropagatedResults:u=null,filter:o=null}){const l={periodStart:e,periodEnd:s,aggregationPeriod:n,metric:r,includePropagatedResults:u,filter:o};return t.get("histograms/aml-checks",l)},getTransactionHistogramReport({periodStart:e=null,periodEnd:s=null,aggregationPeriod:n=null,metric:r=null,filter:u=null}){const o={periodStart:e,periodEnd:s,aggregationPeriod:n,metric:r,filter:u};return t.get("histograms/transactions",o)}}}function ks({apiHandler:t}){return{getApiLogSummary({periodStart:e=null,periodEnd:s=null,filter:n=null,limit:r=null,offset:u=null}){const o={periodStart:e,periodEnd:s,filter:n,limit:r,offset:u};return t.get("reports/api-log-summary",o)},getAmlChecks({periodStart:e=null,periodEnd:s=null,metric:n=null,includePropagatedResults:r=null,filter:u=null}){const o={periodStart:e,periodEnd:s,metric:n,includePropagatedResults:r,filter:u};return t.get("reports/aml-checks",o)},getCumulativeSubscriptions({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/cumulative-subscriptions",l)},getDashboardMetrics({periodStart:e=null,periodEnd:s=null,metrics:n=null,segments:r=null}){const u={periodStart:e,periodEnd:s,metrics:n,segments:r};return t.get("reports/dashboard",u)},getDccMarkup({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/dcc-markup",l)},getDeclinedTransactions({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/declined-transactions",l)},getDeferredRevenue({currency:e=null,asOfDate:s=null,limit:n=null,offset:r=null,filter:u=null}){const o={currency:e,asOfDate:s,limit:n,offset:r,filter:u};return t.get("reports/deferred-revenue",o)},getDisputes({aggregationField:e=null,periodMonth:s=null,limit:n=null,offset:r=null,filter:u=null}){const o={aggregationField:e,periodMonth:s,limit:n,offset:r,filter:u};return t.get("reports/disputes",o)},getEventsTriggeredSummary({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/events-triggered",u)},getTriggeredEventRuleReport({eventType:e,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null}){const o={periodStart:s,periodEnd:n,limit:r,offset:u};return t.get(`reports/events-triggered/${e}/rules`,o)},getFutureRenewals({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/future-renewals",u)},getJournal({currency:e=null,bookedFrom:s=null,bookedTo:n=null,recognizedAt:r=null,aggregationField:u=null,limit:o=null,offset:l=null,filter:a=null}){const p={currency:e,bookedFrom:s,bookedTo:n,recognizedAt:r,aggregationField:u,limit:o,offset:l,filter:a};return t.get("reports/journal",p)},getJournalSummary({periodStart:e=null,periodEnd:s=null,currency:n=null,aggregationField:r=null,amountField:u=null,journalAccountIds:o=null}){const l={periodStart:e,periodEnd:s,currency:n,aggregationField:r,amountField:u,journalAccountIds:o};return t.get("reports/journal-summary",l)},getKycAcceptanceSummary({periodStart:e=null,periodEnd:s=null}){const n={periodStart:e,periodEnd:s};return t.get("reports/kyc-acceptance-summary",n)},getKycRejectionSummary({periodStart:e=null,periodEnd:s=null}){const n={periodStart:e,periodEnd:s};return t.get("reports/kyc-rejection-summary",n)},getKycRequestSummary({periodStart:e=null,periodEnd:s=null}){const n={periodStart:e,periodEnd:s};return t.get("reports/kyc-request-summary",n)},getMonthlyRecurringRevenue({currency:e,periodStart:s,periodEnd:n,limit:r=null,offset:u=null}){const o={currency:e,periodStart:s,periodEnd:n,limit:r,offset:u};return t.get("reports/monthly-recurring-revenue",o)},getAnnualRecurringRevenue({currency:e,periodStart:s,periodEnd:n,limit:r=null,offset:u=null}){const o={currency:e,periodStart:s,periodEnd:n,limit:r,offset:u};return t.get("reports/annual-recurring-revenue",o)},getRenewalSales({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/renewal-sales",u)},getRetentionPercentage({aggregationField:e=null,aggregationPeriod:s=null,includeSwitchedSubscriptions:n=null,periodStart:r=null,periodEnd:u=null,limit:o=null,offset:l=null,filter:a=null,criteria:p=null}){const k={aggregationField:e,aggregationPeriod:s,includeSwitchedSubscriptions:n,periodStart:r,periodEnd:u,limit:o,offset:l,filter:a,criteria:p};return t.get("reports/retention-percentage",k)},getRetentionValue({aggregationField:e=null,aggregationPeriod:s=null,includeRefunds:n=null,includeDisputes:r=null,periodStart:u=null,periodEnd:o=null,limit:l=null,offset:a=null,filter:p=null,sort:k=null,criteria:j=null}){const D={aggregationField:e,aggregationPeriod:s,includeRefunds:n,includeDisputes:r,periodStart:u,periodEnd:o,limit:l,offset:a,filter:p,sort:k,criteria:j};return t.get("reports/retention-value",D)},getRevenueWaterfall({currency:e,issuedFrom:s=null,issuedTo:n=null,recognizedTo:r=null}){const u={currency:e,issuedFrom:s,issuedTo:n,recognizedTo:r};return t.get("reports/revenue-waterfall",u)},getSubscriptionCancellation({periodStart:e=null,periodEnd:s=null,aggregationField:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={periodStart:e,periodEnd:s,aggregationField:n,limit:r,offset:u,filter:o};return t.get("reports/subscription-cancellation",l)},getSubscriptionRenewal({periodStart:e=null,periodEnd:s=null,limit:n=null,offset:r=null}){const u={periodStart:e,periodEnd:s,limit:n,offset:r};return t.get("reports/subscription-renewal",u)},getTax({periodStart:e=null,periodEnd:s=null,accountingMethod:n=null,limit:r=null,offset:u=null}){const o={periodStart:e,periodEnd:s,accountingMethod:n,limit:r,offset:u};return t.get("reports/tax",o)},getTimeSeriesTransaction({type:e=null,subaggregate:s=null,periodStart:n=null,periodEnd:r=null,limit:u=null,offset:o=null}){const l={type:e,subaggregate:s,periodStart:n,periodEnd:r,limit:u,offset:o};return t.get("reports/time-series-transaction",l)},getTransactionsTimeDispute({aggregationField:e=null,periodStart:s=null,periodEnd:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={aggregationField:e,periodStart:s,periodEnd:n,limit:r,offset:u,filter:o};return t.get("reports/transactions-time-dispute",l)},getTransactions({periodStart:e=null,periodEnd:s=null,aggregationField:n=null,limit:r=null,offset:u=null,filter:o=null}){const l={periodStart:e,periodEnd:s,aggregationField:n,limit:r,offset:u,filter:o};return t.get("reports/transactions",l)}}}function vs({apiHandler:t}){return{getSubscriptionSummaryMetrics({subscriptionId:e}){return t.get(`subscriptions/${e}/summary-metrics`)}}}function qs({apiHandler:t}){return{getActivityFeed({eventTypes:e=null,limit:s=1e3,offset:n=0}){const r={eventTypes:e,limit:s,offset:n};return t.getAll("activity-feed",r)},getTransaction({id:e="",eventTypes:s=null,limit:n=1e3,offset:r=0}){const u={eventTypes:s,limit:n,offset:r};return t.getAll(`transactions/${e}/timeline`,u)},getCustomer({id:e="",eventTypes:s=null,limit:n=1e3,offset:r=0}){const u={eventTypes:s,limit:n,offset:r};return t.getAll(`customers/${e}/timeline`,u)}}}function Ts({apiHandler:t}){return{query(){return t.get("location")}}}const w={CustomersResource:Rs,DataExportsResource:bs,HistogramsResource:ws,ReportsResource:ks,SubscriptionsResource:vs,TimelinesResource:qs,LocationResource:Ts};class ds{constructor({apiHandler:e}){this.customers=w.CustomersResource({apiHandler:e}),this.dataExports=w.DataExportsResource({apiHandler:e}),this.histograms=w.HistogramsResource({apiHandler:e}),this.reports=w.ReportsResource({apiHandler:e}),this.subscriptions=w.SubscriptionsResource({apiHandler:e}),this.timelines=w.TimelinesResource({apiHandler:e}),this.location=w.LocationResource({apiHandler:e}),this.addRequestInterceptor=e.addRequestInterceptor,this.removeRequestInterceptor=e.removeRequestInterceptor,this.addResponseInterceptor=e.addResponseInterceptor,this.removeResponseInterceptor=e.removeResponseInterceptor,this.setTimeout=e.setTimeout,this.setProxyAgent=e.setProxyAgent,this.setSessionToken=e.setSessionToken,this.setEndpoints=e.setEndpoints,this.getCancellationToken=e.getCancellationToken}}function Is({apiHandler:t}){return{get({expand:e=null}={}){const s={expand:e};return t.get("account",s)},update({data:e}){return t.patch("account",e)},requestPasswordReset({data:e}){return t.post("account/forgot-password",e)},changePassword({data:e}){return t.patch("account/password",e)},resendEmailVerification({data:e}){return t.post("account/resend-verification",e)},confirmPasswordReset({token:e,data:s}){return t.post(`account/reset-password/${e}`,s)},verifyEmail({token:e}){return t.post(`account/verification/${e}`)},register({data:e}){return t.post("register",e)}}}function Ss({apiHandler:t}){return{login({data:e}){return t.post("login",e)},logout(){return t.post("logout")}}}function Es({apiHandler:t}){return{get({slug:e}){return t.get(`billing-portals/${e}`)}}}function xs({apiHandler:t}){return{get({id:e}){return t.get(`cashiers/${e}`)},cancelPayoutRequests({id:e,data:s}){return t.post(`cashiers/${e}/cancel-payout-requests`,s)}}}function Ps({apiHandler:t}){return{get({id:e}){return t.get(`checkout-forms/${e}`)}}}function Cs({apiHandler:t}){return{getAll({resource:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.getAll(`custom-fields/${e}`,r)}}}function js({apiHandler:t}){return{get({id:e,expand:s=null}){const n={expand:s};return t.get(`deposit-requests/${e}`,n)}}}function Ds({apiHandler:t}){return{create({data:e}){return t.post("deposit",e)}}}function Ms({apiHandler:t}){return{get({id:e}){return t.get(`deposit-strategies/${e}`)}}}function Os({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("invoices",l)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`invoices/${e}`,n)},update({id:e,data:s}){return t.patch(`invoices/${e}`,s)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`invoices/${e}`,s)}}}function Fs({apiHandler:t}){return{getAll({limit:e=null,offset:s=null}={}){const n={limit:e,offset:s};return t.getAll("kyc-documents",n)},create({data:e}){return t.post("kyc-documents",e)},get({id:e}){return t.get(`kyc-documents/${e}`)},update({id:e,data:s}){return t.patch(`kyc-documents/${e}`,s)}}}function Bs({apiHandler:t}){return{create({data:e}){return t.post("kyc-liveness-sessions",e)},get({id:e}){return t.get(`kyc-liveness-sessions/${e}`)},finish({id:e}){return t.post(`kyc-liveness-sessions/${e}/finish`)}}}function Ks({apiHandler:t}){return{get({id:e,expand:s=null}){const n={expand:s};return t.get(`kyc-requests/${e}`,n)}}}function Ns({apiHandler:t}){return{getUpcomingInvoice({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}/upcoming-invoice`,n)},getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("orders",l)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`orders/${e}`,n)},update({id:e,data:s}){return t.patch(`orders/${e}`,s)},cancel({id:e,data:s}){return t.post(`orders/${e}/cancellation`,s)},pause({id:e,data:s}){return t.post(`orders/${e}/pause`,s)}}}function Ls({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("payment-instruments",o)},create({data:e}){return t.post("payment-instruments",e)},get({id:e,limit:s=null,offset:n=null}){const r={limit:s,offset:n};return t.get(`payment-instruments/${e}`,r)},update({id:e,data:s}){return t.patch(`payment-instruments/${e}`,s)},deactivate({id:e}){return t.post(`payment-instruments/${e}/deactivation`)},getSetupTransaction({id:e}){return t.get(`payment-instruments/${e}/setup`)},setup({id:e,data:s}){return t.post(`payment-instruments/${e}/setup`,s)}}}function zs({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("payout-requests",o)},create({data:e}){return t.post("payout-requests",e)},get({id:e}){return t.get(`payout-requests/${e}`)},update({id:e,data:s}){return t.patch(`payout-requests/${e}`,s)}}}function Us({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null,expand:o=null}={}){const l={filter:e,sort:s,limit:n,offset:r,q:u,expand:o};return t.getAll("plans",l)},get({id:e,expand:s=null}){const n={expand:s};return t.get(`plans/${e}`,n)}}}function Vs({apiHandler:t}){return{getAll({filter:e=null,sort:s=null,limit:n=null,offset:r=null,q:u=null}={}){const o={filter:e,sort:s,limit:n,offset:r,q:u};return t.getAll("products",o)},get({id:e}){return t.get(`products/${e}`)}}}function Js({apiHandler:t}){return{payment({data:e}){return t.post("payment",e)},purchase({data:e}){return t.post("purchase",e)},preview({data:e}){return t.post("preview-purchase",e)},readyToPay({data:e}){return t.post("ready-to-pay",e)}}}function Ws({apiHandler:t}){return{get({id:e,expand:s=null}){const n={expand:s};return t.get(`quotes/${e}`,n)},accept({id:e}){return t.post(`quotes/${e}/accept`)},reject({id:e}){return t.post(`quotes/${e}/reject`)},downloadPDF({id:e}){const s={headers:I,responseType:"arraybuffer"};return t.download(`quotes/${e}`,s)}}}function Gs({apiHandler:t}){return{readyToPayout({data:e}){return t.post("ready-to-payout",e)}}}function Ys({apiHandler:t}){return{reactivation({data:e}){return t.post("subscription-reactivations",e)}}}function Qs({apiHandler:t}){return{changeItems({id:e,data:s}){return t.post(`subscriptions/${e}/change-items`,s)},create({data:e}){return t.post("subscriptions",e)}}}function _s({apiHandler:t}){return{getAll({limit:e=null,offset:s=null,filter:n=null,q:r=null,sort:u=null}={}){const o={limit:e,offset:s,filter:n,q:r,sort:u};return t.getAll("transactions",o)},get({id:e}){return t.get(`transactions/${e}`)},getDcc({id:e}){return t.get(`transactions/${e}/dcc`)},updateDcc({id:e,data:s}){return t.patch(`transactions/${e}/dcc`,s)},finishKyc({id:e,token:s}){return t.post(`transactions/${e}/${s}/continue`)},skipKyc({id:e,token:s}){return t.post(`transactions/${e}/${s}/bypass`)},update({id:e,data:s}){return t.patch(`transactions/${e}`,s)}}}function Xs({apiHandler:t}){return{get({id:e}){return t.get(`websites/${e}`)}}}class Zs{constructor({apiHandler:e}){this.account=Is({apiHandler:e}),this.authorization=Ss({apiHandler:e}),this.billingPortals=Es({apiHandler:e}),this.cashiers=xs({apiHandler:e}),this.checkoutForms=Ps({apiHandler:e}),this.customFields=Cs({apiHandler:e}),this.depositRequests=js({apiHandler:e}),this.deposit=Ds({apiHandler:e}),this.depositStrategies=Ms({apiHandler:e}),this.invoices=Os({apiHandler:e}),this.kycDocuments=Fs({apiHandler:e}),this.kycLivenessSessions=Bs({apiHandler:e}),this.kycRequests=Ks({apiHandler:e}),this.orders=Ns({apiHandler:e}),this.paymentInstruments=Ls({apiHandler:e}),this.payoutRequests=zs({apiHandler:e}),this.plans=Us({apiHandler:e}),this.products=Vs({apiHandler:e}),this.purchase=Js({apiHandler:e}),this.quotes=Ws({apiHandler:e}),this.readyToPayout=Gs({apiHandler:e}),this.subscriptionReactivations=Ys({apiHandler:e}),this.subscriptions=Qs({apiHandler:e}),this.transactions=_s({apiHandler:e}),this.websites=Xs({apiHandler:e}),this.checkoutForm=this.checkoutForms,this.billingPortal=this.billingPortals,this.addRequestInterceptor=e.addRequestInterceptor,this.removeRequestInterceptor=e.removeRequestInterceptor,this.addResponseInterceptor=e.addResponseInterceptor,this.removeResponseInterceptor=e.removeResponseInterceptor,this.setTimeout=e.setTimeout,this.setProxyAgent=e.setProxyAgent,this.setSessionToken=e.setSessionToken,this.setPublishableKey=e.setPublishableKey,this.setEndpoints=e.setEndpoints,this.getCancellationToken=e.getCancellationToken,this.generateSignature=e.generateSignature}}function Hs({apiHandler:t}){return new As({apiHandler:t})}function en({apiHandler:t}){return new ds({apiHandler:t})}function tn({apiHandler:t}){return new Zs({apiHandler:t})}const P={live:"https://api.rebilly.com",sandbox:"https://api-sandbox.rebilly.com"},C=6e3;function U({apiKey:t=null,sandbox:e=!1,timeout:s=C,organizationId:n=null,urls:r=P,internalOptions:u=null}={}){if(!r.live||!r.sandbox)throw new Error("RebillyAPI urls config must include a key for both `live` and `sandbox`");if(typeof r.live!="string"||typeof r.sandbox!="string")throw new Error("RebillyAPI urls config `live` and `sandbox` must be strings");const o={apiEndpoints:r,apiKey:t,apiVersion:"",isSandbox:e,requestTimeout:s,jwt:null,organizationId:n,appName:(u==null?void 0:u.appName)??null},l=x({options:o});return Hs({apiHandler:l})}function sn({apiKey:t=null,sandbox:e=!1,timeout:s=C,organizationId:n=null,urls:r=P,internalOptions:u=null}={}){if(!r.live||!r.sandbox)throw new Error("RebillyAPI urls config must include a key for both `live` and `sandbox`");if(typeof r.live!="string"||typeof r.sandbox!="string")throw new Error("RebillyAPI urls config `live` and `sandbox` must be strings");const o={apiEndpoints:r,apiKey:t,apiVersion:"experimental",isSandbox:e,requestTimeout:s,jwt:null,organizationId:n,appName:(u==null?void 0:u.appName)??null},l=x({options:o});return en({apiHandler:l})}function nn({publishableKey:t=null,jwt:e=null,sandbox:s=!1,timeout:n=C,organizationId:r=null,urls:u=P,internalOptions:o=null}={}){if(!u.live||!u.sandbox)throw new Error("RebillyAPI urls config must include a key for both `live` and `sandbox`");if(typeof u.live!="string"||typeof u.sandbox!="string")throw new Error("RebillyAPI urls config `live` and `sandbox` must be strings");const l={apiEndpoints:u,publishableKey:t,jwt:e,apiVersion:"storefront",isSandbox:s,requestTimeout:n,organizationId:r,appName:(o==null?void 0:o.appName)??null},a=x({options:l});return a.setSessionToken(l.jwt),tn({apiHandler:a})}m.RebillyAPI=U,m.RebillyErrors=h,m.RebillyExperimentalAPI=sn,m.RebillyStorefrontAPI=nn,m.cancellation=Ne,m.default=U,Object.defineProperties(m,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rebilly-js-sdk",
3
- "version": "62.69.0",
3
+ "version": "62.71.0",
4
4
  "description": "Official Rebilly API JS library for the browser and Node",
5
5
  "types": "./dist/rebilly-js-sdk.d.ts",
6
6
  "main": "./dist/rebilly-js-sdk.umd.js",