@whop/sdk 0.0.16 → 0.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +43 -0
- package/client.d.mts +2 -2
- package/client.d.mts.map +1 -1
- package/client.d.ts +2 -2
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/companies.d.mts +26 -0
- package/resources/companies.d.mts.map +1 -1
- package/resources/companies.d.ts +26 -0
- package/resources/companies.d.ts.map +1 -1
- package/resources/courses.d.mts +4 -0
- package/resources/courses.d.mts.map +1 -1
- package/resources/courses.d.ts +4 -0
- package/resources/courses.d.ts.map +1 -1
- package/resources/index.d.mts +1 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/ledger-accounts.d.mts +87 -0
- package/resources/ledger-accounts.d.mts.map +1 -1
- package/resources/ledger-accounts.d.ts +87 -0
- package/resources/ledger-accounts.d.ts.map +1 -1
- package/resources/ledger-accounts.js +1 -0
- package/resources/ledger-accounts.js.map +1 -1
- package/resources/ledger-accounts.mjs +1 -0
- package/resources/ledger-accounts.mjs.map +1 -1
- package/resources/payment-methods.d.mts +258 -2
- package/resources/payment-methods.d.mts.map +1 -1
- package/resources/payment-methods.d.ts +258 -2
- package/resources/payment-methods.d.ts.map +1 -1
- package/resources/webhooks.d.mts +24 -2
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +24 -2
- package/resources/webhooks.d.ts.map +1 -1
- package/src/client.ts +2 -0
- package/src/resources/companies.ts +32 -0
- package/src/resources/courses.ts +5 -0
- package/src/resources/index.ts +1 -0
- package/src/resources/ledger-accounts.ts +104 -0
- package/src/resources/payment-methods.ts +310 -2
- package/src/resources/webhooks.ts +29 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -58,7 +58,10 @@ export type PaymentMethodListResponsesCursorPage = CursorPage<PaymentMethodListR
|
|
|
58
58
|
export type PaymentMethodRetrieveResponse =
|
|
59
59
|
| PaymentMethodRetrieveResponse.BasePaymentMethod
|
|
60
60
|
| PaymentMethodRetrieveResponse.CardPaymentMethod
|
|
61
|
-
| PaymentMethodRetrieveResponse.UsBankAccountPaymentMethod
|
|
61
|
+
| PaymentMethodRetrieveResponse.UsBankAccountPaymentMethod
|
|
62
|
+
| PaymentMethodRetrieveResponse.CashappPaymentMethod
|
|
63
|
+
| PaymentMethodRetrieveResponse.IdealPaymentMethod
|
|
64
|
+
| PaymentMethodRetrieveResponse.SepaDebitPaymentMethod;
|
|
62
65
|
|
|
63
66
|
export namespace PaymentMethodRetrieveResponse {
|
|
64
67
|
/**
|
|
@@ -194,6 +197,157 @@ export namespace PaymentMethodRetrieveResponse {
|
|
|
194
197
|
last4: string;
|
|
195
198
|
}
|
|
196
199
|
}
|
|
200
|
+
|
|
201
|
+
/**
|
|
202
|
+
* The Cash App details for the payment method
|
|
203
|
+
*/
|
|
204
|
+
export interface CashappPaymentMethod {
|
|
205
|
+
/**
|
|
206
|
+
* The ID of the payment method
|
|
207
|
+
*/
|
|
208
|
+
id: string;
|
|
209
|
+
|
|
210
|
+
/**
|
|
211
|
+
* The Cash App details associated with this payment method
|
|
212
|
+
*/
|
|
213
|
+
cashapp: CashappPaymentMethod.Cashapp;
|
|
214
|
+
|
|
215
|
+
/**
|
|
216
|
+
* When the payment method was created
|
|
217
|
+
*/
|
|
218
|
+
created_at: string;
|
|
219
|
+
|
|
220
|
+
/**
|
|
221
|
+
* The type of the payment method
|
|
222
|
+
*/
|
|
223
|
+
payment_method_type: PaymentsAPI.PaymentMethodTypes;
|
|
224
|
+
|
|
225
|
+
/**
|
|
226
|
+
* The typename of this object
|
|
227
|
+
*/
|
|
228
|
+
typename: 'CashappPaymentMethod';
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
export namespace CashappPaymentMethod {
|
|
232
|
+
/**
|
|
233
|
+
* The Cash App details associated with this payment method
|
|
234
|
+
*/
|
|
235
|
+
export interface Cashapp {
|
|
236
|
+
/**
|
|
237
|
+
* A unique and immutable identifier assigned by Cash App to every buyer.
|
|
238
|
+
*/
|
|
239
|
+
buyer_id: string | null;
|
|
240
|
+
|
|
241
|
+
/**
|
|
242
|
+
* A public identifier for buyers using Cash App.
|
|
243
|
+
*/
|
|
244
|
+
cashtag: string | null;
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
/**
|
|
249
|
+
* The iDEAL details for the payment method
|
|
250
|
+
*/
|
|
251
|
+
export interface IdealPaymentMethod {
|
|
252
|
+
/**
|
|
253
|
+
* The ID of the payment method
|
|
254
|
+
*/
|
|
255
|
+
id: string;
|
|
256
|
+
|
|
257
|
+
/**
|
|
258
|
+
* When the payment method was created
|
|
259
|
+
*/
|
|
260
|
+
created_at: string;
|
|
261
|
+
|
|
262
|
+
/**
|
|
263
|
+
* The iDEAL details associated with this payment method
|
|
264
|
+
*/
|
|
265
|
+
ideal: IdealPaymentMethod.Ideal;
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* The type of the payment method
|
|
269
|
+
*/
|
|
270
|
+
payment_method_type: PaymentsAPI.PaymentMethodTypes;
|
|
271
|
+
|
|
272
|
+
/**
|
|
273
|
+
* The typename of this object
|
|
274
|
+
*/
|
|
275
|
+
typename: 'IdealPaymentMethod';
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
export namespace IdealPaymentMethod {
|
|
279
|
+
/**
|
|
280
|
+
* The iDEAL details associated with this payment method
|
|
281
|
+
*/
|
|
282
|
+
export interface Ideal {
|
|
283
|
+
/**
|
|
284
|
+
* The customer's bank.
|
|
285
|
+
*/
|
|
286
|
+
bank: string | null;
|
|
287
|
+
|
|
288
|
+
/**
|
|
289
|
+
* The Bank Identifier Code of the customer's bank.
|
|
290
|
+
*/
|
|
291
|
+
bic: string | null;
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
/**
|
|
296
|
+
* The SEPA Direct Debit details for the payment method
|
|
297
|
+
*/
|
|
298
|
+
export interface SepaDebitPaymentMethod {
|
|
299
|
+
/**
|
|
300
|
+
* The ID of the payment method
|
|
301
|
+
*/
|
|
302
|
+
id: string;
|
|
303
|
+
|
|
304
|
+
/**
|
|
305
|
+
* When the payment method was created
|
|
306
|
+
*/
|
|
307
|
+
created_at: string;
|
|
308
|
+
|
|
309
|
+
/**
|
|
310
|
+
* The type of the payment method
|
|
311
|
+
*/
|
|
312
|
+
payment_method_type: PaymentsAPI.PaymentMethodTypes;
|
|
313
|
+
|
|
314
|
+
/**
|
|
315
|
+
* The SEPA Direct Debit details associated with this payment method
|
|
316
|
+
*/
|
|
317
|
+
sepa_debit: SepaDebitPaymentMethod.SepaDebit;
|
|
318
|
+
|
|
319
|
+
/**
|
|
320
|
+
* The typename of this object
|
|
321
|
+
*/
|
|
322
|
+
typename: 'SepaDebitPaymentMethod';
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
export namespace SepaDebitPaymentMethod {
|
|
326
|
+
/**
|
|
327
|
+
* The SEPA Direct Debit details associated with this payment method
|
|
328
|
+
*/
|
|
329
|
+
export interface SepaDebit {
|
|
330
|
+
/**
|
|
331
|
+
* Bank code of the bank associated with the account.
|
|
332
|
+
*/
|
|
333
|
+
bank_code: string | null;
|
|
334
|
+
|
|
335
|
+
/**
|
|
336
|
+
* Branch code of the bank associated with the account.
|
|
337
|
+
*/
|
|
338
|
+
branch_code: string | null;
|
|
339
|
+
|
|
340
|
+
/**
|
|
341
|
+
* Two-letter ISO code representing the country the bank account is located in.
|
|
342
|
+
*/
|
|
343
|
+
country: string | null;
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* Last four digits of the IBAN.
|
|
347
|
+
*/
|
|
348
|
+
last4: string | null;
|
|
349
|
+
}
|
|
350
|
+
}
|
|
197
351
|
}
|
|
198
352
|
|
|
199
353
|
/**
|
|
@@ -202,7 +356,10 @@ export namespace PaymentMethodRetrieveResponse {
|
|
|
202
356
|
export type PaymentMethodListResponse =
|
|
203
357
|
| PaymentMethodListResponse.BasePaymentMethod
|
|
204
358
|
| PaymentMethodListResponse.CardPaymentMethod
|
|
205
|
-
| PaymentMethodListResponse.UsBankAccountPaymentMethod
|
|
359
|
+
| PaymentMethodListResponse.UsBankAccountPaymentMethod
|
|
360
|
+
| PaymentMethodListResponse.CashappPaymentMethod
|
|
361
|
+
| PaymentMethodListResponse.IdealPaymentMethod
|
|
362
|
+
| PaymentMethodListResponse.SepaDebitPaymentMethod;
|
|
206
363
|
|
|
207
364
|
export namespace PaymentMethodListResponse {
|
|
208
365
|
/**
|
|
@@ -338,6 +495,157 @@ export namespace PaymentMethodListResponse {
|
|
|
338
495
|
last4: string;
|
|
339
496
|
}
|
|
340
497
|
}
|
|
498
|
+
|
|
499
|
+
/**
|
|
500
|
+
* The Cash App details for the payment method
|
|
501
|
+
*/
|
|
502
|
+
export interface CashappPaymentMethod {
|
|
503
|
+
/**
|
|
504
|
+
* The ID of the payment method
|
|
505
|
+
*/
|
|
506
|
+
id: string;
|
|
507
|
+
|
|
508
|
+
/**
|
|
509
|
+
* The Cash App details associated with this payment method
|
|
510
|
+
*/
|
|
511
|
+
cashapp: CashappPaymentMethod.Cashapp;
|
|
512
|
+
|
|
513
|
+
/**
|
|
514
|
+
* When the payment method was created
|
|
515
|
+
*/
|
|
516
|
+
created_at: string;
|
|
517
|
+
|
|
518
|
+
/**
|
|
519
|
+
* The type of the payment method
|
|
520
|
+
*/
|
|
521
|
+
payment_method_type: PaymentsAPI.PaymentMethodTypes;
|
|
522
|
+
|
|
523
|
+
/**
|
|
524
|
+
* The typename of this object
|
|
525
|
+
*/
|
|
526
|
+
typename: 'CashappPaymentMethod';
|
|
527
|
+
}
|
|
528
|
+
|
|
529
|
+
export namespace CashappPaymentMethod {
|
|
530
|
+
/**
|
|
531
|
+
* The Cash App details associated with this payment method
|
|
532
|
+
*/
|
|
533
|
+
export interface Cashapp {
|
|
534
|
+
/**
|
|
535
|
+
* A unique and immutable identifier assigned by Cash App to every buyer.
|
|
536
|
+
*/
|
|
537
|
+
buyer_id: string | null;
|
|
538
|
+
|
|
539
|
+
/**
|
|
540
|
+
* A public identifier for buyers using Cash App.
|
|
541
|
+
*/
|
|
542
|
+
cashtag: string | null;
|
|
543
|
+
}
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
/**
|
|
547
|
+
* The iDEAL details for the payment method
|
|
548
|
+
*/
|
|
549
|
+
export interface IdealPaymentMethod {
|
|
550
|
+
/**
|
|
551
|
+
* The ID of the payment method
|
|
552
|
+
*/
|
|
553
|
+
id: string;
|
|
554
|
+
|
|
555
|
+
/**
|
|
556
|
+
* When the payment method was created
|
|
557
|
+
*/
|
|
558
|
+
created_at: string;
|
|
559
|
+
|
|
560
|
+
/**
|
|
561
|
+
* The iDEAL details associated with this payment method
|
|
562
|
+
*/
|
|
563
|
+
ideal: IdealPaymentMethod.Ideal;
|
|
564
|
+
|
|
565
|
+
/**
|
|
566
|
+
* The type of the payment method
|
|
567
|
+
*/
|
|
568
|
+
payment_method_type: PaymentsAPI.PaymentMethodTypes;
|
|
569
|
+
|
|
570
|
+
/**
|
|
571
|
+
* The typename of this object
|
|
572
|
+
*/
|
|
573
|
+
typename: 'IdealPaymentMethod';
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
export namespace IdealPaymentMethod {
|
|
577
|
+
/**
|
|
578
|
+
* The iDEAL details associated with this payment method
|
|
579
|
+
*/
|
|
580
|
+
export interface Ideal {
|
|
581
|
+
/**
|
|
582
|
+
* The customer's bank.
|
|
583
|
+
*/
|
|
584
|
+
bank: string | null;
|
|
585
|
+
|
|
586
|
+
/**
|
|
587
|
+
* The Bank Identifier Code of the customer's bank.
|
|
588
|
+
*/
|
|
589
|
+
bic: string | null;
|
|
590
|
+
}
|
|
591
|
+
}
|
|
592
|
+
|
|
593
|
+
/**
|
|
594
|
+
* The SEPA Direct Debit details for the payment method
|
|
595
|
+
*/
|
|
596
|
+
export interface SepaDebitPaymentMethod {
|
|
597
|
+
/**
|
|
598
|
+
* The ID of the payment method
|
|
599
|
+
*/
|
|
600
|
+
id: string;
|
|
601
|
+
|
|
602
|
+
/**
|
|
603
|
+
* When the payment method was created
|
|
604
|
+
*/
|
|
605
|
+
created_at: string;
|
|
606
|
+
|
|
607
|
+
/**
|
|
608
|
+
* The type of the payment method
|
|
609
|
+
*/
|
|
610
|
+
payment_method_type: PaymentsAPI.PaymentMethodTypes;
|
|
611
|
+
|
|
612
|
+
/**
|
|
613
|
+
* The SEPA Direct Debit details associated with this payment method
|
|
614
|
+
*/
|
|
615
|
+
sepa_debit: SepaDebitPaymentMethod.SepaDebit;
|
|
616
|
+
|
|
617
|
+
/**
|
|
618
|
+
* The typename of this object
|
|
619
|
+
*/
|
|
620
|
+
typename: 'SepaDebitPaymentMethod';
|
|
621
|
+
}
|
|
622
|
+
|
|
623
|
+
export namespace SepaDebitPaymentMethod {
|
|
624
|
+
/**
|
|
625
|
+
* The SEPA Direct Debit details associated with this payment method
|
|
626
|
+
*/
|
|
627
|
+
export interface SepaDebit {
|
|
628
|
+
/**
|
|
629
|
+
* Bank code of the bank associated with the account.
|
|
630
|
+
*/
|
|
631
|
+
bank_code: string | null;
|
|
632
|
+
|
|
633
|
+
/**
|
|
634
|
+
* Branch code of the bank associated with the account.
|
|
635
|
+
*/
|
|
636
|
+
branch_code: string | null;
|
|
637
|
+
|
|
638
|
+
/**
|
|
639
|
+
* Two-letter ISO code representing the country the bank account is located in.
|
|
640
|
+
*/
|
|
641
|
+
country: string | null;
|
|
642
|
+
|
|
643
|
+
/**
|
|
644
|
+
* Last four digits of the IBAN.
|
|
645
|
+
*/
|
|
646
|
+
last4: string | null;
|
|
647
|
+
}
|
|
648
|
+
}
|
|
341
649
|
}
|
|
342
650
|
|
|
343
651
|
export interface PaymentMethodRetrieveParams {
|
|
@@ -833,6 +833,33 @@ export interface CourseLessonInteractionCompletedWebhookEvent {
|
|
|
833
833
|
type: 'course_lesson_interaction.completed';
|
|
834
834
|
}
|
|
835
835
|
|
|
836
|
+
export interface PaymentCreatedWebhookEvent {
|
|
837
|
+
/**
|
|
838
|
+
* A unique ID for every single webhook request
|
|
839
|
+
*/
|
|
840
|
+
id: string;
|
|
841
|
+
|
|
842
|
+
/**
|
|
843
|
+
* The API version for this webhook
|
|
844
|
+
*/
|
|
845
|
+
api_version: 'v1';
|
|
846
|
+
|
|
847
|
+
/**
|
|
848
|
+
* An object representing a receipt for a membership.
|
|
849
|
+
*/
|
|
850
|
+
data: Shared.Payment;
|
|
851
|
+
|
|
852
|
+
/**
|
|
853
|
+
* The timestamp in ISO 8601 format that the webhook was sent at on the server
|
|
854
|
+
*/
|
|
855
|
+
timestamp: string;
|
|
856
|
+
|
|
857
|
+
/**
|
|
858
|
+
* The webhook event type
|
|
859
|
+
*/
|
|
860
|
+
type: 'payment.created';
|
|
861
|
+
}
|
|
862
|
+
|
|
836
863
|
export interface PaymentSucceededWebhookEvent {
|
|
837
864
|
/**
|
|
838
865
|
* A unique ID for every single webhook request
|
|
@@ -1441,6 +1468,7 @@ export type UnwrapWebhookEvent =
|
|
|
1441
1468
|
| WithdrawalCreatedWebhookEvent
|
|
1442
1469
|
| WithdrawalUpdatedWebhookEvent
|
|
1443
1470
|
| CourseLessonInteractionCompletedWebhookEvent
|
|
1471
|
+
| PaymentCreatedWebhookEvent
|
|
1444
1472
|
| PaymentSucceededWebhookEvent
|
|
1445
1473
|
| PaymentFailedWebhookEvent
|
|
1446
1474
|
| PaymentPendingWebhookEvent
|
|
@@ -1467,6 +1495,7 @@ export declare namespace Webhooks {
|
|
|
1467
1495
|
type WithdrawalCreatedWebhookEvent as WithdrawalCreatedWebhookEvent,
|
|
1468
1496
|
type WithdrawalUpdatedWebhookEvent as WithdrawalUpdatedWebhookEvent,
|
|
1469
1497
|
type CourseLessonInteractionCompletedWebhookEvent as CourseLessonInteractionCompletedWebhookEvent,
|
|
1498
|
+
type PaymentCreatedWebhookEvent as PaymentCreatedWebhookEvent,
|
|
1470
1499
|
type PaymentSucceededWebhookEvent as PaymentSucceededWebhookEvent,
|
|
1471
1500
|
type PaymentFailedWebhookEvent as PaymentFailedWebhookEvent,
|
|
1472
1501
|
type PaymentPendingWebhookEvent as PaymentPendingWebhookEvent,
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.0.
|
|
1
|
+
export const VERSION = '0.0.19'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.0.
|
|
1
|
+
export declare const VERSION = "0.0.19";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.0.
|
|
1
|
+
export declare const VERSION = "0.0.19";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.0.
|
|
1
|
+
export const VERSION = '0.0.19'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|