whop_sdk 0.0.17 → 0.0.18

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.
@@ -61,6 +61,26 @@ module WhopSDK
61
61
  end
62
62
  attr_accessor :payments_approval_status
63
63
 
64
+ # The payout account associated with the LedgerAccount, if any.
65
+ sig do
66
+ returns(
67
+ T.nilable(
68
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails
69
+ )
70
+ )
71
+ end
72
+ attr_reader :payout_account_details
73
+
74
+ sig do
75
+ params(
76
+ payout_account_details:
77
+ T.nilable(
78
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::OrHash
79
+ )
80
+ ).void
81
+ end
82
+ attr_writer :payout_account_details
83
+
64
84
  # The fee for transfers, if applicable.
65
85
  sig { returns(T.nilable(Float)) }
66
86
  attr_accessor :transfer_fee
@@ -90,6 +110,10 @@ module WhopSDK
90
110
  T.nilable(
91
111
  WhopSDK::Models::LedgerAccountRetrieveResponse::PaymentsApprovalStatus::OrSymbol
92
112
  ),
113
+ payout_account_details:
114
+ T.nilable(
115
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::OrHash
116
+ ),
93
117
  transfer_fee: T.nilable(Float)
94
118
  ).returns(T.attached_class)
95
119
  end
@@ -106,6 +130,8 @@ module WhopSDK
106
130
  owner:,
107
131
  # The different approval statuses an account can have.
108
132
  payments_approval_status:,
133
+ # The payout account associated with the LedgerAccount, if any.
134
+ payout_account_details:,
109
135
  # The fee for transfers, if applicable.
110
136
  transfer_fee:
111
137
  )
@@ -131,6 +157,10 @@ module WhopSDK
131
157
  T.nilable(
132
158
  WhopSDK::Models::LedgerAccountRetrieveResponse::PaymentsApprovalStatus::TaggedSymbol
133
159
  ),
160
+ payout_account_details:
161
+ T.nilable(
162
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails
163
+ ),
134
164
  transfer_fee: T.nilable(Float)
135
165
  }
136
166
  )
@@ -502,6 +532,238 @@ module WhopSDK
502
532
  def self.values
503
533
  end
504
534
  end
535
+
536
+ class PayoutAccountDetails < WhopSDK::Internal::Type::BaseModel
537
+ OrHash =
538
+ T.type_alias do
539
+ T.any(
540
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails,
541
+ WhopSDK::Internal::AnyHash
542
+ )
543
+ end
544
+
545
+ # Unique identifier for the object
546
+ sig { returns(String) }
547
+ attr_accessor :id
548
+
549
+ # The physical address associated with this payout account
550
+ sig do
551
+ returns(
552
+ T.nilable(
553
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::Address
554
+ )
555
+ )
556
+ end
557
+ attr_reader :address
558
+
559
+ sig do
560
+ params(
561
+ address:
562
+ T.nilable(
563
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::Address::OrHash
564
+ )
565
+ ).void
566
+ end
567
+ attr_writer :address
568
+
569
+ # The company's legal name
570
+ sig { returns(T.nilable(String)) }
571
+ attr_accessor :business_name
572
+
573
+ # The business representative for this payout account
574
+ sig do
575
+ returns(
576
+ T.nilable(
577
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::BusinessRepresentative
578
+ )
579
+ )
580
+ end
581
+ attr_reader :business_representative
582
+
583
+ sig do
584
+ params(
585
+ business_representative:
586
+ T.nilable(
587
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::BusinessRepresentative::OrHash
588
+ )
589
+ ).void
590
+ end
591
+ attr_writer :business_representative
592
+
593
+ # The payout account associated with the LedgerAccount, if any.
594
+ sig do
595
+ params(
596
+ id: String,
597
+ address:
598
+ T.nilable(
599
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::Address::OrHash
600
+ ),
601
+ business_name: T.nilable(String),
602
+ business_representative:
603
+ T.nilable(
604
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::BusinessRepresentative::OrHash
605
+ )
606
+ ).returns(T.attached_class)
607
+ end
608
+ def self.new(
609
+ # Unique identifier for the object
610
+ id:,
611
+ # The physical address associated with this payout account
612
+ address:,
613
+ # The company's legal name
614
+ business_name:,
615
+ # The business representative for this payout account
616
+ business_representative:
617
+ )
618
+ end
619
+
620
+ sig do
621
+ override.returns(
622
+ {
623
+ id: String,
624
+ address:
625
+ T.nilable(
626
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::Address
627
+ ),
628
+ business_name: T.nilable(String),
629
+ business_representative:
630
+ T.nilable(
631
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::BusinessRepresentative
632
+ )
633
+ }
634
+ )
635
+ end
636
+ def to_hash
637
+ end
638
+
639
+ class Address < WhopSDK::Internal::Type::BaseModel
640
+ OrHash =
641
+ T.type_alias do
642
+ T.any(
643
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::Address,
644
+ WhopSDK::Internal::AnyHash
645
+ )
646
+ end
647
+
648
+ # The city of the address.
649
+ sig { returns(T.nilable(String)) }
650
+ attr_accessor :city
651
+
652
+ # The country of the address.
653
+ sig { returns(T.nilable(String)) }
654
+ attr_accessor :country
655
+
656
+ # The line 1 of the address.
657
+ sig { returns(T.nilable(String)) }
658
+ attr_accessor :line1
659
+
660
+ # The line 2 of the address.
661
+ sig { returns(T.nilable(String)) }
662
+ attr_accessor :line2
663
+
664
+ # The postal code of the address.
665
+ sig { returns(T.nilable(String)) }
666
+ attr_accessor :postal_code
667
+
668
+ # The state of the address.
669
+ sig { returns(T.nilable(String)) }
670
+ attr_accessor :state
671
+
672
+ # The physical address associated with this payout account
673
+ sig do
674
+ params(
675
+ city: T.nilable(String),
676
+ country: T.nilable(String),
677
+ line1: T.nilable(String),
678
+ line2: T.nilable(String),
679
+ postal_code: T.nilable(String),
680
+ state: T.nilable(String)
681
+ ).returns(T.attached_class)
682
+ end
683
+ def self.new(
684
+ # The city of the address.
685
+ city:,
686
+ # The country of the address.
687
+ country:,
688
+ # The line 1 of the address.
689
+ line1:,
690
+ # The line 2 of the address.
691
+ line2:,
692
+ # The postal code of the address.
693
+ postal_code:,
694
+ # The state of the address.
695
+ state:
696
+ )
697
+ end
698
+
699
+ sig do
700
+ override.returns(
701
+ {
702
+ city: T.nilable(String),
703
+ country: T.nilable(String),
704
+ line1: T.nilable(String),
705
+ line2: T.nilable(String),
706
+ postal_code: T.nilable(String),
707
+ state: T.nilable(String)
708
+ }
709
+ )
710
+ end
711
+ def to_hash
712
+ end
713
+ end
714
+
715
+ class BusinessRepresentative < WhopSDK::Internal::Type::BaseModel
716
+ OrHash =
717
+ T.type_alias do
718
+ T.any(
719
+ WhopSDK::Models::LedgerAccountRetrieveResponse::PayoutAccountDetails::BusinessRepresentative,
720
+ WhopSDK::Internal::AnyHash
721
+ )
722
+ end
723
+
724
+ # The first name of the business representative.
725
+ sig { returns(T.nilable(String)) }
726
+ attr_accessor :first_name
727
+
728
+ # The last name of the business representative.
729
+ sig { returns(T.nilable(String)) }
730
+ attr_accessor :last_name
731
+
732
+ # The middle name of the business representative.
733
+ sig { returns(T.nilable(String)) }
734
+ attr_accessor :middle_name
735
+
736
+ # The business representative for this payout account
737
+ sig do
738
+ params(
739
+ first_name: T.nilable(String),
740
+ last_name: T.nilable(String),
741
+ middle_name: T.nilable(String)
742
+ ).returns(T.attached_class)
743
+ end
744
+ def self.new(
745
+ # The first name of the business representative.
746
+ first_name:,
747
+ # The last name of the business representative.
748
+ last_name:,
749
+ # The middle name of the business representative.
750
+ middle_name:
751
+ )
752
+ end
753
+
754
+ sig do
755
+ override.returns(
756
+ {
757
+ first_name: T.nilable(String),
758
+ last_name: T.nilable(String),
759
+ middle_name: T.nilable(String)
760
+ }
761
+ )
762
+ end
763
+ def to_hash
764
+ end
765
+ end
766
+ end
505
767
  end
506
768
  end
507
769
  end
@@ -11,7 +11,10 @@ module WhopSDK
11
11
  T.any(
12
12
  WhopSDK::Models::PaymentMethodListResponse::BasePaymentMethod,
13
13
  WhopSDK::Models::PaymentMethodListResponse::CardPaymentMethod,
14
- WhopSDK::Models::PaymentMethodListResponse::UsBankAccountPaymentMethod
14
+ WhopSDK::Models::PaymentMethodListResponse::UsBankAccountPaymentMethod,
15
+ WhopSDK::Models::PaymentMethodListResponse::CashappPaymentMethod,
16
+ WhopSDK::Models::PaymentMethodListResponse::IdealPaymentMethod,
17
+ WhopSDK::Models::PaymentMethodListResponse::SepaDebitPaymentMethod
15
18
  )
16
19
  end
17
20
 
@@ -347,6 +350,393 @@ module WhopSDK
347
350
  end
348
351
  end
349
352
 
353
+ class CashappPaymentMethod < WhopSDK::Internal::Type::BaseModel
354
+ OrHash =
355
+ T.type_alias do
356
+ T.any(
357
+ WhopSDK::Models::PaymentMethodListResponse::CashappPaymentMethod,
358
+ WhopSDK::Internal::AnyHash
359
+ )
360
+ end
361
+
362
+ # The ID of the payment method
363
+ sig { returns(String) }
364
+ attr_accessor :id
365
+
366
+ # The Cash App details associated with this payment method
367
+ sig do
368
+ returns(
369
+ WhopSDK::Models::PaymentMethodListResponse::CashappPaymentMethod::Cashapp
370
+ )
371
+ end
372
+ attr_reader :cashapp
373
+
374
+ sig do
375
+ params(
376
+ cashapp:
377
+ WhopSDK::Models::PaymentMethodListResponse::CashappPaymentMethod::Cashapp::OrHash
378
+ ).void
379
+ end
380
+ attr_writer :cashapp
381
+
382
+ # When the payment method was created
383
+ sig { returns(Time) }
384
+ attr_accessor :created_at
385
+
386
+ # The type of the payment method
387
+ sig { returns(WhopSDK::PaymentMethodTypes::TaggedSymbol) }
388
+ attr_accessor :payment_method_type
389
+
390
+ # The typename of this object
391
+ sig { returns(Symbol) }
392
+ attr_accessor :typename
393
+
394
+ # The Cash App details for the payment method
395
+ sig do
396
+ params(
397
+ id: String,
398
+ cashapp:
399
+ WhopSDK::Models::PaymentMethodListResponse::CashappPaymentMethod::Cashapp::OrHash,
400
+ created_at: Time,
401
+ payment_method_type: WhopSDK::PaymentMethodTypes::OrSymbol,
402
+ typename: Symbol
403
+ ).returns(T.attached_class)
404
+ end
405
+ def self.new(
406
+ # The ID of the payment method
407
+ id:,
408
+ # The Cash App details associated with this payment method
409
+ cashapp:,
410
+ # When the payment method was created
411
+ created_at:,
412
+ # The type of the payment method
413
+ payment_method_type:,
414
+ # The typename of this object
415
+ typename: :CashappPaymentMethod
416
+ )
417
+ end
418
+
419
+ sig do
420
+ override.returns(
421
+ {
422
+ id: String,
423
+ cashapp:
424
+ WhopSDK::Models::PaymentMethodListResponse::CashappPaymentMethod::Cashapp,
425
+ created_at: Time,
426
+ payment_method_type: WhopSDK::PaymentMethodTypes::TaggedSymbol,
427
+ typename: Symbol
428
+ }
429
+ )
430
+ end
431
+ def to_hash
432
+ end
433
+
434
+ class Cashapp < WhopSDK::Internal::Type::BaseModel
435
+ OrHash =
436
+ T.type_alias do
437
+ T.any(
438
+ WhopSDK::Models::PaymentMethodListResponse::CashappPaymentMethod::Cashapp,
439
+ WhopSDK::Internal::AnyHash
440
+ )
441
+ end
442
+
443
+ # A unique and immutable identifier assigned by Cash App to every buyer.
444
+ sig { returns(T.nilable(String)) }
445
+ attr_accessor :buyer_id
446
+
447
+ # A public identifier for buyers using Cash App.
448
+ sig { returns(T.nilable(String)) }
449
+ attr_accessor :cashtag
450
+
451
+ # The Cash App details associated with this payment method
452
+ sig do
453
+ params(
454
+ buyer_id: T.nilable(String),
455
+ cashtag: T.nilable(String)
456
+ ).returns(T.attached_class)
457
+ end
458
+ def self.new(
459
+ # A unique and immutable identifier assigned by Cash App to every buyer.
460
+ buyer_id:,
461
+ # A public identifier for buyers using Cash App.
462
+ cashtag:
463
+ )
464
+ end
465
+
466
+ sig do
467
+ override.returns(
468
+ { buyer_id: T.nilable(String), cashtag: T.nilable(String) }
469
+ )
470
+ end
471
+ def to_hash
472
+ end
473
+ end
474
+ end
475
+
476
+ class IdealPaymentMethod < WhopSDK::Internal::Type::BaseModel
477
+ OrHash =
478
+ T.type_alias do
479
+ T.any(
480
+ WhopSDK::Models::PaymentMethodListResponse::IdealPaymentMethod,
481
+ WhopSDK::Internal::AnyHash
482
+ )
483
+ end
484
+
485
+ # The ID of the payment method
486
+ sig { returns(String) }
487
+ attr_accessor :id
488
+
489
+ # When the payment method was created
490
+ sig { returns(Time) }
491
+ attr_accessor :created_at
492
+
493
+ # The iDEAL details associated with this payment method
494
+ sig do
495
+ returns(
496
+ WhopSDK::Models::PaymentMethodListResponse::IdealPaymentMethod::Ideal
497
+ )
498
+ end
499
+ attr_reader :ideal
500
+
501
+ sig do
502
+ params(
503
+ ideal:
504
+ WhopSDK::Models::PaymentMethodListResponse::IdealPaymentMethod::Ideal::OrHash
505
+ ).void
506
+ end
507
+ attr_writer :ideal
508
+
509
+ # The type of the payment method
510
+ sig { returns(WhopSDK::PaymentMethodTypes::TaggedSymbol) }
511
+ attr_accessor :payment_method_type
512
+
513
+ # The typename of this object
514
+ sig { returns(Symbol) }
515
+ attr_accessor :typename
516
+
517
+ # The iDEAL details for the payment method
518
+ sig do
519
+ params(
520
+ id: String,
521
+ created_at: Time,
522
+ ideal:
523
+ WhopSDK::Models::PaymentMethodListResponse::IdealPaymentMethod::Ideal::OrHash,
524
+ payment_method_type: WhopSDK::PaymentMethodTypes::OrSymbol,
525
+ typename: Symbol
526
+ ).returns(T.attached_class)
527
+ end
528
+ def self.new(
529
+ # The ID of the payment method
530
+ id:,
531
+ # When the payment method was created
532
+ created_at:,
533
+ # The iDEAL details associated with this payment method
534
+ ideal:,
535
+ # The type of the payment method
536
+ payment_method_type:,
537
+ # The typename of this object
538
+ typename: :IdealPaymentMethod
539
+ )
540
+ end
541
+
542
+ sig do
543
+ override.returns(
544
+ {
545
+ id: String,
546
+ created_at: Time,
547
+ ideal:
548
+ WhopSDK::Models::PaymentMethodListResponse::IdealPaymentMethod::Ideal,
549
+ payment_method_type: WhopSDK::PaymentMethodTypes::TaggedSymbol,
550
+ typename: Symbol
551
+ }
552
+ )
553
+ end
554
+ def to_hash
555
+ end
556
+
557
+ class Ideal < WhopSDK::Internal::Type::BaseModel
558
+ OrHash =
559
+ T.type_alias do
560
+ T.any(
561
+ WhopSDK::Models::PaymentMethodListResponse::IdealPaymentMethod::Ideal,
562
+ WhopSDK::Internal::AnyHash
563
+ )
564
+ end
565
+
566
+ # The customer's bank.
567
+ sig { returns(T.nilable(String)) }
568
+ attr_accessor :bank
569
+
570
+ # The Bank Identifier Code of the customer's bank.
571
+ sig { returns(T.nilable(String)) }
572
+ attr_accessor :bic
573
+
574
+ # The iDEAL details associated with this payment method
575
+ sig do
576
+ params(bank: T.nilable(String), bic: T.nilable(String)).returns(
577
+ T.attached_class
578
+ )
579
+ end
580
+ def self.new(
581
+ # The customer's bank.
582
+ bank:,
583
+ # The Bank Identifier Code of the customer's bank.
584
+ bic:
585
+ )
586
+ end
587
+
588
+ sig do
589
+ override.returns(
590
+ { bank: T.nilable(String), bic: T.nilable(String) }
591
+ )
592
+ end
593
+ def to_hash
594
+ end
595
+ end
596
+ end
597
+
598
+ class SepaDebitPaymentMethod < WhopSDK::Internal::Type::BaseModel
599
+ OrHash =
600
+ T.type_alias do
601
+ T.any(
602
+ WhopSDK::Models::PaymentMethodListResponse::SepaDebitPaymentMethod,
603
+ WhopSDK::Internal::AnyHash
604
+ )
605
+ end
606
+
607
+ # The ID of the payment method
608
+ sig { returns(String) }
609
+ attr_accessor :id
610
+
611
+ # When the payment method was created
612
+ sig { returns(Time) }
613
+ attr_accessor :created_at
614
+
615
+ # The type of the payment method
616
+ sig { returns(WhopSDK::PaymentMethodTypes::TaggedSymbol) }
617
+ attr_accessor :payment_method_type
618
+
619
+ # The SEPA Direct Debit details associated with this payment method
620
+ sig do
621
+ returns(
622
+ WhopSDK::Models::PaymentMethodListResponse::SepaDebitPaymentMethod::SepaDebit
623
+ )
624
+ end
625
+ attr_reader :sepa_debit
626
+
627
+ sig do
628
+ params(
629
+ sepa_debit:
630
+ WhopSDK::Models::PaymentMethodListResponse::SepaDebitPaymentMethod::SepaDebit::OrHash
631
+ ).void
632
+ end
633
+ attr_writer :sepa_debit
634
+
635
+ # The typename of this object
636
+ sig { returns(Symbol) }
637
+ attr_accessor :typename
638
+
639
+ # The SEPA Direct Debit details for the payment method
640
+ sig do
641
+ params(
642
+ id: String,
643
+ created_at: Time,
644
+ payment_method_type: WhopSDK::PaymentMethodTypes::OrSymbol,
645
+ sepa_debit:
646
+ WhopSDK::Models::PaymentMethodListResponse::SepaDebitPaymentMethod::SepaDebit::OrHash,
647
+ typename: Symbol
648
+ ).returns(T.attached_class)
649
+ end
650
+ def self.new(
651
+ # The ID of the payment method
652
+ id:,
653
+ # When the payment method was created
654
+ created_at:,
655
+ # The type of the payment method
656
+ payment_method_type:,
657
+ # The SEPA Direct Debit details associated with this payment method
658
+ sepa_debit:,
659
+ # The typename of this object
660
+ typename: :SepaDebitPaymentMethod
661
+ )
662
+ end
663
+
664
+ sig do
665
+ override.returns(
666
+ {
667
+ id: String,
668
+ created_at: Time,
669
+ payment_method_type: WhopSDK::PaymentMethodTypes::TaggedSymbol,
670
+ sepa_debit:
671
+ WhopSDK::Models::PaymentMethodListResponse::SepaDebitPaymentMethod::SepaDebit,
672
+ typename: Symbol
673
+ }
674
+ )
675
+ end
676
+ def to_hash
677
+ end
678
+
679
+ class SepaDebit < WhopSDK::Internal::Type::BaseModel
680
+ OrHash =
681
+ T.type_alias do
682
+ T.any(
683
+ WhopSDK::Models::PaymentMethodListResponse::SepaDebitPaymentMethod::SepaDebit,
684
+ WhopSDK::Internal::AnyHash
685
+ )
686
+ end
687
+
688
+ # Bank code of the bank associated with the account.
689
+ sig { returns(T.nilable(String)) }
690
+ attr_accessor :bank_code
691
+
692
+ # Branch code of the bank associated with the account.
693
+ sig { returns(T.nilable(String)) }
694
+ attr_accessor :branch_code
695
+
696
+ # Two-letter ISO code representing the country the bank account is located in.
697
+ sig { returns(T.nilable(String)) }
698
+ attr_accessor :country
699
+
700
+ # Last four digits of the IBAN.
701
+ sig { returns(T.nilable(String)) }
702
+ attr_accessor :last4
703
+
704
+ # The SEPA Direct Debit details associated with this payment method
705
+ sig do
706
+ params(
707
+ bank_code: T.nilable(String),
708
+ branch_code: T.nilable(String),
709
+ country: T.nilable(String),
710
+ last4: T.nilable(String)
711
+ ).returns(T.attached_class)
712
+ end
713
+ def self.new(
714
+ # Bank code of the bank associated with the account.
715
+ bank_code:,
716
+ # Branch code of the bank associated with the account.
717
+ branch_code:,
718
+ # Two-letter ISO code representing the country the bank account is located in.
719
+ country:,
720
+ # Last four digits of the IBAN.
721
+ last4:
722
+ )
723
+ end
724
+
725
+ sig do
726
+ override.returns(
727
+ {
728
+ bank_code: T.nilable(String),
729
+ branch_code: T.nilable(String),
730
+ country: T.nilable(String),
731
+ last4: T.nilable(String)
732
+ }
733
+ )
734
+ end
735
+ def to_hash
736
+ end
737
+ end
738
+ end
739
+
350
740
  sig do
351
741
  override.returns(
352
742
  T::Array[WhopSDK::Models::PaymentMethodListResponse::Variants]