whop-sdk 0.0.10__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.
- whop_sdk/__init__.py +94 -0
- whop_sdk/_base_client.py +1995 -0
- whop_sdk/_client.py +800 -0
- whop_sdk/_compat.py +219 -0
- whop_sdk/_constants.py +14 -0
- whop_sdk/_exceptions.py +112 -0
- whop_sdk/_files.py +123 -0
- whop_sdk/_models.py +857 -0
- whop_sdk/_qs.py +150 -0
- whop_sdk/_resource.py +43 -0
- whop_sdk/_response.py +830 -0
- whop_sdk/_streaming.py +333 -0
- whop_sdk/_types.py +260 -0
- whop_sdk/_utils/__init__.py +64 -0
- whop_sdk/_utils/_compat.py +45 -0
- whop_sdk/_utils/_datetime_parse.py +136 -0
- whop_sdk/_utils/_logs.py +25 -0
- whop_sdk/_utils/_proxy.py +65 -0
- whop_sdk/_utils/_reflection.py +42 -0
- whop_sdk/_utils/_resources_proxy.py +24 -0
- whop_sdk/_utils/_streams.py +12 -0
- whop_sdk/_utils/_sync.py +58 -0
- whop_sdk/_utils/_transform.py +457 -0
- whop_sdk/_utils/_typing.py +156 -0
- whop_sdk/_utils/_utils.py +421 -0
- whop_sdk/_version.py +4 -0
- whop_sdk/lib/.keep +4 -0
- whop_sdk/pagination.py +61 -0
- whop_sdk/py.typed +0 -0
- whop_sdk/resources/__init__.py +540 -0
- whop_sdk/resources/access_tokens.py +341 -0
- whop_sdk/resources/account_links.py +211 -0
- whop_sdk/resources/app_builds.py +587 -0
- whop_sdk/resources/apps.py +684 -0
- whop_sdk/resources/authorized_users.py +353 -0
- whop_sdk/resources/chat_channels.py +469 -0
- whop_sdk/resources/checkout_configurations.py +776 -0
- whop_sdk/resources/companies.py +465 -0
- whop_sdk/resources/course_chapters.py +602 -0
- whop_sdk/resources/course_lesson_interactions.py +343 -0
- whop_sdk/resources/course_lessons.py +1040 -0
- whop_sdk/resources/course_students.py +327 -0
- whop_sdk/resources/courses.py +776 -0
- whop_sdk/resources/disputes.py +693 -0
- whop_sdk/resources/entries.py +556 -0
- whop_sdk/resources/experiences.py +983 -0
- whop_sdk/resources/forum_posts.py +656 -0
- whop_sdk/resources/forums.py +446 -0
- whop_sdk/resources/invoices.py +1099 -0
- whop_sdk/resources/ledger_accounts.py +171 -0
- whop_sdk/resources/members.py +429 -0
- whop_sdk/resources/memberships.py +818 -0
- whop_sdk/resources/messages.py +558 -0
- whop_sdk/resources/notifications.py +388 -0
- whop_sdk/resources/payment_tokens.py +359 -0
- whop_sdk/resources/payments.py +1040 -0
- whop_sdk/resources/plans.py +1001 -0
- whop_sdk/resources/products.py +970 -0
- whop_sdk/resources/promo_codes.py +668 -0
- whop_sdk/resources/reactions.py +423 -0
- whop_sdk/resources/refunds.py +347 -0
- whop_sdk/resources/reviews.py +332 -0
- whop_sdk/resources/setup_intents.py +349 -0
- whop_sdk/resources/shipments.py +451 -0
- whop_sdk/resources/support_channels.py +455 -0
- whop_sdk/resources/transfers.py +513 -0
- whop_sdk/resources/users.py +248 -0
- whop_sdk/resources/webhooks.py +69 -0
- whop_sdk/resources/withdrawals.py +341 -0
- whop_sdk/types/__init__.py +262 -0
- whop_sdk/types/access_token_create_params.py +64 -0
- whop_sdk/types/access_token_create_response.py +15 -0
- whop_sdk/types/account_link_create_params.py +27 -0
- whop_sdk/types/account_link_create_response.py +15 -0
- whop_sdk/types/app_build_create_params.py +72 -0
- whop_sdk/types/app_build_list_params.py +42 -0
- whop_sdk/types/app_build_list_response.py +50 -0
- whop_sdk/types/app_create_params.py +19 -0
- whop_sdk/types/app_list_params.py +59 -0
- whop_sdk/types/app_list_response.py +110 -0
- whop_sdk/types/app_type.py +7 -0
- whop_sdk/types/app_update_params.py +67 -0
- whop_sdk/types/assessment_question_types.py +7 -0
- whop_sdk/types/authorized_user_list_params.py +41 -0
- whop_sdk/types/authorized_user_list_response.py +33 -0
- whop_sdk/types/authorized_user_retrieve_response.py +33 -0
- whop_sdk/types/billing_reasons.py +9 -0
- whop_sdk/types/card_brands.py +25 -0
- whop_sdk/types/chat_channel_list_params.py +28 -0
- whop_sdk/types/chat_channel_list_response.py +43 -0
- whop_sdk/types/chat_channel_update_params.py +32 -0
- whop_sdk/types/checkout_configuration_create_params.py +373 -0
- whop_sdk/types/checkout_configuration_list_params.py +41 -0
- whop_sdk/types/checkout_configuration_list_response.py +104 -0
- whop_sdk/types/checkout_modes.py +7 -0
- whop_sdk/types/company_create_params.py +22 -0
- whop_sdk/types/company_list_params.py +38 -0
- whop_sdk/types/company_list_response.py +76 -0
- whop_sdk/types/course.py +122 -0
- whop_sdk/types/course_chapter.py +32 -0
- whop_sdk/types/course_chapter_create_params.py +16 -0
- whop_sdk/types/course_chapter_delete_response.py +7 -0
- whop_sdk/types/course_chapter_list_params.py +25 -0
- whop_sdk/types/course_chapter_list_response.py +16 -0
- whop_sdk/types/course_chapter_update_params.py +12 -0
- whop_sdk/types/course_create_params.py +78 -0
- whop_sdk/types/course_delete_response.py +7 -0
- whop_sdk/types/course_lesson_create_params.py +63 -0
- whop_sdk/types/course_lesson_delete_response.py +7 -0
- whop_sdk/types/course_lesson_interaction_completed_webhook_event.py +26 -0
- whop_sdk/types/course_lesson_interaction_list_params.py +34 -0
- whop_sdk/types/course_lesson_list_params.py +28 -0
- whop_sdk/types/course_lesson_list_response.py +57 -0
- whop_sdk/types/course_lesson_mark_as_completed_response.py +7 -0
- whop_sdk/types/course_lesson_start_response.py +7 -0
- whop_sdk/types/course_lesson_submit_assessment_params.py +26 -0
- whop_sdk/types/course_lesson_submit_assessment_response.py +62 -0
- whop_sdk/types/course_lesson_update_params.py +222 -0
- whop_sdk/types/course_list_params.py +28 -0
- whop_sdk/types/course_list_response.py +90 -0
- whop_sdk/types/course_student_list_params.py +28 -0
- whop_sdk/types/course_student_list_response.py +42 -0
- whop_sdk/types/course_student_retrieve_response.py +61 -0
- whop_sdk/types/course_update_params.py +114 -0
- whop_sdk/types/course_visibilities.py +7 -0
- whop_sdk/types/dispute.py +284 -0
- whop_sdk/types/dispute_created_webhook_event.py +26 -0
- whop_sdk/types/dispute_list_params.py +38 -0
- whop_sdk/types/dispute_list_response.py +77 -0
- whop_sdk/types/dispute_statuses.py +17 -0
- whop_sdk/types/dispute_update_evidence_params.py +159 -0
- whop_sdk/types/dispute_updated_webhook_event.py +26 -0
- whop_sdk/types/embed_type.py +7 -0
- whop_sdk/types/entry_approve_response.py +10 -0
- whop_sdk/types/entry_approved_webhook_event.py +26 -0
- whop_sdk/types/entry_created_webhook_event.py +26 -0
- whop_sdk/types/entry_deleted_webhook_event.py +26 -0
- whop_sdk/types/entry_denied_webhook_event.py +26 -0
- whop_sdk/types/entry_list_params.py +52 -0
- whop_sdk/types/entry_list_response.py +56 -0
- whop_sdk/types/experience_attach_params.py +12 -0
- whop_sdk/types/experience_create_params.py +22 -0
- whop_sdk/types/experience_delete_response.py +7 -0
- whop_sdk/types/experience_detach_params.py +12 -0
- whop_sdk/types/experience_duplicate_params.py +13 -0
- whop_sdk/types/experience_list_params.py +40 -0
- whop_sdk/types/experience_list_response.py +73 -0
- whop_sdk/types/experience_update_params.py +46 -0
- whop_sdk/types/forum_list_params.py +28 -0
- whop_sdk/types/forum_list_response.py +33 -0
- whop_sdk/types/forum_post_create_params.py +101 -0
- whop_sdk/types/forum_post_list_params.py +31 -0
- whop_sdk/types/forum_post_list_response.py +60 -0
- whop_sdk/types/forum_post_update_params.py +56 -0
- whop_sdk/types/forum_post_visibility_type.py +7 -0
- whop_sdk/types/forum_update_params.py +23 -0
- whop_sdk/types/invoice_create_params.py +515 -0
- whop_sdk/types/invoice_created_webhook_event.py +26 -0
- whop_sdk/types/invoice_list_params.py +53 -0
- whop_sdk/types/invoice_paid_webhook_event.py +26 -0
- whop_sdk/types/invoice_past_due_webhook_event.py +26 -0
- whop_sdk/types/invoice_void_response.py +7 -0
- whop_sdk/types/invoice_voided_webhook_event.py +26 -0
- whop_sdk/types/languages.py +30 -0
- whop_sdk/types/ledger_account_retrieve_response.py +93 -0
- whop_sdk/types/lesson.py +219 -0
- whop_sdk/types/lesson_types.py +7 -0
- whop_sdk/types/lesson_visibilities.py +7 -0
- whop_sdk/types/member_list_params.py +73 -0
- whop_sdk/types/member_list_response.py +65 -0
- whop_sdk/types/member_retrieve_response.py +79 -0
- whop_sdk/types/membership_activated_webhook_event.py +29 -0
- whop_sdk/types/membership_cancel_params.py +13 -0
- whop_sdk/types/membership_deactivated_webhook_event.py +29 -0
- whop_sdk/types/membership_list_params.py +73 -0
- whop_sdk/types/membership_list_response.py +128 -0
- whop_sdk/types/membership_pause_params.py +16 -0
- whop_sdk/types/membership_update_params.py +13 -0
- whop_sdk/types/message_create_params.py +63 -0
- whop_sdk/types/message_list_params.py +30 -0
- whop_sdk/types/message_list_response.py +90 -0
- whop_sdk/types/message_update_params.py +45 -0
- whop_sdk/types/notification_create_params.py +93 -0
- whop_sdk/types/notification_create_response.py +10 -0
- whop_sdk/types/payment_create_params.py +162 -0
- whop_sdk/types/payment_failed_webhook_event.py +26 -0
- whop_sdk/types/payment_list_params.py +67 -0
- whop_sdk/types/payment_list_response.py +273 -0
- whop_sdk/types/payment_method_types.py +94 -0
- whop_sdk/types/payment_pending_webhook_event.py +26 -0
- whop_sdk/types/payment_provider.py +9 -0
- whop_sdk/types/payment_refund_params.py +13 -0
- whop_sdk/types/payment_succeeded_webhook_event.py +26 -0
- whop_sdk/types/payment_token_list_params.py +38 -0
- whop_sdk/types/payment_token_list_response.py +41 -0
- whop_sdk/types/payment_token_retrieve_params.py +12 -0
- whop_sdk/types/payment_token_retrieve_response.py +41 -0
- whop_sdk/types/plan_create_params.py +162 -0
- whop_sdk/types/plan_delete_response.py +7 -0
- whop_sdk/types/plan_list_params.py +57 -0
- whop_sdk/types/plan_list_response.py +128 -0
- whop_sdk/types/plan_update_params.py +155 -0
- whop_sdk/types/product_create_params.py +147 -0
- whop_sdk/types/product_delete_response.py +7 -0
- whop_sdk/types/product_list_params.py +49 -0
- whop_sdk/types/product_update_params.py +82 -0
- whop_sdk/types/promo_code.py +90 -0
- whop_sdk/types/promo_code_create_params.py +70 -0
- whop_sdk/types/promo_code_delete_response.py +7 -0
- whop_sdk/types/promo_code_list_params.py +45 -0
- whop_sdk/types/promo_code_list_response.py +79 -0
- whop_sdk/types/promo_code_status.py +7 -0
- whop_sdk/types/promo_duration.py +7 -0
- whop_sdk/types/reaction_create_params.py +19 -0
- whop_sdk/types/reaction_list_params.py +25 -0
- whop_sdk/types/reaction_list_response.py +32 -0
- whop_sdk/types/refund_created_webhook_event.py +154 -0
- whop_sdk/types/refund_list_params.py +38 -0
- whop_sdk/types/refund_list_response.py +53 -0
- whop_sdk/types/refund_reference_status.py +7 -0
- whop_sdk/types/refund_reference_type.py +9 -0
- whop_sdk/types/refund_retrieve_response.py +129 -0
- whop_sdk/types/refund_status.py +7 -0
- whop_sdk/types/refund_updated_webhook_event.py +154 -0
- whop_sdk/types/review_list_params.py +40 -0
- whop_sdk/types/review_list_response.py +78 -0
- whop_sdk/types/review_retrieve_response.py +103 -0
- whop_sdk/types/review_status.py +7 -0
- whop_sdk/types/setup_intent.py +111 -0
- whop_sdk/types/setup_intent_canceled_webhook_event.py +29 -0
- whop_sdk/types/setup_intent_list_params.py +38 -0
- whop_sdk/types/setup_intent_list_response.py +111 -0
- whop_sdk/types/setup_intent_requires_action_webhook_event.py +29 -0
- whop_sdk/types/setup_intent_status.py +7 -0
- whop_sdk/types/setup_intent_succeeded_webhook_event.py +29 -0
- whop_sdk/types/shared/__init__.py +62 -0
- whop_sdk/types/shared/access_level.py +7 -0
- whop_sdk/types/shared/access_pass_type.py +7 -0
- whop_sdk/types/shared/app.py +187 -0
- whop_sdk/types/shared/app_build.py +50 -0
- whop_sdk/types/shared/app_build_platforms.py +7 -0
- whop_sdk/types/shared/app_build_statuses.py +7 -0
- whop_sdk/types/shared/app_statuses.py +7 -0
- whop_sdk/types/shared/app_view_type.py +7 -0
- whop_sdk/types/shared/authorized_user_roles.py +9 -0
- whop_sdk/types/shared/business_types.py +22 -0
- whop_sdk/types/shared/chat_channel.py +43 -0
- whop_sdk/types/shared/checkout_configuration.py +104 -0
- whop_sdk/types/shared/collection_method.py +7 -0
- whop_sdk/types/shared/company.py +91 -0
- whop_sdk/types/shared/course_lesson_interaction.py +63 -0
- whop_sdk/types/shared/course_lesson_interaction_list_item.py +44 -0
- whop_sdk/types/shared/currency.py +93 -0
- whop_sdk/types/shared/custom_cta.py +21 -0
- whop_sdk/types/shared/direction.py +7 -0
- whop_sdk/types/shared/dms_post_types.py +7 -0
- whop_sdk/types/shared/email_notification_preferences.py +7 -0
- whop_sdk/types/shared/entry.py +70 -0
- whop_sdk/types/shared/entry_status.py +7 -0
- whop_sdk/types/shared/experience.py +91 -0
- whop_sdk/types/shared/forum.py +33 -0
- whop_sdk/types/shared/forum_post.py +60 -0
- whop_sdk/types/shared/friendly_receipt_status.py +24 -0
- whop_sdk/types/shared/global_affiliate_status.py +7 -0
- whop_sdk/types/shared/industry_types.py +67 -0
- whop_sdk/types/shared/invoice.py +64 -0
- whop_sdk/types/shared/invoice_list_item.py +64 -0
- whop_sdk/types/shared/invoice_status.py +7 -0
- whop_sdk/types/shared/member_most_recent_actions.py +22 -0
- whop_sdk/types/shared/member_statuses.py +7 -0
- whop_sdk/types/shared/membership.py +128 -0
- whop_sdk/types/shared/membership_status.py +9 -0
- whop_sdk/types/shared/message.py +90 -0
- whop_sdk/types/shared/page_info.py +21 -0
- whop_sdk/types/shared/payment.py +273 -0
- whop_sdk/types/shared/plan.py +159 -0
- whop_sdk/types/shared/plan_type.py +7 -0
- whop_sdk/types/shared/product.py +132 -0
- whop_sdk/types/shared/product_list_item.py +57 -0
- whop_sdk/types/shared/promo_type.py +7 -0
- whop_sdk/types/shared/reaction.py +32 -0
- whop_sdk/types/shared/receipt_status.py +7 -0
- whop_sdk/types/shared/release_method.py +7 -0
- whop_sdk/types/shared/shipment.py +48 -0
- whop_sdk/types/shared/shipment_carrier.py +84 -0
- whop_sdk/types/shared/shipment_status.py +18 -0
- whop_sdk/types/shared/shipment_substatus.py +36 -0
- whop_sdk/types/shared/support_channel.py +39 -0
- whop_sdk/types/shared/tax_type.py +7 -0
- whop_sdk/types/shared/transfer.py +112 -0
- whop_sdk/types/shared/visibility.py +7 -0
- whop_sdk/types/shared/visibility_filter.py +9 -0
- whop_sdk/types/shared/who_can_comment_types.py +7 -0
- whop_sdk/types/shared/who_can_post.py +7 -0
- whop_sdk/types/shared/who_can_post_types.py +7 -0
- whop_sdk/types/shared/who_can_react.py +7 -0
- whop_sdk/types/shared_params/__init__.py +34 -0
- whop_sdk/types/shared_params/access_level.py +9 -0
- whop_sdk/types/shared_params/access_pass_type.py +9 -0
- whop_sdk/types/shared_params/app_build_platforms.py +9 -0
- whop_sdk/types/shared_params/app_build_statuses.py +9 -0
- whop_sdk/types/shared_params/app_statuses.py +9 -0
- whop_sdk/types/shared_params/app_view_type.py +9 -0
- whop_sdk/types/shared_params/authorized_user_roles.py +11 -0
- whop_sdk/types/shared_params/business_types.py +24 -0
- whop_sdk/types/shared_params/collection_method.py +9 -0
- whop_sdk/types/shared_params/currency.py +95 -0
- whop_sdk/types/shared_params/custom_cta.py +23 -0
- whop_sdk/types/shared_params/direction.py +9 -0
- whop_sdk/types/shared_params/email_notification_preferences.py +9 -0
- whop_sdk/types/shared_params/entry_status.py +9 -0
- whop_sdk/types/shared_params/friendly_receipt_status.py +26 -0
- whop_sdk/types/shared_params/global_affiliate_status.py +9 -0
- whop_sdk/types/shared_params/industry_types.py +69 -0
- whop_sdk/types/shared_params/invoice_status.py +9 -0
- whop_sdk/types/shared_params/member_most_recent_actions.py +24 -0
- whop_sdk/types/shared_params/member_statuses.py +9 -0
- whop_sdk/types/shared_params/membership_status.py +11 -0
- whop_sdk/types/shared_params/plan_type.py +9 -0
- whop_sdk/types/shared_params/promo_type.py +9 -0
- whop_sdk/types/shared_params/receipt_status.py +9 -0
- whop_sdk/types/shared_params/release_method.py +9 -0
- whop_sdk/types/shared_params/tax_type.py +9 -0
- whop_sdk/types/shared_params/visibility.py +9 -0
- whop_sdk/types/shared_params/visibility_filter.py +11 -0
- whop_sdk/types/shared_params/who_can_comment_types.py +9 -0
- whop_sdk/types/shared_params/who_can_post.py +9 -0
- whop_sdk/types/shared_params/who_can_post_types.py +9 -0
- whop_sdk/types/shared_params/who_can_react.py +9 -0
- whop_sdk/types/shipment_create_params.py +18 -0
- whop_sdk/types/shipment_list_params.py +31 -0
- whop_sdk/types/shipment_list_response.py +48 -0
- whop_sdk/types/support_channel_create_params.py +15 -0
- whop_sdk/types/support_channel_list_params.py +40 -0
- whop_sdk/types/support_channel_list_response.py +39 -0
- whop_sdk/types/transfer_create_params.py +39 -0
- whop_sdk/types/transfer_list_params.py +50 -0
- whop_sdk/types/transfer_list_response.py +38 -0
- whop_sdk/types/unwrap_webhook_event.py +52 -0
- whop_sdk/types/user_check_access_response.py +14 -0
- whop_sdk/types/user_retrieve_response.py +36 -0
- whop_sdk/types/withdrawal_fee_types.py +7 -0
- whop_sdk/types/withdrawal_list_params.py +38 -0
- whop_sdk/types/withdrawal_list_response.py +45 -0
- whop_sdk/types/withdrawal_retrieve_response.py +154 -0
- whop_sdk/types/withdrawal_speeds.py +7 -0
- whop_sdk/types/withdrawal_status.py +9 -0
- whop_sdk/types/withdrawal_types.py +7 -0
- whop_sdk-0.0.10.dist-info/METADATA +509 -0
- whop_sdk-0.0.10.dist-info/RECORD +352 -0
- whop_sdk-0.0.10.dist-info/WHEEL +4 -0
- whop_sdk-0.0.10.dist-info/licenses/LICENSE +201 -0
whop_sdk/_client.py
ADDED
|
@@ -0,0 +1,800 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
import os
|
|
6
|
+
from typing import Any, Mapping
|
|
7
|
+
from typing_extensions import Self, override
|
|
8
|
+
|
|
9
|
+
import httpx
|
|
10
|
+
|
|
11
|
+
from . import _exceptions
|
|
12
|
+
from ._qs import Querystring
|
|
13
|
+
from ._types import (
|
|
14
|
+
Omit,
|
|
15
|
+
Timeout,
|
|
16
|
+
NotGiven,
|
|
17
|
+
Transport,
|
|
18
|
+
ProxiesTypes,
|
|
19
|
+
RequestOptions,
|
|
20
|
+
not_given,
|
|
21
|
+
)
|
|
22
|
+
from ._utils import is_given, get_async_library
|
|
23
|
+
from ._version import __version__
|
|
24
|
+
from .resources import (
|
|
25
|
+
apps,
|
|
26
|
+
plans,
|
|
27
|
+
users,
|
|
28
|
+
forums,
|
|
29
|
+
courses,
|
|
30
|
+
entries,
|
|
31
|
+
members,
|
|
32
|
+
refunds,
|
|
33
|
+
reviews,
|
|
34
|
+
disputes,
|
|
35
|
+
invoices,
|
|
36
|
+
messages,
|
|
37
|
+
payments,
|
|
38
|
+
products,
|
|
39
|
+
webhooks,
|
|
40
|
+
companies,
|
|
41
|
+
reactions,
|
|
42
|
+
shipments,
|
|
43
|
+
transfers,
|
|
44
|
+
app_builds,
|
|
45
|
+
experiences,
|
|
46
|
+
forum_posts,
|
|
47
|
+
memberships,
|
|
48
|
+
promo_codes,
|
|
49
|
+
withdrawals,
|
|
50
|
+
access_tokens,
|
|
51
|
+
account_links,
|
|
52
|
+
chat_channels,
|
|
53
|
+
notifications,
|
|
54
|
+
setup_intents,
|
|
55
|
+
course_lessons,
|
|
56
|
+
payment_tokens,
|
|
57
|
+
course_chapters,
|
|
58
|
+
course_students,
|
|
59
|
+
ledger_accounts,
|
|
60
|
+
authorized_users,
|
|
61
|
+
support_channels,
|
|
62
|
+
checkout_configurations,
|
|
63
|
+
course_lesson_interactions,
|
|
64
|
+
)
|
|
65
|
+
from ._streaming import Stream as Stream, AsyncStream as AsyncStream
|
|
66
|
+
from ._exceptions import WhopError, APIStatusError
|
|
67
|
+
from ._base_client import (
|
|
68
|
+
DEFAULT_MAX_RETRIES,
|
|
69
|
+
SyncAPIClient,
|
|
70
|
+
AsyncAPIClient,
|
|
71
|
+
)
|
|
72
|
+
|
|
73
|
+
__all__ = ["Timeout", "Transport", "ProxiesTypes", "RequestOptions", "Whop", "AsyncWhop", "Client", "AsyncClient"]
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
class Whop(SyncAPIClient):
|
|
77
|
+
apps: apps.AppsResource
|
|
78
|
+
invoices: invoices.InvoicesResource
|
|
79
|
+
course_lesson_interactions: course_lesson_interactions.CourseLessonInteractionsResource
|
|
80
|
+
products: products.ProductsResource
|
|
81
|
+
companies: companies.CompaniesResource
|
|
82
|
+
webhooks: webhooks.WebhooksResource
|
|
83
|
+
plans: plans.PlansResource
|
|
84
|
+
entries: entries.EntriesResource
|
|
85
|
+
forum_posts: forum_posts.ForumPostsResource
|
|
86
|
+
transfers: transfers.TransfersResource
|
|
87
|
+
ledger_accounts: ledger_accounts.LedgerAccountsResource
|
|
88
|
+
memberships: memberships.MembershipsResource
|
|
89
|
+
authorized_users: authorized_users.AuthorizedUsersResource
|
|
90
|
+
app_builds: app_builds.AppBuildsResource
|
|
91
|
+
shipments: shipments.ShipmentsResource
|
|
92
|
+
checkout_configurations: checkout_configurations.CheckoutConfigurationsResource
|
|
93
|
+
messages: messages.MessagesResource
|
|
94
|
+
chat_channels: chat_channels.ChatChannelsResource
|
|
95
|
+
users: users.UsersResource
|
|
96
|
+
payments: payments.PaymentsResource
|
|
97
|
+
support_channels: support_channels.SupportChannelsResource
|
|
98
|
+
experiences: experiences.ExperiencesResource
|
|
99
|
+
reactions: reactions.ReactionsResource
|
|
100
|
+
members: members.MembersResource
|
|
101
|
+
forums: forums.ForumsResource
|
|
102
|
+
promo_codes: promo_codes.PromoCodesResource
|
|
103
|
+
courses: courses.CoursesResource
|
|
104
|
+
course_chapters: course_chapters.CourseChaptersResource
|
|
105
|
+
course_lessons: course_lessons.CourseLessonsResource
|
|
106
|
+
reviews: reviews.ReviewsResource
|
|
107
|
+
course_students: course_students.CourseStudentsResource
|
|
108
|
+
access_tokens: access_tokens.AccessTokensResource
|
|
109
|
+
notifications: notifications.NotificationsResource
|
|
110
|
+
disputes: disputes.DisputesResource
|
|
111
|
+
refunds: refunds.RefundsResource
|
|
112
|
+
withdrawals: withdrawals.WithdrawalsResource
|
|
113
|
+
account_links: account_links.AccountLinksResource
|
|
114
|
+
setup_intents: setup_intents.SetupIntentsResource
|
|
115
|
+
payment_tokens: payment_tokens.PaymentTokensResource
|
|
116
|
+
with_raw_response: WhopWithRawResponse
|
|
117
|
+
with_streaming_response: WhopWithStreamedResponse
|
|
118
|
+
|
|
119
|
+
# client options
|
|
120
|
+
api_key: str
|
|
121
|
+
webhook_key: str | None
|
|
122
|
+
app_id: str | None
|
|
123
|
+
|
|
124
|
+
def __init__(
|
|
125
|
+
self,
|
|
126
|
+
*,
|
|
127
|
+
api_key: str | None = None,
|
|
128
|
+
webhook_key: str | None = None,
|
|
129
|
+
app_id: str | None = None,
|
|
130
|
+
base_url: str | httpx.URL | None = None,
|
|
131
|
+
timeout: float | Timeout | None | NotGiven = not_given,
|
|
132
|
+
max_retries: int = DEFAULT_MAX_RETRIES,
|
|
133
|
+
default_headers: Mapping[str, str] | None = None,
|
|
134
|
+
default_query: Mapping[str, object] | None = None,
|
|
135
|
+
# Configure a custom httpx client.
|
|
136
|
+
# We provide a `DefaultHttpxClient` class that you can pass to retain the default values we use for `limits`, `timeout` & `follow_redirects`.
|
|
137
|
+
# See the [httpx documentation](https://www.python-httpx.org/api/#client) for more details.
|
|
138
|
+
http_client: httpx.Client | None = None,
|
|
139
|
+
# Enable or disable schema validation for data returned by the API.
|
|
140
|
+
# When enabled an error APIResponseValidationError is raised
|
|
141
|
+
# if the API responds with invalid data for the expected schema.
|
|
142
|
+
#
|
|
143
|
+
# This parameter may be removed or changed in the future.
|
|
144
|
+
# If you rely on this feature, please open a GitHub issue
|
|
145
|
+
# outlining your use-case to help us decide if it should be
|
|
146
|
+
# part of our public interface in the future.
|
|
147
|
+
_strict_response_validation: bool = False,
|
|
148
|
+
) -> None:
|
|
149
|
+
"""Construct a new synchronous Whop client instance.
|
|
150
|
+
|
|
151
|
+
This automatically infers the following arguments from their corresponding environment variables if they are not provided:
|
|
152
|
+
- `api_key` from `WHOP_API_KEY`
|
|
153
|
+
- `webhook_key` from `WHOP_WEBHOOK_SECRET`
|
|
154
|
+
- `app_id` from `WHOP_APP_ID`
|
|
155
|
+
"""
|
|
156
|
+
if api_key is None:
|
|
157
|
+
api_key = os.environ.get("WHOP_API_KEY")
|
|
158
|
+
if api_key is None:
|
|
159
|
+
raise WhopError(
|
|
160
|
+
"The api_key client option must be set either by passing api_key to the client or by setting the WHOP_API_KEY environment variable"
|
|
161
|
+
)
|
|
162
|
+
self.api_key = api_key
|
|
163
|
+
|
|
164
|
+
if webhook_key is None:
|
|
165
|
+
webhook_key = os.environ.get("WHOP_WEBHOOK_SECRET")
|
|
166
|
+
self.webhook_key = webhook_key
|
|
167
|
+
|
|
168
|
+
if app_id is None:
|
|
169
|
+
app_id = os.environ.get("WHOP_APP_ID")
|
|
170
|
+
self.app_id = app_id
|
|
171
|
+
|
|
172
|
+
if base_url is None:
|
|
173
|
+
base_url = os.environ.get("WHOP_BASE_URL")
|
|
174
|
+
if base_url is None:
|
|
175
|
+
base_url = f"https://api.whop.com/api/v1"
|
|
176
|
+
|
|
177
|
+
super().__init__(
|
|
178
|
+
version=__version__,
|
|
179
|
+
base_url=base_url,
|
|
180
|
+
max_retries=max_retries,
|
|
181
|
+
timeout=timeout,
|
|
182
|
+
http_client=http_client,
|
|
183
|
+
custom_headers=default_headers,
|
|
184
|
+
custom_query=default_query,
|
|
185
|
+
_strict_response_validation=_strict_response_validation,
|
|
186
|
+
)
|
|
187
|
+
|
|
188
|
+
self.apps = apps.AppsResource(self)
|
|
189
|
+
self.invoices = invoices.InvoicesResource(self)
|
|
190
|
+
self.course_lesson_interactions = course_lesson_interactions.CourseLessonInteractionsResource(self)
|
|
191
|
+
self.products = products.ProductsResource(self)
|
|
192
|
+
self.companies = companies.CompaniesResource(self)
|
|
193
|
+
self.webhooks = webhooks.WebhooksResource(self)
|
|
194
|
+
self.plans = plans.PlansResource(self)
|
|
195
|
+
self.entries = entries.EntriesResource(self)
|
|
196
|
+
self.forum_posts = forum_posts.ForumPostsResource(self)
|
|
197
|
+
self.transfers = transfers.TransfersResource(self)
|
|
198
|
+
self.ledger_accounts = ledger_accounts.LedgerAccountsResource(self)
|
|
199
|
+
self.memberships = memberships.MembershipsResource(self)
|
|
200
|
+
self.authorized_users = authorized_users.AuthorizedUsersResource(self)
|
|
201
|
+
self.app_builds = app_builds.AppBuildsResource(self)
|
|
202
|
+
self.shipments = shipments.ShipmentsResource(self)
|
|
203
|
+
self.checkout_configurations = checkout_configurations.CheckoutConfigurationsResource(self)
|
|
204
|
+
self.messages = messages.MessagesResource(self)
|
|
205
|
+
self.chat_channels = chat_channels.ChatChannelsResource(self)
|
|
206
|
+
self.users = users.UsersResource(self)
|
|
207
|
+
self.payments = payments.PaymentsResource(self)
|
|
208
|
+
self.support_channels = support_channels.SupportChannelsResource(self)
|
|
209
|
+
self.experiences = experiences.ExperiencesResource(self)
|
|
210
|
+
self.reactions = reactions.ReactionsResource(self)
|
|
211
|
+
self.members = members.MembersResource(self)
|
|
212
|
+
self.forums = forums.ForumsResource(self)
|
|
213
|
+
self.promo_codes = promo_codes.PromoCodesResource(self)
|
|
214
|
+
self.courses = courses.CoursesResource(self)
|
|
215
|
+
self.course_chapters = course_chapters.CourseChaptersResource(self)
|
|
216
|
+
self.course_lessons = course_lessons.CourseLessonsResource(self)
|
|
217
|
+
self.reviews = reviews.ReviewsResource(self)
|
|
218
|
+
self.course_students = course_students.CourseStudentsResource(self)
|
|
219
|
+
self.access_tokens = access_tokens.AccessTokensResource(self)
|
|
220
|
+
self.notifications = notifications.NotificationsResource(self)
|
|
221
|
+
self.disputes = disputes.DisputesResource(self)
|
|
222
|
+
self.refunds = refunds.RefundsResource(self)
|
|
223
|
+
self.withdrawals = withdrawals.WithdrawalsResource(self)
|
|
224
|
+
self.account_links = account_links.AccountLinksResource(self)
|
|
225
|
+
self.setup_intents = setup_intents.SetupIntentsResource(self)
|
|
226
|
+
self.payment_tokens = payment_tokens.PaymentTokensResource(self)
|
|
227
|
+
self.with_raw_response = WhopWithRawResponse(self)
|
|
228
|
+
self.with_streaming_response = WhopWithStreamedResponse(self)
|
|
229
|
+
|
|
230
|
+
@property
|
|
231
|
+
@override
|
|
232
|
+
def qs(self) -> Querystring:
|
|
233
|
+
return Querystring(array_format="brackets")
|
|
234
|
+
|
|
235
|
+
@property
|
|
236
|
+
@override
|
|
237
|
+
def auth_headers(self) -> dict[str, str]:
|
|
238
|
+
api_key = self.api_key
|
|
239
|
+
return {"Authorization": f"Bearer {api_key}"}
|
|
240
|
+
|
|
241
|
+
@property
|
|
242
|
+
@override
|
|
243
|
+
def default_headers(self) -> dict[str, str | Omit]:
|
|
244
|
+
return {
|
|
245
|
+
**super().default_headers,
|
|
246
|
+
"X-Stainless-Async": "false",
|
|
247
|
+
"X-Whop-App-Id": self.app_id if self.app_id is not None else Omit(),
|
|
248
|
+
**self._custom_headers,
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
def copy(
|
|
252
|
+
self,
|
|
253
|
+
*,
|
|
254
|
+
api_key: str | None = None,
|
|
255
|
+
webhook_key: str | None = None,
|
|
256
|
+
app_id: str | None = None,
|
|
257
|
+
base_url: str | httpx.URL | None = None,
|
|
258
|
+
timeout: float | Timeout | None | NotGiven = not_given,
|
|
259
|
+
http_client: httpx.Client | None = None,
|
|
260
|
+
max_retries: int | NotGiven = not_given,
|
|
261
|
+
default_headers: Mapping[str, str] | None = None,
|
|
262
|
+
set_default_headers: Mapping[str, str] | None = None,
|
|
263
|
+
default_query: Mapping[str, object] | None = None,
|
|
264
|
+
set_default_query: Mapping[str, object] | None = None,
|
|
265
|
+
_extra_kwargs: Mapping[str, Any] = {},
|
|
266
|
+
) -> Self:
|
|
267
|
+
"""
|
|
268
|
+
Create a new client instance re-using the same options given to the current client with optional overriding.
|
|
269
|
+
"""
|
|
270
|
+
if default_headers is not None and set_default_headers is not None:
|
|
271
|
+
raise ValueError("The `default_headers` and `set_default_headers` arguments are mutually exclusive")
|
|
272
|
+
|
|
273
|
+
if default_query is not None and set_default_query is not None:
|
|
274
|
+
raise ValueError("The `default_query` and `set_default_query` arguments are mutually exclusive")
|
|
275
|
+
|
|
276
|
+
headers = self._custom_headers
|
|
277
|
+
if default_headers is not None:
|
|
278
|
+
headers = {**headers, **default_headers}
|
|
279
|
+
elif set_default_headers is not None:
|
|
280
|
+
headers = set_default_headers
|
|
281
|
+
|
|
282
|
+
params = self._custom_query
|
|
283
|
+
if default_query is not None:
|
|
284
|
+
params = {**params, **default_query}
|
|
285
|
+
elif set_default_query is not None:
|
|
286
|
+
params = set_default_query
|
|
287
|
+
|
|
288
|
+
http_client = http_client or self._client
|
|
289
|
+
return self.__class__(
|
|
290
|
+
api_key=api_key or self.api_key,
|
|
291
|
+
webhook_key=webhook_key or self.webhook_key,
|
|
292
|
+
app_id=app_id or self.app_id,
|
|
293
|
+
base_url=base_url or self.base_url,
|
|
294
|
+
timeout=self.timeout if isinstance(timeout, NotGiven) else timeout,
|
|
295
|
+
http_client=http_client,
|
|
296
|
+
max_retries=max_retries if is_given(max_retries) else self.max_retries,
|
|
297
|
+
default_headers=headers,
|
|
298
|
+
default_query=params,
|
|
299
|
+
**_extra_kwargs,
|
|
300
|
+
)
|
|
301
|
+
|
|
302
|
+
# Alias for `copy` for nicer inline usage, e.g.
|
|
303
|
+
# client.with_options(timeout=10).foo.create(...)
|
|
304
|
+
with_options = copy
|
|
305
|
+
|
|
306
|
+
@override
|
|
307
|
+
def _make_status_error(
|
|
308
|
+
self,
|
|
309
|
+
err_msg: str,
|
|
310
|
+
*,
|
|
311
|
+
body: object,
|
|
312
|
+
response: httpx.Response,
|
|
313
|
+
) -> APIStatusError:
|
|
314
|
+
if response.status_code == 400:
|
|
315
|
+
return _exceptions.BadRequestError(err_msg, response=response, body=body)
|
|
316
|
+
|
|
317
|
+
if response.status_code == 401:
|
|
318
|
+
return _exceptions.AuthenticationError(err_msg, response=response, body=body)
|
|
319
|
+
|
|
320
|
+
if response.status_code == 403:
|
|
321
|
+
return _exceptions.PermissionDeniedError(err_msg, response=response, body=body)
|
|
322
|
+
|
|
323
|
+
if response.status_code == 404:
|
|
324
|
+
return _exceptions.NotFoundError(err_msg, response=response, body=body)
|
|
325
|
+
|
|
326
|
+
if response.status_code == 409:
|
|
327
|
+
return _exceptions.ConflictError(err_msg, response=response, body=body)
|
|
328
|
+
|
|
329
|
+
if response.status_code == 422:
|
|
330
|
+
return _exceptions.UnprocessableEntityError(err_msg, response=response, body=body)
|
|
331
|
+
|
|
332
|
+
if response.status_code == 429:
|
|
333
|
+
return _exceptions.RateLimitError(err_msg, response=response, body=body)
|
|
334
|
+
|
|
335
|
+
if response.status_code >= 500:
|
|
336
|
+
return _exceptions.InternalServerError(err_msg, response=response, body=body)
|
|
337
|
+
return APIStatusError(err_msg, response=response, body=body)
|
|
338
|
+
|
|
339
|
+
|
|
340
|
+
class AsyncWhop(AsyncAPIClient):
|
|
341
|
+
apps: apps.AsyncAppsResource
|
|
342
|
+
invoices: invoices.AsyncInvoicesResource
|
|
343
|
+
course_lesson_interactions: course_lesson_interactions.AsyncCourseLessonInteractionsResource
|
|
344
|
+
products: products.AsyncProductsResource
|
|
345
|
+
companies: companies.AsyncCompaniesResource
|
|
346
|
+
webhooks: webhooks.AsyncWebhooksResource
|
|
347
|
+
plans: plans.AsyncPlansResource
|
|
348
|
+
entries: entries.AsyncEntriesResource
|
|
349
|
+
forum_posts: forum_posts.AsyncForumPostsResource
|
|
350
|
+
transfers: transfers.AsyncTransfersResource
|
|
351
|
+
ledger_accounts: ledger_accounts.AsyncLedgerAccountsResource
|
|
352
|
+
memberships: memberships.AsyncMembershipsResource
|
|
353
|
+
authorized_users: authorized_users.AsyncAuthorizedUsersResource
|
|
354
|
+
app_builds: app_builds.AsyncAppBuildsResource
|
|
355
|
+
shipments: shipments.AsyncShipmentsResource
|
|
356
|
+
checkout_configurations: checkout_configurations.AsyncCheckoutConfigurationsResource
|
|
357
|
+
messages: messages.AsyncMessagesResource
|
|
358
|
+
chat_channels: chat_channels.AsyncChatChannelsResource
|
|
359
|
+
users: users.AsyncUsersResource
|
|
360
|
+
payments: payments.AsyncPaymentsResource
|
|
361
|
+
support_channels: support_channels.AsyncSupportChannelsResource
|
|
362
|
+
experiences: experiences.AsyncExperiencesResource
|
|
363
|
+
reactions: reactions.AsyncReactionsResource
|
|
364
|
+
members: members.AsyncMembersResource
|
|
365
|
+
forums: forums.AsyncForumsResource
|
|
366
|
+
promo_codes: promo_codes.AsyncPromoCodesResource
|
|
367
|
+
courses: courses.AsyncCoursesResource
|
|
368
|
+
course_chapters: course_chapters.AsyncCourseChaptersResource
|
|
369
|
+
course_lessons: course_lessons.AsyncCourseLessonsResource
|
|
370
|
+
reviews: reviews.AsyncReviewsResource
|
|
371
|
+
course_students: course_students.AsyncCourseStudentsResource
|
|
372
|
+
access_tokens: access_tokens.AsyncAccessTokensResource
|
|
373
|
+
notifications: notifications.AsyncNotificationsResource
|
|
374
|
+
disputes: disputes.AsyncDisputesResource
|
|
375
|
+
refunds: refunds.AsyncRefundsResource
|
|
376
|
+
withdrawals: withdrawals.AsyncWithdrawalsResource
|
|
377
|
+
account_links: account_links.AsyncAccountLinksResource
|
|
378
|
+
setup_intents: setup_intents.AsyncSetupIntentsResource
|
|
379
|
+
payment_tokens: payment_tokens.AsyncPaymentTokensResource
|
|
380
|
+
with_raw_response: AsyncWhopWithRawResponse
|
|
381
|
+
with_streaming_response: AsyncWhopWithStreamedResponse
|
|
382
|
+
|
|
383
|
+
# client options
|
|
384
|
+
api_key: str
|
|
385
|
+
webhook_key: str | None
|
|
386
|
+
app_id: str | None
|
|
387
|
+
|
|
388
|
+
def __init__(
|
|
389
|
+
self,
|
|
390
|
+
*,
|
|
391
|
+
api_key: str | None = None,
|
|
392
|
+
webhook_key: str | None = None,
|
|
393
|
+
app_id: str | None = None,
|
|
394
|
+
base_url: str | httpx.URL | None = None,
|
|
395
|
+
timeout: float | Timeout | None | NotGiven = not_given,
|
|
396
|
+
max_retries: int = DEFAULT_MAX_RETRIES,
|
|
397
|
+
default_headers: Mapping[str, str] | None = None,
|
|
398
|
+
default_query: Mapping[str, object] | None = None,
|
|
399
|
+
# Configure a custom httpx client.
|
|
400
|
+
# We provide a `DefaultAsyncHttpxClient` class that you can pass to retain the default values we use for `limits`, `timeout` & `follow_redirects`.
|
|
401
|
+
# See the [httpx documentation](https://www.python-httpx.org/api/#asyncclient) for more details.
|
|
402
|
+
http_client: httpx.AsyncClient | None = None,
|
|
403
|
+
# Enable or disable schema validation for data returned by the API.
|
|
404
|
+
# When enabled an error APIResponseValidationError is raised
|
|
405
|
+
# if the API responds with invalid data for the expected schema.
|
|
406
|
+
#
|
|
407
|
+
# This parameter may be removed or changed in the future.
|
|
408
|
+
# If you rely on this feature, please open a GitHub issue
|
|
409
|
+
# outlining your use-case to help us decide if it should be
|
|
410
|
+
# part of our public interface in the future.
|
|
411
|
+
_strict_response_validation: bool = False,
|
|
412
|
+
) -> None:
|
|
413
|
+
"""Construct a new async AsyncWhop client instance.
|
|
414
|
+
|
|
415
|
+
This automatically infers the following arguments from their corresponding environment variables if they are not provided:
|
|
416
|
+
- `api_key` from `WHOP_API_KEY`
|
|
417
|
+
- `webhook_key` from `WHOP_WEBHOOK_SECRET`
|
|
418
|
+
- `app_id` from `WHOP_APP_ID`
|
|
419
|
+
"""
|
|
420
|
+
if api_key is None:
|
|
421
|
+
api_key = os.environ.get("WHOP_API_KEY")
|
|
422
|
+
if api_key is None:
|
|
423
|
+
raise WhopError(
|
|
424
|
+
"The api_key client option must be set either by passing api_key to the client or by setting the WHOP_API_KEY environment variable"
|
|
425
|
+
)
|
|
426
|
+
self.api_key = api_key
|
|
427
|
+
|
|
428
|
+
if webhook_key is None:
|
|
429
|
+
webhook_key = os.environ.get("WHOP_WEBHOOK_SECRET")
|
|
430
|
+
self.webhook_key = webhook_key
|
|
431
|
+
|
|
432
|
+
if app_id is None:
|
|
433
|
+
app_id = os.environ.get("WHOP_APP_ID")
|
|
434
|
+
self.app_id = app_id
|
|
435
|
+
|
|
436
|
+
if base_url is None:
|
|
437
|
+
base_url = os.environ.get("WHOP_BASE_URL")
|
|
438
|
+
if base_url is None:
|
|
439
|
+
base_url = f"https://api.whop.com/api/v1"
|
|
440
|
+
|
|
441
|
+
super().__init__(
|
|
442
|
+
version=__version__,
|
|
443
|
+
base_url=base_url,
|
|
444
|
+
max_retries=max_retries,
|
|
445
|
+
timeout=timeout,
|
|
446
|
+
http_client=http_client,
|
|
447
|
+
custom_headers=default_headers,
|
|
448
|
+
custom_query=default_query,
|
|
449
|
+
_strict_response_validation=_strict_response_validation,
|
|
450
|
+
)
|
|
451
|
+
|
|
452
|
+
self.apps = apps.AsyncAppsResource(self)
|
|
453
|
+
self.invoices = invoices.AsyncInvoicesResource(self)
|
|
454
|
+
self.course_lesson_interactions = course_lesson_interactions.AsyncCourseLessonInteractionsResource(self)
|
|
455
|
+
self.products = products.AsyncProductsResource(self)
|
|
456
|
+
self.companies = companies.AsyncCompaniesResource(self)
|
|
457
|
+
self.webhooks = webhooks.AsyncWebhooksResource(self)
|
|
458
|
+
self.plans = plans.AsyncPlansResource(self)
|
|
459
|
+
self.entries = entries.AsyncEntriesResource(self)
|
|
460
|
+
self.forum_posts = forum_posts.AsyncForumPostsResource(self)
|
|
461
|
+
self.transfers = transfers.AsyncTransfersResource(self)
|
|
462
|
+
self.ledger_accounts = ledger_accounts.AsyncLedgerAccountsResource(self)
|
|
463
|
+
self.memberships = memberships.AsyncMembershipsResource(self)
|
|
464
|
+
self.authorized_users = authorized_users.AsyncAuthorizedUsersResource(self)
|
|
465
|
+
self.app_builds = app_builds.AsyncAppBuildsResource(self)
|
|
466
|
+
self.shipments = shipments.AsyncShipmentsResource(self)
|
|
467
|
+
self.checkout_configurations = checkout_configurations.AsyncCheckoutConfigurationsResource(self)
|
|
468
|
+
self.messages = messages.AsyncMessagesResource(self)
|
|
469
|
+
self.chat_channels = chat_channels.AsyncChatChannelsResource(self)
|
|
470
|
+
self.users = users.AsyncUsersResource(self)
|
|
471
|
+
self.payments = payments.AsyncPaymentsResource(self)
|
|
472
|
+
self.support_channels = support_channels.AsyncSupportChannelsResource(self)
|
|
473
|
+
self.experiences = experiences.AsyncExperiencesResource(self)
|
|
474
|
+
self.reactions = reactions.AsyncReactionsResource(self)
|
|
475
|
+
self.members = members.AsyncMembersResource(self)
|
|
476
|
+
self.forums = forums.AsyncForumsResource(self)
|
|
477
|
+
self.promo_codes = promo_codes.AsyncPromoCodesResource(self)
|
|
478
|
+
self.courses = courses.AsyncCoursesResource(self)
|
|
479
|
+
self.course_chapters = course_chapters.AsyncCourseChaptersResource(self)
|
|
480
|
+
self.course_lessons = course_lessons.AsyncCourseLessonsResource(self)
|
|
481
|
+
self.reviews = reviews.AsyncReviewsResource(self)
|
|
482
|
+
self.course_students = course_students.AsyncCourseStudentsResource(self)
|
|
483
|
+
self.access_tokens = access_tokens.AsyncAccessTokensResource(self)
|
|
484
|
+
self.notifications = notifications.AsyncNotificationsResource(self)
|
|
485
|
+
self.disputes = disputes.AsyncDisputesResource(self)
|
|
486
|
+
self.refunds = refunds.AsyncRefundsResource(self)
|
|
487
|
+
self.withdrawals = withdrawals.AsyncWithdrawalsResource(self)
|
|
488
|
+
self.account_links = account_links.AsyncAccountLinksResource(self)
|
|
489
|
+
self.setup_intents = setup_intents.AsyncSetupIntentsResource(self)
|
|
490
|
+
self.payment_tokens = payment_tokens.AsyncPaymentTokensResource(self)
|
|
491
|
+
self.with_raw_response = AsyncWhopWithRawResponse(self)
|
|
492
|
+
self.with_streaming_response = AsyncWhopWithStreamedResponse(self)
|
|
493
|
+
|
|
494
|
+
@property
|
|
495
|
+
@override
|
|
496
|
+
def qs(self) -> Querystring:
|
|
497
|
+
return Querystring(array_format="brackets")
|
|
498
|
+
|
|
499
|
+
@property
|
|
500
|
+
@override
|
|
501
|
+
def auth_headers(self) -> dict[str, str]:
|
|
502
|
+
api_key = self.api_key
|
|
503
|
+
return {"Authorization": f"Bearer {api_key}"}
|
|
504
|
+
|
|
505
|
+
@property
|
|
506
|
+
@override
|
|
507
|
+
def default_headers(self) -> dict[str, str | Omit]:
|
|
508
|
+
return {
|
|
509
|
+
**super().default_headers,
|
|
510
|
+
"X-Stainless-Async": f"async:{get_async_library()}",
|
|
511
|
+
"X-Whop-App-Id": self.app_id if self.app_id is not None else Omit(),
|
|
512
|
+
**self._custom_headers,
|
|
513
|
+
}
|
|
514
|
+
|
|
515
|
+
def copy(
|
|
516
|
+
self,
|
|
517
|
+
*,
|
|
518
|
+
api_key: str | None = None,
|
|
519
|
+
webhook_key: str | None = None,
|
|
520
|
+
app_id: str | None = None,
|
|
521
|
+
base_url: str | httpx.URL | None = None,
|
|
522
|
+
timeout: float | Timeout | None | NotGiven = not_given,
|
|
523
|
+
http_client: httpx.AsyncClient | None = None,
|
|
524
|
+
max_retries: int | NotGiven = not_given,
|
|
525
|
+
default_headers: Mapping[str, str] | None = None,
|
|
526
|
+
set_default_headers: Mapping[str, str] | None = None,
|
|
527
|
+
default_query: Mapping[str, object] | None = None,
|
|
528
|
+
set_default_query: Mapping[str, object] | None = None,
|
|
529
|
+
_extra_kwargs: Mapping[str, Any] = {},
|
|
530
|
+
) -> Self:
|
|
531
|
+
"""
|
|
532
|
+
Create a new client instance re-using the same options given to the current client with optional overriding.
|
|
533
|
+
"""
|
|
534
|
+
if default_headers is not None and set_default_headers is not None:
|
|
535
|
+
raise ValueError("The `default_headers` and `set_default_headers` arguments are mutually exclusive")
|
|
536
|
+
|
|
537
|
+
if default_query is not None and set_default_query is not None:
|
|
538
|
+
raise ValueError("The `default_query` and `set_default_query` arguments are mutually exclusive")
|
|
539
|
+
|
|
540
|
+
headers = self._custom_headers
|
|
541
|
+
if default_headers is not None:
|
|
542
|
+
headers = {**headers, **default_headers}
|
|
543
|
+
elif set_default_headers is not None:
|
|
544
|
+
headers = set_default_headers
|
|
545
|
+
|
|
546
|
+
params = self._custom_query
|
|
547
|
+
if default_query is not None:
|
|
548
|
+
params = {**params, **default_query}
|
|
549
|
+
elif set_default_query is not None:
|
|
550
|
+
params = set_default_query
|
|
551
|
+
|
|
552
|
+
http_client = http_client or self._client
|
|
553
|
+
return self.__class__(
|
|
554
|
+
api_key=api_key or self.api_key,
|
|
555
|
+
webhook_key=webhook_key or self.webhook_key,
|
|
556
|
+
app_id=app_id or self.app_id,
|
|
557
|
+
base_url=base_url or self.base_url,
|
|
558
|
+
timeout=self.timeout if isinstance(timeout, NotGiven) else timeout,
|
|
559
|
+
http_client=http_client,
|
|
560
|
+
max_retries=max_retries if is_given(max_retries) else self.max_retries,
|
|
561
|
+
default_headers=headers,
|
|
562
|
+
default_query=params,
|
|
563
|
+
**_extra_kwargs,
|
|
564
|
+
)
|
|
565
|
+
|
|
566
|
+
# Alias for `copy` for nicer inline usage, e.g.
|
|
567
|
+
# client.with_options(timeout=10).foo.create(...)
|
|
568
|
+
with_options = copy
|
|
569
|
+
|
|
570
|
+
@override
|
|
571
|
+
def _make_status_error(
|
|
572
|
+
self,
|
|
573
|
+
err_msg: str,
|
|
574
|
+
*,
|
|
575
|
+
body: object,
|
|
576
|
+
response: httpx.Response,
|
|
577
|
+
) -> APIStatusError:
|
|
578
|
+
if response.status_code == 400:
|
|
579
|
+
return _exceptions.BadRequestError(err_msg, response=response, body=body)
|
|
580
|
+
|
|
581
|
+
if response.status_code == 401:
|
|
582
|
+
return _exceptions.AuthenticationError(err_msg, response=response, body=body)
|
|
583
|
+
|
|
584
|
+
if response.status_code == 403:
|
|
585
|
+
return _exceptions.PermissionDeniedError(err_msg, response=response, body=body)
|
|
586
|
+
|
|
587
|
+
if response.status_code == 404:
|
|
588
|
+
return _exceptions.NotFoundError(err_msg, response=response, body=body)
|
|
589
|
+
|
|
590
|
+
if response.status_code == 409:
|
|
591
|
+
return _exceptions.ConflictError(err_msg, response=response, body=body)
|
|
592
|
+
|
|
593
|
+
if response.status_code == 422:
|
|
594
|
+
return _exceptions.UnprocessableEntityError(err_msg, response=response, body=body)
|
|
595
|
+
|
|
596
|
+
if response.status_code == 429:
|
|
597
|
+
return _exceptions.RateLimitError(err_msg, response=response, body=body)
|
|
598
|
+
|
|
599
|
+
if response.status_code >= 500:
|
|
600
|
+
return _exceptions.InternalServerError(err_msg, response=response, body=body)
|
|
601
|
+
return APIStatusError(err_msg, response=response, body=body)
|
|
602
|
+
|
|
603
|
+
|
|
604
|
+
class WhopWithRawResponse:
|
|
605
|
+
def __init__(self, client: Whop) -> None:
|
|
606
|
+
self.apps = apps.AppsResourceWithRawResponse(client.apps)
|
|
607
|
+
self.invoices = invoices.InvoicesResourceWithRawResponse(client.invoices)
|
|
608
|
+
self.course_lesson_interactions = course_lesson_interactions.CourseLessonInteractionsResourceWithRawResponse(
|
|
609
|
+
client.course_lesson_interactions
|
|
610
|
+
)
|
|
611
|
+
self.products = products.ProductsResourceWithRawResponse(client.products)
|
|
612
|
+
self.companies = companies.CompaniesResourceWithRawResponse(client.companies)
|
|
613
|
+
self.plans = plans.PlansResourceWithRawResponse(client.plans)
|
|
614
|
+
self.entries = entries.EntriesResourceWithRawResponse(client.entries)
|
|
615
|
+
self.forum_posts = forum_posts.ForumPostsResourceWithRawResponse(client.forum_posts)
|
|
616
|
+
self.transfers = transfers.TransfersResourceWithRawResponse(client.transfers)
|
|
617
|
+
self.ledger_accounts = ledger_accounts.LedgerAccountsResourceWithRawResponse(client.ledger_accounts)
|
|
618
|
+
self.memberships = memberships.MembershipsResourceWithRawResponse(client.memberships)
|
|
619
|
+
self.authorized_users = authorized_users.AuthorizedUsersResourceWithRawResponse(client.authorized_users)
|
|
620
|
+
self.app_builds = app_builds.AppBuildsResourceWithRawResponse(client.app_builds)
|
|
621
|
+
self.shipments = shipments.ShipmentsResourceWithRawResponse(client.shipments)
|
|
622
|
+
self.checkout_configurations = checkout_configurations.CheckoutConfigurationsResourceWithRawResponse(
|
|
623
|
+
client.checkout_configurations
|
|
624
|
+
)
|
|
625
|
+
self.messages = messages.MessagesResourceWithRawResponse(client.messages)
|
|
626
|
+
self.chat_channels = chat_channels.ChatChannelsResourceWithRawResponse(client.chat_channels)
|
|
627
|
+
self.users = users.UsersResourceWithRawResponse(client.users)
|
|
628
|
+
self.payments = payments.PaymentsResourceWithRawResponse(client.payments)
|
|
629
|
+
self.support_channels = support_channels.SupportChannelsResourceWithRawResponse(client.support_channels)
|
|
630
|
+
self.experiences = experiences.ExperiencesResourceWithRawResponse(client.experiences)
|
|
631
|
+
self.reactions = reactions.ReactionsResourceWithRawResponse(client.reactions)
|
|
632
|
+
self.members = members.MembersResourceWithRawResponse(client.members)
|
|
633
|
+
self.forums = forums.ForumsResourceWithRawResponse(client.forums)
|
|
634
|
+
self.promo_codes = promo_codes.PromoCodesResourceWithRawResponse(client.promo_codes)
|
|
635
|
+
self.courses = courses.CoursesResourceWithRawResponse(client.courses)
|
|
636
|
+
self.course_chapters = course_chapters.CourseChaptersResourceWithRawResponse(client.course_chapters)
|
|
637
|
+
self.course_lessons = course_lessons.CourseLessonsResourceWithRawResponse(client.course_lessons)
|
|
638
|
+
self.reviews = reviews.ReviewsResourceWithRawResponse(client.reviews)
|
|
639
|
+
self.course_students = course_students.CourseStudentsResourceWithRawResponse(client.course_students)
|
|
640
|
+
self.access_tokens = access_tokens.AccessTokensResourceWithRawResponse(client.access_tokens)
|
|
641
|
+
self.notifications = notifications.NotificationsResourceWithRawResponse(client.notifications)
|
|
642
|
+
self.disputes = disputes.DisputesResourceWithRawResponse(client.disputes)
|
|
643
|
+
self.refunds = refunds.RefundsResourceWithRawResponse(client.refunds)
|
|
644
|
+
self.withdrawals = withdrawals.WithdrawalsResourceWithRawResponse(client.withdrawals)
|
|
645
|
+
self.account_links = account_links.AccountLinksResourceWithRawResponse(client.account_links)
|
|
646
|
+
self.setup_intents = setup_intents.SetupIntentsResourceWithRawResponse(client.setup_intents)
|
|
647
|
+
self.payment_tokens = payment_tokens.PaymentTokensResourceWithRawResponse(client.payment_tokens)
|
|
648
|
+
|
|
649
|
+
|
|
650
|
+
class AsyncWhopWithRawResponse:
|
|
651
|
+
def __init__(self, client: AsyncWhop) -> None:
|
|
652
|
+
self.apps = apps.AsyncAppsResourceWithRawResponse(client.apps)
|
|
653
|
+
self.invoices = invoices.AsyncInvoicesResourceWithRawResponse(client.invoices)
|
|
654
|
+
self.course_lesson_interactions = (
|
|
655
|
+
course_lesson_interactions.AsyncCourseLessonInteractionsResourceWithRawResponse(
|
|
656
|
+
client.course_lesson_interactions
|
|
657
|
+
)
|
|
658
|
+
)
|
|
659
|
+
self.products = products.AsyncProductsResourceWithRawResponse(client.products)
|
|
660
|
+
self.companies = companies.AsyncCompaniesResourceWithRawResponse(client.companies)
|
|
661
|
+
self.plans = plans.AsyncPlansResourceWithRawResponse(client.plans)
|
|
662
|
+
self.entries = entries.AsyncEntriesResourceWithRawResponse(client.entries)
|
|
663
|
+
self.forum_posts = forum_posts.AsyncForumPostsResourceWithRawResponse(client.forum_posts)
|
|
664
|
+
self.transfers = transfers.AsyncTransfersResourceWithRawResponse(client.transfers)
|
|
665
|
+
self.ledger_accounts = ledger_accounts.AsyncLedgerAccountsResourceWithRawResponse(client.ledger_accounts)
|
|
666
|
+
self.memberships = memberships.AsyncMembershipsResourceWithRawResponse(client.memberships)
|
|
667
|
+
self.authorized_users = authorized_users.AsyncAuthorizedUsersResourceWithRawResponse(client.authorized_users)
|
|
668
|
+
self.app_builds = app_builds.AsyncAppBuildsResourceWithRawResponse(client.app_builds)
|
|
669
|
+
self.shipments = shipments.AsyncShipmentsResourceWithRawResponse(client.shipments)
|
|
670
|
+
self.checkout_configurations = checkout_configurations.AsyncCheckoutConfigurationsResourceWithRawResponse(
|
|
671
|
+
client.checkout_configurations
|
|
672
|
+
)
|
|
673
|
+
self.messages = messages.AsyncMessagesResourceWithRawResponse(client.messages)
|
|
674
|
+
self.chat_channels = chat_channels.AsyncChatChannelsResourceWithRawResponse(client.chat_channels)
|
|
675
|
+
self.users = users.AsyncUsersResourceWithRawResponse(client.users)
|
|
676
|
+
self.payments = payments.AsyncPaymentsResourceWithRawResponse(client.payments)
|
|
677
|
+
self.support_channels = support_channels.AsyncSupportChannelsResourceWithRawResponse(client.support_channels)
|
|
678
|
+
self.experiences = experiences.AsyncExperiencesResourceWithRawResponse(client.experiences)
|
|
679
|
+
self.reactions = reactions.AsyncReactionsResourceWithRawResponse(client.reactions)
|
|
680
|
+
self.members = members.AsyncMembersResourceWithRawResponse(client.members)
|
|
681
|
+
self.forums = forums.AsyncForumsResourceWithRawResponse(client.forums)
|
|
682
|
+
self.promo_codes = promo_codes.AsyncPromoCodesResourceWithRawResponse(client.promo_codes)
|
|
683
|
+
self.courses = courses.AsyncCoursesResourceWithRawResponse(client.courses)
|
|
684
|
+
self.course_chapters = course_chapters.AsyncCourseChaptersResourceWithRawResponse(client.course_chapters)
|
|
685
|
+
self.course_lessons = course_lessons.AsyncCourseLessonsResourceWithRawResponse(client.course_lessons)
|
|
686
|
+
self.reviews = reviews.AsyncReviewsResourceWithRawResponse(client.reviews)
|
|
687
|
+
self.course_students = course_students.AsyncCourseStudentsResourceWithRawResponse(client.course_students)
|
|
688
|
+
self.access_tokens = access_tokens.AsyncAccessTokensResourceWithRawResponse(client.access_tokens)
|
|
689
|
+
self.notifications = notifications.AsyncNotificationsResourceWithRawResponse(client.notifications)
|
|
690
|
+
self.disputes = disputes.AsyncDisputesResourceWithRawResponse(client.disputes)
|
|
691
|
+
self.refunds = refunds.AsyncRefundsResourceWithRawResponse(client.refunds)
|
|
692
|
+
self.withdrawals = withdrawals.AsyncWithdrawalsResourceWithRawResponse(client.withdrawals)
|
|
693
|
+
self.account_links = account_links.AsyncAccountLinksResourceWithRawResponse(client.account_links)
|
|
694
|
+
self.setup_intents = setup_intents.AsyncSetupIntentsResourceWithRawResponse(client.setup_intents)
|
|
695
|
+
self.payment_tokens = payment_tokens.AsyncPaymentTokensResourceWithRawResponse(client.payment_tokens)
|
|
696
|
+
|
|
697
|
+
|
|
698
|
+
class WhopWithStreamedResponse:
|
|
699
|
+
def __init__(self, client: Whop) -> None:
|
|
700
|
+
self.apps = apps.AppsResourceWithStreamingResponse(client.apps)
|
|
701
|
+
self.invoices = invoices.InvoicesResourceWithStreamingResponse(client.invoices)
|
|
702
|
+
self.course_lesson_interactions = (
|
|
703
|
+
course_lesson_interactions.CourseLessonInteractionsResourceWithStreamingResponse(
|
|
704
|
+
client.course_lesson_interactions
|
|
705
|
+
)
|
|
706
|
+
)
|
|
707
|
+
self.products = products.ProductsResourceWithStreamingResponse(client.products)
|
|
708
|
+
self.companies = companies.CompaniesResourceWithStreamingResponse(client.companies)
|
|
709
|
+
self.plans = plans.PlansResourceWithStreamingResponse(client.plans)
|
|
710
|
+
self.entries = entries.EntriesResourceWithStreamingResponse(client.entries)
|
|
711
|
+
self.forum_posts = forum_posts.ForumPostsResourceWithStreamingResponse(client.forum_posts)
|
|
712
|
+
self.transfers = transfers.TransfersResourceWithStreamingResponse(client.transfers)
|
|
713
|
+
self.ledger_accounts = ledger_accounts.LedgerAccountsResourceWithStreamingResponse(client.ledger_accounts)
|
|
714
|
+
self.memberships = memberships.MembershipsResourceWithStreamingResponse(client.memberships)
|
|
715
|
+
self.authorized_users = authorized_users.AuthorizedUsersResourceWithStreamingResponse(client.authorized_users)
|
|
716
|
+
self.app_builds = app_builds.AppBuildsResourceWithStreamingResponse(client.app_builds)
|
|
717
|
+
self.shipments = shipments.ShipmentsResourceWithStreamingResponse(client.shipments)
|
|
718
|
+
self.checkout_configurations = checkout_configurations.CheckoutConfigurationsResourceWithStreamingResponse(
|
|
719
|
+
client.checkout_configurations
|
|
720
|
+
)
|
|
721
|
+
self.messages = messages.MessagesResourceWithStreamingResponse(client.messages)
|
|
722
|
+
self.chat_channels = chat_channels.ChatChannelsResourceWithStreamingResponse(client.chat_channels)
|
|
723
|
+
self.users = users.UsersResourceWithStreamingResponse(client.users)
|
|
724
|
+
self.payments = payments.PaymentsResourceWithStreamingResponse(client.payments)
|
|
725
|
+
self.support_channels = support_channels.SupportChannelsResourceWithStreamingResponse(client.support_channels)
|
|
726
|
+
self.experiences = experiences.ExperiencesResourceWithStreamingResponse(client.experiences)
|
|
727
|
+
self.reactions = reactions.ReactionsResourceWithStreamingResponse(client.reactions)
|
|
728
|
+
self.members = members.MembersResourceWithStreamingResponse(client.members)
|
|
729
|
+
self.forums = forums.ForumsResourceWithStreamingResponse(client.forums)
|
|
730
|
+
self.promo_codes = promo_codes.PromoCodesResourceWithStreamingResponse(client.promo_codes)
|
|
731
|
+
self.courses = courses.CoursesResourceWithStreamingResponse(client.courses)
|
|
732
|
+
self.course_chapters = course_chapters.CourseChaptersResourceWithStreamingResponse(client.course_chapters)
|
|
733
|
+
self.course_lessons = course_lessons.CourseLessonsResourceWithStreamingResponse(client.course_lessons)
|
|
734
|
+
self.reviews = reviews.ReviewsResourceWithStreamingResponse(client.reviews)
|
|
735
|
+
self.course_students = course_students.CourseStudentsResourceWithStreamingResponse(client.course_students)
|
|
736
|
+
self.access_tokens = access_tokens.AccessTokensResourceWithStreamingResponse(client.access_tokens)
|
|
737
|
+
self.notifications = notifications.NotificationsResourceWithStreamingResponse(client.notifications)
|
|
738
|
+
self.disputes = disputes.DisputesResourceWithStreamingResponse(client.disputes)
|
|
739
|
+
self.refunds = refunds.RefundsResourceWithStreamingResponse(client.refunds)
|
|
740
|
+
self.withdrawals = withdrawals.WithdrawalsResourceWithStreamingResponse(client.withdrawals)
|
|
741
|
+
self.account_links = account_links.AccountLinksResourceWithStreamingResponse(client.account_links)
|
|
742
|
+
self.setup_intents = setup_intents.SetupIntentsResourceWithStreamingResponse(client.setup_intents)
|
|
743
|
+
self.payment_tokens = payment_tokens.PaymentTokensResourceWithStreamingResponse(client.payment_tokens)
|
|
744
|
+
|
|
745
|
+
|
|
746
|
+
class AsyncWhopWithStreamedResponse:
|
|
747
|
+
def __init__(self, client: AsyncWhop) -> None:
|
|
748
|
+
self.apps = apps.AsyncAppsResourceWithStreamingResponse(client.apps)
|
|
749
|
+
self.invoices = invoices.AsyncInvoicesResourceWithStreamingResponse(client.invoices)
|
|
750
|
+
self.course_lesson_interactions = (
|
|
751
|
+
course_lesson_interactions.AsyncCourseLessonInteractionsResourceWithStreamingResponse(
|
|
752
|
+
client.course_lesson_interactions
|
|
753
|
+
)
|
|
754
|
+
)
|
|
755
|
+
self.products = products.AsyncProductsResourceWithStreamingResponse(client.products)
|
|
756
|
+
self.companies = companies.AsyncCompaniesResourceWithStreamingResponse(client.companies)
|
|
757
|
+
self.plans = plans.AsyncPlansResourceWithStreamingResponse(client.plans)
|
|
758
|
+
self.entries = entries.AsyncEntriesResourceWithStreamingResponse(client.entries)
|
|
759
|
+
self.forum_posts = forum_posts.AsyncForumPostsResourceWithStreamingResponse(client.forum_posts)
|
|
760
|
+
self.transfers = transfers.AsyncTransfersResourceWithStreamingResponse(client.transfers)
|
|
761
|
+
self.ledger_accounts = ledger_accounts.AsyncLedgerAccountsResourceWithStreamingResponse(client.ledger_accounts)
|
|
762
|
+
self.memberships = memberships.AsyncMembershipsResourceWithStreamingResponse(client.memberships)
|
|
763
|
+
self.authorized_users = authorized_users.AsyncAuthorizedUsersResourceWithStreamingResponse(
|
|
764
|
+
client.authorized_users
|
|
765
|
+
)
|
|
766
|
+
self.app_builds = app_builds.AsyncAppBuildsResourceWithStreamingResponse(client.app_builds)
|
|
767
|
+
self.shipments = shipments.AsyncShipmentsResourceWithStreamingResponse(client.shipments)
|
|
768
|
+
self.checkout_configurations = checkout_configurations.AsyncCheckoutConfigurationsResourceWithStreamingResponse(
|
|
769
|
+
client.checkout_configurations
|
|
770
|
+
)
|
|
771
|
+
self.messages = messages.AsyncMessagesResourceWithStreamingResponse(client.messages)
|
|
772
|
+
self.chat_channels = chat_channels.AsyncChatChannelsResourceWithStreamingResponse(client.chat_channels)
|
|
773
|
+
self.users = users.AsyncUsersResourceWithStreamingResponse(client.users)
|
|
774
|
+
self.payments = payments.AsyncPaymentsResourceWithStreamingResponse(client.payments)
|
|
775
|
+
self.support_channels = support_channels.AsyncSupportChannelsResourceWithStreamingResponse(
|
|
776
|
+
client.support_channels
|
|
777
|
+
)
|
|
778
|
+
self.experiences = experiences.AsyncExperiencesResourceWithStreamingResponse(client.experiences)
|
|
779
|
+
self.reactions = reactions.AsyncReactionsResourceWithStreamingResponse(client.reactions)
|
|
780
|
+
self.members = members.AsyncMembersResourceWithStreamingResponse(client.members)
|
|
781
|
+
self.forums = forums.AsyncForumsResourceWithStreamingResponse(client.forums)
|
|
782
|
+
self.promo_codes = promo_codes.AsyncPromoCodesResourceWithStreamingResponse(client.promo_codes)
|
|
783
|
+
self.courses = courses.AsyncCoursesResourceWithStreamingResponse(client.courses)
|
|
784
|
+
self.course_chapters = course_chapters.AsyncCourseChaptersResourceWithStreamingResponse(client.course_chapters)
|
|
785
|
+
self.course_lessons = course_lessons.AsyncCourseLessonsResourceWithStreamingResponse(client.course_lessons)
|
|
786
|
+
self.reviews = reviews.AsyncReviewsResourceWithStreamingResponse(client.reviews)
|
|
787
|
+
self.course_students = course_students.AsyncCourseStudentsResourceWithStreamingResponse(client.course_students)
|
|
788
|
+
self.access_tokens = access_tokens.AsyncAccessTokensResourceWithStreamingResponse(client.access_tokens)
|
|
789
|
+
self.notifications = notifications.AsyncNotificationsResourceWithStreamingResponse(client.notifications)
|
|
790
|
+
self.disputes = disputes.AsyncDisputesResourceWithStreamingResponse(client.disputes)
|
|
791
|
+
self.refunds = refunds.AsyncRefundsResourceWithStreamingResponse(client.refunds)
|
|
792
|
+
self.withdrawals = withdrawals.AsyncWithdrawalsResourceWithStreamingResponse(client.withdrawals)
|
|
793
|
+
self.account_links = account_links.AsyncAccountLinksResourceWithStreamingResponse(client.account_links)
|
|
794
|
+
self.setup_intents = setup_intents.AsyncSetupIntentsResourceWithStreamingResponse(client.setup_intents)
|
|
795
|
+
self.payment_tokens = payment_tokens.AsyncPaymentTokensResourceWithStreamingResponse(client.payment_tokens)
|
|
796
|
+
|
|
797
|
+
|
|
798
|
+
Client = Whop
|
|
799
|
+
|
|
800
|
+
AsyncClient = AsyncWhop
|