whop_sdk 0.0.7 → 0.0.9

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 (251) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +35 -0
  3. data/README.md +7 -7
  4. data/lib/whop_sdk/client.rb +12 -0
  5. data/lib/whop_sdk/internal/type/base_model.rb +1 -1
  6. data/lib/whop_sdk/models/account_link_create_params.rb +62 -0
  7. data/lib/whop_sdk/models/account_link_create_response.rb +28 -0
  8. data/lib/whop_sdk/models/app.rb +9 -1
  9. data/lib/whop_sdk/models/app_build_list_params.rb +17 -1
  10. data/lib/whop_sdk/models/app_list_params.rb +10 -1
  11. data/lib/whop_sdk/models/app_list_response.rb +9 -1
  12. data/lib/whop_sdk/models/app_type.rb +18 -0
  13. data/lib/whop_sdk/models/app_update_params.rb +9 -1
  14. data/lib/whop_sdk/models/authorized_user_list_params.rb +17 -1
  15. data/lib/whop_sdk/models/checkout_configuration.rb +69 -7
  16. data/lib/whop_sdk/models/checkout_configuration_create_params.rb +73 -1
  17. data/lib/whop_sdk/models/checkout_configuration_list_params.rb +17 -1
  18. data/lib/whop_sdk/models/checkout_configuration_list_response.rb +69 -7
  19. data/lib/whop_sdk/models/checkout_modes.rb +16 -0
  20. data/lib/whop_sdk/models/company_list_params.rb +17 -1
  21. data/lib/whop_sdk/models/course.rb +9 -1
  22. data/lib/whop_sdk/models/course_lesson_list_response.rb +9 -1
  23. data/lib/whop_sdk/models/course_lesson_mark_as_completed_params.rb +14 -0
  24. data/lib/whop_sdk/models/course_lesson_mark_as_completed_response.rb +8 -0
  25. data/lib/whop_sdk/models/course_lesson_start_params.rb +14 -0
  26. data/lib/whop_sdk/models/course_lesson_start_response.rb +8 -0
  27. data/lib/whop_sdk/models/course_lesson_submit_assessment_params.rb +52 -0
  28. data/lib/whop_sdk/models/course_lesson_submit_assessment_response.rb +151 -0
  29. data/lib/whop_sdk/models/course_list_response.rb +9 -1
  30. data/lib/whop_sdk/models/dispute_list_params.rb +17 -1
  31. data/lib/whop_sdk/models/entry_list_params.rb +17 -1
  32. data/lib/whop_sdk/models/experience_list_params.rb +17 -1
  33. data/lib/whop_sdk/models/forum_post_create_params.rb +3 -14
  34. data/lib/whop_sdk/models/forum_post_update_params.rb +3 -14
  35. data/lib/whop_sdk/models/forum_post_visibility_type.rb +16 -0
  36. data/lib/whop_sdk/models/invoice_list_params.rb +17 -1
  37. data/lib/whop_sdk/models/lesson.rb +104 -2
  38. data/lib/whop_sdk/models/payment_method_types.rb +1 -0
  39. data/lib/whop_sdk/models/payment_provider.rb +22 -0
  40. data/lib/whop_sdk/models/plan_create_params.rb +3 -21
  41. data/lib/whop_sdk/models/plan_list_params.rb +17 -1
  42. data/lib/whop_sdk/models/product_list_params.rb +17 -1
  43. data/lib/whop_sdk/models/product_update_params.rb +1 -61
  44. data/lib/whop_sdk/models/promo_code_list_params.rb +17 -1
  45. data/lib/whop_sdk/models/refund_created_webhook_event.rb +354 -0
  46. data/lib/whop_sdk/models/refund_list_params.rb +78 -0
  47. data/lib/whop_sdk/models/refund_list_response.rb +113 -0
  48. data/lib/whop_sdk/models/refund_reference_status.rb +17 -0
  49. data/lib/whop_sdk/models/refund_reference_type.rb +17 -0
  50. data/lib/whop_sdk/models/refund_retrieve_params.rb +14 -0
  51. data/lib/whop_sdk/models/refund_retrieve_response.rb +307 -0
  52. data/lib/whop_sdk/models/refund_status.rb +19 -0
  53. data/lib/whop_sdk/models/refund_updated_webhook_event.rb +354 -0
  54. data/lib/whop_sdk/models/review_list_params.rb +17 -1
  55. data/lib/whop_sdk/models/transfer_list_params.rb +17 -1
  56. data/lib/whop_sdk/models/unwrap_webhook_event.rb +5 -1
  57. data/lib/whop_sdk/models/withdrawal_fee_types.rb +16 -0
  58. data/lib/whop_sdk/models/withdrawal_list_params.rb +78 -0
  59. data/lib/whop_sdk/models/withdrawal_list_response.rb +87 -0
  60. data/lib/whop_sdk/models/withdrawal_retrieve_params.rb +14 -0
  61. data/lib/whop_sdk/models/withdrawal_retrieve_response.rb +320 -0
  62. data/lib/whop_sdk/models/withdrawal_speeds.rb +16 -0
  63. data/lib/whop_sdk/models/withdrawal_status.rb +21 -0
  64. data/lib/whop_sdk/models/withdrawal_types.rb +16 -0
  65. data/lib/whop_sdk/models.rb +42 -0
  66. data/lib/whop_sdk/resources/account_links.rb +47 -0
  67. data/lib/whop_sdk/resources/app_builds.rb +5 -1
  68. data/lib/whop_sdk/resources/apps.rb +6 -2
  69. data/lib/whop_sdk/resources/authorized_users.rb +5 -1
  70. data/lib/whop_sdk/resources/checkout_configurations.rb +16 -2
  71. data/lib/whop_sdk/resources/companies.rb +5 -1
  72. data/lib/whop_sdk/resources/course_lessons.rb +64 -0
  73. data/lib/whop_sdk/resources/disputes.rb +5 -1
  74. data/lib/whop_sdk/resources/entries.rb +5 -1
  75. data/lib/whop_sdk/resources/experiences.rb +5 -1
  76. data/lib/whop_sdk/resources/forum_posts.rb +2 -2
  77. data/lib/whop_sdk/resources/invoices.rb +5 -1
  78. data/lib/whop_sdk/resources/plans.rb +7 -7
  79. data/lib/whop_sdk/resources/products.rb +6 -4
  80. data/lib/whop_sdk/resources/promo_codes.rb +5 -1
  81. data/lib/whop_sdk/resources/refunds.rb +82 -0
  82. data/lib/whop_sdk/resources/reviews.rb +5 -1
  83. data/lib/whop_sdk/resources/transfers.rb +5 -1
  84. data/lib/whop_sdk/resources/webhooks.rb +1 -1
  85. data/lib/whop_sdk/resources/withdrawals.rb +79 -0
  86. data/lib/whop_sdk/version.rb +1 -1
  87. data/lib/whop_sdk.rb +33 -0
  88. data/manifest.yaml +1 -0
  89. data/rbi/whop_sdk/client.rbi +9 -0
  90. data/rbi/whop_sdk/models/account_link_create_params.rbi +101 -0
  91. data/rbi/whop_sdk/models/account_link_create_response.rbi +38 -0
  92. data/rbi/whop_sdk/models/app.rbi +8 -0
  93. data/rbi/whop_sdk/models/app_build_list_params.rbi +16 -0
  94. data/rbi/whop_sdk/models/app_list_params.rbi +13 -0
  95. data/rbi/whop_sdk/models/app_list_response.rbi +8 -0
  96. data/rbi/whop_sdk/models/app_type.rbi +22 -0
  97. data/rbi/whop_sdk/models/app_update_params.rbi +8 -0
  98. data/rbi/whop_sdk/models/authorized_user_list_params.rbi +16 -0
  99. data/rbi/whop_sdk/models/checkout_configuration.rbi +117 -7
  100. data/rbi/whop_sdk/models/checkout_configuration_create_params.rbi +116 -0
  101. data/rbi/whop_sdk/models/checkout_configuration_list_params.rbi +16 -0
  102. data/rbi/whop_sdk/models/checkout_configuration_list_response.rbi +127 -7
  103. data/rbi/whop_sdk/models/checkout_modes.rbi +20 -0
  104. data/rbi/whop_sdk/models/company_list_params.rbi +16 -0
  105. data/rbi/whop_sdk/models/course.rbi +8 -0
  106. data/rbi/whop_sdk/models/course_lesson_list_response.rbi +8 -0
  107. data/rbi/whop_sdk/models/course_lesson_mark_as_completed_params.rbi +30 -0
  108. data/rbi/whop_sdk/models/course_lesson_mark_as_completed_response.rbi +8 -0
  109. data/rbi/whop_sdk/models/course_lesson_start_params.rbi +27 -0
  110. data/rbi/whop_sdk/models/course_lesson_start_response.rbi +8 -0
  111. data/rbi/whop_sdk/models/course_lesson_submit_assessment_params.rbi +104 -0
  112. data/rbi/whop_sdk/models/course_lesson_submit_assessment_response.rbi +222 -0
  113. data/rbi/whop_sdk/models/course_list_response.rbi +8 -0
  114. data/rbi/whop_sdk/models/dispute_list_params.rbi +16 -0
  115. data/rbi/whop_sdk/models/entry_list_params.rbi +16 -0
  116. data/rbi/whop_sdk/models/experience_list_params.rbi +16 -0
  117. data/rbi/whop_sdk/models/forum_post_create_params.rbi +3 -37
  118. data/rbi/whop_sdk/models/forum_post_update_params.rbi +3 -37
  119. data/rbi/whop_sdk/models/forum_post_visibility_type.rbi +27 -0
  120. data/rbi/whop_sdk/models/invoice_list_params.rbi +16 -0
  121. data/rbi/whop_sdk/models/lesson.rbi +115 -3
  122. data/rbi/whop_sdk/models/payment_method_types.rbi +1 -0
  123. data/rbi/whop_sdk/models/payment_provider.rbi +27 -0
  124. data/rbi/whop_sdk/models/plan_create_params.rbi +2 -22
  125. data/rbi/whop_sdk/models/plan_list_params.rbi +16 -0
  126. data/rbi/whop_sdk/models/product_list_params.rbi +16 -0
  127. data/rbi/whop_sdk/models/product_update_params.rbi +0 -110
  128. data/rbi/whop_sdk/models/promo_code_list_params.rbi +16 -0
  129. data/rbi/whop_sdk/models/refund_created_webhook_event.rbi +561 -0
  130. data/rbi/whop_sdk/models/refund_list_params.rbi +99 -0
  131. data/rbi/whop_sdk/models/refund_list_response.rbi +155 -0
  132. data/rbi/whop_sdk/models/refund_reference_status.rbi +26 -0
  133. data/rbi/whop_sdk/models/refund_reference_type.rbi +36 -0
  134. data/rbi/whop_sdk/models/refund_retrieve_params.rbi +27 -0
  135. data/rbi/whop_sdk/models/refund_retrieve_response.rbi +484 -0
  136. data/rbi/whop_sdk/models/refund_status.rbi +24 -0
  137. data/rbi/whop_sdk/models/refund_updated_webhook_event.rbi +561 -0
  138. data/rbi/whop_sdk/models/review_list_params.rbi +16 -0
  139. data/rbi/whop_sdk/models/transfer_list_params.rbi +16 -0
  140. data/rbi/whop_sdk/models/unwrap_webhook_event.rbi +3 -1
  141. data/rbi/whop_sdk/models/withdrawal_fee_types.rbi +22 -0
  142. data/rbi/whop_sdk/models/withdrawal_list_params.rbi +99 -0
  143. data/rbi/whop_sdk/models/withdrawal_list_response.rbi +107 -0
  144. data/rbi/whop_sdk/models/withdrawal_retrieve_params.rbi +27 -0
  145. data/rbi/whop_sdk/models/withdrawal_retrieve_response.rbi +713 -0
  146. data/rbi/whop_sdk/models/withdrawal_speeds.rbi +22 -0
  147. data/rbi/whop_sdk/models/withdrawal_status.rbi +28 -0
  148. data/rbi/whop_sdk/models/withdrawal_types.rbi +20 -0
  149. data/rbi/whop_sdk/models.rbi +44 -0
  150. data/rbi/whop_sdk/resources/account_links.rbi +39 -0
  151. data/rbi/whop_sdk/resources/app_builds.rbi +6 -0
  152. data/rbi/whop_sdk/resources/apps.rbi +6 -0
  153. data/rbi/whop_sdk/resources/authorized_users.rbi +6 -0
  154. data/rbi/whop_sdk/resources/checkout_configurations.rbi +21 -0
  155. data/rbi/whop_sdk/resources/companies.rbi +6 -0
  156. data/rbi/whop_sdk/resources/course_lessons.rbi +48 -0
  157. data/rbi/whop_sdk/resources/disputes.rbi +6 -0
  158. data/rbi/whop_sdk/resources/entries.rbi +6 -0
  159. data/rbi/whop_sdk/resources/experiences.rbi +6 -0
  160. data/rbi/whop_sdk/resources/forum_posts.rbi +2 -4
  161. data/rbi/whop_sdk/resources/invoices.rbi +6 -0
  162. data/rbi/whop_sdk/resources/plans.rbi +7 -9
  163. data/rbi/whop_sdk/resources/products.rbi +6 -9
  164. data/rbi/whop_sdk/resources/promo_codes.rbi +6 -0
  165. data/rbi/whop_sdk/resources/refunds.rbi +74 -0
  166. data/rbi/whop_sdk/resources/reviews.rbi +6 -0
  167. data/rbi/whop_sdk/resources/transfers.rbi +6 -0
  168. data/rbi/whop_sdk/resources/webhooks.rbi +3 -1
  169. data/rbi/whop_sdk/resources/withdrawals.rbi +71 -0
  170. data/sig/whop_sdk/client.rbs +6 -0
  171. data/sig/whop_sdk/models/account_link_create_params.rbs +52 -0
  172. data/sig/whop_sdk/models/account_link_create_response.rbs +15 -0
  173. data/sig/whop_sdk/models/app.rbs +5 -0
  174. data/sig/whop_sdk/models/app_build_list_params.rbs +10 -0
  175. data/sig/whop_sdk/models/app_list_params.rbs +7 -0
  176. data/sig/whop_sdk/models/app_list_response.rbs +5 -0
  177. data/sig/whop_sdk/models/app_type.rbs +16 -0
  178. data/sig/whop_sdk/models/app_update_params.rbs +5 -0
  179. data/sig/whop_sdk/models/authorized_user_list_params.rbs +10 -0
  180. data/sig/whop_sdk/models/checkout_configuration.rbs +45 -8
  181. data/sig/whop_sdk/models/checkout_configuration_create_params.rbs +43 -1
  182. data/sig/whop_sdk/models/checkout_configuration_list_params.rbs +10 -0
  183. data/sig/whop_sdk/models/checkout_configuration_list_response.rbs +45 -8
  184. data/sig/whop_sdk/models/checkout_modes.rbs +14 -0
  185. data/sig/whop_sdk/models/company_list_params.rbs +10 -0
  186. data/sig/whop_sdk/models/course.rbs +5 -0
  187. data/sig/whop_sdk/models/course_lesson_list_response.rbs +5 -0
  188. data/sig/whop_sdk/models/course_lesson_mark_as_completed_params.rbs +15 -0
  189. data/sig/whop_sdk/models/course_lesson_mark_as_completed_response.rbs +5 -0
  190. data/sig/whop_sdk/models/course_lesson_start_params.rbs +15 -0
  191. data/sig/whop_sdk/models/course_lesson_start_response.rbs +5 -0
  192. data/sig/whop_sdk/models/course_lesson_submit_assessment_params.rbs +51 -0
  193. data/sig/whop_sdk/models/course_lesson_submit_assessment_response.rbs +96 -0
  194. data/sig/whop_sdk/models/course_list_response.rbs +5 -0
  195. data/sig/whop_sdk/models/dispute_list_params.rbs +10 -0
  196. data/sig/whop_sdk/models/entry_list_params.rbs +10 -0
  197. data/sig/whop_sdk/models/experience_list_params.rbs +10 -0
  198. data/sig/whop_sdk/models/forum_post_create_params.rbs +4 -15
  199. data/sig/whop_sdk/models/forum_post_update_params.rbs +4 -15
  200. data/sig/whop_sdk/models/forum_post_visibility_type.rbs +14 -0
  201. data/sig/whop_sdk/models/invoice_list_params.rbs +10 -0
  202. data/sig/whop_sdk/models/lesson.rbs +79 -3
  203. data/sig/whop_sdk/models/payment_method_types.rbs +2 -0
  204. data/sig/whop_sdk/models/payment_provider.rbs +28 -0
  205. data/sig/whop_sdk/models/plan_create_params.rbs +0 -10
  206. data/sig/whop_sdk/models/plan_list_params.rbs +10 -0
  207. data/sig/whop_sdk/models/product_list_params.rbs +10 -0
  208. data/sig/whop_sdk/models/product_update_params.rbs +0 -36
  209. data/sig/whop_sdk/models/promo_code_list_params.rbs +10 -0
  210. data/sig/whop_sdk/models/refund_created_webhook_event.rbs +252 -0
  211. data/sig/whop_sdk/models/refund_list_params.rbs +61 -0
  212. data/sig/whop_sdk/models/refund_list_response.rbs +80 -0
  213. data/sig/whop_sdk/models/refund_reference_status.rbs +15 -0
  214. data/sig/whop_sdk/models/refund_reference_type.rbs +18 -0
  215. data/sig/whop_sdk/models/refund_retrieve_params.rbs +15 -0
  216. data/sig/whop_sdk/models/refund_retrieve_response.rbs +215 -0
  217. data/sig/whop_sdk/models/refund_status.rbs +18 -0
  218. data/sig/whop_sdk/models/refund_updated_webhook_event.rbs +252 -0
  219. data/sig/whop_sdk/models/review_list_params.rbs +10 -0
  220. data/sig/whop_sdk/models/transfer_list_params.rbs +10 -0
  221. data/sig/whop_sdk/models/unwrap_webhook_event.rbs +2 -0
  222. data/sig/whop_sdk/models/withdrawal_fee_types.rbs +14 -0
  223. data/sig/whop_sdk/models/withdrawal_list_params.rbs +61 -0
  224. data/sig/whop_sdk/models/withdrawal_list_response.rbs +60 -0
  225. data/sig/whop_sdk/models/withdrawal_retrieve_params.rbs +15 -0
  226. data/sig/whop_sdk/models/withdrawal_retrieve_response.rbs +297 -0
  227. data/sig/whop_sdk/models/withdrawal_speeds.rbs +14 -0
  228. data/sig/whop_sdk/models/withdrawal_status.rbs +26 -0
  229. data/sig/whop_sdk/models/withdrawal_types.rbs +14 -0
  230. data/sig/whop_sdk/models.rbs +42 -0
  231. data/sig/whop_sdk/resources/account_links.rbs +15 -0
  232. data/sig/whop_sdk/resources/app_builds.rbs +2 -0
  233. data/sig/whop_sdk/resources/apps.rbs +2 -0
  234. data/sig/whop_sdk/resources/authorized_users.rbs +2 -0
  235. data/sig/whop_sdk/resources/checkout_configurations.rbs +5 -0
  236. data/sig/whop_sdk/resources/companies.rbs +2 -0
  237. data/sig/whop_sdk/resources/course_lessons.rbs +16 -0
  238. data/sig/whop_sdk/resources/disputes.rbs +2 -0
  239. data/sig/whop_sdk/resources/entries.rbs +2 -0
  240. data/sig/whop_sdk/resources/experiences.rbs +2 -0
  241. data/sig/whop_sdk/resources/forum_posts.rbs +2 -2
  242. data/sig/whop_sdk/resources/invoices.rbs +2 -0
  243. data/sig/whop_sdk/resources/plans.rbs +2 -2
  244. data/sig/whop_sdk/resources/products.rbs +2 -1
  245. data/sig/whop_sdk/resources/promo_codes.rbs +2 -0
  246. data/sig/whop_sdk/resources/refunds.rbs +24 -0
  247. data/sig/whop_sdk/resources/reviews.rbs +2 -0
  248. data/sig/whop_sdk/resources/transfers.rbs +2 -0
  249. data/sig/whop_sdk/resources/webhooks.rbs +3 -1
  250. data/sig/whop_sdk/resources/withdrawals.rbs +24 -0
  251. metadata +98 -2
@@ -0,0 +1,22 @@
1
+ # typed: strong
2
+
3
+ module WhopSDK
4
+ module Models
5
+ # The different speeds of withdrawals
6
+ module WithdrawalSpeeds
7
+ extend WhopSDK::Internal::Type::Enum
8
+
9
+ TaggedSymbol = T.type_alias { T.all(Symbol, WhopSDK::WithdrawalSpeeds) }
10
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
11
+
12
+ STANDARD = T.let(:standard, WhopSDK::WithdrawalSpeeds::TaggedSymbol)
13
+ INSTANT = T.let(:instant, WhopSDK::WithdrawalSpeeds::TaggedSymbol)
14
+
15
+ sig do
16
+ override.returns(T::Array[WhopSDK::WithdrawalSpeeds::TaggedSymbol])
17
+ end
18
+ def self.values
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,28 @@
1
+ # typed: strong
2
+
3
+ module WhopSDK
4
+ module Models
5
+ # The status of a withdrawal request
6
+ module WithdrawalStatus
7
+ extend WhopSDK::Internal::Type::Enum
8
+
9
+ TaggedSymbol = T.type_alias { T.all(Symbol, WhopSDK::WithdrawalStatus) }
10
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
11
+
12
+ REQUESTED = T.let(:requested, WhopSDK::WithdrawalStatus::TaggedSymbol)
13
+ AWAITING_PAYMENT =
14
+ T.let(:awaiting_payment, WhopSDK::WithdrawalStatus::TaggedSymbol)
15
+ IN_TRANSIT = T.let(:in_transit, WhopSDK::WithdrawalStatus::TaggedSymbol)
16
+ COMPLETED = T.let(:completed, WhopSDK::WithdrawalStatus::TaggedSymbol)
17
+ FAILED = T.let(:failed, WhopSDK::WithdrawalStatus::TaggedSymbol)
18
+ CANCELED = T.let(:canceled, WhopSDK::WithdrawalStatus::TaggedSymbol)
19
+ DENIED = T.let(:denied, WhopSDK::WithdrawalStatus::TaggedSymbol)
20
+
21
+ sig do
22
+ override.returns(T::Array[WhopSDK::WithdrawalStatus::TaggedSymbol])
23
+ end
24
+ def self.values
25
+ end
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,20 @@
1
+ # typed: strong
2
+
3
+ module WhopSDK
4
+ module Models
5
+ # The types of withdrawals
6
+ module WithdrawalTypes
7
+ extend WhopSDK::Internal::Type::Enum
8
+
9
+ TaggedSymbol = T.type_alias { T.all(Symbol, WhopSDK::WithdrawalTypes) }
10
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
11
+
12
+ REGULAR = T.let(:regular, WhopSDK::WithdrawalTypes::TaggedSymbol)
13
+ CLAWBACK = T.let(:clawback, WhopSDK::WithdrawalTypes::TaggedSymbol)
14
+
15
+ sig { override.returns(T::Array[WhopSDK::WithdrawalTypes::TaggedSymbol]) }
16
+ def self.values
17
+ end
18
+ end
19
+ end
20
+ end
@@ -7,6 +7,8 @@ module WhopSDK
7
7
 
8
8
  AccessTokenCreateParams = WhopSDK::Models::AccessTokenCreateParams
9
9
 
10
+ AccountLinkCreateParams = WhopSDK::Models::AccountLinkCreateParams
11
+
10
12
  App = WhopSDK::Models::App
11
13
 
12
14
  AppBuild = WhopSDK::Models::AppBuild
@@ -31,6 +33,8 @@ module WhopSDK
31
33
 
32
34
  AppStatuses = WhopSDK::Models::AppStatuses
33
35
 
36
+ AppType = WhopSDK::Models::AppType
37
+
34
38
  AppUpdateParams = WhopSDK::Models::AppUpdateParams
35
39
 
36
40
  AppViewType = WhopSDK::Models::AppViewType
@@ -68,6 +72,8 @@ module WhopSDK
68
72
  CheckoutConfigurationRetrieveParams =
69
73
  WhopSDK::Models::CheckoutConfigurationRetrieveParams
70
74
 
75
+ CheckoutModes = WhopSDK::Models::CheckoutModes
76
+
71
77
  CollectionMethod = WhopSDK::Models::CollectionMethod
72
78
 
73
79
  Company = WhopSDK::Models::Company
@@ -116,8 +122,16 @@ module WhopSDK
116
122
 
117
123
  CourseLessonListParams = WhopSDK::Models::CourseLessonListParams
118
124
 
125
+ CourseLessonMarkAsCompletedParams =
126
+ WhopSDK::Models::CourseLessonMarkAsCompletedParams
127
+
119
128
  CourseLessonRetrieveParams = WhopSDK::Models::CourseLessonRetrieveParams
120
129
 
130
+ CourseLessonStartParams = WhopSDK::Models::CourseLessonStartParams
131
+
132
+ CourseLessonSubmitAssessmentParams =
133
+ WhopSDK::Models::CourseLessonSubmitAssessmentParams
134
+
121
135
  CourseLessonUpdateParams = WhopSDK::Models::CourseLessonUpdateParams
122
136
 
123
137
  CourseListParams = WhopSDK::Models::CourseListParams
@@ -212,6 +226,8 @@ module WhopSDK
212
226
 
213
227
  ForumPostUpdateParams = WhopSDK::Models::ForumPostUpdateParams
214
228
 
229
+ ForumPostVisibilityType = WhopSDK::Models::ForumPostVisibilityType
230
+
215
231
  ForumRetrieveParams = WhopSDK::Models::ForumRetrieveParams
216
232
 
217
233
  ForumUpdateParams = WhopSDK::Models::ForumUpdateParams
@@ -308,6 +324,8 @@ module WhopSDK
308
324
 
309
325
  PaymentPendingWebhookEvent = WhopSDK::Models::PaymentPendingWebhookEvent
310
326
 
327
+ PaymentProvider = WhopSDK::Models::PaymentProvider
328
+
311
329
  PaymentRefundParams = WhopSDK::Models::PaymentRefundParams
312
330
 
313
331
  PaymentRetrieveParams = WhopSDK::Models::PaymentRetrieveParams
@@ -372,6 +390,20 @@ module WhopSDK
372
390
 
373
391
  ReceiptStatus = WhopSDK::Models::ReceiptStatus
374
392
 
393
+ RefundCreatedWebhookEvent = WhopSDK::Models::RefundCreatedWebhookEvent
394
+
395
+ RefundListParams = WhopSDK::Models::RefundListParams
396
+
397
+ RefundReferenceStatus = WhopSDK::Models::RefundReferenceStatus
398
+
399
+ RefundReferenceType = WhopSDK::Models::RefundReferenceType
400
+
401
+ RefundRetrieveParams = WhopSDK::Models::RefundRetrieveParams
402
+
403
+ RefundStatus = WhopSDK::Models::RefundStatus
404
+
405
+ RefundUpdatedWebhookEvent = WhopSDK::Models::RefundUpdatedWebhookEvent
406
+
375
407
  ReleaseMethod = WhopSDK::Models::ReleaseMethod
376
408
 
377
409
  ReviewListParams = WhopSDK::Models::ReviewListParams
@@ -431,4 +463,16 @@ module WhopSDK
431
463
  WhoCanPostTypes = WhopSDK::Models::WhoCanPostTypes
432
464
 
433
465
  WhoCanReact = WhopSDK::Models::WhoCanReact
466
+
467
+ WithdrawalFeeTypes = WhopSDK::Models::WithdrawalFeeTypes
468
+
469
+ WithdrawalListParams = WhopSDK::Models::WithdrawalListParams
470
+
471
+ WithdrawalRetrieveParams = WhopSDK::Models::WithdrawalRetrieveParams
472
+
473
+ WithdrawalSpeeds = WhopSDK::Models::WithdrawalSpeeds
474
+
475
+ WithdrawalStatus = WhopSDK::Models::WithdrawalStatus
476
+
477
+ WithdrawalTypes = WhopSDK::Models::WithdrawalTypes
434
478
  end
@@ -0,0 +1,39 @@
1
+ # typed: strong
2
+
3
+ module WhopSDK
4
+ module Resources
5
+ class AccountLinks
6
+ # Generates a url that a user can be directed to in order to access their
7
+ # sub-merchant account. For example, they can visit the hosted payouts portal or
8
+ # the hosted KYC onboarding flow.
9
+ sig do
10
+ params(
11
+ company_id: String,
12
+ refresh_url: String,
13
+ return_url: String,
14
+ use_case: WhopSDK::AccountLinkCreateParams::UseCase::OrSymbol,
15
+ request_options: WhopSDK::RequestOptions::OrHash
16
+ ).returns(WhopSDK::Models::AccountLinkCreateResponse)
17
+ end
18
+ def create(
19
+ # The ID of the Company to generate the url for. The company must be a
20
+ # sub-merchant of the API key's company.
21
+ company_id:,
22
+ # The URL to redirect to if the session expires and needs to be re-authenticated
23
+ # due to the token expiring.
24
+ refresh_url:,
25
+ # The URL to redirect to when the customer wants to return to your site.
26
+ return_url:,
27
+ # The use case for which the link will be used.
28
+ use_case:,
29
+ request_options: {}
30
+ )
31
+ end
32
+
33
+ # @api private
34
+ sig { params(client: WhopSDK::Client).returns(T.attached_class) }
35
+ def self.new(client:)
36
+ end
37
+ end
38
+ end
39
+ end
@@ -72,6 +72,8 @@ module WhopSDK
72
72
  app_id: String,
73
73
  after: T.nilable(String),
74
74
  before: T.nilable(String),
75
+ created_after: T.nilable(Time),
76
+ created_before: T.nilable(Time),
75
77
  first: T.nilable(Integer),
76
78
  last: T.nilable(Integer),
77
79
  platform: T.nilable(WhopSDK::AppBuildPlatforms::OrSymbol),
@@ -88,6 +90,10 @@ module WhopSDK
88
90
  after: nil,
89
91
  # Returns the elements in the list that come before the specified cursor.
90
92
  before: nil,
93
+ # The minimum creation date to filter by
94
+ created_after: nil,
95
+ # The maximum creation date to filter by
96
+ created_before: nil,
91
97
  # Returns the first _n_ elements from the list.
92
98
  first: nil,
93
99
  # Returns the last _n_ elements from the list.
@@ -56,6 +56,7 @@ module WhopSDK
56
56
  params(
57
57
  id: String,
58
58
  app_store_description: T.nilable(String),
59
+ app_type: T.nilable(WhopSDK::AppType::OrSymbol),
59
60
  base_url: T.nilable(String),
60
61
  dashboard_path: T.nilable(String),
61
62
  description: T.nilable(String),
@@ -82,6 +83,8 @@ module WhopSDK
82
83
  id,
83
84
  # The description of the app for the app store in-depth app view.
84
85
  app_store_description: nil,
86
+ # The type of end-user an app is built for
87
+ app_type: nil,
85
88
  # The base production url of the app
86
89
  base_url: nil,
87
90
  # The path for the dashboard view of the app
@@ -108,6 +111,7 @@ module WhopSDK
108
111
  sig do
109
112
  params(
110
113
  after: T.nilable(String),
114
+ app_type: T.nilable(WhopSDK::AppType::OrSymbol),
111
115
  before: T.nilable(String),
112
116
  company_id: T.nilable(String),
113
117
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
@@ -125,6 +129,8 @@ module WhopSDK
125
129
  def list(
126
130
  # Returns the elements in the list that come after the specified cursor.
127
131
  after: nil,
132
+ # The type of end-user an app is built for
133
+ app_type: nil,
128
134
  # Returns the elements in the list that come before the specified cursor.
129
135
  before: nil,
130
136
  # The ID of the company to filter apps by
@@ -33,6 +33,8 @@ module WhopSDK
33
33
  company_id: String,
34
34
  after: T.nilable(String),
35
35
  before: T.nilable(String),
36
+ created_after: T.nilable(Time),
37
+ created_before: T.nilable(Time),
36
38
  first: T.nilable(Integer),
37
39
  last: T.nilable(Integer),
38
40
  role: T.nilable(WhopSDK::AuthorizedUserRoles::OrSymbol),
@@ -51,6 +53,10 @@ module WhopSDK
51
53
  after: nil,
52
54
  # Returns the elements in the list that come before the specified cursor.
53
55
  before: nil,
56
+ # The minimum creation date to filter by
57
+ created_after: nil,
58
+ # The maximum creation date to filter by
59
+ created_before: nil,
54
60
  # Returns the first _n_ elements from the list.
55
61
  first: nil,
56
62
  # Returns the last _n_ elements from the list.
@@ -11,13 +11,20 @@ module WhopSDK
11
11
  # - `plan:create`
12
12
  # - `access_pass:create`
13
13
  # - `access_pass:update`
14
+ # - `checkout_configuration:basic:read`
14
15
  sig do
15
16
  params(
16
17
  plan: WhopSDK::CheckoutConfigurationCreateParams::Plan::OrHash,
17
18
  plan_id: String,
19
+ company_id: String,
18
20
  affiliate_code: T.nilable(String),
19
21
  metadata: T.nilable(T::Hash[Symbol, T.anything]),
22
+ payment_method_configuration:
23
+ T.nilable(
24
+ WhopSDK::CheckoutConfigurationCreateParams::PaymentMethodConfiguration::OrHash
25
+ ),
20
26
  redirect_url: T.nilable(String),
27
+ mode: Symbol,
21
28
  request_options: WhopSDK::RequestOptions::OrHash
22
29
  ).returns(WhopSDK::CheckoutConfiguration)
23
30
  end
@@ -26,12 +33,20 @@ module WhopSDK
26
33
  plan:,
27
34
  # The ID of the plan to use for the checkout configuration
28
35
  plan_id:,
36
+ # The ID of the company for which to generate the checkout configuration. Only
37
+ # required in setup mode.
38
+ company_id:,
29
39
  # The affiliate code to use for the checkout configuration
30
40
  affiliate_code: nil,
31
41
  # The metadata to use for the checkout configuration
32
42
  metadata: nil,
43
+ # This currently only works for configurations made in 'setup' mode. The explicit
44
+ # payment method configuration for the checkout session. If not provided, the
45
+ # platform or company's defaults will apply.
46
+ payment_method_configuration: nil,
33
47
  # The URL to redirect the user to after the checkout configuration is created
34
48
  redirect_url: nil,
49
+ mode: :setup,
35
50
  request_options: {}
36
51
  )
37
52
  end
@@ -64,6 +79,8 @@ module WhopSDK
64
79
  company_id: String,
65
80
  after: T.nilable(String),
66
81
  before: T.nilable(String),
82
+ created_after: T.nilable(Time),
83
+ created_before: T.nilable(Time),
67
84
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
68
85
  first: T.nilable(Integer),
69
86
  last: T.nilable(Integer),
@@ -82,6 +99,10 @@ module WhopSDK
82
99
  after: nil,
83
100
  # Returns the elements in the list that come before the specified cursor.
84
101
  before: nil,
102
+ # The minimum creation date to filter by
103
+ created_after: nil,
104
+ # The maximum creation date to filter by
105
+ created_before: nil,
85
106
  # The direction of the sort.
86
107
  direction: nil,
87
108
  # Returns the first _n_ elements from the list.
@@ -59,6 +59,8 @@ module WhopSDK
59
59
  parent_company_id: String,
60
60
  after: T.nilable(String),
61
61
  before: T.nilable(String),
62
+ created_after: T.nilable(Time),
63
+ created_before: T.nilable(Time),
62
64
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
63
65
  first: T.nilable(Integer),
64
66
  last: T.nilable(Integer),
@@ -74,6 +76,10 @@ module WhopSDK
74
76
  after: nil,
75
77
  # Returns the elements in the list that come before the specified cursor.
76
78
  before: nil,
79
+ # The minimum creation date to filter by
80
+ created_after: nil,
81
+ # The maximum creation date to filter by
82
+ created_before: nil,
77
83
  # The direction of the sort.
78
84
  direction: nil,
79
85
  # Returns the first _n_ elements from the list.
@@ -212,6 +212,54 @@ module WhopSDK
212
212
  )
213
213
  end
214
214
 
215
+ # Marks a course lesson as completed
216
+ sig do
217
+ params(
218
+ lesson_id: String,
219
+ request_options: WhopSDK::RequestOptions::OrHash
220
+ ).returns(T::Boolean)
221
+ end
222
+ def mark_as_completed(
223
+ # The ID of the lesson to mark as completed
224
+ lesson_id,
225
+ request_options: {}
226
+ )
227
+ end
228
+
229
+ # Starts a course lesson
230
+ sig do
231
+ params(
232
+ lesson_id: String,
233
+ request_options: WhopSDK::RequestOptions::OrHash
234
+ ).returns(T::Boolean)
235
+ end
236
+ def start(
237
+ # The ID of the lesson being started
238
+ lesson_id,
239
+ request_options: {}
240
+ )
241
+ end
242
+
243
+ # Submits answers for a course assessment
244
+ sig do
245
+ params(
246
+ lesson_id: String,
247
+ answers:
248
+ T::Array[
249
+ WhopSDK::CourseLessonSubmitAssessmentParams::Answer::OrHash
250
+ ],
251
+ request_options: WhopSDK::RequestOptions::OrHash
252
+ ).returns(WhopSDK::Models::CourseLessonSubmitAssessmentResponse)
253
+ end
254
+ def submit_assessment(
255
+ # The ID of the lesson (quiz or knowledge check) to submit answers for
256
+ lesson_id,
257
+ # The answers to the assessment questions
258
+ answers:,
259
+ request_options: {}
260
+ )
261
+ end
262
+
215
263
  # @api private
216
264
  sig { params(client: WhopSDK::Client).returns(T.attached_class) }
217
265
  def self.new(client:)
@@ -42,6 +42,8 @@ module WhopSDK
42
42
  company_id: String,
43
43
  after: T.nilable(String),
44
44
  before: T.nilable(String),
45
+ created_after: T.nilable(Time),
46
+ created_before: T.nilable(Time),
45
47
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
46
48
  first: T.nilable(Integer),
47
49
  last: T.nilable(Integer),
@@ -57,6 +59,10 @@ module WhopSDK
57
59
  after: nil,
58
60
  # Returns the elements in the list that come before the specified cursor.
59
61
  before: nil,
62
+ # The minimum creation date to filter by
63
+ created_after: nil,
64
+ # The maximum creation date to filter by
65
+ created_before: nil,
60
66
  # The direction of the sort.
61
67
  direction: nil,
62
68
  # Returns the first _n_ elements from the list.
@@ -33,6 +33,8 @@ module WhopSDK
33
33
  company_id: String,
34
34
  after: T.nilable(String),
35
35
  before: T.nilable(String),
36
+ created_after: T.nilable(Time),
37
+ created_before: T.nilable(Time),
36
38
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
37
39
  first: T.nilable(Integer),
38
40
  last: T.nilable(Integer),
@@ -52,6 +54,10 @@ module WhopSDK
52
54
  after: nil,
53
55
  # Returns the elements in the list that come before the specified cursor.
54
56
  before: nil,
57
+ # The minimum creation date to filter by
58
+ created_after: nil,
59
+ # The maximum creation date to filter by
60
+ created_before: nil,
55
61
  # The direction of the sort.
56
62
  direction: nil,
57
63
  # Returns the first _n_ elements from the list.
@@ -91,6 +91,8 @@ module WhopSDK
91
91
  after: T.nilable(String),
92
92
  app_id: T.nilable(String),
93
93
  before: T.nilable(String),
94
+ created_after: T.nilable(Time),
95
+ created_before: T.nilable(Time),
94
96
  first: T.nilable(Integer),
95
97
  last: T.nilable(Integer),
96
98
  product_id: T.nilable(String),
@@ -108,6 +110,10 @@ module WhopSDK
108
110
  app_id: nil,
109
111
  # Returns the elements in the list that come before the specified cursor.
110
112
  before: nil,
113
+ # The minimum creation date to filter by
114
+ created_after: nil,
115
+ # The maximum creation date to filter by
116
+ created_before: nil,
111
117
  # Returns the first _n_ elements from the list.
112
118
  first: nil,
113
119
  # Returns the last _n_ elements from the list.
@@ -28,8 +28,7 @@ module WhopSDK
28
28
  pinned: T.nilable(T::Boolean),
29
29
  poll: T.nilable(WhopSDK::ForumPostCreateParams::Poll::OrHash),
30
30
  title: T.nilable(String),
31
- visibility:
32
- T.nilable(WhopSDK::ForumPostCreateParams::Visibility::OrSymbol),
31
+ visibility: T.nilable(WhopSDK::ForumPostVisibilityType::OrSymbol),
33
32
  request_options: WhopSDK::RequestOptions::OrHash
34
33
  ).returns(WhopSDK::ForumPost)
35
34
  end
@@ -99,8 +98,7 @@ module WhopSDK
99
98
  content: T.nilable(String),
100
99
  is_pinned: T.nilable(T::Boolean),
101
100
  title: T.nilable(String),
102
- visibility:
103
- T.nilable(WhopSDK::ForumPostUpdateParams::Visibility::OrSymbol),
101
+ visibility: T.nilable(WhopSDK::ForumPostVisibilityType::OrSymbol),
104
102
  request_options: WhopSDK::RequestOptions::OrHash
105
103
  ).returns(WhopSDK::ForumPost)
106
104
  end
@@ -93,6 +93,8 @@ module WhopSDK
93
93
  before: T.nilable(String),
94
94
  collection_methods:
95
95
  T.nilable(T::Array[WhopSDK::CollectionMethod::OrSymbol]),
96
+ created_after: T.nilable(Time),
97
+ created_before: T.nilable(Time),
96
98
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
97
99
  first: T.nilable(Integer),
98
100
  last: T.nilable(Integer),
@@ -111,6 +113,10 @@ module WhopSDK
111
113
  before: nil,
112
114
  # Filter invoices by their collection method
113
115
  collection_methods: nil,
116
+ # The minimum creation date to filter by
117
+ created_after: nil,
118
+ # The maximum creation date to filter by
119
+ created_before: nil,
114
120
  # The direction of the sort.
115
121
  direction: nil,
116
122
  # Returns the first _n_ elements from the list.
@@ -38,8 +38,6 @@ module WhopSDK
38
38
  release_method: T.nilable(WhopSDK::ReleaseMethod::OrSymbol),
39
39
  renewal_price: T.nilable(Float),
40
40
  stock: T.nilable(Integer),
41
- strike_through_initial_price: T.nilable(Float),
42
- strike_through_renewal_price: T.nilable(Float),
43
41
  title: T.nilable(String),
44
42
  trial_period_days: T.nilable(Integer),
45
43
  unlimited_stock: T.nilable(T::Boolean),
@@ -60,7 +58,7 @@ module WhopSDK
60
58
  custom_fields: nil,
61
59
  # The description of the plan.
62
60
  description: nil,
63
- # The interval at which the plan charges (expiration plans).
61
+ # The interval at which the plan expires and revokes access (expiration plans).
64
62
  expiration_days: nil,
65
63
  # An image for the plan. This will be visible on the product page to customers.
66
64
  image: nil,
@@ -85,12 +83,6 @@ module WhopSDK
85
83
  renewal_price: nil,
86
84
  # The number of units available for purchase.
87
85
  stock: nil,
88
- # The price to display with a strikethrough for the initial price. Provided as a
89
- # number in dollars. Eg: 19.99 for $19.99
90
- strike_through_initial_price: nil,
91
- # The price to display with a strikethrough for the renewal price. Provided as a
92
- # number in dollars. Eg: 19.99 for $19.99
93
- strike_through_renewal_price: nil,
94
86
  # The title of the plan. This will be visible on the product page to customers.
95
87
  title: nil,
96
88
  # The number of free trial days added before a renewal plan.
@@ -222,6 +214,8 @@ module WhopSDK
222
214
  company_id: String,
223
215
  after: T.nilable(String),
224
216
  before: T.nilable(String),
217
+ created_after: T.nilable(Time),
218
+ created_before: T.nilable(Time),
225
219
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
226
220
  first: T.nilable(Integer),
227
221
  last: T.nilable(Integer),
@@ -244,6 +238,10 @@ module WhopSDK
244
238
  after: nil,
245
239
  # Returns the elements in the list that come before the specified cursor.
246
240
  before: nil,
241
+ # The minimum creation date to filter by
242
+ created_after: nil,
243
+ # The maximum creation date to filter by
244
+ created_before: nil,
247
245
  # The direction of the sort.
248
246
  direction: nil,
249
247
  # Returns the first _n_ elements from the list.
@@ -117,13 +117,6 @@ module WhopSDK
117
117
  sig do
118
118
  params(
119
119
  id: String,
120
- banner_image:
121
- T.nilable(
122
- T.any(
123
- WhopSDK::ProductUpdateParams::BannerImage::AttachmentInputWithDirectUploadID::OrHash,
124
- WhopSDK::ProductUpdateParams::BannerImage::AttachmentInputWithID::OrHash
125
- )
126
- ),
127
120
  business_type: T.nilable(WhopSDK::BusinessTypes::OrSymbol),
128
121
  collect_shipping_address: T.nilable(T::Boolean),
129
122
  custom_cta: T.nilable(WhopSDK::CustomCta::OrSymbol),
@@ -151,8 +144,6 @@ module WhopSDK
151
144
  def update(
152
145
  # The ID (tag) of the product
153
146
  id,
154
- # A banner image for the product in png, jpeg format
155
- banner_image: nil,
156
147
  # The different business types a company can be.
157
148
  business_type: nil,
158
149
  # Whether or not to collect shipping information at checkout from the customer.
@@ -205,6 +196,8 @@ module WhopSDK
205
196
  company_id: String,
206
197
  after: T.nilable(String),
207
198
  before: T.nilable(String),
199
+ created_after: T.nilable(Time),
200
+ created_before: T.nilable(Time),
208
201
  direction: T.nilable(WhopSDK::Direction::OrSymbol),
209
202
  first: T.nilable(Integer),
210
203
  last: T.nilable(Integer),
@@ -222,6 +215,10 @@ module WhopSDK
222
215
  after: nil,
223
216
  # Returns the elements in the list that come before the specified cursor.
224
217
  before: nil,
218
+ # The minimum creation date to filter by
219
+ created_after: nil,
220
+ # The maximum creation date to filter by
221
+ created_before: nil,
225
222
  # The direction of the sort.
226
223
  direction: nil,
227
224
  # Returns the first _n_ elements from the list.
@@ -97,6 +97,8 @@ module WhopSDK
97
97
  company_id: String,
98
98
  after: T.nilable(String),
99
99
  before: T.nilable(String),
100
+ created_after: T.nilable(Time),
101
+ created_before: T.nilable(Time),
100
102
  first: T.nilable(Integer),
101
103
  last: T.nilable(Integer),
102
104
  plan_ids: T.nilable(T::Array[String]),
@@ -114,6 +116,10 @@ module WhopSDK
114
116
  after: nil,
115
117
  # Returns the elements in the list that come before the specified cursor.
116
118
  before: nil,
119
+ # The minimum creation date to filter by
120
+ created_after: nil,
121
+ # The maximum creation date to filter by
122
+ created_before: nil,
117
123
  # Returns the first _n_ elements from the list.
118
124
  first: nil,
119
125
  # Returns the last _n_ elements from the list.