@checkoutpage/sdk 0.1.2 → 0.1.12

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/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- interface CheckoutPageClientOptions {
1
+ interface CheckoutPageApiClientOptions {
2
2
  apiKey: string;
3
3
  baseUrl?: string;
4
4
  }
@@ -8,18 +8,503 @@ interface RequestOptions {
8
8
  body?: unknown;
9
9
  query?: Record<string, string | number | boolean | undefined>;
10
10
  }
11
- declare class CheckoutPageClient {
11
+ declare class CheckoutPageApiClient {
12
12
  private readonly apiKey;
13
13
  private readonly baseUrl;
14
- constructor(options: CheckoutPageClientOptions);
14
+ constructor(options: CheckoutPageApiClientOptions);
15
15
  request<T>(options: RequestOptions): Promise<T>;
16
16
  private buildUrl;
17
17
  private handleResponse;
18
18
  private extractErrorMessage;
19
19
  }
20
20
 
21
+ interface components {
22
+ schemas: {
23
+ /** NotFoundResponse */
24
+ NotFoundResponse: {
25
+ message: string;
26
+ };
27
+ /** Ticket */
28
+ Ticket: Record<string, never>;
29
+ /** @example 6812fe6e9f39b6760576f01c */
30
+ PageId: string;
31
+ /** @example 6812fe6e9f39b6760576f01c */
32
+ TicketId: string;
33
+ /** @example 6812fe6e9f39b6760576f01c */
34
+ CustomerId: string;
35
+ /** @example 6812fe6e9f39b6760576f01c */
36
+ SellerId: string;
37
+ /** @example 6812fe6e9f39b6760576f01c */
38
+ ChargeId: string;
39
+ /** @example 6812fe6e9f39b6760576f01c */
40
+ SubscriptionId: string;
41
+ /** @example 6812fe6e9f39b6760576f01c */
42
+ SubscriptionPaymentId: string;
43
+ /** @example 6812fe6e9f39b6760576f01c */
44
+ ApiKeyId: string;
45
+ Booking: {
46
+ id: string;
47
+ orderId?: string;
48
+ orderStatus?: string;
49
+ customerEmail?: string;
50
+ customerId?: string;
51
+ sellerId?: string;
52
+ pageId?: string;
53
+ currency?: string;
54
+ /** @description The total amount intended to be collected. */
55
+ amount: number;
56
+ /** @description The amount of money paid toward the total. */
57
+ amountPaid?: number;
58
+ /** @description The outstanding amount of money to be paid. */
59
+ amountDue?: number;
60
+ amountUsd?: number;
61
+ amountExcludingTax?: number;
62
+ taxAmount?: number;
63
+ taxBreakdown: {
64
+ taxType?: string;
65
+ taxabilityReason?: string;
66
+ taxableAmount?: number;
67
+ taxAmount?: number;
68
+ taxRateDetails?: {
69
+ country?: string;
70
+ percentageDecimal?: number;
71
+ state?: string;
72
+ taxType?: string;
73
+ };
74
+ }[];
75
+ stripeTaxCalculationId?: string;
76
+ stripeTaxTransactionId?: string;
77
+ dynamicPrice?: number;
78
+ fees?: {
79
+ name?: string;
80
+ amount?: number;
81
+ percentage?: number;
82
+ }[];
83
+ billing?: {
84
+ name?: string;
85
+ companyName?: string;
86
+ email?: string;
87
+ billingEmail?: string;
88
+ phone?: string;
89
+ address?: {
90
+ line1?: string;
91
+ line2?: string;
92
+ city?: string;
93
+ state?: string;
94
+ postalCode?: string;
95
+ country?: string;
96
+ };
97
+ };
98
+ shipping?: {
99
+ name?: string;
100
+ phone?: string;
101
+ address?: {
102
+ line1?: string;
103
+ line2?: string;
104
+ city?: string;
105
+ state?: string;
106
+ postalCode?: string;
107
+ country?: string;
108
+ };
109
+ };
110
+ fields?: {
111
+ fieldId?: string;
112
+ label?: string;
113
+ value?: string;
114
+ /** @enum {string} */
115
+ element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
116
+ /** @enum {string} */
117
+ type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
118
+ meta?: string;
119
+ reference?: string;
120
+ }[];
121
+ coupon?: {
122
+ id?: string;
123
+ label?: string;
124
+ code?: string;
125
+ amountOff?: number;
126
+ percentOff?: number;
127
+ discount?: number;
128
+ };
129
+ discount?: {
130
+ minQuantity?: number;
131
+ maxQuantity?: number;
132
+ percentOff?: number;
133
+ amountOff?: number;
134
+ amount?: number;
135
+ };
136
+ livemode?: boolean;
137
+ /** @enum {string} */
138
+ status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
139
+ paymentError?: string;
140
+ paymentMethod?: {
141
+ /** @enum {string} */
142
+ gateway?: "stripe" | "paypal" | "manual";
143
+ method?: string;
144
+ wallet?: string;
145
+ /** @enum {string} */
146
+ mode?: "default" | "express";
147
+ brand?: string;
148
+ last4?: string;
149
+ country?: string;
150
+ exp_month?: number;
151
+ exp_year?: number;
152
+ funding?: string;
153
+ };
154
+ paymentOption?: {
155
+ /** @enum {string} */
156
+ type?: "manual" | "partial" | "full";
157
+ name?: string;
158
+ description?: string;
159
+ instructions?: string;
160
+ partialAmount?: number;
161
+ /** @enum {string} */
162
+ manualType?: "invoice" | "cash_on_delivery";
163
+ };
164
+ locale?: string;
165
+ sessionId?: string;
166
+ userAgent?: string;
167
+ screenWidth?: number;
168
+ visitId?: string;
169
+ queryParameters?: {
170
+ [key: string]: string;
171
+ };
172
+ stripePaymentIntentId?: string;
173
+ stripePaymentIntentClientSecret?: string;
174
+ stripeChargeId?: string;
175
+ upsell?: boolean;
176
+ upsellPageId?: string;
177
+ upsellChargeId?: string;
178
+ upsellSubscriptionId?: string;
179
+ invoiceId?: string;
180
+ transactionIds?: string[];
181
+ /** @description The date this was canceled. */
182
+ canceledAt?: string;
183
+ /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
184
+ canceledBy?: string;
185
+ /** @description The reason for the cancellation */
186
+ canceledReason?: string;
187
+ isAbandoned?: boolean;
188
+ /**
189
+ * Format: date-time
190
+ * @description The date at which the customer recovered their checkout through cart abandonment.
191
+ */
192
+ recoveredAt?: string;
193
+ /** @enum {string} */
194
+ abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "skipped";
195
+ /** Format: date-time */
196
+ abandonedCartEmailSentAt?: string;
197
+ /** Format: date-time */
198
+ createdAt: string;
199
+ /** Format: date-time */
200
+ updatedAt: string;
201
+ tickets?: {
202
+ name?: string;
203
+ ticketTypeId?: string;
204
+ capacity?: number;
205
+ reference?: string;
206
+ ticketGroupId?: string;
207
+ ticketGroupName?: string;
208
+ ticketGroupCapacity?: number;
209
+ ticketGroupReference?: string;
210
+ quantity?: number;
211
+ price?: number;
212
+ originalPrice?: number;
213
+ bookingFeeAmount?: number;
214
+ discount?: {
215
+ minQuantity?: number;
216
+ maxQuantity?: number;
217
+ percentOff?: number;
218
+ amountOff?: number;
219
+ amount?: number;
220
+ };
221
+ }[];
222
+ };
223
+ Customer: {
224
+ id: string;
225
+ name?: string;
226
+ companyName?: string;
227
+ email: string;
228
+ phone?: string;
229
+ billingEmail?: string;
230
+ address?: {
231
+ line1?: string;
232
+ line2?: string;
233
+ city?: string;
234
+ state?: string;
235
+ postalCode?: string;
236
+ country?: string;
237
+ };
238
+ shipping?: {
239
+ name?: string;
240
+ phone?: string;
241
+ address?: {
242
+ line1?: string;
243
+ line2?: string;
244
+ city?: string;
245
+ state?: string;
246
+ postalCode?: string;
247
+ country?: string;
248
+ };
249
+ };
250
+ taxId?: string;
251
+ taxIdType?: string;
252
+ sellerId: string;
253
+ stripeCustomerId?: string;
254
+ /** Format: date-time */
255
+ createdAt: string;
256
+ /** Format: date-time */
257
+ updatedAt: string;
258
+ };
259
+ Coupon: {
260
+ id: string;
261
+ label: string;
262
+ code: string;
263
+ amountOff?: number | null;
264
+ percentOff?: number | null;
265
+ appliesToSetupFee?: boolean;
266
+ /** @enum {string} */
267
+ duration: "once" | "repeating" | "forever";
268
+ durationInMonths?: number;
269
+ /** Format: date-time */
270
+ redeemBy?: string;
271
+ maxRedemptions?: number;
272
+ timesRedeemed: number;
273
+ currency?: string;
274
+ /** @example false */
275
+ deleted: boolean;
276
+ sellerId: string;
277
+ pageIds?: string[];
278
+ stripeCouponId?: string;
279
+ /** Format: date-time */
280
+ createdAt: string;
281
+ /** Format: date-time */
282
+ updatedAt: string;
283
+ };
284
+ Payment: {
285
+ id: string;
286
+ orderId?: string;
287
+ orderStatus?: string;
288
+ customerEmail?: string;
289
+ customerId?: string;
290
+ sellerId?: string;
291
+ pageId?: string;
292
+ currency?: string;
293
+ /** @description The total amount intended to be collected. */
294
+ amount: number;
295
+ /** @description The amount of money paid toward the total. */
296
+ amountPaid?: number;
297
+ /** @description The outstanding amount of money to be paid. */
298
+ amountDue?: number;
299
+ amountUsd?: number;
300
+ amountExcludingTax?: number;
301
+ taxAmount?: number;
302
+ taxBreakdown: {
303
+ taxType?: string;
304
+ taxabilityReason?: string;
305
+ taxableAmount?: number;
306
+ taxAmount?: number;
307
+ taxRateDetails?: {
308
+ country?: string;
309
+ percentageDecimal?: number;
310
+ state?: string;
311
+ taxType?: string;
312
+ };
313
+ }[];
314
+ stripeTaxCalculationId?: string;
315
+ stripeTaxTransactionId?: string;
316
+ dynamicPrice?: number;
317
+ fees?: {
318
+ name?: string;
319
+ amount?: number;
320
+ percentage?: number;
321
+ }[];
322
+ billing?: {
323
+ name?: string;
324
+ companyName?: string;
325
+ email?: string;
326
+ billingEmail?: string;
327
+ phone?: string;
328
+ address?: {
329
+ line1?: string;
330
+ line2?: string;
331
+ city?: string;
332
+ state?: string;
333
+ postalCode?: string;
334
+ country?: string;
335
+ };
336
+ };
337
+ shipping?: {
338
+ name?: string;
339
+ phone?: string;
340
+ address?: {
341
+ line1?: string;
342
+ line2?: string;
343
+ city?: string;
344
+ state?: string;
345
+ postalCode?: string;
346
+ country?: string;
347
+ };
348
+ };
349
+ fields?: {
350
+ fieldId?: string;
351
+ label?: string;
352
+ value?: string;
353
+ /** @enum {string} */
354
+ element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
355
+ /** @enum {string} */
356
+ type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
357
+ meta?: string;
358
+ reference?: string;
359
+ }[];
360
+ coupon?: {
361
+ id?: string;
362
+ label?: string;
363
+ code?: string;
364
+ amountOff?: number;
365
+ percentOff?: number;
366
+ discount?: number;
367
+ };
368
+ discount?: {
369
+ minQuantity?: number;
370
+ maxQuantity?: number;
371
+ percentOff?: number;
372
+ amountOff?: number;
373
+ amount?: number;
374
+ };
375
+ livemode?: boolean;
376
+ /** @enum {string} */
377
+ status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
378
+ paymentError?: string;
379
+ paymentMethod?: {
380
+ /** @enum {string} */
381
+ gateway?: "stripe" | "paypal" | "manual";
382
+ method?: string;
383
+ wallet?: string;
384
+ /** @enum {string} */
385
+ mode?: "default" | "express";
386
+ brand?: string;
387
+ last4?: string;
388
+ country?: string;
389
+ exp_month?: number;
390
+ exp_year?: number;
391
+ funding?: string;
392
+ };
393
+ paymentOption?: {
394
+ /** @enum {string} */
395
+ type?: "manual" | "partial" | "full";
396
+ name?: string;
397
+ description?: string;
398
+ instructions?: string;
399
+ partialAmount?: number;
400
+ /** @enum {string} */
401
+ manualType?: "invoice" | "cash_on_delivery";
402
+ };
403
+ locale?: string;
404
+ sessionId?: string;
405
+ userAgent?: string;
406
+ screenWidth?: number;
407
+ visitId?: string;
408
+ queryParameters?: {
409
+ [key: string]: string;
410
+ };
411
+ stripePaymentIntentId?: string;
412
+ stripePaymentIntentClientSecret?: string;
413
+ stripeChargeId?: string;
414
+ upsell?: boolean;
415
+ upsellPageId?: string;
416
+ upsellChargeId?: string;
417
+ upsellSubscriptionId?: string;
418
+ invoiceId?: string;
419
+ transactionIds?: string[];
420
+ /** @description The date this was canceled. */
421
+ canceledAt?: string;
422
+ /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
423
+ canceledBy?: string;
424
+ /** @description The reason for the cancellation */
425
+ canceledReason?: string;
426
+ isAbandoned?: boolean;
427
+ /**
428
+ * Format: date-time
429
+ * @description The date at which the customer recovered their checkout through cart abandonment.
430
+ */
431
+ recoveredAt?: string;
432
+ /** @enum {string} */
433
+ abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "skipped";
434
+ /** Format: date-time */
435
+ abandonedCartEmailSentAt?: string;
436
+ /** Format: date-time */
437
+ createdAt: string;
438
+ /** Format: date-time */
439
+ updatedAt: string;
440
+ productId?: string;
441
+ productPrice?: number;
442
+ payWhatYouWantPrice?: number;
443
+ discountedFromPrice?: number;
444
+ setupFee?: number;
445
+ quantity?: number;
446
+ sku?: string;
447
+ variants?: {
448
+ name?: string;
449
+ variantId?: string;
450
+ reference?: string;
451
+ /** @enum {string} */
452
+ selectionType?: "single" | "multiple" | "quantity";
453
+ selectedOptions?: {
454
+ optionId?: string;
455
+ optionName?: string;
456
+ sku?: string;
457
+ quantity?: number;
458
+ additionalChargeAmount?: number;
459
+ originalAdditionalChargeAmount?: number;
460
+ discount?: {
461
+ minQuantity?: number;
462
+ maxQuantity?: number;
463
+ percentOff?: number;
464
+ amountOff?: number;
465
+ amount?: number;
466
+ };
467
+ }[];
468
+ }[];
469
+ licenseKeyId?: string;
470
+ };
471
+ };
472
+ responses: {
473
+ /** @description Resource not found */
474
+ NotFoundResponse: {
475
+ headers: {
476
+ [name: string]: unknown;
477
+ };
478
+ content: {
479
+ "application/json": components["schemas"]["NotFoundResponse"];
480
+ };
481
+ };
482
+ /** @description Resource not found */
483
+ Ticket: {
484
+ headers: {
485
+ [name: string]: unknown;
486
+ };
487
+ content: {
488
+ "application/json": components["schemas"]["Ticket"];
489
+ };
490
+ };
491
+ };
492
+ parameters: {
493
+ PageId: components["schemas"]["PageId"];
494
+ TicketId: components["schemas"]["TicketId"];
495
+ CustomerId: components["schemas"]["CustomerId"];
496
+ SellerId: components["schemas"]["SellerId"];
497
+ ChargeId: components["schemas"]["ChargeId"];
498
+ SubscriptionId: components["schemas"]["SubscriptionId"];
499
+ SubscriptionPaymentId: components["schemas"]["SubscriptionPaymentId"];
500
+ ApiKeyId: components["schemas"]["ApiKeyId"];
501
+ };
502
+ requestBodies: never;
503
+ headers: never;
504
+ pathItems: never;
505
+ }
21
506
  interface operations {
22
- "events/tickets/validate-qrcode": {
507
+ "events/validate": {
23
508
  parameters: {
24
509
  query?: never;
25
510
  header?: never;
@@ -39,7 +524,7 @@ interface operations {
39
524
  };
40
525
  };
41
526
  responses: {
42
- /** @description QR code validation successful */
527
+ /** @description Ticket validation successful */
43
528
  200: {
44
529
  headers: {
45
530
  [name: string]: unknown;
@@ -47,26 +532,66 @@ interface operations {
47
532
  content: {
48
533
  "application/json": {
49
534
  success: boolean;
50
- ticket: {
535
+ ticket: components["schemas"]["Ticket"] & {
51
536
  id: string;
52
- status: string;
53
- customerName: string;
537
+ sellerId: string;
538
+ chargeId: string;
539
+ pageId: string;
540
+ /** @enum {string} */
541
+ status: "PAID" | "CANCELED";
542
+ orderId: string;
543
+ customerName?: string;
54
544
  customerEmail: string;
545
+ ticketTypeId: string;
546
+ checkIns: {
547
+ /** @enum {string} */
548
+ method: "QRSCAN" | "MANUAL";
549
+ /** Format: date */
550
+ checkedInAt: string;
551
+ checkedInByUserId: string;
552
+ /** @enum {string} */
553
+ status: "UNCHECKEDIN" | "CHECKEDIN";
554
+ }[];
555
+ latestCheckIn?: {
556
+ /** @enum {string} */
557
+ method: "QRSCAN" | "MANUAL";
558
+ /** Format: date */
559
+ checkedInAt: string;
560
+ checkedInByUserId: string;
561
+ /** @enum {string} */
562
+ status: "UNCHECKEDIN" | "CHECKEDIN";
563
+ };
55
564
  ticketShortId: string;
56
565
  /** @enum {string} */
57
- checkInStatus?: "CHECKEDIN" | "UNCHECKEDIN";
566
+ checkInStatus?: "UNCHECKEDIN" | "CHECKEDIN";
567
+ originalPrice: number;
568
+ discountAmount: number;
569
+ feeAmount: number;
570
+ taxAmount: number;
571
+ couponAmount: number;
572
+ revenue: number;
573
+ currency?: string;
574
+ livemode: boolean;
575
+ metadata?: {
576
+ key: string;
577
+ value: string;
578
+ /** Format: date-time */
579
+ addedAt: string;
580
+ }[];
581
+ /** Format: date-time */
582
+ orderedAt: string;
583
+ /** Format: date-time */
584
+ canceledAt?: string;
585
+ /** Format: date-time */
586
+ createdAt: string;
587
+ /** Format: date-time */
588
+ updatedAt: string;
58
589
  };
59
- metadata?: {
60
- key: string;
61
- value: string;
62
- /** Format: date */
63
- addedAt: string;
64
- }[];
65
590
  message?: string;
66
591
  };
67
592
  };
68
593
  };
69
- /** @description Bad request - Invalid QR code format */
594
+ /** @description Bad request - Invalid QR code */
70
595
  400: {
71
596
  headers: {
72
597
  [name: string]: unknown;
@@ -110,14 +635,18 @@ interface operations {
110
635
  };
111
636
  };
112
637
  };
113
- "events/bookings/list": {
638
+ "events/bookings": {
114
639
  parameters: {
115
640
  query?: {
641
+ /** @description The number of results per page. Minimum value is 1 and maximum is 100. Defaults to 20. */
642
+ limit?: string;
643
+ /** @description A cursor value specifying the ObjectId of a resource to start before. Retrieves items that appear after this cursor in the list. Cannot be used together with ending_before. */
644
+ starting_after?: string;
645
+ /** @description A cursor value specifying the ObjectId of a resource to end after. Retrieves items that appear before this cursor in the list. Cannot be used together with starting_after. */
646
+ ending_before?: string;
116
647
  search?: string;
117
- status?: string;
648
+ status?: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
118
649
  pageId?: string;
119
- limit?: string;
120
- skip?: string;
121
650
  };
122
651
  header?: never;
123
652
  path?: never;
@@ -133,209 +662,8 @@ interface operations {
133
662
  content: {
134
663
  "application/json": {
135
664
  has_more: boolean;
136
- total?: number;
137
- data: {
138
- id: string;
139
- orderId?: string;
140
- orderStatus?: string;
141
- stripePaymentId?: string;
142
- customerEmail?: string;
143
- customerId?: string;
144
- sellerId?: string;
145
- pageId?: string;
146
- currency?: string;
147
- /** @description The total amount intended to be collected. */
148
- amount: number;
149
- /** @description The amount of money paid toward the total. */
150
- amountPaid?: number;
151
- /** @description The outstanding amount of money to be paid. */
152
- amountDue?: number;
153
- amountUsd?: number;
154
- amountExcludingTax?: number;
155
- taxAmount?: number;
156
- taxBreakdown: {
157
- taxType?: string;
158
- taxabilityReason?: string;
159
- taxableAmount?: number;
160
- taxAmount?: number;
161
- taxRateDetails?: {
162
- country?: string;
163
- percentageDecimal?: number;
164
- state?: string;
165
- taxType?: string;
166
- };
167
- }[];
168
- stripeTaxCalculationId?: string;
169
- stripeTaxTransactionId?: string;
170
- dynamicPrice?: number;
171
- feeAmount?: number;
172
- fee?: number;
173
- fees?: {
174
- name?: string;
175
- amount?: number;
176
- percentage?: number;
177
- }[];
178
- billing?: {
179
- name?: string;
180
- companyName?: string;
181
- email?: string;
182
- billingEmail?: string;
183
- phone?: string;
184
- address?: {
185
- line1?: string;
186
- line2?: string;
187
- city?: string;
188
- state?: string;
189
- postalCode?: string;
190
- country?: string;
191
- };
192
- };
193
- shipping?: {
194
- name?: string;
195
- phone?: string;
196
- address?: {
197
- line1?: string;
198
- line2?: string;
199
- city?: string;
200
- state?: string;
201
- postalCode?: string;
202
- country?: string;
203
- };
204
- };
205
- fields?: {
206
- fieldId?: string;
207
- label?: string;
208
- value?: string;
209
- /** @enum {string} */
210
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
211
- /** @enum {string} */
212
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
213
- meta?: string;
214
- reference?: string;
215
- }[];
216
- coupon?: {
217
- id?: string;
218
- label?: string;
219
- code?: string;
220
- amountOff?: number;
221
- percentOff?: number;
222
- discount?: number;
223
- };
224
- discount?: {
225
- minQuantity?: number;
226
- maxQuantity?: number;
227
- percentOff?: number;
228
- amountOff?: number;
229
- amount?: number;
230
- };
231
- livemode?: boolean;
232
- /** @enum {string} */
233
- status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
234
- paymentError?: string;
235
- /** @enum {string} */
236
- statusReason?: "api_connection_error" | "api_error" | "authentication_error" | "card_error" | "idempotency_error" | "invalid_request_error" | "rate_limit_error";
237
- paymentMethod?: {
238
- /** @enum {string} */
239
- gateway?: "stripe" | "paypal" | "manual";
240
- method?: string;
241
- wallet?: string;
242
- /** @enum {string} */
243
- mode?: "default" | "express";
244
- brand?: string;
245
- last4?: string;
246
- country?: string;
247
- exp_month?: number;
248
- exp_year?: number;
249
- funding?: string;
250
- };
251
- paymentOption?: {
252
- /** @enum {string} */
253
- type?: "manual" | "partial" | "full";
254
- name?: string;
255
- description?: string;
256
- instructions?: string;
257
- partialAmount?: number;
258
- /** @enum {string} */
259
- manualType?: "invoice" | "cash_on_delivery";
260
- };
261
- locale?: string;
262
- sessionId?: string;
263
- clientIp?: string;
264
- userAgent?: string;
265
- screenWidth?: number;
266
- visitId?: string;
267
- queryParameters?: {
268
- [key: string]: string;
269
- };
270
- stripePaymentIntentId?: string;
271
- stripePaymentIntentClientSecret?: string;
272
- upsell?: boolean;
273
- upsellPageId?: string;
274
- upsellChargeId?: string;
275
- upsellSubscriptionId?: string;
276
- invoiceId?: string;
277
- transactionIds?: string[];
278
- /** @description The date this was canceled. */
279
- canceledAt?: string;
280
- /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
281
- canceledBy?: string;
282
- /** @description The reason for the cancellation */
283
- reason?: string;
284
- isAbandoned?: boolean;
285
- /** Format: date-time */
286
- recoveredAt?: string;
287
- /** @enum {string} */
288
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
289
- /** Format: date-time */
290
- abandonedCartEmailSentAt?: string;
291
- /** Format: date-time */
292
- createdAt: string;
293
- /** Format: date-time */
294
- updatedAt: string;
295
- productId?: string;
296
- productPrice?: number;
297
- payWhatYouWantPrice?: number;
298
- discountedFromPrice?: number;
299
- setupFee?: number;
300
- quantity?: number;
301
- sku?: string;
302
- variants?: {
303
- name?: string;
304
- variantId?: string;
305
- reference?: string;
306
- /** @enum {string} */
307
- selectionType?: "single" | "multiple" | "quantity";
308
- sku?: string;
309
- selectedOptions?: {
310
- optionId?: string;
311
- optionName?: string;
312
- sku?: string;
313
- quantity?: number;
314
- additionalChargeAmount?: number;
315
- originalAdditionalChargeAmount?: number;
316
- discount?: {
317
- minQuantity?: number;
318
- maxQuantity?: number;
319
- percentOff?: number;
320
- amountOff?: number;
321
- amount?: number;
322
- };
323
- }[];
324
- additionalChargeAmount?: number;
325
- originalAdditionalChargeAmount?: number;
326
- selectedOptionName?: string;
327
- selectedOptionId?: string;
328
- selectedOptionQuantity?: number;
329
- selectedOptionDiscount?: {
330
- minQuantity?: number;
331
- maxQuantity?: number;
332
- percentOff?: number;
333
- amountOff?: number;
334
- amount?: number;
335
- };
336
- }[];
337
- licenseKeyId?: string;
338
- }[];
665
+ total: number;
666
+ data: components["schemas"]["Booking"][];
339
667
  };
340
668
  };
341
669
  };
@@ -376,42 +704,33 @@ interface operations {
376
704
  };
377
705
  };
378
706
  };
379
- "health/check": {
707
+ "customers/list": {
380
708
  parameters: {
381
- query?: never;
709
+ query?: {
710
+ /** @description The number of results per page. Minimum value is 1 and maximum is 100. Defaults to 20. */
711
+ limit?: string;
712
+ /** @description A cursor value specifying the ObjectId of a resource to start before. Retrieves items that appear after this cursor in the list. Cannot be used together with ending_before. */
713
+ starting_after?: string;
714
+ /** @description A cursor value specifying the ObjectId of a resource to end after. Retrieves items that appear before this cursor in the list. Cannot be used together with starting_after. */
715
+ ending_before?: string;
716
+ search?: string;
717
+ };
382
718
  header?: never;
383
719
  path?: never;
384
720
  cookie?: never;
385
721
  };
386
722
  requestBody?: never;
387
723
  responses: {
388
- /** @description API key health information retrieved successfully */
724
+ /** @description Customers retrieved successfully */
389
725
  200: {
390
726
  headers: {
391
727
  [name: string]: unknown;
392
728
  };
393
729
  content: {
394
730
  "application/json": {
395
- /** @enum {string} */
396
- status: "operational";
397
- apiKey: {
398
- id: string;
399
- name: string;
400
- permissions: string[];
401
- scopes: string[];
402
- isDeleted: boolean;
403
- usageCount: number;
404
- lastUsedAt: string | null;
405
- createdAt: string;
406
- expiresAt: string | null;
407
- keyPreview: string;
408
- };
409
- rateLimit: {
410
- requests: number;
411
- window: number;
412
- } | null;
413
- healthScore: number;
414
- warnings: string[];
731
+ has_more: boolean;
732
+ total: number;
733
+ data: components["schemas"]["Customer"][];
415
734
  };
416
735
  };
417
736
  };
@@ -436,13 +755,6 @@ interface operations {
436
755
  };
437
756
  content?: never;
438
757
  };
439
- /** @description API key not found */
440
- 404: {
441
- headers: {
442
- [name: string]: unknown;
443
- };
444
- content?: never;
445
- };
446
758
  /** @description Rate Limit Exceeded - Please try again later. */
447
759
  429: {
448
760
  headers: {
@@ -459,156 +771,25 @@ interface operations {
459
771
  };
460
772
  };
461
773
  };
462
- "customers/list": {
774
+ "customers/get": {
463
775
  parameters: {
464
- query?: {
465
- search?: string;
466
- limit?: string;
467
- skip?: string;
468
- };
776
+ query?: never;
469
777
  header?: never;
470
- path?: never;
778
+ path: {
779
+ customerId: string;
780
+ };
471
781
  cookie?: never;
472
782
  };
473
783
  requestBody?: never;
474
784
  responses: {
475
- /** @description Customers retrieved successfully */
785
+ /** @description Customer retrieved successfully */
476
786
  200: {
477
787
  headers: {
478
788
  [name: string]: unknown;
479
789
  };
480
790
  content: {
481
791
  "application/json": {
482
- has_more: boolean;
483
- total?: number;
484
- data: {
485
- id: string;
486
- name?: string;
487
- companyName?: string;
488
- email: string;
489
- phone?: string;
490
- billingEmail?: string;
491
- address?: {
492
- line1?: string;
493
- line2?: string;
494
- city?: string;
495
- state?: string;
496
- postalCode?: string;
497
- country?: string;
498
- };
499
- shipping?: {
500
- name?: string;
501
- phone?: string;
502
- address?: {
503
- line1?: string;
504
- line2?: string;
505
- city?: string;
506
- state?: string;
507
- postalCode?: string;
508
- country?: string;
509
- };
510
- };
511
- taxId?: string;
512
- taxIdType?: string;
513
- seller: string;
514
- stripeCustomerId?: string;
515
- /** Format: date-time */
516
- createdAt: string;
517
- /** Format: date-time */
518
- updatedAt: string;
519
- }[];
520
- };
521
- };
522
- };
523
- /** @description Bad request - Invalid request parameters */
524
- 400: {
525
- headers: {
526
- [name: string]: unknown;
527
- };
528
- content?: never;
529
- };
530
- /** @description Unauthorized - Missing or invalid API key */
531
- 401: {
532
- headers: {
533
- [name: string]: unknown;
534
- };
535
- content?: never;
536
- };
537
- /** @description Forbidden - Insufficient permissions or validation error */
538
- 403: {
539
- headers: {
540
- [name: string]: unknown;
541
- };
542
- content?: never;
543
- };
544
- /** @description Rate Limit Exceeded - Please try again later. */
545
- 429: {
546
- headers: {
547
- [name: string]: unknown;
548
- };
549
- content?: never;
550
- };
551
- /** @description Internal server error */
552
- 500: {
553
- headers: {
554
- [name: string]: unknown;
555
- };
556
- content?: never;
557
- };
558
- };
559
- };
560
- "customers/get": {
561
- parameters: {
562
- query?: never;
563
- header?: never;
564
- path: {
565
- customerId: string;
566
- };
567
- cookie?: never;
568
- };
569
- requestBody?: never;
570
- responses: {
571
- /** @description Customer retrieved successfully */
572
- 200: {
573
- headers: {
574
- [name: string]: unknown;
575
- };
576
- content: {
577
- "application/json": {
578
- id: string;
579
- name?: string;
580
- companyName?: string;
581
- email: string;
582
- phone?: string;
583
- billingEmail?: string;
584
- address?: {
585
- line1?: string;
586
- line2?: string;
587
- city?: string;
588
- state?: string;
589
- postalCode?: string;
590
- country?: string;
591
- };
592
- shipping?: {
593
- name?: string;
594
- phone?: string;
595
- address?: {
596
- line1?: string;
597
- line2?: string;
598
- city?: string;
599
- state?: string;
600
- postalCode?: string;
601
- country?: string;
602
- };
603
- };
604
- taxId?: string;
605
- taxIdType?: string;
606
- seller: string;
607
- stripeCustomerId?: string;
608
- /** Format: date-time */
609
- createdAt: string;
610
- /** Format: date-time */
611
- updatedAt: string;
792
+ data: components["schemas"]["Customer"];
612
793
  };
613
794
  };
614
795
  };
@@ -659,9 +840,13 @@ interface operations {
659
840
  "coupons/list": {
660
841
  parameters: {
661
842
  query?: {
662
- search?: string;
843
+ /** @description The number of results per page. Minimum value is 1 and maximum is 100. Defaults to 20. */
663
844
  limit?: string;
664
- skip?: string;
845
+ /** @description A cursor value specifying the ObjectId of a resource to start before. Retrieves items that appear after this cursor in the list. Cannot be used together with ending_before. */
846
+ starting_after?: string;
847
+ /** @description A cursor value specifying the ObjectId of a resource to end after. Retrieves items that appear before this cursor in the list. Cannot be used together with starting_after. */
848
+ ending_before?: string;
849
+ search?: string;
665
850
  };
666
851
  header?: never;
667
852
  path?: never;
@@ -677,31 +862,8 @@ interface operations {
677
862
  content: {
678
863
  "application/json": {
679
864
  has_more: boolean;
680
- total?: number;
681
- data: {
682
- id: string;
683
- label: string;
684
- code: string;
685
- amountOff?: number | null;
686
- percentOff?: number | null;
687
- appliesToSetupFee?: boolean;
688
- /** @enum {string} */
689
- duration: "once" | "repeating" | "forever";
690
- durationInMonths?: number;
691
- /** Format: date-time */
692
- redeemBy?: string;
693
- maxRedemptions?: number;
694
- timesRedeemed: number;
695
- currency?: string;
696
- deleted: boolean;
697
- sellerId: string;
698
- pageIds?: string[];
699
- stripeId?: string;
700
- /** Format: date-time */
701
- createdAt: string;
702
- /** Format: date-time */
703
- updatedAt: string;
704
- }[];
865
+ total: number;
866
+ data: components["schemas"]["Coupon"][];
705
867
  };
706
868
  };
707
869
  };
@@ -763,12 +925,12 @@ interface operations {
763
925
  */
764
926
  code: string;
765
927
  /**
766
- * @description A positive integer representing the amount to subtract from an invoice total (required if percent_off is not passed).
928
+ * @description A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).
767
929
  * @example 100
768
930
  */
769
931
  amountOff?: number;
770
932
  /**
771
- * @description Three-letter ISO code for the currency of the amountOff parameter (required if amountOff is passed).
933
+ * @description Three-letter ISO code for the currency of the amountOff parameter (required if `amountOff` is passed).
772
934
  * @example usd
773
935
  * @enum {string}
774
936
  */
@@ -776,11 +938,11 @@ interface operations {
776
938
  /** @enum {string} */
777
939
  duration: "once" | "repeating" | "forever";
778
940
  /**
779
- * @description A positive integer representing the number of months the coupon applies for (required if duration === repeating)
941
+ * @description A positive integer representing the number of months the coupon applies for (required if `duration === repeating`)
780
942
  * @example 3
781
943
  */
782
944
  durationInMonths?: number;
783
- /** @description A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if amount_off is not passed). */
945
+ /** @description A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed). */
784
946
  percentOff?: number;
785
947
  /**
786
948
  * @description Apply discount to setup fee
@@ -790,15 +952,9 @@ interface operations {
790
952
  /**
791
953
  * @description A list of pageIds that this coupon can be used within.
792
954
  * @example [
793
- * {
794
- * "description": "67ee075004de439ab0b675b6"
795
- * },
796
- * {
797
- * "description": "67fcbdac6a91c25ef2d3534a"
798
- * }
955
+ * "67ee075004de439ab0b675b6",
956
+ * "67fcbdac6a91c25ef2d3534a"
799
957
  * ]
800
- * @example 67ee075004de439ab0b675b6
801
- * @example 67fcbdac6a91c25ef2d3534a
802
958
  */
803
959
  pageIds?: string[];
804
960
  /**
@@ -823,28 +979,7 @@ interface operations {
823
979
  };
824
980
  content: {
825
981
  "application/json": {
826
- id: string;
827
- label: string;
828
- code: string;
829
- amountOff?: number | null;
830
- percentOff?: number | null;
831
- appliesToSetupFee?: boolean;
832
- /** @enum {string} */
833
- duration: "once" | "repeating" | "forever";
834
- durationInMonths?: number;
835
- /** Format: date-time */
836
- redeemBy?: string;
837
- maxRedemptions?: number;
838
- timesRedeemed: number;
839
- currency?: string;
840
- deleted: boolean;
841
- sellerId: string;
842
- pageIds?: string[];
843
- stripeId?: string;
844
- /** Format: date-time */
845
- createdAt: string;
846
- /** Format: date-time */
847
- updatedAt: string;
982
+ data: components["schemas"]["Coupon"];
848
983
  };
849
984
  };
850
985
  };
@@ -895,11 +1030,15 @@ interface operations {
895
1030
  "subscriptions/list": {
896
1031
  parameters: {
897
1032
  query?: {
1033
+ /** @description The number of results per page. Minimum value is 1 and maximum is 100. Defaults to 20. */
1034
+ limit?: string;
1035
+ /** @description A cursor value specifying the ObjectId of a resource to start before. Retrieves items that appear after this cursor in the list. Cannot be used together with ending_before. */
1036
+ starting_after?: string;
1037
+ /** @description A cursor value specifying the ObjectId of a resource to end after. Retrieves items that appear before this cursor in the list. Cannot be used together with starting_after. */
1038
+ ending_before?: string;
898
1039
  search?: string;
899
1040
  pageId?: string;
900
1041
  status?: string;
901
- limit?: string;
902
- skip?: string;
903
1042
  };
904
1043
  header?: never;
905
1044
  path?: never;
@@ -915,11 +1054,12 @@ interface operations {
915
1054
  content: {
916
1055
  "application/json": {
917
1056
  has_more: boolean;
918
- total?: number;
1057
+ total: number;
919
1058
  data: {
920
1059
  id: string;
921
1060
  orderId?: string;
922
- subscriptionId?: string;
1061
+ stripeSubscriptionId?: string;
1062
+ stripeCustomerId?: string;
923
1063
  customerEmail?: string;
924
1064
  currency?: string;
925
1065
  amount: number;
@@ -949,7 +1089,6 @@ interface operations {
949
1089
  productPrice?: number;
950
1090
  dynamicPrice?: number;
951
1091
  discountedFromPrice?: number;
952
- feePercentage?: number;
953
1092
  sku?: string;
954
1093
  billing?: {
955
1094
  name?: string;
@@ -1016,26 +1155,12 @@ interface operations {
1016
1155
  optionInvoiceItemId?: string;
1017
1156
  optionInvoiceItemPaid?: boolean;
1018
1157
  }[];
1019
- selectedOptionName?: string;
1020
- additionalChargeAmount?: number;
1021
- discountAmount?: number;
1022
1158
  fees?: {
1023
1159
  name?: string;
1024
1160
  amount?: number;
1025
1161
  percentage?: number;
1026
1162
  stripeInvoiceItemId?: string;
1027
1163
  }[];
1028
- additionalChargeAmountTotal?: number;
1029
- additionalChargeAmountUsd?: number;
1030
- sku?: string;
1031
- /** @enum {string} */
1032
- selectedOptionType?: "one_time" | "recurring";
1033
- selectedOptionId?: string;
1034
- selectedOptionQuantity?: number;
1035
- selectedOptionStripePriceId?: string;
1036
- selectedOptionStripeProductId?: string;
1037
- selectedOptionInvoiceItemId?: string;
1038
- selectedOptionInvoiceItemPaid?: boolean;
1039
1164
  }[];
1040
1165
  couponId?: string;
1041
1166
  licenseKeyId?: string;
@@ -1061,14 +1186,12 @@ interface operations {
1061
1186
  };
1062
1187
  locale?: string;
1063
1188
  sessionId?: string;
1064
- clientIp?: string;
1065
1189
  userAgent?: string;
1066
1190
  screenWidth?: number;
1067
1191
  visitId?: string;
1068
1192
  queryParameters?: {
1069
- key: string;
1070
- value: string;
1071
- }[];
1193
+ [key: string]: string;
1194
+ };
1072
1195
  stripePaymentIntentId?: string;
1073
1196
  stripePaymentIntentClientSecret?: string;
1074
1197
  stripeSetupIntentId?: string;
@@ -1089,8 +1212,6 @@ interface operations {
1089
1212
  upsellPageId?: string;
1090
1213
  upsellChargeId?: string;
1091
1214
  upsellSubscriptionId?: string;
1092
- stripeSubscriptionId?: string;
1093
- stripeCustomerId?: string;
1094
1215
  sellerId?: string;
1095
1216
  customerId?: string;
1096
1217
  pageId?: string;
@@ -1154,11 +1275,15 @@ interface operations {
1154
1275
  "payments/list": {
1155
1276
  parameters: {
1156
1277
  query?: {
1278
+ /** @description The number of results per page. Minimum value is 1 and maximum is 100. Defaults to 20. */
1279
+ limit?: string;
1280
+ /** @description A cursor value specifying the ObjectId of a resource to start before. Retrieves items that appear after this cursor in the list. Cannot be used together with ending_before. */
1281
+ starting_after?: string;
1282
+ /** @description A cursor value specifying the ObjectId of a resource to end after. Retrieves items that appear before this cursor in the list. Cannot be used together with starting_after. */
1283
+ ending_before?: string;
1157
1284
  search?: string;
1158
- status?: string;
1285
+ status?: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
1159
1286
  pageId?: string;
1160
- limit?: string;
1161
- skip?: string;
1162
1287
  };
1163
1288
  header?: never;
1164
1289
  path?: never;
@@ -1174,209 +1299,8 @@ interface operations {
1174
1299
  content: {
1175
1300
  "application/json": {
1176
1301
  has_more: boolean;
1177
- total?: number;
1178
- data: {
1179
- id: string;
1180
- orderId?: string;
1181
- orderStatus?: string;
1182
- stripePaymentId?: string;
1183
- customerEmail?: string;
1184
- customerId?: string;
1185
- sellerId?: string;
1186
- pageId?: string;
1187
- currency?: string;
1188
- /** @description The total amount intended to be collected. */
1189
- amount: number;
1190
- /** @description The amount of money paid toward the total. */
1191
- amountPaid?: number;
1192
- /** @description The outstanding amount of money to be paid. */
1193
- amountDue?: number;
1194
- amountUsd?: number;
1195
- amountExcludingTax?: number;
1196
- taxAmount?: number;
1197
- taxBreakdown: {
1198
- taxType?: string;
1199
- taxabilityReason?: string;
1200
- taxableAmount?: number;
1201
- taxAmount?: number;
1202
- taxRateDetails?: {
1203
- country?: string;
1204
- percentageDecimal?: number;
1205
- state?: string;
1206
- taxType?: string;
1207
- };
1208
- }[];
1209
- stripeTaxCalculationId?: string;
1210
- stripeTaxTransactionId?: string;
1211
- dynamicPrice?: number;
1212
- feeAmount?: number;
1213
- fee?: number;
1214
- fees?: {
1215
- name?: string;
1216
- amount?: number;
1217
- percentage?: number;
1218
- }[];
1219
- billing?: {
1220
- name?: string;
1221
- companyName?: string;
1222
- email?: string;
1223
- billingEmail?: string;
1224
- phone?: string;
1225
- address?: {
1226
- line1?: string;
1227
- line2?: string;
1228
- city?: string;
1229
- state?: string;
1230
- postalCode?: string;
1231
- country?: string;
1232
- };
1233
- };
1234
- shipping?: {
1235
- name?: string;
1236
- phone?: string;
1237
- address?: {
1238
- line1?: string;
1239
- line2?: string;
1240
- city?: string;
1241
- state?: string;
1242
- postalCode?: string;
1243
- country?: string;
1244
- };
1245
- };
1246
- fields?: {
1247
- fieldId?: string;
1248
- label?: string;
1249
- value?: string;
1250
- /** @enum {string} */
1251
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
1252
- /** @enum {string} */
1253
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
1254
- meta?: string;
1255
- reference?: string;
1256
- }[];
1257
- coupon?: {
1258
- id?: string;
1259
- label?: string;
1260
- code?: string;
1261
- amountOff?: number;
1262
- percentOff?: number;
1263
- discount?: number;
1264
- };
1265
- discount?: {
1266
- minQuantity?: number;
1267
- maxQuantity?: number;
1268
- percentOff?: number;
1269
- amountOff?: number;
1270
- amount?: number;
1271
- };
1272
- livemode?: boolean;
1273
- /** @enum {string} */
1274
- status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
1275
- paymentError?: string;
1276
- /** @enum {string} */
1277
- statusReason?: "api_connection_error" | "api_error" | "authentication_error" | "card_error" | "idempotency_error" | "invalid_request_error" | "rate_limit_error";
1278
- paymentMethod?: {
1279
- /** @enum {string} */
1280
- gateway?: "stripe" | "paypal" | "manual";
1281
- method?: string;
1282
- wallet?: string;
1283
- /** @enum {string} */
1284
- mode?: "default" | "express";
1285
- brand?: string;
1286
- last4?: string;
1287
- country?: string;
1288
- exp_month?: number;
1289
- exp_year?: number;
1290
- funding?: string;
1291
- };
1292
- paymentOption?: {
1293
- /** @enum {string} */
1294
- type?: "manual" | "partial" | "full";
1295
- name?: string;
1296
- description?: string;
1297
- instructions?: string;
1298
- partialAmount?: number;
1299
- /** @enum {string} */
1300
- manualType?: "invoice" | "cash_on_delivery";
1301
- };
1302
- locale?: string;
1303
- sessionId?: string;
1304
- clientIp?: string;
1305
- userAgent?: string;
1306
- screenWidth?: number;
1307
- visitId?: string;
1308
- queryParameters?: {
1309
- [key: string]: string;
1310
- };
1311
- stripePaymentIntentId?: string;
1312
- stripePaymentIntentClientSecret?: string;
1313
- upsell?: boolean;
1314
- upsellPageId?: string;
1315
- upsellChargeId?: string;
1316
- upsellSubscriptionId?: string;
1317
- invoiceId?: string;
1318
- transactionIds?: string[];
1319
- /** @description The date this was canceled. */
1320
- canceledAt?: string;
1321
- /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
1322
- canceledBy?: string;
1323
- /** @description The reason for the cancellation */
1324
- reason?: string;
1325
- isAbandoned?: boolean;
1326
- /** Format: date-time */
1327
- recoveredAt?: string;
1328
- /** @enum {string} */
1329
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
1330
- /** Format: date-time */
1331
- abandonedCartEmailSentAt?: string;
1332
- /** Format: date-time */
1333
- createdAt: string;
1334
- /** Format: date-time */
1335
- updatedAt: string;
1336
- productId?: string;
1337
- productPrice?: number;
1338
- payWhatYouWantPrice?: number;
1339
- discountedFromPrice?: number;
1340
- setupFee?: number;
1341
- quantity?: number;
1342
- sku?: string;
1343
- variants?: {
1344
- name?: string;
1345
- variantId?: string;
1346
- reference?: string;
1347
- /** @enum {string} */
1348
- selectionType?: "single" | "multiple" | "quantity";
1349
- sku?: string;
1350
- selectedOptions?: {
1351
- optionId?: string;
1352
- optionName?: string;
1353
- sku?: string;
1354
- quantity?: number;
1355
- additionalChargeAmount?: number;
1356
- originalAdditionalChargeAmount?: number;
1357
- discount?: {
1358
- minQuantity?: number;
1359
- maxQuantity?: number;
1360
- percentOff?: number;
1361
- amountOff?: number;
1362
- amount?: number;
1363
- };
1364
- }[];
1365
- additionalChargeAmount?: number;
1366
- originalAdditionalChargeAmount?: number;
1367
- selectedOptionName?: string;
1368
- selectedOptionId?: string;
1369
- selectedOptionQuantity?: number;
1370
- selectedOptionDiscount?: {
1371
- minQuantity?: number;
1372
- maxQuantity?: number;
1373
- percentOff?: number;
1374
- amountOff?: number;
1375
- amount?: number;
1376
- };
1377
- }[];
1378
- licenseKeyId?: string;
1379
- }[];
1302
+ total: number;
1303
+ data: components["schemas"]["Payment"][];
1380
1304
  };
1381
1305
  };
1382
1306
  };
@@ -1435,42 +1359,7 @@ interface operations {
1435
1359
  /** @enum {string} */
1436
1360
  event: "customer.created";
1437
1361
  data: {
1438
- customer: {
1439
- id: string;
1440
- name?: string;
1441
- companyName?: string;
1442
- email: string;
1443
- phone?: string;
1444
- billingEmail?: string;
1445
- address?: {
1446
- line1?: string;
1447
- line2?: string;
1448
- city?: string;
1449
- state?: string;
1450
- postalCode?: string;
1451
- country?: string;
1452
- };
1453
- shipping?: {
1454
- name?: string;
1455
- phone?: string;
1456
- address?: {
1457
- line1?: string;
1458
- line2?: string;
1459
- city?: string;
1460
- state?: string;
1461
- postalCode?: string;
1462
- country?: string;
1463
- };
1464
- };
1465
- taxId?: string;
1466
- taxIdType?: string;
1467
- seller: string;
1468
- stripeCustomerId?: string;
1469
- /** Format: date-time */
1470
- createdAt: string;
1471
- /** Format: date-time */
1472
- updatedAt: string;
1473
- };
1362
+ customer: components["schemas"]["Customer"];
1474
1363
  };
1475
1364
  };
1476
1365
  };
@@ -1503,42 +1392,7 @@ interface operations {
1503
1392
  /** @enum {string} */
1504
1393
  event: "customer.updated";
1505
1394
  data: {
1506
- customer: {
1507
- id: string;
1508
- name?: string;
1509
- companyName?: string;
1510
- email: string;
1511
- phone?: string;
1512
- billingEmail?: string;
1513
- address?: {
1514
- line1?: string;
1515
- line2?: string;
1516
- city?: string;
1517
- state?: string;
1518
- postalCode?: string;
1519
- country?: string;
1520
- };
1521
- shipping?: {
1522
- name?: string;
1523
- phone?: string;
1524
- address?: {
1525
- line1?: string;
1526
- line2?: string;
1527
- city?: string;
1528
- state?: string;
1529
- postalCode?: string;
1530
- country?: string;
1531
- };
1532
- };
1533
- taxId?: string;
1534
- taxIdType?: string;
1535
- seller: string;
1536
- stripeCustomerId?: string;
1537
- /** Format: date-time */
1538
- createdAt: string;
1539
- /** Format: date-time */
1540
- updatedAt: string;
1541
- };
1395
+ customer: components["schemas"]["Customer"];
1542
1396
  };
1543
1397
  };
1544
1398
  };
@@ -1571,1137 +1425,7 @@ interface operations {
1571
1425
  /** @enum {string} */
1572
1426
  event: "payment.created";
1573
1427
  data: {
1574
- payment: {
1575
- id: string;
1576
- orderId?: string;
1577
- orderStatus?: string;
1578
- stripePaymentId?: string;
1579
- customerEmail?: string;
1580
- customerId?: string;
1581
- sellerId?: string;
1582
- pageId?: string;
1583
- currency?: string;
1584
- /** @description The total amount intended to be collected. */
1585
- amount: number;
1586
- /** @description The amount of money paid toward the total. */
1587
- amountPaid?: number;
1588
- /** @description The outstanding amount of money to be paid. */
1589
- amountDue?: number;
1590
- amountUsd?: number;
1591
- amountExcludingTax?: number;
1592
- taxAmount?: number;
1593
- taxBreakdown: {
1594
- taxType?: string;
1595
- taxabilityReason?: string;
1596
- taxableAmount?: number;
1597
- taxAmount?: number;
1598
- taxRateDetails?: {
1599
- country?: string;
1600
- percentageDecimal?: number;
1601
- state?: string;
1602
- taxType?: string;
1603
- };
1604
- }[];
1605
- stripeTaxCalculationId?: string;
1606
- stripeTaxTransactionId?: string;
1607
- dynamicPrice?: number;
1608
- feeAmount?: number;
1609
- fee?: number;
1610
- fees?: {
1611
- name?: string;
1612
- amount?: number;
1613
- percentage?: number;
1614
- }[];
1615
- billing?: {
1616
- name?: string;
1617
- companyName?: string;
1618
- email?: string;
1619
- billingEmail?: string;
1620
- phone?: string;
1621
- address?: {
1622
- line1?: string;
1623
- line2?: string;
1624
- city?: string;
1625
- state?: string;
1626
- postalCode?: string;
1627
- country?: string;
1628
- };
1629
- };
1630
- shipping?: {
1631
- name?: string;
1632
- phone?: string;
1633
- address?: {
1634
- line1?: string;
1635
- line2?: string;
1636
- city?: string;
1637
- state?: string;
1638
- postalCode?: string;
1639
- country?: string;
1640
- };
1641
- };
1642
- fields?: {
1643
- fieldId?: string;
1644
- label?: string;
1645
- value?: string;
1646
- /** @enum {string} */
1647
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
1648
- /** @enum {string} */
1649
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
1650
- meta?: string;
1651
- reference?: string;
1652
- }[];
1653
- coupon?: {
1654
- id?: string;
1655
- label?: string;
1656
- code?: string;
1657
- amountOff?: number;
1658
- percentOff?: number;
1659
- discount?: number;
1660
- };
1661
- discount?: {
1662
- minQuantity?: number;
1663
- maxQuantity?: number;
1664
- percentOff?: number;
1665
- amountOff?: number;
1666
- amount?: number;
1667
- };
1668
- livemode?: boolean;
1669
- /** @enum {string} */
1670
- status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
1671
- paymentError?: string;
1672
- /** @enum {string} */
1673
- statusReason?: "api_connection_error" | "api_error" | "authentication_error" | "card_error" | "idempotency_error" | "invalid_request_error" | "rate_limit_error";
1674
- paymentMethod?: {
1675
- /** @enum {string} */
1676
- gateway?: "stripe" | "paypal" | "manual";
1677
- method?: string;
1678
- wallet?: string;
1679
- /** @enum {string} */
1680
- mode?: "default" | "express";
1681
- brand?: string;
1682
- last4?: string;
1683
- country?: string;
1684
- exp_month?: number;
1685
- exp_year?: number;
1686
- funding?: string;
1687
- };
1688
- paymentOption?: {
1689
- /** @enum {string} */
1690
- type?: "manual" | "partial" | "full";
1691
- name?: string;
1692
- description?: string;
1693
- instructions?: string;
1694
- partialAmount?: number;
1695
- /** @enum {string} */
1696
- manualType?: "invoice" | "cash_on_delivery";
1697
- };
1698
- locale?: string;
1699
- sessionId?: string;
1700
- clientIp?: string;
1701
- userAgent?: string;
1702
- screenWidth?: number;
1703
- visitId?: string;
1704
- queryParameters?: {
1705
- [key: string]: string;
1706
- };
1707
- stripePaymentIntentId?: string;
1708
- stripePaymentIntentClientSecret?: string;
1709
- upsell?: boolean;
1710
- upsellPageId?: string;
1711
- upsellChargeId?: string;
1712
- upsellSubscriptionId?: string;
1713
- invoiceId?: string;
1714
- transactionIds?: string[];
1715
- /** @description The date this was canceled. */
1716
- canceledAt?: string;
1717
- /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
1718
- canceledBy?: string;
1719
- /** @description The reason for the cancellation */
1720
- reason?: string;
1721
- isAbandoned?: boolean;
1722
- /** Format: date-time */
1723
- recoveredAt?: string;
1724
- /** @enum {string} */
1725
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
1726
- /** Format: date-time */
1727
- abandonedCartEmailSentAt?: string;
1728
- /** Format: date-time */
1729
- createdAt: string;
1730
- /** Format: date-time */
1731
- updatedAt: string;
1732
- productId?: string;
1733
- productPrice?: number;
1734
- payWhatYouWantPrice?: number;
1735
- discountedFromPrice?: number;
1736
- setupFee?: number;
1737
- quantity?: number;
1738
- sku?: string;
1739
- variants?: {
1740
- name?: string;
1741
- variantId?: string;
1742
- reference?: string;
1743
- /** @enum {string} */
1744
- selectionType?: "single" | "multiple" | "quantity";
1745
- sku?: string;
1746
- selectedOptions?: {
1747
- optionId?: string;
1748
- optionName?: string;
1749
- sku?: string;
1750
- quantity?: number;
1751
- additionalChargeAmount?: number;
1752
- originalAdditionalChargeAmount?: number;
1753
- discount?: {
1754
- minQuantity?: number;
1755
- maxQuantity?: number;
1756
- percentOff?: number;
1757
- amountOff?: number;
1758
- amount?: number;
1759
- };
1760
- }[];
1761
- additionalChargeAmount?: number;
1762
- originalAdditionalChargeAmount?: number;
1763
- selectedOptionName?: string;
1764
- selectedOptionId?: string;
1765
- selectedOptionQuantity?: number;
1766
- selectedOptionDiscount?: {
1767
- minQuantity?: number;
1768
- maxQuantity?: number;
1769
- percentOff?: number;
1770
- amountOff?: number;
1771
- amount?: number;
1772
- };
1773
- }[];
1774
- licenseKeyId?: string;
1775
- };
1776
- };
1777
- };
1778
- };
1779
- };
1780
- responses: {
1781
- /** @description Return a 200 status to indicate that the data was received successfully. */
1782
- 200: {
1783
- headers: {
1784
- [name: string]: unknown;
1785
- };
1786
- content?: never;
1787
- };
1788
- };
1789
- };
1790
- "webhooks/payment.paid": {
1791
- parameters: {
1792
- query?: never;
1793
- header?: never;
1794
- path?: never;
1795
- cookie?: never;
1796
- };
1797
- requestBody?: {
1798
- content: {
1799
- "application/json": {
1800
- seller_id: string;
1801
- /** Format: date-time */
1802
- timestamp: string;
1803
- /** @description Unique identifier for idempotency */
1804
- event_id: string;
1805
- /** @enum {string} */
1806
- event: "payment.paid";
1807
- data: {
1808
- payment: {
1809
- id: string;
1810
- orderId?: string;
1811
- orderStatus?: string;
1812
- stripePaymentId?: string;
1813
- customerEmail?: string;
1814
- customerId?: string;
1815
- sellerId?: string;
1816
- pageId?: string;
1817
- currency?: string;
1818
- /** @description The total amount intended to be collected. */
1819
- amount: number;
1820
- /** @description The amount of money paid toward the total. */
1821
- amountPaid?: number;
1822
- /** @description The outstanding amount of money to be paid. */
1823
- amountDue?: number;
1824
- amountUsd?: number;
1825
- amountExcludingTax?: number;
1826
- taxAmount?: number;
1827
- taxBreakdown: {
1828
- taxType?: string;
1829
- taxabilityReason?: string;
1830
- taxableAmount?: number;
1831
- taxAmount?: number;
1832
- taxRateDetails?: {
1833
- country?: string;
1834
- percentageDecimal?: number;
1835
- state?: string;
1836
- taxType?: string;
1837
- };
1838
- }[];
1839
- stripeTaxCalculationId?: string;
1840
- stripeTaxTransactionId?: string;
1841
- dynamicPrice?: number;
1842
- feeAmount?: number;
1843
- fee?: number;
1844
- fees?: {
1845
- name?: string;
1846
- amount?: number;
1847
- percentage?: number;
1848
- }[];
1849
- billing?: {
1850
- name?: string;
1851
- companyName?: string;
1852
- email?: string;
1853
- billingEmail?: string;
1854
- phone?: string;
1855
- address?: {
1856
- line1?: string;
1857
- line2?: string;
1858
- city?: string;
1859
- state?: string;
1860
- postalCode?: string;
1861
- country?: string;
1862
- };
1863
- };
1864
- shipping?: {
1865
- name?: string;
1866
- phone?: string;
1867
- address?: {
1868
- line1?: string;
1869
- line2?: string;
1870
- city?: string;
1871
- state?: string;
1872
- postalCode?: string;
1873
- country?: string;
1874
- };
1875
- };
1876
- fields?: {
1877
- fieldId?: string;
1878
- label?: string;
1879
- value?: string;
1880
- /** @enum {string} */
1881
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
1882
- /** @enum {string} */
1883
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
1884
- meta?: string;
1885
- reference?: string;
1886
- }[];
1887
- coupon?: {
1888
- id?: string;
1889
- label?: string;
1890
- code?: string;
1891
- amountOff?: number;
1892
- percentOff?: number;
1893
- discount?: number;
1894
- };
1895
- discount?: {
1896
- minQuantity?: number;
1897
- maxQuantity?: number;
1898
- percentOff?: number;
1899
- amountOff?: number;
1900
- amount?: number;
1901
- };
1902
- livemode?: boolean;
1903
- /** @enum {string} */
1904
- status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
1905
- paymentError?: string;
1906
- /** @enum {string} */
1907
- statusReason?: "api_connection_error" | "api_error" | "authentication_error" | "card_error" | "idempotency_error" | "invalid_request_error" | "rate_limit_error";
1908
- paymentMethod?: {
1909
- /** @enum {string} */
1910
- gateway?: "stripe" | "paypal" | "manual";
1911
- method?: string;
1912
- wallet?: string;
1913
- /** @enum {string} */
1914
- mode?: "default" | "express";
1915
- brand?: string;
1916
- last4?: string;
1917
- country?: string;
1918
- exp_month?: number;
1919
- exp_year?: number;
1920
- funding?: string;
1921
- };
1922
- paymentOption?: {
1923
- /** @enum {string} */
1924
- type?: "manual" | "partial" | "full";
1925
- name?: string;
1926
- description?: string;
1927
- instructions?: string;
1928
- partialAmount?: number;
1929
- /** @enum {string} */
1930
- manualType?: "invoice" | "cash_on_delivery";
1931
- };
1932
- locale?: string;
1933
- sessionId?: string;
1934
- clientIp?: string;
1935
- userAgent?: string;
1936
- screenWidth?: number;
1937
- visitId?: string;
1938
- queryParameters?: {
1939
- [key: string]: string;
1940
- };
1941
- stripePaymentIntentId?: string;
1942
- stripePaymentIntentClientSecret?: string;
1943
- upsell?: boolean;
1944
- upsellPageId?: string;
1945
- upsellChargeId?: string;
1946
- upsellSubscriptionId?: string;
1947
- invoiceId?: string;
1948
- transactionIds?: string[];
1949
- /** @description The date this was canceled. */
1950
- canceledAt?: string;
1951
- /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
1952
- canceledBy?: string;
1953
- /** @description The reason for the cancellation */
1954
- reason?: string;
1955
- isAbandoned?: boolean;
1956
- /** Format: date-time */
1957
- recoveredAt?: string;
1958
- /** @enum {string} */
1959
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
1960
- /** Format: date-time */
1961
- abandonedCartEmailSentAt?: string;
1962
- /** Format: date-time */
1963
- createdAt: string;
1964
- /** Format: date-time */
1965
- updatedAt: string;
1966
- productId?: string;
1967
- productPrice?: number;
1968
- payWhatYouWantPrice?: number;
1969
- discountedFromPrice?: number;
1970
- setupFee?: number;
1971
- quantity?: number;
1972
- sku?: string;
1973
- variants?: {
1974
- name?: string;
1975
- variantId?: string;
1976
- reference?: string;
1977
- /** @enum {string} */
1978
- selectionType?: "single" | "multiple" | "quantity";
1979
- sku?: string;
1980
- selectedOptions?: {
1981
- optionId?: string;
1982
- optionName?: string;
1983
- sku?: string;
1984
- quantity?: number;
1985
- additionalChargeAmount?: number;
1986
- originalAdditionalChargeAmount?: number;
1987
- discount?: {
1988
- minQuantity?: number;
1989
- maxQuantity?: number;
1990
- percentOff?: number;
1991
- amountOff?: number;
1992
- amount?: number;
1993
- };
1994
- }[];
1995
- additionalChargeAmount?: number;
1996
- originalAdditionalChargeAmount?: number;
1997
- selectedOptionName?: string;
1998
- selectedOptionId?: string;
1999
- selectedOptionQuantity?: number;
2000
- selectedOptionDiscount?: {
2001
- minQuantity?: number;
2002
- maxQuantity?: number;
2003
- percentOff?: number;
2004
- amountOff?: number;
2005
- amount?: number;
2006
- };
2007
- }[];
2008
- licenseKeyId?: string;
2009
- };
2010
- };
2011
- };
2012
- };
2013
- };
2014
- responses: {
2015
- /** @description Return a 200 status to indicate that the data was received successfully. */
2016
- 200: {
2017
- headers: {
2018
- [name: string]: unknown;
2019
- };
2020
- content?: never;
2021
- };
2022
- };
2023
- };
2024
- "webhooks/booking.created": {
2025
- parameters: {
2026
- query?: never;
2027
- header?: never;
2028
- path?: never;
2029
- cookie?: never;
2030
- };
2031
- requestBody?: {
2032
- content: {
2033
- "application/json": {
2034
- seller_id: string;
2035
- /** Format: date-time */
2036
- timestamp: string;
2037
- /** @description Unique identifier for idempotency */
2038
- event_id: string;
2039
- /** @enum {string} */
2040
- event: "booking.created";
2041
- data: {
2042
- booking: {
2043
- id: string;
2044
- orderId?: string;
2045
- orderStatus?: string;
2046
- stripePaymentId?: string;
2047
- customerEmail?: string;
2048
- customerId?: string;
2049
- sellerId?: string;
2050
- pageId?: string;
2051
- currency?: string;
2052
- /** @description The total amount intended to be collected. */
2053
- amount: number;
2054
- /** @description The amount of money paid toward the total. */
2055
- amountPaid?: number;
2056
- /** @description The outstanding amount of money to be paid. */
2057
- amountDue?: number;
2058
- amountUsd?: number;
2059
- amountExcludingTax?: number;
2060
- taxAmount?: number;
2061
- taxBreakdown: {
2062
- taxType?: string;
2063
- taxabilityReason?: string;
2064
- taxableAmount?: number;
2065
- taxAmount?: number;
2066
- taxRateDetails?: {
2067
- country?: string;
2068
- percentageDecimal?: number;
2069
- state?: string;
2070
- taxType?: string;
2071
- };
2072
- }[];
2073
- stripeTaxCalculationId?: string;
2074
- stripeTaxTransactionId?: string;
2075
- dynamicPrice?: number;
2076
- feeAmount?: number;
2077
- fee?: number;
2078
- fees?: {
2079
- name?: string;
2080
- amount?: number;
2081
- percentage?: number;
2082
- }[];
2083
- billing?: {
2084
- name?: string;
2085
- companyName?: string;
2086
- email?: string;
2087
- billingEmail?: string;
2088
- phone?: string;
2089
- address?: {
2090
- line1?: string;
2091
- line2?: string;
2092
- city?: string;
2093
- state?: string;
2094
- postalCode?: string;
2095
- country?: string;
2096
- };
2097
- };
2098
- shipping?: {
2099
- name?: string;
2100
- phone?: string;
2101
- address?: {
2102
- line1?: string;
2103
- line2?: string;
2104
- city?: string;
2105
- state?: string;
2106
- postalCode?: string;
2107
- country?: string;
2108
- };
2109
- };
2110
- fields?: {
2111
- fieldId?: string;
2112
- label?: string;
2113
- value?: string;
2114
- /** @enum {string} */
2115
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
2116
- /** @enum {string} */
2117
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
2118
- meta?: string;
2119
- reference?: string;
2120
- }[];
2121
- coupon?: {
2122
- id?: string;
2123
- label?: string;
2124
- code?: string;
2125
- amountOff?: number;
2126
- percentOff?: number;
2127
- discount?: number;
2128
- };
2129
- discount?: {
2130
- minQuantity?: number;
2131
- maxQuantity?: number;
2132
- percentOff?: number;
2133
- amountOff?: number;
2134
- amount?: number;
2135
- };
2136
- livemode?: boolean;
2137
- /** @enum {string} */
2138
- status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
2139
- paymentError?: string;
2140
- /** @enum {string} */
2141
- statusReason?: "api_connection_error" | "api_error" | "authentication_error" | "card_error" | "idempotency_error" | "invalid_request_error" | "rate_limit_error";
2142
- paymentMethod?: {
2143
- /** @enum {string} */
2144
- gateway?: "stripe" | "paypal" | "manual";
2145
- method?: string;
2146
- wallet?: string;
2147
- /** @enum {string} */
2148
- mode?: "default" | "express";
2149
- brand?: string;
2150
- last4?: string;
2151
- country?: string;
2152
- exp_month?: number;
2153
- exp_year?: number;
2154
- funding?: string;
2155
- };
2156
- paymentOption?: {
2157
- /** @enum {string} */
2158
- type?: "manual" | "partial" | "full";
2159
- name?: string;
2160
- description?: string;
2161
- instructions?: string;
2162
- partialAmount?: number;
2163
- /** @enum {string} */
2164
- manualType?: "invoice" | "cash_on_delivery";
2165
- };
2166
- locale?: string;
2167
- sessionId?: string;
2168
- clientIp?: string;
2169
- userAgent?: string;
2170
- screenWidth?: number;
2171
- visitId?: string;
2172
- queryParameters?: {
2173
- [key: string]: string;
2174
- };
2175
- stripePaymentIntentId?: string;
2176
- stripePaymentIntentClientSecret?: string;
2177
- upsell?: boolean;
2178
- upsellPageId?: string;
2179
- upsellChargeId?: string;
2180
- upsellSubscriptionId?: string;
2181
- invoiceId?: string;
2182
- transactionIds?: string[];
2183
- /** @description The date this was canceled. */
2184
- canceledAt?: string;
2185
- /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
2186
- canceledBy?: string;
2187
- /** @description The reason for the cancellation */
2188
- reason?: string;
2189
- isAbandoned?: boolean;
2190
- /** Format: date-time */
2191
- recoveredAt?: string;
2192
- /** @enum {string} */
2193
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
2194
- /** Format: date-time */
2195
- abandonedCartEmailSentAt?: string;
2196
- /** Format: date-time */
2197
- createdAt: string;
2198
- /** Format: date-time */
2199
- updatedAt: string;
2200
- productId?: string;
2201
- productPrice?: number;
2202
- payWhatYouWantPrice?: number;
2203
- discountedFromPrice?: number;
2204
- setupFee?: number;
2205
- quantity?: number;
2206
- sku?: string;
2207
- variants?: {
2208
- name?: string;
2209
- variantId?: string;
2210
- reference?: string;
2211
- /** @enum {string} */
2212
- selectionType?: "single" | "multiple" | "quantity";
2213
- sku?: string;
2214
- selectedOptions?: {
2215
- optionId?: string;
2216
- optionName?: string;
2217
- sku?: string;
2218
- quantity?: number;
2219
- additionalChargeAmount?: number;
2220
- originalAdditionalChargeAmount?: number;
2221
- discount?: {
2222
- minQuantity?: number;
2223
- maxQuantity?: number;
2224
- percentOff?: number;
2225
- amountOff?: number;
2226
- amount?: number;
2227
- };
2228
- }[];
2229
- additionalChargeAmount?: number;
2230
- originalAdditionalChargeAmount?: number;
2231
- selectedOptionName?: string;
2232
- selectedOptionId?: string;
2233
- selectedOptionQuantity?: number;
2234
- selectedOptionDiscount?: {
2235
- minQuantity?: number;
2236
- maxQuantity?: number;
2237
- percentOff?: number;
2238
- amountOff?: number;
2239
- amount?: number;
2240
- };
2241
- }[];
2242
- licenseKeyId?: string;
2243
- };
2244
- };
2245
- };
2246
- };
2247
- };
2248
- responses: {
2249
- /** @description Return a 200 status to indicate that the data was received successfully. */
2250
- 200: {
2251
- headers: {
2252
- [name: string]: unknown;
2253
- };
2254
- content?: never;
2255
- };
2256
- };
2257
- };
2258
- "webhooks/booking.paid": {
2259
- parameters: {
2260
- query?: never;
2261
- header?: never;
2262
- path?: never;
2263
- cookie?: never;
2264
- };
2265
- requestBody?: {
2266
- content: {
2267
- "application/json": {
2268
- seller_id: string;
2269
- /** Format: date-time */
2270
- timestamp: string;
2271
- /** @description Unique identifier for idempotency */
2272
- event_id: string;
2273
- /** @enum {string} */
2274
- event: "booking.paid";
2275
- data: {
2276
- booking: {
2277
- id: string;
2278
- orderId?: string;
2279
- orderStatus?: string;
2280
- stripePaymentId?: string;
2281
- customerEmail?: string;
2282
- customerId?: string;
2283
- sellerId?: string;
2284
- pageId?: string;
2285
- currency?: string;
2286
- /** @description The total amount intended to be collected. */
2287
- amount: number;
2288
- /** @description The amount of money paid toward the total. */
2289
- amountPaid?: number;
2290
- /** @description The outstanding amount of money to be paid. */
2291
- amountDue?: number;
2292
- amountUsd?: number;
2293
- amountExcludingTax?: number;
2294
- taxAmount?: number;
2295
- taxBreakdown: {
2296
- taxType?: string;
2297
- taxabilityReason?: string;
2298
- taxableAmount?: number;
2299
- taxAmount?: number;
2300
- taxRateDetails?: {
2301
- country?: string;
2302
- percentageDecimal?: number;
2303
- state?: string;
2304
- taxType?: string;
2305
- };
2306
- }[];
2307
- stripeTaxCalculationId?: string;
2308
- stripeTaxTransactionId?: string;
2309
- dynamicPrice?: number;
2310
- feeAmount?: number;
2311
- fee?: number;
2312
- fees?: {
2313
- name?: string;
2314
- amount?: number;
2315
- percentage?: number;
2316
- }[];
2317
- billing?: {
2318
- name?: string;
2319
- companyName?: string;
2320
- email?: string;
2321
- billingEmail?: string;
2322
- phone?: string;
2323
- address?: {
2324
- line1?: string;
2325
- line2?: string;
2326
- city?: string;
2327
- state?: string;
2328
- postalCode?: string;
2329
- country?: string;
2330
- };
2331
- };
2332
- shipping?: {
2333
- name?: string;
2334
- phone?: string;
2335
- address?: {
2336
- line1?: string;
2337
- line2?: string;
2338
- city?: string;
2339
- state?: string;
2340
- postalCode?: string;
2341
- country?: string;
2342
- };
2343
- };
2344
- fields?: {
2345
- fieldId?: string;
2346
- label?: string;
2347
- value?: string;
2348
- /** @enum {string} */
2349
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
2350
- /** @enum {string} */
2351
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
2352
- meta?: string;
2353
- reference?: string;
2354
- }[];
2355
- coupon?: {
2356
- id?: string;
2357
- label?: string;
2358
- code?: string;
2359
- amountOff?: number;
2360
- percentOff?: number;
2361
- discount?: number;
2362
- };
2363
- discount?: {
2364
- minQuantity?: number;
2365
- maxQuantity?: number;
2366
- percentOff?: number;
2367
- amountOff?: number;
2368
- amount?: number;
2369
- };
2370
- livemode?: boolean;
2371
- /** @enum {string} */
2372
- status: "created" | "pending" | "unpaid" | "partially_paid" | "paid" | "canceled" | "failed" | "partial_refund" | "refunded" | "draft" | "draft_expired";
2373
- paymentError?: string;
2374
- /** @enum {string} */
2375
- statusReason?: "api_connection_error" | "api_error" | "authentication_error" | "card_error" | "idempotency_error" | "invalid_request_error" | "rate_limit_error";
2376
- paymentMethod?: {
2377
- /** @enum {string} */
2378
- gateway?: "stripe" | "paypal" | "manual";
2379
- method?: string;
2380
- wallet?: string;
2381
- /** @enum {string} */
2382
- mode?: "default" | "express";
2383
- brand?: string;
2384
- last4?: string;
2385
- country?: string;
2386
- exp_month?: number;
2387
- exp_year?: number;
2388
- funding?: string;
2389
- };
2390
- paymentOption?: {
2391
- /** @enum {string} */
2392
- type?: "manual" | "partial" | "full";
2393
- name?: string;
2394
- description?: string;
2395
- instructions?: string;
2396
- partialAmount?: number;
2397
- /** @enum {string} */
2398
- manualType?: "invoice" | "cash_on_delivery";
2399
- };
2400
- locale?: string;
2401
- sessionId?: string;
2402
- clientIp?: string;
2403
- userAgent?: string;
2404
- screenWidth?: number;
2405
- visitId?: string;
2406
- queryParameters?: {
2407
- [key: string]: string;
2408
- };
2409
- stripePaymentIntentId?: string;
2410
- stripePaymentIntentClientSecret?: string;
2411
- upsell?: boolean;
2412
- upsellPageId?: string;
2413
- upsellChargeId?: string;
2414
- upsellSubscriptionId?: string;
2415
- invoiceId?: string;
2416
- transactionIds?: string[];
2417
- /** @description The date this was canceled. */
2418
- canceledAt?: string;
2419
- /** @description The userId that canceled this. If this is a booking, tickets were canceled in addition. */
2420
- canceledBy?: string;
2421
- /** @description The reason for the cancellation */
2422
- reason?: string;
2423
- isAbandoned?: boolean;
2424
- /** Format: date-time */
2425
- recoveredAt?: string;
2426
- /** @enum {string} */
2427
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
2428
- /** Format: date-time */
2429
- abandonedCartEmailSentAt?: string;
2430
- /** Format: date-time */
2431
- createdAt: string;
2432
- /** Format: date-time */
2433
- updatedAt: string;
2434
- productId?: string;
2435
- productPrice?: number;
2436
- payWhatYouWantPrice?: number;
2437
- discountedFromPrice?: number;
2438
- setupFee?: number;
2439
- quantity?: number;
2440
- sku?: string;
2441
- variants?: {
2442
- name?: string;
2443
- variantId?: string;
2444
- reference?: string;
2445
- /** @enum {string} */
2446
- selectionType?: "single" | "multiple" | "quantity";
2447
- sku?: string;
2448
- selectedOptions?: {
2449
- optionId?: string;
2450
- optionName?: string;
2451
- sku?: string;
2452
- quantity?: number;
2453
- additionalChargeAmount?: number;
2454
- originalAdditionalChargeAmount?: number;
2455
- discount?: {
2456
- minQuantity?: number;
2457
- maxQuantity?: number;
2458
- percentOff?: number;
2459
- amountOff?: number;
2460
- amount?: number;
2461
- };
2462
- }[];
2463
- additionalChargeAmount?: number;
2464
- originalAdditionalChargeAmount?: number;
2465
- selectedOptionName?: string;
2466
- selectedOptionId?: string;
2467
- selectedOptionQuantity?: number;
2468
- selectedOptionDiscount?: {
2469
- minQuantity?: number;
2470
- maxQuantity?: number;
2471
- percentOff?: number;
2472
- amountOff?: number;
2473
- amount?: number;
2474
- };
2475
- }[];
2476
- licenseKeyId?: string;
2477
- };
2478
- };
2479
- };
2480
- };
2481
- };
2482
- responses: {
2483
- /** @description Return a 200 status to indicate that the data was received successfully. */
2484
- 200: {
2485
- headers: {
2486
- [name: string]: unknown;
2487
- };
2488
- content?: never;
2489
- };
2490
- };
2491
- };
2492
- "webhooks/subscription.created": {
2493
- parameters: {
2494
- query?: never;
2495
- header?: never;
2496
- path?: never;
2497
- cookie?: never;
2498
- };
2499
- requestBody?: {
2500
- content: {
2501
- "application/json": {
2502
- seller_id: string;
2503
- /** Format: date-time */
2504
- timestamp: string;
2505
- /** @description Unique identifier for idempotency */
2506
- event_id: string;
2507
- /** @enum {string} */
2508
- event: "subscription.created";
2509
- data: {
2510
- subscription: {
2511
- id: string;
2512
- orderId?: string;
2513
- subscriptionId?: string;
2514
- customerEmail?: string;
2515
- currency?: string;
2516
- amount: number;
2517
- amountUsd?: number;
2518
- interval?: string;
2519
- intervalCount?: number;
2520
- planIterations?: number;
2521
- fees?: {
2522
- name?: string;
2523
- amount?: number;
2524
- percentage?: number;
2525
- stripeProductId?: string;
2526
- }[];
2527
- setupFee?: number;
2528
- setupFeeDiscountAmount?: number;
2529
- setupFeeFees?: {
2530
- name?: string;
2531
- amount?: number;
2532
- percentage?: number;
2533
- stripeInvoiceItemId?: string;
2534
- }[];
2535
- setupFeeTotal?: number;
2536
- setupFeeUsd?: number;
2537
- setupFeeInvoiceItemId?: string;
2538
- setupFeeInvoiceItemPaid?: boolean;
2539
- quantity?: number;
2540
- productPrice?: number;
2541
- dynamicPrice?: number;
2542
- discountedFromPrice?: number;
2543
- feePercentage?: number;
2544
- sku?: string;
2545
- billing?: {
2546
- name?: string;
2547
- companyName?: string;
2548
- email?: string;
2549
- billingEmail?: string;
2550
- phone?: string;
2551
- address?: {
2552
- line1?: string;
2553
- line2?: string;
2554
- city?: string;
2555
- state?: string;
2556
- postalCode?: string;
2557
- country?: string;
2558
- };
2559
- };
2560
- shipping?: {
2561
- name?: string;
2562
- phone?: string;
2563
- address?: {
2564
- line1?: string;
2565
- line2?: string;
2566
- city?: string;
2567
- state?: string;
2568
- postalCode?: string;
2569
- country?: string;
2570
- };
2571
- };
2572
- fields?: {
2573
- fieldId?: string;
2574
- label?: string;
2575
- value?: string;
2576
- /** @enum {string} */
2577
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
2578
- /** @enum {string} */
2579
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
2580
- reference?: string;
2581
- }[];
2582
- variants?: {
2583
- name?: string;
2584
- variantId?: string;
2585
- reference?: string;
2586
- /** @enum {string} */
2587
- selectionType?: "single" | "multiple" | "quantity";
2588
- selectedOptions?: {
2589
- optionId?: string;
2590
- /** @enum {string} */
2591
- optionType?: "one_time" | "recurring";
2592
- optionName?: string;
2593
- sku?: string;
2594
- quantity?: number;
2595
- additionalChargeAmount?: number;
2596
- discountAmount?: number;
2597
- fees?: {
2598
- name?: string;
2599
- amount?: number;
2600
- percentage?: number;
2601
- stripeInvoiceItemId?: string;
2602
- }[];
2603
- additionalChargeAmountTotal?: number;
2604
- additionalChargeAmountUsd?: number;
2605
- optionStripePriceId?: string;
2606
- optionStripeProductId?: string;
2607
- optionInvoiceItemId?: string;
2608
- optionInvoiceItemPaid?: boolean;
2609
- }[];
2610
- selectedOptionName?: string;
2611
- additionalChargeAmount?: number;
2612
- discountAmount?: number;
2613
- fees?: {
2614
- name?: string;
2615
- amount?: number;
2616
- percentage?: number;
2617
- stripeInvoiceItemId?: string;
2618
- }[];
2619
- additionalChargeAmountTotal?: number;
2620
- additionalChargeAmountUsd?: number;
2621
- sku?: string;
2622
- /** @enum {string} */
2623
- selectedOptionType?: "one_time" | "recurring";
2624
- selectedOptionId?: string;
2625
- selectedOptionQuantity?: number;
2626
- selectedOptionStripePriceId?: string;
2627
- selectedOptionStripeProductId?: string;
2628
- selectedOptionInvoiceItemId?: string;
2629
- selectedOptionInvoiceItemPaid?: boolean;
2630
- }[];
2631
- couponId?: string;
2632
- licenseKeyId?: string;
2633
- livemode?: boolean;
2634
- /** @enum {string} */
2635
- status?: "draft" | "draft_expired" | "incomplete" | "incomplete_expired" | "trialing" | "scheduled" | "active" | "past_due" | "canceled" | "unpaid" | "failed" | "completed";
2636
- /** @enum {string} */
2637
- paymentStatus?: "draft" | "deleted" | "open" | "paid" | "uncollectible" | "void" | "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
2638
- paymentError?: string;
2639
- paymentMethod?: {
2640
- /** @enum {string} */
2641
- gateway?: "stripe" | "paypal" | "manual";
2642
- method?: string;
2643
- wallet?: string;
2644
- /** @enum {string} */
2645
- mode?: "default" | "express";
2646
- brand?: string;
2647
- last4?: string;
2648
- country?: string;
2649
- exp_month?: number;
2650
- exp_year?: number;
2651
- funding?: string;
2652
- };
2653
- locale?: string;
2654
- sessionId?: string;
2655
- clientIp?: string;
2656
- userAgent?: string;
2657
- screenWidth?: number;
2658
- visitId?: string;
2659
- queryParameters?: {
2660
- key: string;
2661
- value: string;
2662
- }[];
2663
- stripePaymentIntentId?: string;
2664
- stripePaymentIntentClientSecret?: string;
2665
- stripeSetupIntentId?: string;
2666
- /** Format: date-time */
2667
- startDate?: string;
2668
- /** Format: date-time */
2669
- trialEnd?: string;
2670
- /** Format: date-time */
2671
- trialStart?: string;
2672
- /** Format: date-time */
2673
- cancelAt?: string;
2674
- cancelAtPeriodEnd?: boolean;
2675
- /** Format: date-time */
2676
- currentPeriodStart?: string;
2677
- /** Format: date-time */
2678
- currentPeriodEnd?: string;
2679
- upsell?: boolean;
2680
- upsellPageId?: string;
2681
- upsellChargeId?: string;
2682
- upsellSubscriptionId?: string;
2683
- stripeSubscriptionId?: string;
2684
- stripeCustomerId?: string;
2685
- sellerId?: string;
2686
- customerId?: string;
2687
- pageId?: string;
2688
- productId?: string;
2689
- /** Format: date-time */
2690
- canceledAt?: string;
2691
- canceledBy?: string;
2692
- reason?: string;
2693
- isAbandoned?: boolean;
2694
- /** Format: date-time */
2695
- recoveredAt?: string;
2696
- /** @enum {string} */
2697
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
2698
- /** Format: date-time */
2699
- abandonedCartEmailSentAt?: string;
2700
- /** Format: date-time */
2701
- createdAt: string;
2702
- /** Format: date-time */
2703
- updatedAt: string;
2704
- };
1428
+ payment: components["schemas"]["Payment"];
2705
1429
  };
2706
1430
  };
2707
1431
  };
@@ -2716,7 +1440,7 @@ interface operations {
2716
1440
  };
2717
1441
  };
2718
1442
  };
2719
- "webhooks/subscription.active": {
1443
+ "webhooks/payment.paid": {
2720
1444
  parameters: {
2721
1445
  query?: never;
2722
1446
  header?: never;
@@ -2732,203 +1456,75 @@ interface operations {
2732
1456
  /** @description Unique identifier for idempotency */
2733
1457
  event_id: string;
2734
1458
  /** @enum {string} */
2735
- event: "subscription.active";
1459
+ event: "payment.paid";
2736
1460
  data: {
2737
- subscription: {
2738
- id: string;
2739
- orderId?: string;
2740
- subscriptionId?: string;
2741
- customerEmail?: string;
2742
- currency?: string;
2743
- amount: number;
2744
- amountUsd?: number;
2745
- interval?: string;
2746
- intervalCount?: number;
2747
- planIterations?: number;
2748
- fees?: {
2749
- name?: string;
2750
- amount?: number;
2751
- percentage?: number;
2752
- stripeProductId?: string;
2753
- }[];
2754
- setupFee?: number;
2755
- setupFeeDiscountAmount?: number;
2756
- setupFeeFees?: {
2757
- name?: string;
2758
- amount?: number;
2759
- percentage?: number;
2760
- stripeInvoiceItemId?: string;
2761
- }[];
2762
- setupFeeTotal?: number;
2763
- setupFeeUsd?: number;
2764
- setupFeeInvoiceItemId?: string;
2765
- setupFeeInvoiceItemPaid?: boolean;
2766
- quantity?: number;
2767
- productPrice?: number;
2768
- dynamicPrice?: number;
2769
- discountedFromPrice?: number;
2770
- feePercentage?: number;
2771
- sku?: string;
2772
- billing?: {
2773
- name?: string;
2774
- companyName?: string;
2775
- email?: string;
2776
- billingEmail?: string;
2777
- phone?: string;
2778
- address?: {
2779
- line1?: string;
2780
- line2?: string;
2781
- city?: string;
2782
- state?: string;
2783
- postalCode?: string;
2784
- country?: string;
2785
- };
2786
- };
2787
- shipping?: {
2788
- name?: string;
2789
- phone?: string;
2790
- address?: {
2791
- line1?: string;
2792
- line2?: string;
2793
- city?: string;
2794
- state?: string;
2795
- postalCode?: string;
2796
- country?: string;
2797
- };
2798
- };
2799
- fields?: {
2800
- fieldId?: string;
2801
- label?: string;
2802
- value?: string;
2803
- /** @enum {string} */
2804
- element?: "checkbox" | "quantity" | "multiple-choice" | "select" | "po-number" | "text" | "textarea" | "number" | "date-time" | "date" | "time" | "email" | "tax-id" | "phone" | "country";
2805
- /** @enum {string} */
2806
- type?: "" | "company-name" | "po-number" | "name" | "first-name" | "last-name" | "email" | "billing-email" | "phone" | "address-line1" | "address-city" | "address-country" | "address-line2" | "address-postal_code" | "address-state" | "shipping-name" | "shipping-phone" | "shipping-address-line1" | "shipping-address-city" | "shipping-address-country" | "shipping-address-line2" | "shipping-address-postal_code" | "shipping-address-state" | "tax-id";
2807
- reference?: string;
2808
- }[];
2809
- variants?: {
2810
- name?: string;
2811
- variantId?: string;
2812
- reference?: string;
2813
- /** @enum {string} */
2814
- selectionType?: "single" | "multiple" | "quantity";
2815
- selectedOptions?: {
2816
- optionId?: string;
2817
- /** @enum {string} */
2818
- optionType?: "one_time" | "recurring";
2819
- optionName?: string;
2820
- sku?: string;
2821
- quantity?: number;
2822
- additionalChargeAmount?: number;
2823
- discountAmount?: number;
2824
- fees?: {
2825
- name?: string;
2826
- amount?: number;
2827
- percentage?: number;
2828
- stripeInvoiceItemId?: string;
2829
- }[];
2830
- additionalChargeAmountTotal?: number;
2831
- additionalChargeAmountUsd?: number;
2832
- optionStripePriceId?: string;
2833
- optionStripeProductId?: string;
2834
- optionInvoiceItemId?: string;
2835
- optionInvoiceItemPaid?: boolean;
2836
- }[];
2837
- selectedOptionName?: string;
2838
- additionalChargeAmount?: number;
2839
- discountAmount?: number;
2840
- fees?: {
2841
- name?: string;
2842
- amount?: number;
2843
- percentage?: number;
2844
- stripeInvoiceItemId?: string;
2845
- }[];
2846
- additionalChargeAmountTotal?: number;
2847
- additionalChargeAmountUsd?: number;
2848
- sku?: string;
2849
- /** @enum {string} */
2850
- selectedOptionType?: "one_time" | "recurring";
2851
- selectedOptionId?: string;
2852
- selectedOptionQuantity?: number;
2853
- selectedOptionStripePriceId?: string;
2854
- selectedOptionStripeProductId?: string;
2855
- selectedOptionInvoiceItemId?: string;
2856
- selectedOptionInvoiceItemPaid?: boolean;
2857
- }[];
2858
- couponId?: string;
2859
- licenseKeyId?: string;
2860
- livemode?: boolean;
2861
- /** @enum {string} */
2862
- status?: "draft" | "draft_expired" | "incomplete" | "incomplete_expired" | "trialing" | "scheduled" | "active" | "past_due" | "canceled" | "unpaid" | "failed" | "completed";
2863
- /** @enum {string} */
2864
- paymentStatus?: "draft" | "deleted" | "open" | "paid" | "uncollectible" | "void" | "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
2865
- paymentError?: string;
2866
- paymentMethod?: {
2867
- /** @enum {string} */
2868
- gateway?: "stripe" | "paypal" | "manual";
2869
- method?: string;
2870
- wallet?: string;
2871
- /** @enum {string} */
2872
- mode?: "default" | "express";
2873
- brand?: string;
2874
- last4?: string;
2875
- country?: string;
2876
- exp_month?: number;
2877
- exp_year?: number;
2878
- funding?: string;
2879
- };
2880
- locale?: string;
2881
- sessionId?: string;
2882
- clientIp?: string;
2883
- userAgent?: string;
2884
- screenWidth?: number;
2885
- visitId?: string;
2886
- queryParameters?: {
2887
- key: string;
2888
- value: string;
2889
- }[];
2890
- stripePaymentIntentId?: string;
2891
- stripePaymentIntentClientSecret?: string;
2892
- stripeSetupIntentId?: string;
2893
- /** Format: date-time */
2894
- startDate?: string;
2895
- /** Format: date-time */
2896
- trialEnd?: string;
2897
- /** Format: date-time */
2898
- trialStart?: string;
2899
- /** Format: date-time */
2900
- cancelAt?: string;
2901
- cancelAtPeriodEnd?: boolean;
2902
- /** Format: date-time */
2903
- currentPeriodStart?: string;
2904
- /** Format: date-time */
2905
- currentPeriodEnd?: string;
2906
- upsell?: boolean;
2907
- upsellPageId?: string;
2908
- upsellChargeId?: string;
2909
- upsellSubscriptionId?: string;
2910
- stripeSubscriptionId?: string;
2911
- stripeCustomerId?: string;
2912
- sellerId?: string;
2913
- customerId?: string;
2914
- pageId?: string;
2915
- productId?: string;
2916
- /** Format: date-time */
2917
- canceledAt?: string;
2918
- canceledBy?: string;
2919
- reason?: string;
2920
- isAbandoned?: boolean;
2921
- /** Format: date-time */
2922
- recoveredAt?: string;
2923
- /** @enum {string} */
2924
- abandonedCartEmailStatus?: "pending" | "first_sent" | "second_sent" | "third_sent" | "converted" | "skipped";
2925
- /** Format: date-time */
2926
- abandonedCartEmailSentAt?: string;
2927
- /** Format: date-time */
2928
- createdAt: string;
2929
- /** Format: date-time */
2930
- updatedAt: string;
2931
- };
1461
+ payment: components["schemas"]["Payment"];
1462
+ };
1463
+ };
1464
+ };
1465
+ };
1466
+ responses: {
1467
+ /** @description Return a 200 status to indicate that the data was received successfully. */
1468
+ 200: {
1469
+ headers: {
1470
+ [name: string]: unknown;
1471
+ };
1472
+ content?: never;
1473
+ };
1474
+ };
1475
+ };
1476
+ "webhooks/booking.created": {
1477
+ parameters: {
1478
+ query?: never;
1479
+ header?: never;
1480
+ path?: never;
1481
+ cookie?: never;
1482
+ };
1483
+ requestBody?: {
1484
+ content: {
1485
+ "application/json": {
1486
+ seller_id: string;
1487
+ /** Format: date-time */
1488
+ timestamp: string;
1489
+ /** @description Unique identifier for idempotency */
1490
+ event_id: string;
1491
+ /** @enum {string} */
1492
+ event: "booking.created";
1493
+ data: {
1494
+ booking: components["schemas"]["Payment"];
1495
+ };
1496
+ };
1497
+ };
1498
+ };
1499
+ responses: {
1500
+ /** @description Return a 200 status to indicate that the data was received successfully. */
1501
+ 200: {
1502
+ headers: {
1503
+ [name: string]: unknown;
1504
+ };
1505
+ content?: never;
1506
+ };
1507
+ };
1508
+ };
1509
+ "webhooks/booking.paid": {
1510
+ parameters: {
1511
+ query?: never;
1512
+ header?: never;
1513
+ path?: never;
1514
+ cookie?: never;
1515
+ };
1516
+ requestBody?: {
1517
+ content: {
1518
+ "application/json": {
1519
+ seller_id: string;
1520
+ /** Format: date-time */
1521
+ timestamp: string;
1522
+ /** @description Unique identifier for idempotency */
1523
+ event_id: string;
1524
+ /** @enum {string} */
1525
+ event: "booking.paid";
1526
+ data: {
1527
+ booking: components["schemas"]["Payment"];
2932
1528
  };
2933
1529
  };
2934
1530
  };
@@ -3031,20 +1627,86 @@ interface operations {
3031
1627
  }
3032
1628
 
3033
1629
  /**
3034
- * Type definitions for the CheckoutPage API
1630
+ * Type definitions for the Checkout Page API
3035
1631
  *
3036
1632
  * This file exports commonly used types from the generated schema.
3037
1633
  * The full generated schema is available in ./generated/schema.ts
3038
1634
  */
3039
1635
 
3040
1636
  type Customer = operations['customers/get']['responses'][200]['content']['application/json'];
3041
- type Address = NonNullable<Customer['address']>;
3042
- type Shipping = NonNullable<Customer['shipping']>;
1637
+ type CustomerList = operations['customers/list']['responses'][200]['content']['application/json'];
1638
+ type CustomerListArgs = operations['customers/list']['parameters']['query'];
1639
+ type CustomerListParams = Omit<NonNullable<CustomerListArgs>, 'limit'> & {
1640
+ limit?: number;
1641
+ };
1642
+ type Address = NonNullable<Customer['data']['address']>;
1643
+ type Shipping = NonNullable<Customer['data']['shipping']>;
1644
+ type CouponList = operations['coupons/list']['responses'][200]['content']['application/json'];
1645
+ type Coupon = CouponList['data'][number];
1646
+ type CreateCouponResponse = operations['coupons/create']['responses']['201']['content']['application/json'];
1647
+ type CouponListArgs = operations['coupons/list']['parameters']['query'];
1648
+ type CouponListParams = Omit<NonNullable<CouponListArgs>, 'limit'> & {
1649
+ limit?: number;
1650
+ };
1651
+ type CouponCreateArgs = NonNullable<operations['coupons/create']['requestBody']>['content']['application/json'];
1652
+ type NonRepeatingParams = CouponCreateArgs & {
1653
+ duration: 'once' | 'forever';
1654
+ durationInMonths?: never;
1655
+ };
1656
+ type RepeatingParams = CouponCreateArgs & {
1657
+ duration: 'repeating';
1658
+ durationInMonths: number;
1659
+ };
1660
+ type AmountNonRepeating = {
1661
+ type: 'amount';
1662
+ } & Omit<NonRepeatingParams, 'percentOff'>;
1663
+ type AmountRepeating = {
1664
+ type: 'amount';
1665
+ } & Omit<RepeatingParams, 'percentOff'>;
1666
+ type PercentNonRepeating = {
1667
+ type: 'percent';
1668
+ } & Omit<NonRepeatingParams, 'amountOff' | 'currency'>;
1669
+ type PercentRepeating = {
1670
+ type: 'percent';
1671
+ } & Omit<RepeatingParams, 'amountOff' | 'currency'>;
1672
+ type CreateCouponParams = AmountNonRepeating | AmountRepeating | PercentNonRepeating | PercentRepeating;
1673
+ type PaymentList = operations['payments/list']['responses'][200]['content']['application/json'];
1674
+ type Payment = PaymentList['data'][number];
1675
+ type PaymentListArgs = operations['payments/list']['parameters']['query'];
1676
+ type PaymentListParams = Omit<NonNullable<PaymentListArgs>, 'limit'> & {
1677
+ limit?: number;
1678
+ };
1679
+ type SubscriptionList = operations['subscriptions/list']['responses'][200]['content']['application/json'];
1680
+ type Subscription = SubscriptionList['data'][number];
1681
+ type SubscriptionListArgs = operations['subscriptions/list']['parameters']['query'];
1682
+ type SubscriptionListParams = Omit<NonNullable<SubscriptionListArgs>, 'limit'> & {
1683
+ limit?: number;
1684
+ };
3043
1685
 
3044
1686
  declare class CustomerResource {
3045
1687
  private client;
3046
- constructor(client: CheckoutPageClient);
1688
+ constructor(client: CheckoutPageApiClient);
3047
1689
  get(customerId: string): Promise<Customer>;
1690
+ list(args?: CustomerListParams): Promise<CustomerList>;
1691
+ }
1692
+
1693
+ declare class CouponResource {
1694
+ private client;
1695
+ constructor(client: CheckoutPageApiClient);
1696
+ list(args?: CouponListParams): Promise<CouponList>;
1697
+ create(params: CreateCouponParams): Promise<CreateCouponResponse>;
1698
+ }
1699
+
1700
+ declare class PaymentResource {
1701
+ private client;
1702
+ constructor(client: CheckoutPageApiClient);
1703
+ list(args?: PaymentListParams): Promise<PaymentList>;
1704
+ }
1705
+
1706
+ declare class SubscriptionResource {
1707
+ private client;
1708
+ constructor(client: CheckoutPageApiClient);
1709
+ list(args?: SubscriptionListParams): Promise<SubscriptionList>;
3048
1710
  }
3049
1711
 
3050
1712
  declare class CheckoutPageError extends Error {
@@ -3056,6 +1718,9 @@ declare class AuthenticationError extends CheckoutPageError {
3056
1718
  declare class NotFoundError extends CheckoutPageError {
3057
1719
  constructor(message?: string);
3058
1720
  }
1721
+ declare class ConflictError extends CheckoutPageError {
1722
+ constructor(message?: string);
1723
+ }
3059
1724
  declare class RateLimitError extends CheckoutPageError {
3060
1725
  constructor(message?: string);
3061
1726
  }
@@ -3068,10 +1733,14 @@ declare class APIError extends CheckoutPageError {
3068
1733
  constructor(message: string, statusCode: number, response?: unknown);
3069
1734
  }
3070
1735
 
3071
- declare class CheckoutPage {
1736
+ declare class CheckoutPageClient {
3072
1737
  readonly customers: CustomerResource;
1738
+ readonly coupons: CouponResource;
1739
+ readonly payments: PaymentResource;
1740
+ readonly subscriptions: SubscriptionResource;
3073
1741
  private readonly client;
3074
- constructor(options: CheckoutPageClientOptions);
1742
+ constructor(options: CheckoutPageApiClientOptions);
3075
1743
  }
1744
+ declare const createCheckoutPageClient: (options: CheckoutPageApiClientOptions) => CheckoutPageClient;
3076
1745
 
3077
- export { APIError, type Address, AuthenticationError, CheckoutPage, type CheckoutPageClientOptions, CheckoutPageError, type Customer, NotFoundError, RateLimitError, type Shipping, ValidationError };
1746
+ export { APIError, type Address, AuthenticationError, type CheckoutPageApiClientOptions, CheckoutPageClient, CheckoutPageError, ConflictError, type Coupon, type CouponList, type Customer, NotFoundError, type Payment, type PaymentList, RateLimitError, type Shipping, type Subscription, type SubscriptionList, ValidationError, createCheckoutPageClient };