whop-sdk 0.0.1__py3-none-any.whl

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.

Potentially problematic release.


This version of whop-sdk might be problematic. Click here for more details.

Files changed (212) hide show
  1. whop_sdk/__init__.py +94 -0
  2. whop_sdk/_base_client.py +1995 -0
  3. whop_sdk/_client.py +664 -0
  4. whop_sdk/_compat.py +219 -0
  5. whop_sdk/_constants.py +14 -0
  6. whop_sdk/_exceptions.py +112 -0
  7. whop_sdk/_files.py +123 -0
  8. whop_sdk/_models.py +835 -0
  9. whop_sdk/_qs.py +150 -0
  10. whop_sdk/_resource.py +43 -0
  11. whop_sdk/_response.py +830 -0
  12. whop_sdk/_streaming.py +333 -0
  13. whop_sdk/_types.py +260 -0
  14. whop_sdk/_utils/__init__.py +64 -0
  15. whop_sdk/_utils/_compat.py +45 -0
  16. whop_sdk/_utils/_datetime_parse.py +136 -0
  17. whop_sdk/_utils/_logs.py +25 -0
  18. whop_sdk/_utils/_proxy.py +65 -0
  19. whop_sdk/_utils/_reflection.py +42 -0
  20. whop_sdk/_utils/_resources_proxy.py +24 -0
  21. whop_sdk/_utils/_streams.py +12 -0
  22. whop_sdk/_utils/_sync.py +86 -0
  23. whop_sdk/_utils/_transform.py +457 -0
  24. whop_sdk/_utils/_typing.py +156 -0
  25. whop_sdk/_utils/_utils.py +421 -0
  26. whop_sdk/_version.py +4 -0
  27. whop_sdk/lib/.keep +4 -0
  28. whop_sdk/pagination.py +61 -0
  29. whop_sdk/py.typed +0 -0
  30. whop_sdk/resources/__init__.py +316 -0
  31. whop_sdk/resources/app_builds.py +562 -0
  32. whop_sdk/resources/apps.py +665 -0
  33. whop_sdk/resources/authorized_users.py +336 -0
  34. whop_sdk/resources/chat_channels.py +469 -0
  35. whop_sdk/resources/checkout_configurations.py +464 -0
  36. whop_sdk/resources/companies.py +171 -0
  37. whop_sdk/resources/course_lesson_interactions.py +343 -0
  38. whop_sdk/resources/entries.py +539 -0
  39. whop_sdk/resources/experiences.py +859 -0
  40. whop_sdk/resources/forum_posts.py +512 -0
  41. whop_sdk/resources/invoices.py +633 -0
  42. whop_sdk/resources/ledger_accounts.py +171 -0
  43. whop_sdk/resources/memberships.py +810 -0
  44. whop_sdk/resources/messages.py +446 -0
  45. whop_sdk/resources/payments.py +761 -0
  46. whop_sdk/resources/plans.py +906 -0
  47. whop_sdk/resources/products.py +969 -0
  48. whop_sdk/resources/reactions.py +423 -0
  49. whop_sdk/resources/shipments.py +451 -0
  50. whop_sdk/resources/support_channels.py +455 -0
  51. whop_sdk/resources/transfers.py +488 -0
  52. whop_sdk/resources/users.py +248 -0
  53. whop_sdk/resources/webhooks.py +69 -0
  54. whop_sdk/types/__init__.py +135 -0
  55. whop_sdk/types/app_build_create_params.py +59 -0
  56. whop_sdk/types/app_build_list_params.py +34 -0
  57. whop_sdk/types/app_build_list_response.py +50 -0
  58. whop_sdk/types/app_create_params.py +19 -0
  59. whop_sdk/types/app_list_params.py +54 -0
  60. whop_sdk/types/app_list_response.py +91 -0
  61. whop_sdk/types/app_update_params.py +58 -0
  62. whop_sdk/types/authorized_user_list_params.py +33 -0
  63. whop_sdk/types/authorized_user_list_response.py +33 -0
  64. whop_sdk/types/authorized_user_retrieve_response.py +33 -0
  65. whop_sdk/types/chat_channel_list_params.py +28 -0
  66. whop_sdk/types/chat_channel_list_response.py +43 -0
  67. whop_sdk/types/chat_channel_update_params.py +32 -0
  68. whop_sdk/types/checkout_configuration_create_params.py +129 -0
  69. whop_sdk/types/checkout_configuration_list_params.py +33 -0
  70. whop_sdk/types/checkout_configuration_list_response.py +66 -0
  71. whop_sdk/types/course_lesson_interaction_list_params.py +34 -0
  72. whop_sdk/types/entry_approve_response.py +10 -0
  73. whop_sdk/types/entry_list_params.py +44 -0
  74. whop_sdk/types/entry_list_response.py +56 -0
  75. whop_sdk/types/experience_attach_params.py +12 -0
  76. whop_sdk/types/experience_create_params.py +22 -0
  77. whop_sdk/types/experience_delete_response.py +7 -0
  78. whop_sdk/types/experience_detach_params.py +12 -0
  79. whop_sdk/types/experience_list_params.py +31 -0
  80. whop_sdk/types/experience_list_response.py +47 -0
  81. whop_sdk/types/experience_update_params.py +41 -0
  82. whop_sdk/types/forum_post_create_params.py +85 -0
  83. whop_sdk/types/forum_post_list_params.py +31 -0
  84. whop_sdk/types/forum_post_list_response.py +53 -0
  85. whop_sdk/types/invoice_create_params.py +137 -0
  86. whop_sdk/types/invoice_create_response.py +16 -0
  87. whop_sdk/types/invoice_created_webhook_event.py +26 -0
  88. whop_sdk/types/invoice_list_params.py +50 -0
  89. whop_sdk/types/invoice_paid_webhook_event.py +26 -0
  90. whop_sdk/types/invoice_past_due_webhook_event.py +26 -0
  91. whop_sdk/types/invoice_void_response.py +7 -0
  92. whop_sdk/types/invoice_voided_webhook_event.py +26 -0
  93. whop_sdk/types/ledger_account_retrieve_response.py +78 -0
  94. whop_sdk/types/membership_cancel_params.py +13 -0
  95. whop_sdk/types/membership_list_params.py +70 -0
  96. whop_sdk/types/membership_list_response.py +117 -0
  97. whop_sdk/types/membership_pause_params.py +16 -0
  98. whop_sdk/types/membership_update_params.py +13 -0
  99. whop_sdk/types/message_create_params.py +51 -0
  100. whop_sdk/types/message_list_params.py +30 -0
  101. whop_sdk/types/message_list_response.py +90 -0
  102. whop_sdk/types/payment_list_params.py +72 -0
  103. whop_sdk/types/payment_list_response.py +221 -0
  104. whop_sdk/types/payment_refund_params.py +13 -0
  105. whop_sdk/types/plan_create_params.py +106 -0
  106. whop_sdk/types/plan_delete_response.py +7 -0
  107. whop_sdk/types/plan_list_params.py +49 -0
  108. whop_sdk/types/plan_list_response.py +92 -0
  109. whop_sdk/types/plan_update_params.py +95 -0
  110. whop_sdk/types/product_create_params.py +170 -0
  111. whop_sdk/types/product_delete_response.py +7 -0
  112. whop_sdk/types/product_list_params.py +41 -0
  113. whop_sdk/types/product_update_params.py +90 -0
  114. whop_sdk/types/reaction_create_params.py +19 -0
  115. whop_sdk/types/reaction_list_params.py +25 -0
  116. whop_sdk/types/reaction_list_response.py +32 -0
  117. whop_sdk/types/shared/__init__.py +55 -0
  118. whop_sdk/types/shared/access_pass_type.py +7 -0
  119. whop_sdk/types/shared/app.py +159 -0
  120. whop_sdk/types/shared/app_build.py +50 -0
  121. whop_sdk/types/shared/app_build_platforms.py +7 -0
  122. whop_sdk/types/shared/app_build_statuses.py +7 -0
  123. whop_sdk/types/shared/app_statuses.py +7 -0
  124. whop_sdk/types/shared/app_view_type.py +7 -0
  125. whop_sdk/types/shared/authorized_user_roles.py +9 -0
  126. whop_sdk/types/shared/business_types.py +22 -0
  127. whop_sdk/types/shared/chat_channel.py +43 -0
  128. whop_sdk/types/shared/checkout_configuration.py +66 -0
  129. whop_sdk/types/shared/collection_method.py +7 -0
  130. whop_sdk/types/shared/company.py +71 -0
  131. whop_sdk/types/shared/course_lesson_interaction.py +44 -0
  132. whop_sdk/types/shared/course_lesson_interaction_list_item.py +44 -0
  133. whop_sdk/types/shared/currency.py +92 -0
  134. whop_sdk/types/shared/custom_cta.py +21 -0
  135. whop_sdk/types/shared/direction.py +7 -0
  136. whop_sdk/types/shared/dms_post_types.py +7 -0
  137. whop_sdk/types/shared/entry.py +70 -0
  138. whop_sdk/types/shared/entry_status.py +7 -0
  139. whop_sdk/types/shared/experience.py +66 -0
  140. whop_sdk/types/shared/forum_post.py +53 -0
  141. whop_sdk/types/shared/friendly_receipt_status.py +24 -0
  142. whop_sdk/types/shared/global_affiliate_status.py +7 -0
  143. whop_sdk/types/shared/industry_types.py +67 -0
  144. whop_sdk/types/shared/invoice.py +61 -0
  145. whop_sdk/types/shared/invoice_list_item.py +61 -0
  146. whop_sdk/types/shared/invoice_status.py +7 -0
  147. whop_sdk/types/shared/membership.py +117 -0
  148. whop_sdk/types/shared/membership_status.py +9 -0
  149. whop_sdk/types/shared/message.py +90 -0
  150. whop_sdk/types/shared/page_info.py +21 -0
  151. whop_sdk/types/shared/payment.py +211 -0
  152. whop_sdk/types/shared/plan.py +123 -0
  153. whop_sdk/types/shared/plan_type.py +7 -0
  154. whop_sdk/types/shared/product.py +124 -0
  155. whop_sdk/types/shared/product_list_item.py +49 -0
  156. whop_sdk/types/shared/promo_type.py +7 -0
  157. whop_sdk/types/shared/reaction.py +32 -0
  158. whop_sdk/types/shared/receipt_status.py +7 -0
  159. whop_sdk/types/shared/release_method.py +7 -0
  160. whop_sdk/types/shared/shipment.py +48 -0
  161. whop_sdk/types/shared/shipment_carrier.py +84 -0
  162. whop_sdk/types/shared/shipment_status.py +18 -0
  163. whop_sdk/types/shared/shipment_substatus.py +36 -0
  164. whop_sdk/types/shared/support_channel.py +39 -0
  165. whop_sdk/types/shared/tax_type.py +7 -0
  166. whop_sdk/types/shared/transfer.py +109 -0
  167. whop_sdk/types/shared/visibility.py +7 -0
  168. whop_sdk/types/shared/visibility_filter.py +9 -0
  169. whop_sdk/types/shared/who_can_post.py +7 -0
  170. whop_sdk/types/shared/who_can_react.py +7 -0
  171. whop_sdk/types/shared_params/__init__.py +27 -0
  172. whop_sdk/types/shared_params/access_pass_type.py +9 -0
  173. whop_sdk/types/shared_params/app_build_platforms.py +9 -0
  174. whop_sdk/types/shared_params/app_build_statuses.py +9 -0
  175. whop_sdk/types/shared_params/app_statuses.py +9 -0
  176. whop_sdk/types/shared_params/app_view_type.py +9 -0
  177. whop_sdk/types/shared_params/authorized_user_roles.py +11 -0
  178. whop_sdk/types/shared_params/business_types.py +24 -0
  179. whop_sdk/types/shared_params/collection_method.py +9 -0
  180. whop_sdk/types/shared_params/currency.py +94 -0
  181. whop_sdk/types/shared_params/custom_cta.py +23 -0
  182. whop_sdk/types/shared_params/direction.py +9 -0
  183. whop_sdk/types/shared_params/entry_status.py +9 -0
  184. whop_sdk/types/shared_params/friendly_receipt_status.py +26 -0
  185. whop_sdk/types/shared_params/global_affiliate_status.py +9 -0
  186. whop_sdk/types/shared_params/industry_types.py +69 -0
  187. whop_sdk/types/shared_params/invoice_status.py +9 -0
  188. whop_sdk/types/shared_params/membership_status.py +11 -0
  189. whop_sdk/types/shared_params/plan_type.py +9 -0
  190. whop_sdk/types/shared_params/receipt_status.py +9 -0
  191. whop_sdk/types/shared_params/release_method.py +9 -0
  192. whop_sdk/types/shared_params/tax_type.py +9 -0
  193. whop_sdk/types/shared_params/visibility.py +9 -0
  194. whop_sdk/types/shared_params/visibility_filter.py +11 -0
  195. whop_sdk/types/shared_params/who_can_post.py +9 -0
  196. whop_sdk/types/shared_params/who_can_react.py +9 -0
  197. whop_sdk/types/shipment_create_params.py +18 -0
  198. whop_sdk/types/shipment_list_params.py +31 -0
  199. whop_sdk/types/shipment_list_response.py +48 -0
  200. whop_sdk/types/support_channel_create_params.py +15 -0
  201. whop_sdk/types/support_channel_list_params.py +40 -0
  202. whop_sdk/types/support_channel_list_response.py +39 -0
  203. whop_sdk/types/transfer_create_params.py +36 -0
  204. whop_sdk/types/transfer_list_params.py +42 -0
  205. whop_sdk/types/transfer_list_response.py +35 -0
  206. whop_sdk/types/unwrap_webhook_event.py +15 -0
  207. whop_sdk/types/user_check_access_response.py +15 -0
  208. whop_sdk/types/user_retrieve_response.py +25 -0
  209. whop_sdk-0.0.1.dist-info/METADATA +522 -0
  210. whop_sdk-0.0.1.dist-info/RECORD +212 -0
  211. whop_sdk-0.0.1.dist-info/WHEEL +4 -0
  212. whop_sdk-0.0.1.dist-info/licenses/LICENSE +201 -0
@@ -0,0 +1,170 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Iterable, Optional
6
+ from typing_extensions import Literal, Required, TypedDict
7
+
8
+ from .._types import SequenceNotStr
9
+ from .shared.currency import Currency
10
+ from .shared.plan_type import PlanType
11
+ from .shared.custom_cta import CustomCta
12
+ from .shared.visibility import Visibility
13
+ from .shared.business_types import BusinessTypes
14
+ from .shared.industry_types import IndustryTypes
15
+ from .shared.release_method import ReleaseMethod
16
+ from .shared.access_pass_type import AccessPassType
17
+ from .shared.global_affiliate_status import GlobalAffiliateStatus
18
+
19
+ __all__ = ["ProductCreateParams", "BannerImage", "PlanOptions", "PlanOptionsCustomField", "ProductHighlight"]
20
+
21
+
22
+ class ProductCreateParams(TypedDict, total=False):
23
+ company_id: Required[str]
24
+ """The ID of the company to create the product for."""
25
+
26
+ title: Required[str]
27
+ """The title of the product."""
28
+
29
+ access_pass_type: Optional[AccessPassType]
30
+ """The different types an access pass can be."""
31
+
32
+ banner_image: Optional[BannerImage]
33
+ """A banner image for the product in png, jpeg format"""
34
+
35
+ business_type: Optional[BusinessTypes]
36
+ """The different business types a company can be."""
37
+
38
+ collect_shipping_address: Optional[bool]
39
+ """Whether or not to collect shipping information at checkout from the customer."""
40
+
41
+ custom_cta: Optional[CustomCta]
42
+ """The different types of custom CTAs that can be selected."""
43
+
44
+ custom_cta_url: Optional[str]
45
+ """The custom call to action URL for the product."""
46
+
47
+ custom_statement_descriptor: Optional[str]
48
+ """The custom statement descriptor for the product i.e.
49
+
50
+ WHOP\\**SPORTS, must be between 5 and 22 characters, contain at least one letter,
51
+ and not contain any of the following characters: <, >, \\,, ', "
52
+ """
53
+
54
+ description: Optional[str]
55
+ """A written description of the product."""
56
+
57
+ experience_ids: Optional[SequenceNotStr[str]]
58
+ """An array of experience IDs that this pass has"""
59
+
60
+ global_affiliate_percentage: Optional[float]
61
+ """The percentage of the revenue that goes to the global affiliate program."""
62
+
63
+ global_affiliate_status: Optional[GlobalAffiliateStatus]
64
+ """The different statuses of the global affiliate program for an access pass."""
65
+
66
+ headline: Optional[str]
67
+ """The headline of the product."""
68
+
69
+ industry_type: Optional[IndustryTypes]
70
+ """The different industry types a company can be in."""
71
+
72
+ member_affiliate_percentage: Optional[float]
73
+ """The percentage of the revenue that goes to the member affiliate program."""
74
+
75
+ member_affiliate_status: Optional[GlobalAffiliateStatus]
76
+ """The different statuses of the global affiliate program for an access pass."""
77
+
78
+ plan_options: Optional[PlanOptions]
79
+ """The details to assign an autogenerated plan."""
80
+
81
+ product_highlights: Optional[Iterable[ProductHighlight]]
82
+ """The product highlights for the product."""
83
+
84
+ product_tax_code_id: Optional[str]
85
+ """The ID of the product tax code to apply to this product."""
86
+
87
+ redirect_purchase_url: Optional[str]
88
+ """The URL to redirect the customer to after a purchase."""
89
+
90
+ route: Optional[str]
91
+ """The route of the product."""
92
+
93
+ visibility: Optional[Visibility]
94
+ """Visibility of a resource"""
95
+
96
+
97
+ class BannerImage(TypedDict, total=False):
98
+ id: Optional[str]
99
+ """The ID of an existing attachment object.
100
+
101
+ Use this when updating a resource and keeping a subset of the attachments. Don't
102
+ use this unless you know what you're doing.
103
+ """
104
+
105
+ direct_upload_id: Optional[str]
106
+ """This ID should be used the first time you upload an attachment.
107
+
108
+ It is the ID of the direct upload that was created when uploading the file to S3
109
+ via the mediaDirectUpload mutation.
110
+ """
111
+
112
+
113
+ class PlanOptionsCustomField(TypedDict, total=False):
114
+ field_type: Required[Literal["text"]]
115
+ """The type of the custom field."""
116
+
117
+ name: Required[str]
118
+ """The name of the custom field."""
119
+
120
+ id: Optional[str]
121
+ """The ID of the custom field (if being updated)"""
122
+
123
+ order: Optional[int]
124
+ """The order of the field."""
125
+
126
+ placeholder: Optional[str]
127
+ """The placeholder value of the field."""
128
+
129
+ required: Optional[bool]
130
+ """Whether or not the field is required."""
131
+
132
+
133
+ class PlanOptions(TypedDict, total=False):
134
+ base_currency: Optional[Currency]
135
+ """The available currencies on the platform"""
136
+
137
+ billing_period: Optional[int]
138
+ """The interval at which the plan charges (renewal plans)."""
139
+
140
+ custom_fields: Optional[Iterable[PlanOptionsCustomField]]
141
+ """An array of custom field objects."""
142
+
143
+ initial_price: Optional[float]
144
+ """An additional amount charged upon first purchase."""
145
+
146
+ plan_type: Optional[PlanType]
147
+ """The type of plan that can be attached to an access pass"""
148
+
149
+ release_method: Optional[ReleaseMethod]
150
+ """The methods of how a plan can be released."""
151
+
152
+ renewal_price: Optional[float]
153
+ """The amount the customer is charged every billing period."""
154
+
155
+ visibility: Optional[Visibility]
156
+ """Visibility of a resource"""
157
+
158
+
159
+ class ProductHighlight(TypedDict, total=False):
160
+ content: Required[str]
161
+ """
162
+ Text to display to describe the product highlight (max length 250 for
163
+ qualification or benefits, 170 for who this is for, 140 for pricing features).
164
+ """
165
+
166
+ highlight_type: Required[Literal["qualification", "benefit", "who_this_is_for", "pricing_feature"]]
167
+ """The type of this highlight."""
168
+
169
+ title: Optional[str]
170
+ """The title of the product highlight, if applicable."""
@@ -0,0 +1,7 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing_extensions import TypeAlias
4
+
5
+ __all__ = ["ProductDeleteResponse"]
6
+
7
+ ProductDeleteResponse: TypeAlias = bool
@@ -0,0 +1,41 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import List, Optional
6
+ from typing_extensions import Literal, Required, TypedDict
7
+
8
+ from .shared.direction import Direction
9
+ from .shared.access_pass_type import AccessPassType
10
+ from .shared.visibility_filter import VisibilityFilter
11
+
12
+ __all__ = ["ProductListParams"]
13
+
14
+
15
+ class ProductListParams(TypedDict, total=False):
16
+ company_id: Required[str]
17
+ """The ID of the company to filter products by"""
18
+
19
+ after: Optional[str]
20
+ """Returns the elements in the list that come after the specified cursor."""
21
+
22
+ before: Optional[str]
23
+ """Returns the elements in the list that come before the specified cursor."""
24
+
25
+ direction: Optional[Direction]
26
+ """The direction of the sort."""
27
+
28
+ first: Optional[int]
29
+ """Returns the first _n_ elements from the list."""
30
+
31
+ last: Optional[int]
32
+ """Returns the last _n_ elements from the list."""
33
+
34
+ order: Optional[Literal["active_memberships_count", "created_at", "usd_gmv", "usd_gmv_30_days"]]
35
+ """The ways a relation of AccessPasses can be ordered"""
36
+
37
+ product_types: Optional[List[AccessPassType]]
38
+ """The type of products to filter by"""
39
+
40
+ visibilities: Optional[List[VisibilityFilter]]
41
+ """The visibility of the products to filter by"""
@@ -0,0 +1,90 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import TypedDict
7
+
8
+ from .shared.custom_cta import CustomCta
9
+ from .shared.visibility import Visibility
10
+ from .shared.business_types import BusinessTypes
11
+ from .shared.industry_types import IndustryTypes
12
+ from .shared.global_affiliate_status import GlobalAffiliateStatus
13
+
14
+ __all__ = ["ProductUpdateParams", "BannerImage"]
15
+
16
+
17
+ class ProductUpdateParams(TypedDict, total=False):
18
+ banner_image: Optional[BannerImage]
19
+ """A banner image for the product in png, jpeg format"""
20
+
21
+ business_type: Optional[BusinessTypes]
22
+ """The different business types a company can be."""
23
+
24
+ collect_shipping_address: Optional[bool]
25
+ """Whether or not to collect shipping information at checkout from the customer."""
26
+
27
+ custom_cta: Optional[CustomCta]
28
+ """The different types of custom CTAs that can be selected."""
29
+
30
+ custom_cta_url: Optional[str]
31
+ """The custom call to action URL for the product."""
32
+
33
+ custom_statement_descriptor: Optional[str]
34
+ """The custom statement descriptor for the product i.e.
35
+
36
+ WHOP\\**SPORTS, must be between 5 and 22 characters, contain at least one letter,
37
+ and not contain any of the following characters: <, >, \\,, ', "
38
+ """
39
+
40
+ description: Optional[str]
41
+ """A written description of the product."""
42
+
43
+ global_affiliate_percentage: Optional[float]
44
+ """The percentage of the revenue that goes to the global affiliate program."""
45
+
46
+ global_affiliate_status: Optional[GlobalAffiliateStatus]
47
+ """The different statuses of the global affiliate program for an access pass."""
48
+
49
+ headline: Optional[str]
50
+ """The headline of the product."""
51
+
52
+ industry_type: Optional[IndustryTypes]
53
+ """The different industry types a company can be in."""
54
+
55
+ member_affiliate_percentage: Optional[float]
56
+ """The percentage of the revenue that goes to the member affiliate program."""
57
+
58
+ member_affiliate_status: Optional[GlobalAffiliateStatus]
59
+ """The different statuses of the global affiliate program for an access pass."""
60
+
61
+ product_tax_code_id: Optional[str]
62
+ """The ID of the product tax code to apply to this product."""
63
+
64
+ redirect_purchase_url: Optional[str]
65
+ """The URL to redirect the customer to after a purchase."""
66
+
67
+ route: Optional[str]
68
+ """The route of the product."""
69
+
70
+ title: Optional[str]
71
+ """The title of the product."""
72
+
73
+ visibility: Optional[Visibility]
74
+ """Visibility of a resource"""
75
+
76
+
77
+ class BannerImage(TypedDict, total=False):
78
+ id: Optional[str]
79
+ """The ID of an existing attachment object.
80
+
81
+ Use this when updating a resource and keeping a subset of the attachments. Don't
82
+ use this unless you know what you're doing.
83
+ """
84
+
85
+ direct_upload_id: Optional[str]
86
+ """This ID should be used the first time you upload an attachment.
87
+
88
+ It is the ID of the direct upload that was created when uploading the file to S3
89
+ via the mediaDirectUpload mutation.
90
+ """
@@ -0,0 +1,19 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import Required, TypedDict
7
+
8
+ __all__ = ["ReactionCreateParams"]
9
+
10
+
11
+ class ReactionCreateParams(TypedDict, total=False):
12
+ resource_id: Required[str]
13
+ """The ID of the post or message to react to."""
14
+
15
+ emoji: Optional[str]
16
+ """The emoji to react with (e.g., :heart: or '😀').
17
+
18
+ It will be ignored in forums, as everything will be :heart:
19
+ """
@@ -0,0 +1,25 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import Required, TypedDict
7
+
8
+ __all__ = ["ReactionListParams"]
9
+
10
+
11
+ class ReactionListParams(TypedDict, total=False):
12
+ resource_id: Required[str]
13
+ """The ID of the post or message to list reactions for"""
14
+
15
+ after: Optional[str]
16
+ """Returns the elements in the list that come after the specified cursor."""
17
+
18
+ before: Optional[str]
19
+ """Returns the elements in the list that come before the specified cursor."""
20
+
21
+ first: Optional[int]
22
+ """Returns the first _n_ elements from the list."""
23
+
24
+ last: Optional[int]
25
+ """Returns the last _n_ elements from the list."""
@@ -0,0 +1,32 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import Optional
4
+
5
+ from .._models import BaseModel
6
+
7
+ __all__ = ["ReactionListResponse", "User"]
8
+
9
+
10
+ class User(BaseModel):
11
+ id: str
12
+ """The internal ID of the user."""
13
+
14
+ name: Optional[str] = None
15
+ """The name of the user from their Whop account."""
16
+
17
+ username: str
18
+ """The username of the user from their Whop account."""
19
+
20
+
21
+ class ReactionListResponse(BaseModel):
22
+ id: str
23
+ """The unique identifier for the entity"""
24
+
25
+ emoji: Optional[str] = None
26
+ """The emoji that was used in shortcode format (:heart:)"""
27
+
28
+ resource_id: str
29
+ """The ID of the post this reaction belongs to"""
30
+
31
+ user: User
32
+ """The user who reacted to the post"""
@@ -0,0 +1,55 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from .app import App as App
4
+ from .plan import Plan as Plan
5
+ from .entry import Entry as Entry
6
+ from .company import Company as Company
7
+ from .invoice import Invoice as Invoice
8
+ from .message import Message as Message
9
+ from .payment import Payment as Payment
10
+ from .product import Product as Product
11
+ from .currency import Currency as Currency
12
+ from .reaction import Reaction as Reaction
13
+ from .shipment import Shipment as Shipment
14
+ from .tax_type import TaxType as TaxType
15
+ from .transfer import Transfer as Transfer
16
+ from .app_build import AppBuild as AppBuild
17
+ from .direction import Direction as Direction
18
+ from .page_info import PageInfo as PageInfo
19
+ from .plan_type import PlanType as PlanType
20
+ from .custom_cta import CustomCta as CustomCta
21
+ from .experience import Experience as Experience
22
+ from .forum_post import ForumPost as ForumPost
23
+ from .membership import Membership as Membership
24
+ from .promo_type import PromoType as PromoType
25
+ from .visibility import Visibility as Visibility
26
+ from .app_statuses import AppStatuses as AppStatuses
27
+ from .chat_channel import ChatChannel as ChatChannel
28
+ from .entry_status import EntryStatus as EntryStatus
29
+ from .who_can_post import WhoCanPost as WhoCanPost
30
+ from .app_view_type import AppViewType as AppViewType
31
+ from .who_can_react import WhoCanReact as WhoCanReact
32
+ from .business_types import BusinessTypes as BusinessTypes
33
+ from .dms_post_types import DmsPostTypes as DmsPostTypes
34
+ from .industry_types import IndustryTypes as IndustryTypes
35
+ from .invoice_status import InvoiceStatus as InvoiceStatus
36
+ from .receipt_status import ReceiptStatus as ReceiptStatus
37
+ from .release_method import ReleaseMethod as ReleaseMethod
38
+ from .shipment_status import ShipmentStatus as ShipmentStatus
39
+ from .support_channel import SupportChannel as SupportChannel
40
+ from .access_pass_type import AccessPassType as AccessPassType
41
+ from .shipment_carrier import ShipmentCarrier as ShipmentCarrier
42
+ from .collection_method import CollectionMethod as CollectionMethod
43
+ from .invoice_list_item import InvoiceListItem as InvoiceListItem
44
+ from .membership_status import MembershipStatus as MembershipStatus
45
+ from .product_list_item import ProductListItem as ProductListItem
46
+ from .visibility_filter import VisibilityFilter as VisibilityFilter
47
+ from .app_build_statuses import AppBuildStatuses as AppBuildStatuses
48
+ from .shipment_substatus import ShipmentSubstatus as ShipmentSubstatus
49
+ from .app_build_platforms import AppBuildPlatforms as AppBuildPlatforms
50
+ from .authorized_user_roles import AuthorizedUserRoles as AuthorizedUserRoles
51
+ from .checkout_configuration import CheckoutConfiguration as CheckoutConfiguration
52
+ from .friendly_receipt_status import FriendlyReceiptStatus as FriendlyReceiptStatus
53
+ from .global_affiliate_status import GlobalAffiliateStatus as GlobalAffiliateStatus
54
+ from .course_lesson_interaction import CourseLessonInteraction as CourseLessonInteraction
55
+ from .course_lesson_interaction_list_item import CourseLessonInteractionListItem as CourseLessonInteractionListItem
@@ -0,0 +1,7 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing_extensions import Literal, TypeAlias
4
+
5
+ __all__ = ["AccessPassType"]
6
+
7
+ AccessPassType: TypeAlias = Literal["regular", "app", "experience_upsell", "api_only"]
@@ -0,0 +1,159 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import List, Optional
4
+ from datetime import datetime
5
+
6
+ from ..._models import BaseModel
7
+ from .app_statuses import AppStatuses
8
+
9
+ __all__ = ["App", "APIKey", "Company", "Creator", "RequestedPermission", "RequestedPermissionPermissionAction", "Stats"]
10
+
11
+
12
+ class APIKey(BaseModel):
13
+ id: str
14
+ """The ID of this API key"""
15
+
16
+ token: str
17
+ """This is the API key used to authenticate requests"""
18
+
19
+ created_at: datetime
20
+ """When this API key was created at"""
21
+
22
+
23
+ class Company(BaseModel):
24
+ id: str
25
+ """The ID (tag) of the company."""
26
+
27
+ title: str
28
+ """The title of the company."""
29
+
30
+
31
+ class Creator(BaseModel):
32
+ id: str
33
+ """The internal ID of the user."""
34
+
35
+ name: Optional[str] = None
36
+ """The name of the user from their Whop account."""
37
+
38
+ username: str
39
+ """The username of the user from their Whop account."""
40
+
41
+
42
+ class RequestedPermissionPermissionAction(BaseModel):
43
+ action: str
44
+ """The identifier of the action."""
45
+
46
+ name: str
47
+ """The human readable name of the action."""
48
+
49
+
50
+ class RequestedPermission(BaseModel):
51
+ is_required: bool
52
+ """Whether the action is required for the app to function."""
53
+
54
+ justification: str
55
+ """The reason for requesting the action."""
56
+
57
+ permission_action: RequestedPermissionPermissionAction
58
+ """The action that the app will request off of users when a user installs the app."""
59
+
60
+
61
+ class Stats(BaseModel):
62
+ dau: int
63
+ """
64
+ This is the number of users that have spent time in this app in the last 24
65
+ hours.
66
+ """
67
+
68
+ mau: int
69
+ """
70
+ This is the number of users that have spent time in this app in the last 28
71
+ days.
72
+ """
73
+
74
+ time_spent_last24_hours: int
75
+ """
76
+ This how much time, in seconds, users have spent in this app in the last 24
77
+ hours.
78
+ """
79
+
80
+ wau: int
81
+ """
82
+ This is the number of users that have spent time in this app in the last 7 days.
83
+ """
84
+
85
+
86
+ class App(BaseModel):
87
+ id: str
88
+ """The ID of the app"""
89
+
90
+ api_key: Optional[APIKey] = None
91
+ """The API key for the app"""
92
+
93
+ base_url: Optional[str] = None
94
+ """The base url of the app"""
95
+
96
+ company: Company
97
+ """The company that owns the app"""
98
+
99
+ creator: Creator
100
+ """The creator of the app"""
101
+
102
+ dashboard_path: Optional[str] = None
103
+ """The path part for a specific view of the app.
104
+
105
+ This is the template part of the url after the base domain. Eg:
106
+ /experiences/[experienceId]
107
+ """
108
+
109
+ description: Optional[str] = None
110
+ """The description of the app"""
111
+
112
+ discover_path: Optional[str] = None
113
+ """The path part for a specific view of the app.
114
+
115
+ This is the template part of the url after the base domain. Eg:
116
+ /experiences/[experienceId]
117
+ """
118
+
119
+ domain_id: str
120
+ """The unique part of the proxied domain for this app.
121
+
122
+ Used to generate the base url used to display the app inside the whop platform.
123
+ Refers to the id part in the final url: https://{domain_id}.apps.whop.com
124
+ """
125
+
126
+ experience_path: Optional[str] = None
127
+ """The path part for a specific view of the app.
128
+
129
+ This is the template part of the url after the base domain. Eg:
130
+ /experiences/[experienceId]
131
+ """
132
+
133
+ name: str
134
+ """The name of the app"""
135
+
136
+ requested_permissions: List[RequestedPermission]
137
+ """
138
+ The set of permissions that an app requests to be granted when a user installs
139
+ the app.
140
+ """
141
+
142
+ stats: Optional[Stats] = None
143
+ """A collection of stats for the app."""
144
+
145
+ status: AppStatuses
146
+ """If the status is live, the app is visible on Whop discovery.
147
+
148
+ In order to be live, you need to set the name, icon, and description. Being
149
+ unlisted or hidden means it's not visible on Whop but you can still install the
150
+ app via direct link. To remove the app from whop discovery, you should set the
151
+ status to unlisted.
152
+ """
153
+
154
+ verified: bool
155
+ """Whether this app has been verified by Whop.
156
+
157
+ Verified apps are endorsed by whop and are shown in the 'featured apps' section
158
+ of the app store.
159
+ """
@@ -0,0 +1,50 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import List, Optional
4
+ from datetime import datetime
5
+
6
+ from ..._models import BaseModel
7
+ from .app_view_type import AppViewType
8
+ from .app_build_statuses import AppBuildStatuses
9
+ from .app_build_platforms import AppBuildPlatforms
10
+
11
+ __all__ = ["AppBuild"]
12
+
13
+
14
+ class AppBuild(BaseModel):
15
+ id: str
16
+ """The ID of the app build. It will look like apbu_xxxxx."""
17
+
18
+ checksum: str
19
+ """
20
+ This is generated by the client and used to verify the integrity of the file
21
+ that is submitted. It is a SHA256 hash of the app build file.
22
+ """
23
+
24
+ created_at: datetime
25
+ """When this app build was created."""
26
+
27
+ file_url: str
28
+ """The URL to download the app build .zip file."""
29
+
30
+ is_production: bool
31
+ """Whether this app build is currently being used in production."""
32
+
33
+ platform: AppBuildPlatforms
34
+ """The platform of the app build (ios, android, web)"""
35
+
36
+ review_message: Optional[str] = None
37
+ """The review message for the app build, if any.
38
+
39
+ This is populated when the build is rejected and there is a reason specified by
40
+ the reviewer.
41
+ """
42
+
43
+ status: AppBuildStatuses
44
+ """The status of the app build (draft, approved, rejected, pending, etc)"""
45
+
46
+ supported_app_view_types: List[AppViewType]
47
+ """The supported app view types for the app build.
48
+
49
+ These are the views that the developer has specified that this build supports.
50
+ """
@@ -0,0 +1,7 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing_extensions import Literal, TypeAlias
4
+
5
+ __all__ = ["AppBuildPlatforms"]
6
+
7
+ AppBuildPlatforms: TypeAlias = Literal["ios", "android", "web"]
@@ -0,0 +1,7 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing_extensions import Literal, TypeAlias
4
+
5
+ __all__ = ["AppBuildStatuses"]
6
+
7
+ AppBuildStatuses: TypeAlias = Literal["draft", "pending", "approved", "rejected"]