whop_sdk 0.0.9 → 0.0.11

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.
Files changed (85) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +23 -0
  3. data/README.md +1 -1
  4. data/lib/whop_sdk/client.rb +8 -0
  5. data/lib/whop_sdk/internal/type/union.rb +12 -0
  6. data/lib/whop_sdk/models/app_build_create_params.rb +9 -1
  7. data/lib/whop_sdk/models/invoice_create_params.rb +10 -1
  8. data/lib/whop_sdk/models/payment.rb +88 -1
  9. data/lib/whop_sdk/models/payment_create_params.rb +307 -0
  10. data/lib/whop_sdk/models/payment_list_response.rb +88 -1
  11. data/lib/whop_sdk/models/payment_method_list_params.rb +78 -0
  12. data/lib/whop_sdk/models/payment_method_list_response.rb +85 -0
  13. data/lib/whop_sdk/models/payment_method_retrieve_params.rb +22 -0
  14. data/lib/whop_sdk/models/payment_method_retrieve_response.rb +85 -0
  15. data/lib/whop_sdk/models/setup_intent.rb +251 -0
  16. data/lib/whop_sdk/models/setup_intent_canceled_webhook_event.rb +52 -0
  17. data/lib/whop_sdk/models/setup_intent_list_params.rb +78 -0
  18. data/lib/whop_sdk/models/setup_intent_list_response.rb +253 -0
  19. data/lib/whop_sdk/models/setup_intent_requires_action_webhook_event.rb +52 -0
  20. data/lib/whop_sdk/models/setup_intent_retrieve_params.rb +14 -0
  21. data/lib/whop_sdk/models/setup_intent_status.rb +18 -0
  22. data/lib/whop_sdk/models/setup_intent_succeeded_webhook_event.rb +52 -0
  23. data/lib/whop_sdk/models/unwrap_webhook_event.rb +28 -19
  24. data/lib/whop_sdk/models.rb +20 -0
  25. data/lib/whop_sdk/resources/app_builds.rb +3 -1
  26. data/lib/whop_sdk/resources/invoices.rb +3 -1
  27. data/lib/whop_sdk/resources/payment_methods.rb +91 -0
  28. data/lib/whop_sdk/resources/payments.rb +50 -0
  29. data/lib/whop_sdk/resources/setup_intents.rb +91 -0
  30. data/lib/whop_sdk/resources/webhooks.rb +1 -1
  31. data/lib/whop_sdk/version.rb +1 -1
  32. data/lib/whop_sdk.rb +15 -0
  33. data/rbi/whop_sdk/client.rbi +6 -0
  34. data/rbi/whop_sdk/models/app_build_create_params.rbi +8 -0
  35. data/rbi/whop_sdk/models/invoice_create_params.rbi +10 -0
  36. data/rbi/whop_sdk/models/payment.rbi +139 -0
  37. data/rbi/whop_sdk/models/payment_create_params.rbi +384 -0
  38. data/rbi/whop_sdk/models/payment_list_response.rbi +164 -0
  39. data/rbi/whop_sdk/models/payment_method_list_params.rbi +99 -0
  40. data/rbi/whop_sdk/models/payment_method_list_response.rbi +137 -0
  41. data/rbi/whop_sdk/models/payment_method_retrieve_params.rbi +43 -0
  42. data/rbi/whop_sdk/models/payment_method_retrieve_response.rbi +142 -0
  43. data/rbi/whop_sdk/models/setup_intent.rbi +410 -0
  44. data/rbi/whop_sdk/models/setup_intent_canceled_webhook_event.rbi +77 -0
  45. data/rbi/whop_sdk/models/setup_intent_list_params.rbi +99 -0
  46. data/rbi/whop_sdk/models/setup_intent_list_response.rbi +491 -0
  47. data/rbi/whop_sdk/models/setup_intent_requires_action_webhook_event.rbi +77 -0
  48. data/rbi/whop_sdk/models/setup_intent_retrieve_params.rbi +27 -0
  49. data/rbi/whop_sdk/models/setup_intent_status.rbi +25 -0
  50. data/rbi/whop_sdk/models/setup_intent_succeeded_webhook_event.rbi +77 -0
  51. data/rbi/whop_sdk/models/unwrap_webhook_event.rbi +3 -0
  52. data/rbi/whop_sdk/models.rbi +23 -0
  53. data/rbi/whop_sdk/resources/app_builds.rbi +3 -0
  54. data/rbi/whop_sdk/resources/invoices.rbi +4 -0
  55. data/rbi/whop_sdk/resources/payment_methods.rbi +84 -0
  56. data/rbi/whop_sdk/resources/payments.rbi +44 -0
  57. data/rbi/whop_sdk/resources/setup_intents.rbi +85 -0
  58. data/rbi/whop_sdk/resources/webhooks.rbi +3 -0
  59. data/sig/whop_sdk/client.rbs +4 -0
  60. data/sig/whop_sdk/models/app_build_create_params.rbs +5 -0
  61. data/sig/whop_sdk/models/invoice_create_params.rbs +5 -0
  62. data/sig/whop_sdk/models/payment.rbs +69 -0
  63. data/sig/whop_sdk/models/payment_create_params.rbs +210 -0
  64. data/sig/whop_sdk/models/payment_list_response.rbs +69 -0
  65. data/sig/whop_sdk/models/payment_method_list_params.rbs +61 -0
  66. data/sig/whop_sdk/models/payment_method_list_response.rbs +67 -0
  67. data/sig/whop_sdk/models/payment_method_retrieve_params.rbs +23 -0
  68. data/sig/whop_sdk/models/payment_method_retrieve_response.rbs +67 -0
  69. data/sig/whop_sdk/models/setup_intent.rbs +189 -0
  70. data/sig/whop_sdk/models/setup_intent_canceled_webhook_event.rbs +40 -0
  71. data/sig/whop_sdk/models/setup_intent_list_params.rbs +61 -0
  72. data/sig/whop_sdk/models/setup_intent_list_response.rbs +193 -0
  73. data/sig/whop_sdk/models/setup_intent_requires_action_webhook_event.rbs +40 -0
  74. data/sig/whop_sdk/models/setup_intent_retrieve_params.rbs +15 -0
  75. data/sig/whop_sdk/models/setup_intent_status.rbs +17 -0
  76. data/sig/whop_sdk/models/setup_intent_succeeded_webhook_event.rbs +40 -0
  77. data/sig/whop_sdk/models/unwrap_webhook_event.rbs +3 -0
  78. data/sig/whop_sdk/models.rbs +20 -0
  79. data/sig/whop_sdk/resources/app_builds.rbs +1 -0
  80. data/sig/whop_sdk/resources/invoices.rbs +1 -0
  81. data/sig/whop_sdk/resources/payment_methods.rbs +25 -0
  82. data/sig/whop_sdk/resources/payments.rbs +9 -0
  83. data/sig/whop_sdk/resources/setup_intents.rbs +24 -0
  84. data/sig/whop_sdk/resources/webhooks.rbs +3 -0
  85. metadata +47 -2
@@ -0,0 +1,410 @@
1
+ # typed: strong
2
+
3
+ module WhopSDK
4
+ module Models
5
+ class SetupIntent < WhopSDK::Internal::Type::BaseModel
6
+ OrHash =
7
+ T.type_alias { T.any(WhopSDK::SetupIntent, WhopSDK::Internal::AnyHash) }
8
+
9
+ # The setup intent ID
10
+ sig { returns(String) }
11
+ attr_accessor :id
12
+
13
+ # The checkout configuration associated with the setup intent
14
+ sig { returns(T.nilable(WhopSDK::SetupIntent::CheckoutConfiguration)) }
15
+ attr_reader :checkout_configuration
16
+
17
+ sig do
18
+ params(
19
+ checkout_configuration:
20
+ T.nilable(WhopSDK::SetupIntent::CheckoutConfiguration::OrHash)
21
+ ).void
22
+ end
23
+ attr_writer :checkout_configuration
24
+
25
+ # The company of the setup intent
26
+ sig { returns(T.nilable(WhopSDK::SetupIntent::Company)) }
27
+ attr_reader :company
28
+
29
+ sig do
30
+ params(company: T.nilable(WhopSDK::SetupIntent::Company::OrHash)).void
31
+ end
32
+ attr_writer :company
33
+
34
+ # The datetime the payment was created
35
+ sig { returns(Time) }
36
+ attr_accessor :created_at
37
+
38
+ # The error message, if any.
39
+ sig { returns(T.nilable(String)) }
40
+ attr_accessor :error_message
41
+
42
+ # The member connected to the setup intent
43
+ sig { returns(T.nilable(WhopSDK::SetupIntent::Member)) }
44
+ attr_reader :member
45
+
46
+ sig do
47
+ params(member: T.nilable(WhopSDK::SetupIntent::Member::OrHash)).void
48
+ end
49
+ attr_writer :member
50
+
51
+ # The metadata associated with the setup intent
52
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
53
+ attr_accessor :metadata
54
+
55
+ # The payment method created during the setup, if available.
56
+ sig { returns(T.nilable(WhopSDK::SetupIntent::PaymentMethod)) }
57
+ attr_reader :payment_method
58
+
59
+ sig do
60
+ params(
61
+ payment_method: T.nilable(WhopSDK::SetupIntent::PaymentMethod::OrHash)
62
+ ).void
63
+ end
64
+ attr_writer :payment_method
65
+
66
+ # The status of the setup intent
67
+ sig { returns(WhopSDK::SetupIntentStatus::TaggedSymbol) }
68
+ attr_accessor :status
69
+
70
+ # An object representing a setup intent, which is a flow for allowing a customer
71
+ # to add a payment method to their account without making a purchase.
72
+ sig do
73
+ params(
74
+ id: String,
75
+ checkout_configuration:
76
+ T.nilable(WhopSDK::SetupIntent::CheckoutConfiguration::OrHash),
77
+ company: T.nilable(WhopSDK::SetupIntent::Company::OrHash),
78
+ created_at: Time,
79
+ error_message: T.nilable(String),
80
+ member: T.nilable(WhopSDK::SetupIntent::Member::OrHash),
81
+ metadata: T.nilable(T::Hash[Symbol, T.anything]),
82
+ payment_method:
83
+ T.nilable(WhopSDK::SetupIntent::PaymentMethod::OrHash),
84
+ status: WhopSDK::SetupIntentStatus::OrSymbol
85
+ ).returns(T.attached_class)
86
+ end
87
+ def self.new(
88
+ # The setup intent ID
89
+ id:,
90
+ # The checkout configuration associated with the setup intent
91
+ checkout_configuration:,
92
+ # The company of the setup intent
93
+ company:,
94
+ # The datetime the payment was created
95
+ created_at:,
96
+ # The error message, if any.
97
+ error_message:,
98
+ # The member connected to the setup intent
99
+ member:,
100
+ # The metadata associated with the setup intent
101
+ metadata:,
102
+ # The payment method created during the setup, if available.
103
+ payment_method:,
104
+ # The status of the setup intent
105
+ status:
106
+ )
107
+ end
108
+
109
+ sig do
110
+ override.returns(
111
+ {
112
+ id: String,
113
+ checkout_configuration:
114
+ T.nilable(WhopSDK::SetupIntent::CheckoutConfiguration),
115
+ company: T.nilable(WhopSDK::SetupIntent::Company),
116
+ created_at: Time,
117
+ error_message: T.nilable(String),
118
+ member: T.nilable(WhopSDK::SetupIntent::Member),
119
+ metadata: T.nilable(T::Hash[Symbol, T.anything]),
120
+ payment_method: T.nilable(WhopSDK::SetupIntent::PaymentMethod),
121
+ status: WhopSDK::SetupIntentStatus::TaggedSymbol
122
+ }
123
+ )
124
+ end
125
+ def to_hash
126
+ end
127
+
128
+ class CheckoutConfiguration < WhopSDK::Internal::Type::BaseModel
129
+ OrHash =
130
+ T.type_alias do
131
+ T.any(
132
+ WhopSDK::SetupIntent::CheckoutConfiguration,
133
+ WhopSDK::Internal::AnyHash
134
+ )
135
+ end
136
+
137
+ # The ID of the checkout configuration
138
+ sig { returns(String) }
139
+ attr_accessor :id
140
+
141
+ # The checkout configuration associated with the setup intent
142
+ sig { params(id: String).returns(T.attached_class) }
143
+ def self.new(
144
+ # The ID of the checkout configuration
145
+ id:
146
+ )
147
+ end
148
+
149
+ sig { override.returns({ id: String }) }
150
+ def to_hash
151
+ end
152
+ end
153
+
154
+ class Company < WhopSDK::Internal::Type::BaseModel
155
+ OrHash =
156
+ T.type_alias do
157
+ T.any(WhopSDK::SetupIntent::Company, WhopSDK::Internal::AnyHash)
158
+ end
159
+
160
+ # The ID (tag) of the company.
161
+ sig { returns(String) }
162
+ attr_accessor :id
163
+
164
+ # The company of the setup intent
165
+ sig { params(id: String).returns(T.attached_class) }
166
+ def self.new(
167
+ # The ID (tag) of the company.
168
+ id:
169
+ )
170
+ end
171
+
172
+ sig { override.returns({ id: String }) }
173
+ def to_hash
174
+ end
175
+ end
176
+
177
+ class Member < WhopSDK::Internal::Type::BaseModel
178
+ OrHash =
179
+ T.type_alias do
180
+ T.any(WhopSDK::SetupIntent::Member, WhopSDK::Internal::AnyHash)
181
+ end
182
+
183
+ # The ID of the member
184
+ sig { returns(String) }
185
+ attr_accessor :id
186
+
187
+ # The user for this member, if any.
188
+ sig { returns(T.nilable(WhopSDK::SetupIntent::Member::User)) }
189
+ attr_reader :user
190
+
191
+ sig do
192
+ params(
193
+ user: T.nilable(WhopSDK::SetupIntent::Member::User::OrHash)
194
+ ).void
195
+ end
196
+ attr_writer :user
197
+
198
+ # The member connected to the setup intent
199
+ sig do
200
+ params(
201
+ id: String,
202
+ user: T.nilable(WhopSDK::SetupIntent::Member::User::OrHash)
203
+ ).returns(T.attached_class)
204
+ end
205
+ def self.new(
206
+ # The ID of the member
207
+ id:,
208
+ # The user for this member, if any.
209
+ user:
210
+ )
211
+ end
212
+
213
+ sig do
214
+ override.returns(
215
+ { id: String, user: T.nilable(WhopSDK::SetupIntent::Member::User) }
216
+ )
217
+ end
218
+ def to_hash
219
+ end
220
+
221
+ class User < WhopSDK::Internal::Type::BaseModel
222
+ OrHash =
223
+ T.type_alias do
224
+ T.any(
225
+ WhopSDK::SetupIntent::Member::User,
226
+ WhopSDK::Internal::AnyHash
227
+ )
228
+ end
229
+
230
+ # The internal ID of the user account.
231
+ sig { returns(String) }
232
+ attr_accessor :id
233
+
234
+ # The digital mailing address of the user.
235
+ sig { returns(T.nilable(String)) }
236
+ attr_accessor :email
237
+
238
+ # The user's full name.
239
+ sig { returns(T.nilable(String)) }
240
+ attr_accessor :name
241
+
242
+ # The whop username.
243
+ sig { returns(String) }
244
+ attr_accessor :username
245
+
246
+ # The user for this member, if any.
247
+ sig do
248
+ params(
249
+ id: String,
250
+ email: T.nilable(String),
251
+ name: T.nilable(String),
252
+ username: String
253
+ ).returns(T.attached_class)
254
+ end
255
+ def self.new(
256
+ # The internal ID of the user account.
257
+ id:,
258
+ # The digital mailing address of the user.
259
+ email:,
260
+ # The user's full name.
261
+ name:,
262
+ # The whop username.
263
+ username:
264
+ )
265
+ end
266
+
267
+ sig do
268
+ override.returns(
269
+ {
270
+ id: String,
271
+ email: T.nilable(String),
272
+ name: T.nilable(String),
273
+ username: String
274
+ }
275
+ )
276
+ end
277
+ def to_hash
278
+ end
279
+ end
280
+ end
281
+
282
+ class PaymentMethod < WhopSDK::Internal::Type::BaseModel
283
+ OrHash =
284
+ T.type_alias do
285
+ T.any(
286
+ WhopSDK::SetupIntent::PaymentMethod,
287
+ WhopSDK::Internal::AnyHash
288
+ )
289
+ end
290
+
291
+ # The ID of the payment method
292
+ sig { returns(String) }
293
+ attr_accessor :id
294
+
295
+ # The card data associated with the payment method, if its a debit or credit card.
296
+ sig { returns(T.nilable(WhopSDK::SetupIntent::PaymentMethod::Card)) }
297
+ attr_reader :card
298
+
299
+ sig do
300
+ params(
301
+ card: T.nilable(WhopSDK::SetupIntent::PaymentMethod::Card::OrHash)
302
+ ).void
303
+ end
304
+ attr_writer :card
305
+
306
+ # The date and time the payment method was created
307
+ sig { returns(Time) }
308
+ attr_accessor :created_at
309
+
310
+ # The payment method type of the payment method
311
+ sig { returns(WhopSDK::PaymentMethodTypes::TaggedSymbol) }
312
+ attr_accessor :payment_method_type
313
+
314
+ # The payment method created during the setup, if available.
315
+ sig do
316
+ params(
317
+ id: String,
318
+ card: T.nilable(WhopSDK::SetupIntent::PaymentMethod::Card::OrHash),
319
+ created_at: Time,
320
+ payment_method_type: WhopSDK::PaymentMethodTypes::OrSymbol
321
+ ).returns(T.attached_class)
322
+ end
323
+ def self.new(
324
+ # The ID of the payment method
325
+ id:,
326
+ # The card data associated with the payment method, if its a debit or credit card.
327
+ card:,
328
+ # The date and time the payment method was created
329
+ created_at:,
330
+ # The payment method type of the payment method
331
+ payment_method_type:
332
+ )
333
+ end
334
+
335
+ sig do
336
+ override.returns(
337
+ {
338
+ id: String,
339
+ card: T.nilable(WhopSDK::SetupIntent::PaymentMethod::Card),
340
+ created_at: Time,
341
+ payment_method_type: WhopSDK::PaymentMethodTypes::TaggedSymbol
342
+ }
343
+ )
344
+ end
345
+ def to_hash
346
+ end
347
+
348
+ class Card < WhopSDK::Internal::Type::BaseModel
349
+ OrHash =
350
+ T.type_alias do
351
+ T.any(
352
+ WhopSDK::SetupIntent::PaymentMethod::Card,
353
+ WhopSDK::Internal::AnyHash
354
+ )
355
+ end
356
+
357
+ # Possible card brands that a payment token can have
358
+ sig { returns(T.nilable(WhopSDK::CardBrands::TaggedSymbol)) }
359
+ attr_accessor :brand
360
+
361
+ # Card expiration month, like 03 for March.
362
+ sig { returns(T.nilable(Integer)) }
363
+ attr_accessor :exp_month
364
+
365
+ # Card expiration year, like 27 for 2027.
366
+ sig { returns(T.nilable(Integer)) }
367
+ attr_accessor :exp_year
368
+
369
+ # Last four digits of the card.
370
+ sig { returns(T.nilable(String)) }
371
+ attr_accessor :last4
372
+
373
+ # The card data associated with the payment method, if its a debit or credit card.
374
+ sig do
375
+ params(
376
+ brand: T.nilable(WhopSDK::CardBrands::OrSymbol),
377
+ exp_month: T.nilable(Integer),
378
+ exp_year: T.nilable(Integer),
379
+ last4: T.nilable(String)
380
+ ).returns(T.attached_class)
381
+ end
382
+ def self.new(
383
+ # Possible card brands that a payment token can have
384
+ brand:,
385
+ # Card expiration month, like 03 for March.
386
+ exp_month:,
387
+ # Card expiration year, like 27 for 2027.
388
+ exp_year:,
389
+ # Last four digits of the card.
390
+ last4:
391
+ )
392
+ end
393
+
394
+ sig do
395
+ override.returns(
396
+ {
397
+ brand: T.nilable(WhopSDK::CardBrands::TaggedSymbol),
398
+ exp_month: T.nilable(Integer),
399
+ exp_year: T.nilable(Integer),
400
+ last4: T.nilable(String)
401
+ }
402
+ )
403
+ end
404
+ def to_hash
405
+ end
406
+ end
407
+ end
408
+ end
409
+ end
410
+ end
@@ -0,0 +1,77 @@
1
+ # typed: strong
2
+
3
+ module WhopSDK
4
+ module Models
5
+ class SetupIntentCanceledWebhookEvent < WhopSDK::Internal::Type::BaseModel
6
+ OrHash =
7
+ T.type_alias do
8
+ T.any(
9
+ WhopSDK::SetupIntentCanceledWebhookEvent,
10
+ WhopSDK::Internal::AnyHash
11
+ )
12
+ end
13
+
14
+ # A unique ID for every single webhook request
15
+ sig { returns(String) }
16
+ attr_accessor :id
17
+
18
+ # The API version for this webhook
19
+ sig { returns(Symbol) }
20
+ attr_accessor :api_version
21
+
22
+ # An object representing a setup intent, which is a flow for allowing a customer
23
+ # to add a payment method to their account without making a purchase.
24
+ sig { returns(WhopSDK::SetupIntent) }
25
+ attr_reader :data
26
+
27
+ sig { params(data: WhopSDK::SetupIntent::OrHash).void }
28
+ attr_writer :data
29
+
30
+ # The timestamp in ISO 8601 format that the webhook was sent at on the server
31
+ sig { returns(Time) }
32
+ attr_accessor :timestamp
33
+
34
+ # The webhook event type
35
+ sig { returns(Symbol) }
36
+ attr_accessor :type
37
+
38
+ sig do
39
+ params(
40
+ id: String,
41
+ data: WhopSDK::SetupIntent::OrHash,
42
+ timestamp: Time,
43
+ api_version: Symbol,
44
+ type: Symbol
45
+ ).returns(T.attached_class)
46
+ end
47
+ def self.new(
48
+ # A unique ID for every single webhook request
49
+ id:,
50
+ # An object representing a setup intent, which is a flow for allowing a customer
51
+ # to add a payment method to their account without making a purchase.
52
+ data:,
53
+ # The timestamp in ISO 8601 format that the webhook was sent at on the server
54
+ timestamp:,
55
+ # The API version for this webhook
56
+ api_version: :v1,
57
+ # The webhook event type
58
+ type: :"setup_intent.canceled"
59
+ )
60
+ end
61
+
62
+ sig do
63
+ override.returns(
64
+ {
65
+ id: String,
66
+ api_version: Symbol,
67
+ data: WhopSDK::SetupIntent,
68
+ timestamp: Time,
69
+ type: Symbol
70
+ }
71
+ )
72
+ end
73
+ def to_hash
74
+ end
75
+ end
76
+ end
77
+ end
@@ -0,0 +1,99 @@
1
+ # typed: strong
2
+
3
+ module WhopSDK
4
+ module Models
5
+ class SetupIntentListParams < 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::SetupIntentListParams, WhopSDK::Internal::AnyHash)
12
+ end
13
+
14
+ # The ID of the company to list setup intents for
15
+ sig { returns(String) }
16
+ attr_accessor :company_id
17
+
18
+ # Returns the elements in the list that come after the specified cursor.
19
+ sig { returns(T.nilable(String)) }
20
+ attr_accessor :after
21
+
22
+ # Returns the elements in the list that come before the specified cursor.
23
+ sig { returns(T.nilable(String)) }
24
+ attr_accessor :before
25
+
26
+ # The minimum creation date to filter by
27
+ sig { returns(T.nilable(Time)) }
28
+ attr_accessor :created_after
29
+
30
+ # The maximum creation date to filter by
31
+ sig { returns(T.nilable(Time)) }
32
+ attr_accessor :created_before
33
+
34
+ # The direction of the sort.
35
+ sig { returns(T.nilable(WhopSDK::Direction::OrSymbol)) }
36
+ attr_accessor :direction
37
+
38
+ # Returns the first _n_ elements from the list.
39
+ sig { returns(T.nilable(Integer)) }
40
+ attr_accessor :first
41
+
42
+ # Returns the last _n_ elements from the list.
43
+ sig { returns(T.nilable(Integer)) }
44
+ attr_accessor :last
45
+
46
+ sig do
47
+ params(
48
+ company_id: String,
49
+ after: T.nilable(String),
50
+ before: T.nilable(String),
51
+ created_after: T.nilable(Time),
52
+ created_before: T.nilable(Time),
53
+ direction: T.nilable(WhopSDK::Direction::OrSymbol),
54
+ first: T.nilable(Integer),
55
+ last: T.nilable(Integer),
56
+ request_options: WhopSDK::RequestOptions::OrHash
57
+ ).returns(T.attached_class)
58
+ end
59
+ def self.new(
60
+ # The ID of the company to list setup intents for
61
+ company_id:,
62
+ # Returns the elements in the list that come after the specified cursor.
63
+ after: nil,
64
+ # Returns the elements in the list that come before the specified cursor.
65
+ before: nil,
66
+ # The minimum creation date to filter by
67
+ created_after: nil,
68
+ # The maximum creation date to filter by
69
+ created_before: nil,
70
+ # The direction of the sort.
71
+ direction: nil,
72
+ # Returns the first _n_ elements from the list.
73
+ first: nil,
74
+ # Returns the last _n_ elements from the list.
75
+ last: nil,
76
+ request_options: {}
77
+ )
78
+ end
79
+
80
+ sig do
81
+ override.returns(
82
+ {
83
+ company_id: String,
84
+ after: T.nilable(String),
85
+ before: T.nilable(String),
86
+ created_after: T.nilable(Time),
87
+ created_before: T.nilable(Time),
88
+ direction: T.nilable(WhopSDK::Direction::OrSymbol),
89
+ first: T.nilable(Integer),
90
+ last: T.nilable(Integer),
91
+ request_options: WhopSDK::RequestOptions
92
+ }
93
+ )
94
+ end
95
+ def to_hash
96
+ end
97
+ end
98
+ end
99
+ end