whop_sdk 0.0.14 → 0.0.16
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +24 -0
- data/README.md +1 -1
- data/lib/whop_sdk/client.rb +8 -0
- data/lib/whop_sdk/models/checkout_configuration.rb +9 -1
- data/lib/whop_sdk/models/checkout_configuration_create_params.rb +9 -1
- data/lib/whop_sdk/models/checkout_configuration_list_response.rb +9 -1
- data/lib/whop_sdk/models/course.rb +57 -1
- data/lib/whop_sdk/models/course_lesson_interaction.rb +23 -1
- data/lib/whop_sdk/models/course_lesson_interaction_list_item.rb +23 -1
- data/lib/whop_sdk/models/experience.rb +9 -1
- data/lib/whop_sdk/models/experience_create_params.rb +9 -1
- data/lib/whop_sdk/models/experience_list_response.rb +9 -1
- data/lib/whop_sdk/models/experience_update_params.rb +9 -1
- data/lib/whop_sdk/models/fee_markup_create_params.rb +62 -0
- data/lib/whop_sdk/models/fee_markup_create_response.rb +67 -0
- data/lib/whop_sdk/models/fee_markup_delete_params.rb +14 -0
- data/lib/whop_sdk/models/fee_markup_delete_response.rb +8 -0
- data/lib/whop_sdk/models/fee_markup_list_params.rb +58 -0
- data/lib/whop_sdk/models/fee_markup_list_response.rb +67 -0
- data/lib/whop_sdk/models/fee_markup_type.rb +19 -0
- data/lib/whop_sdk/models/payment_list_fees_params.rb +46 -0
- data/lib/whop_sdk/models/payment_list_fees_response.rb +84 -0
- data/lib/whop_sdk/models/payment_method_list_response.rb +214 -76
- data/lib/whop_sdk/models/payment_method_retrieve_response.rb +214 -76
- data/lib/whop_sdk/models/payout_method_list_params.rb +54 -0
- data/lib/whop_sdk/models/payout_method_list_response.rb +95 -0
- data/lib/whop_sdk/models/withdrawal_create_params.rb +46 -0
- data/lib/whop_sdk/models/withdrawal_create_response.rb +275 -0
- data/lib/whop_sdk/models.rb +14 -0
- data/lib/whop_sdk/resources/checkout_configurations.rb +3 -1
- data/lib/whop_sdk/resources/experiences.rb +6 -2
- data/lib/whop_sdk/resources/fee_markups.rb +112 -0
- data/lib/whop_sdk/resources/payment_methods.rb +2 -2
- data/lib/whop_sdk/resources/payments.rb +35 -0
- data/lib/whop_sdk/resources/payout_methods.rb +49 -0
- data/lib/whop_sdk/resources/withdrawals.rb +34 -0
- data/lib/whop_sdk/version.rb +1 -1
- data/lib/whop_sdk.rb +15 -0
- data/rbi/whop_sdk/client.rbi +6 -0
- data/rbi/whop_sdk/models/checkout_configuration.rbi +8 -0
- data/rbi/whop_sdk/models/checkout_configuration_create_params.rbi +8 -0
- data/rbi/whop_sdk/models/checkout_configuration_list_response.rbi +8 -0
- data/rbi/whop_sdk/models/course.rbi +115 -3
- data/rbi/whop_sdk/models/course_lesson_interaction.rbi +55 -2
- data/rbi/whop_sdk/models/course_lesson_interaction_list_item.rbi +60 -2
- data/rbi/whop_sdk/models/experience.rbi +8 -0
- data/rbi/whop_sdk/models/experience_create_params.rbi +8 -0
- data/rbi/whop_sdk/models/experience_list_response.rbi +8 -0
- data/rbi/whop_sdk/models/experience_update_params.rbi +8 -0
- data/rbi/whop_sdk/models/fee_markup_create_params.rbi +83 -0
- data/rbi/whop_sdk/models/fee_markup_create_response.rbi +89 -0
- data/rbi/whop_sdk/models/fee_markup_delete_params.rbi +27 -0
- data/rbi/whop_sdk/models/fee_markup_delete_response.rbi +8 -0
- data/rbi/whop_sdk/models/fee_markup_list_params.rbi +77 -0
- data/rbi/whop_sdk/models/fee_markup_list_response.rbi +89 -0
- data/rbi/whop_sdk/models/fee_markup_type.rbi +37 -0
- data/rbi/whop_sdk/models/payment_list_fees_params.rbi +67 -0
- data/rbi/whop_sdk/models/payment_list_fees_response.rbi +239 -0
- data/rbi/whop_sdk/models/payment_method_list_response.rbi +305 -83
- data/rbi/whop_sdk/models/payment_method_retrieve_response.rbi +305 -88
- data/rbi/whop_sdk/models/payout_method_list_params.rbi +75 -0
- data/rbi/whop_sdk/models/payout_method_list_response.rbi +200 -0
- data/rbi/whop_sdk/models/withdrawal_create_params.rbi +67 -0
- data/rbi/whop_sdk/models/withdrawal_create_response.rbi +564 -0
- data/rbi/whop_sdk/models.rbi +14 -0
- data/rbi/whop_sdk/resources/checkout_configurations.rbi +3 -0
- data/rbi/whop_sdk/resources/experiences.rbi +6 -0
- data/rbi/whop_sdk/resources/fee_markups.rbi +96 -0
- data/rbi/whop_sdk/resources/payment_methods.rbi +2 -2
- data/rbi/whop_sdk/resources/payments.rbi +34 -0
- data/rbi/whop_sdk/resources/payout_methods.rbi +46 -0
- data/rbi/whop_sdk/resources/withdrawals.rbi +29 -0
- data/sig/whop_sdk/client.rbs +4 -0
- data/sig/whop_sdk/models/checkout_configuration.rbs +5 -0
- data/sig/whop_sdk/models/checkout_configuration_create_params.rbs +5 -0
- data/sig/whop_sdk/models/checkout_configuration_list_response.rbs +5 -0
- data/sig/whop_sdk/models/course.rbs +45 -3
- data/sig/whop_sdk/models/course_lesson_interaction.rbs +28 -3
- data/sig/whop_sdk/models/course_lesson_interaction_list_item.rbs +28 -3
- data/sig/whop_sdk/models/experience.rbs +5 -0
- data/sig/whop_sdk/models/experience_create_params.rbs +11 -1
- data/sig/whop_sdk/models/experience_list_response.rbs +5 -0
- data/sig/whop_sdk/models/experience_update_params.rbs +5 -0
- data/sig/whop_sdk/models/fee_markup_create_params.rbs +51 -0
- data/sig/whop_sdk/models/fee_markup_create_response.rbs +50 -0
- data/sig/whop_sdk/models/fee_markup_delete_params.rbs +15 -0
- data/sig/whop_sdk/models/fee_markup_delete_response.rbs +5 -0
- data/sig/whop_sdk/models/fee_markup_list_params.rbs +46 -0
- data/sig/whop_sdk/models/fee_markup_list_response.rbs +50 -0
- data/sig/whop_sdk/models/fee_markup_type.rbs +22 -0
- data/sig/whop_sdk/models/payment_list_fees_params.rbs +36 -0
- data/sig/whop_sdk/models/payment_list_fees_response.rbs +104 -0
- data/sig/whop_sdk/models/payment_method_list_response.rbs +149 -41
- data/sig/whop_sdk/models/payment_method_retrieve_response.rbs +149 -41
- data/sig/whop_sdk/models/payout_method_list_params.rbs +46 -0
- data/sig/whop_sdk/models/payout_method_list_response.rbs +83 -0
- data/sig/whop_sdk/models/withdrawal_create_params.rbs +41 -0
- data/sig/whop_sdk/models/withdrawal_create_response.rbs +243 -0
- data/sig/whop_sdk/models.rbs +14 -0
- data/sig/whop_sdk/resources/checkout_configurations.rbs +1 -0
- data/sig/whop_sdk/resources/experiences.rbs +2 -0
- data/sig/whop_sdk/resources/fee_markups.rbs +28 -0
- data/sig/whop_sdk/resources/payment_methods.rbs +2 -2
- data/sig/whop_sdk/resources/payments.rbs +9 -0
- data/sig/whop_sdk/resources/payout_methods.rbs +16 -0
- data/sig/whop_sdk/resources/withdrawals.rbs +8 -0
- metadata +47 -2
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module WhopSDK
|
|
4
|
+
module Models
|
|
5
|
+
class PayoutMethodListResponse < WhopSDK::Internal::Type::BaseModel
|
|
6
|
+
OrHash =
|
|
7
|
+
T.type_alias do
|
|
8
|
+
T.any(
|
|
9
|
+
WhopSDK::Models::PayoutMethodListResponse,
|
|
10
|
+
WhopSDK::Internal::AnyHash
|
|
11
|
+
)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
# The ID of the payout token
|
|
15
|
+
sig { returns(String) }
|
|
16
|
+
attr_accessor :id
|
|
17
|
+
|
|
18
|
+
# The currency code of the payout destination. This is the currency that payouts
|
|
19
|
+
# will be made in for this token.
|
|
20
|
+
sig { returns(String) }
|
|
21
|
+
attr_accessor :currency
|
|
22
|
+
|
|
23
|
+
# The payout destination associated with the payout token
|
|
24
|
+
sig do
|
|
25
|
+
returns(
|
|
26
|
+
T.nilable(WhopSDK::Models::PayoutMethodListResponse::Destination)
|
|
27
|
+
)
|
|
28
|
+
end
|
|
29
|
+
attr_reader :destination
|
|
30
|
+
|
|
31
|
+
sig do
|
|
32
|
+
params(
|
|
33
|
+
destination:
|
|
34
|
+
T.nilable(
|
|
35
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::OrHash
|
|
36
|
+
)
|
|
37
|
+
).void
|
|
38
|
+
end
|
|
39
|
+
attr_writer :destination
|
|
40
|
+
|
|
41
|
+
# An optional nickname for the payout token to help the user identify it. This is
|
|
42
|
+
# not used by the provider and is only for the user's reference.
|
|
43
|
+
sig { returns(T.nilable(String)) }
|
|
44
|
+
attr_accessor :nickname
|
|
45
|
+
|
|
46
|
+
# An object representing an user's setup payout destination.
|
|
47
|
+
sig do
|
|
48
|
+
params(
|
|
49
|
+
id: String,
|
|
50
|
+
currency: String,
|
|
51
|
+
destination:
|
|
52
|
+
T.nilable(
|
|
53
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::OrHash
|
|
54
|
+
),
|
|
55
|
+
nickname: T.nilable(String)
|
|
56
|
+
).returns(T.attached_class)
|
|
57
|
+
end
|
|
58
|
+
def self.new(
|
|
59
|
+
# The ID of the payout token
|
|
60
|
+
id:,
|
|
61
|
+
# The currency code of the payout destination. This is the currency that payouts
|
|
62
|
+
# will be made in for this token.
|
|
63
|
+
currency:,
|
|
64
|
+
# The payout destination associated with the payout token
|
|
65
|
+
destination:,
|
|
66
|
+
# An optional nickname for the payout token to help the user identify it. This is
|
|
67
|
+
# not used by the provider and is only for the user's reference.
|
|
68
|
+
nickname:
|
|
69
|
+
)
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
sig do
|
|
73
|
+
override.returns(
|
|
74
|
+
{
|
|
75
|
+
id: String,
|
|
76
|
+
currency: String,
|
|
77
|
+
destination:
|
|
78
|
+
T.nilable(WhopSDK::Models::PayoutMethodListResponse::Destination),
|
|
79
|
+
nickname: T.nilable(String)
|
|
80
|
+
}
|
|
81
|
+
)
|
|
82
|
+
end
|
|
83
|
+
def to_hash
|
|
84
|
+
end
|
|
85
|
+
|
|
86
|
+
class Destination < WhopSDK::Internal::Type::BaseModel
|
|
87
|
+
OrHash =
|
|
88
|
+
T.type_alias do
|
|
89
|
+
T.any(
|
|
90
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination,
|
|
91
|
+
WhopSDK::Internal::AnyHash
|
|
92
|
+
)
|
|
93
|
+
end
|
|
94
|
+
|
|
95
|
+
# The category of the payout destination
|
|
96
|
+
sig do
|
|
97
|
+
returns(
|
|
98
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
99
|
+
)
|
|
100
|
+
end
|
|
101
|
+
attr_accessor :category
|
|
102
|
+
|
|
103
|
+
# The country code of the payout destination
|
|
104
|
+
sig { returns(String) }
|
|
105
|
+
attr_accessor :country_code
|
|
106
|
+
|
|
107
|
+
# The name of the payer associated with the payout destination
|
|
108
|
+
sig { returns(String) }
|
|
109
|
+
attr_accessor :name
|
|
110
|
+
|
|
111
|
+
# The payout destination associated with the payout token
|
|
112
|
+
sig do
|
|
113
|
+
params(
|
|
114
|
+
category:
|
|
115
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::OrSymbol,
|
|
116
|
+
country_code: String,
|
|
117
|
+
name: String
|
|
118
|
+
).returns(T.attached_class)
|
|
119
|
+
end
|
|
120
|
+
def self.new(
|
|
121
|
+
# The category of the payout destination
|
|
122
|
+
category:,
|
|
123
|
+
# The country code of the payout destination
|
|
124
|
+
country_code:,
|
|
125
|
+
# The name of the payer associated with the payout destination
|
|
126
|
+
name:
|
|
127
|
+
)
|
|
128
|
+
end
|
|
129
|
+
|
|
130
|
+
sig do
|
|
131
|
+
override.returns(
|
|
132
|
+
{
|
|
133
|
+
category:
|
|
134
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol,
|
|
135
|
+
country_code: String,
|
|
136
|
+
name: String
|
|
137
|
+
}
|
|
138
|
+
)
|
|
139
|
+
end
|
|
140
|
+
def to_hash
|
|
141
|
+
end
|
|
142
|
+
|
|
143
|
+
# The category of the payout destination
|
|
144
|
+
module Category
|
|
145
|
+
extend WhopSDK::Internal::Type::Enum
|
|
146
|
+
|
|
147
|
+
TaggedSymbol =
|
|
148
|
+
T.type_alias do
|
|
149
|
+
T.all(
|
|
150
|
+
Symbol,
|
|
151
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category
|
|
152
|
+
)
|
|
153
|
+
end
|
|
154
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
155
|
+
|
|
156
|
+
CRYPTO =
|
|
157
|
+
T.let(
|
|
158
|
+
:crypto,
|
|
159
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
160
|
+
)
|
|
161
|
+
RTP =
|
|
162
|
+
T.let(
|
|
163
|
+
:rtp,
|
|
164
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
165
|
+
)
|
|
166
|
+
NEXT_DAY_BANK =
|
|
167
|
+
T.let(
|
|
168
|
+
:next_day_bank,
|
|
169
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
170
|
+
)
|
|
171
|
+
BANK_WIRE =
|
|
172
|
+
T.let(
|
|
173
|
+
:bank_wire,
|
|
174
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
175
|
+
)
|
|
176
|
+
DIGITAL_WALLET =
|
|
177
|
+
T.let(
|
|
178
|
+
:digital_wallet,
|
|
179
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
180
|
+
)
|
|
181
|
+
UNKNOWN =
|
|
182
|
+
T.let(
|
|
183
|
+
:unknown,
|
|
184
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
185
|
+
)
|
|
186
|
+
|
|
187
|
+
sig do
|
|
188
|
+
override.returns(
|
|
189
|
+
T::Array[
|
|
190
|
+
WhopSDK::Models::PayoutMethodListResponse::Destination::Category::TaggedSymbol
|
|
191
|
+
]
|
|
192
|
+
)
|
|
193
|
+
end
|
|
194
|
+
def self.values
|
|
195
|
+
end
|
|
196
|
+
end
|
|
197
|
+
end
|
|
198
|
+
end
|
|
199
|
+
end
|
|
200
|
+
end
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module WhopSDK
|
|
4
|
+
module Models
|
|
5
|
+
class WithdrawalCreateParams < WhopSDK::Internal::Type::BaseModel
|
|
6
|
+
extend WhopSDK::Internal::Type::RequestParameters::Converter
|
|
7
|
+
include WhopSDK::Internal::Type::RequestParameters
|
|
8
|
+
|
|
9
|
+
OrHash =
|
|
10
|
+
T.type_alias do
|
|
11
|
+
T.any(WhopSDK::WithdrawalCreateParams, WhopSDK::Internal::AnyHash)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
# The amount to withdraw in the specified currency
|
|
15
|
+
sig { returns(Float) }
|
|
16
|
+
attr_accessor :amount
|
|
17
|
+
|
|
18
|
+
# The ID of the company to withdraw from.
|
|
19
|
+
sig { returns(String) }
|
|
20
|
+
attr_accessor :company_id
|
|
21
|
+
|
|
22
|
+
# The currency that is being withdrawn.
|
|
23
|
+
sig { returns(WhopSDK::Currency::OrSymbol) }
|
|
24
|
+
attr_accessor :currency
|
|
25
|
+
|
|
26
|
+
# The ID of the payout method to use for the withdrawal.
|
|
27
|
+
sig { returns(T.nilable(String)) }
|
|
28
|
+
attr_accessor :payout_method_id
|
|
29
|
+
|
|
30
|
+
sig do
|
|
31
|
+
params(
|
|
32
|
+
amount: Float,
|
|
33
|
+
company_id: String,
|
|
34
|
+
currency: WhopSDK::Currency::OrSymbol,
|
|
35
|
+
payout_method_id: T.nilable(String),
|
|
36
|
+
request_options: WhopSDK::RequestOptions::OrHash
|
|
37
|
+
).returns(T.attached_class)
|
|
38
|
+
end
|
|
39
|
+
def self.new(
|
|
40
|
+
# The amount to withdraw in the specified currency
|
|
41
|
+
amount:,
|
|
42
|
+
# The ID of the company to withdraw from.
|
|
43
|
+
company_id:,
|
|
44
|
+
# The currency that is being withdrawn.
|
|
45
|
+
currency:,
|
|
46
|
+
# The ID of the payout method to use for the withdrawal.
|
|
47
|
+
payout_method_id: nil,
|
|
48
|
+
request_options: {}
|
|
49
|
+
)
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
sig do
|
|
53
|
+
override.returns(
|
|
54
|
+
{
|
|
55
|
+
amount: Float,
|
|
56
|
+
company_id: String,
|
|
57
|
+
currency: WhopSDK::Currency::OrSymbol,
|
|
58
|
+
payout_method_id: T.nilable(String),
|
|
59
|
+
request_options: WhopSDK::RequestOptions
|
|
60
|
+
}
|
|
61
|
+
)
|
|
62
|
+
end
|
|
63
|
+
def to_hash
|
|
64
|
+
end
|
|
65
|
+
end
|
|
66
|
+
end
|
|
67
|
+
end
|