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
|
@@ -0,0 +1,693 @@
|
|
|
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 Union, Optional
|
|
6
|
+
from datetime import datetime
|
|
7
|
+
|
|
8
|
+
import httpx
|
|
9
|
+
|
|
10
|
+
from ..types import dispute_list_params, dispute_update_evidence_params
|
|
11
|
+
from .._types import Body, Omit, Query, Headers, NotGiven, omit, not_given
|
|
12
|
+
from .._utils import maybe_transform, async_maybe_transform
|
|
13
|
+
from .._compat import cached_property
|
|
14
|
+
from .._resource import SyncAPIResource, AsyncAPIResource
|
|
15
|
+
from .._response import (
|
|
16
|
+
to_raw_response_wrapper,
|
|
17
|
+
to_streamed_response_wrapper,
|
|
18
|
+
async_to_raw_response_wrapper,
|
|
19
|
+
async_to_streamed_response_wrapper,
|
|
20
|
+
)
|
|
21
|
+
from ..pagination import SyncCursorPage, AsyncCursorPage
|
|
22
|
+
from .._base_client import AsyncPaginator, make_request_options
|
|
23
|
+
from ..types.dispute import Dispute
|
|
24
|
+
from ..types.shared.direction import Direction
|
|
25
|
+
from ..types.dispute_list_response import DisputeListResponse
|
|
26
|
+
|
|
27
|
+
__all__ = ["DisputesResource", "AsyncDisputesResource"]
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class DisputesResource(SyncAPIResource):
|
|
31
|
+
@cached_property
|
|
32
|
+
def with_raw_response(self) -> DisputesResourceWithRawResponse:
|
|
33
|
+
"""
|
|
34
|
+
This property can be used as a prefix for any HTTP method call to return
|
|
35
|
+
the raw response object instead of the parsed content.
|
|
36
|
+
|
|
37
|
+
For more information, see https://www.github.com/whopio/whopsdk-python#accessing-raw-response-data-eg-headers
|
|
38
|
+
"""
|
|
39
|
+
return DisputesResourceWithRawResponse(self)
|
|
40
|
+
|
|
41
|
+
@cached_property
|
|
42
|
+
def with_streaming_response(self) -> DisputesResourceWithStreamingResponse:
|
|
43
|
+
"""
|
|
44
|
+
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
45
|
+
|
|
46
|
+
For more information, see https://www.github.com/whopio/whopsdk-python#with_streaming_response
|
|
47
|
+
"""
|
|
48
|
+
return DisputesResourceWithStreamingResponse(self)
|
|
49
|
+
|
|
50
|
+
def retrieve(
|
|
51
|
+
self,
|
|
52
|
+
id: str,
|
|
53
|
+
*,
|
|
54
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
55
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
56
|
+
extra_headers: Headers | None = None,
|
|
57
|
+
extra_query: Query | None = None,
|
|
58
|
+
extra_body: Body | None = None,
|
|
59
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
60
|
+
) -> Dispute:
|
|
61
|
+
"""
|
|
62
|
+
Retrieves a Dispute by ID
|
|
63
|
+
|
|
64
|
+
Required permissions:
|
|
65
|
+
|
|
66
|
+
- `payment:dispute:read`
|
|
67
|
+
- `plan:basic:read`
|
|
68
|
+
- `access_pass:basic:read`
|
|
69
|
+
- `company:basic:read`
|
|
70
|
+
- `payment:basic:read`
|
|
71
|
+
- `member:email:read`
|
|
72
|
+
- `member:basic:read`
|
|
73
|
+
- `member:phone:read`
|
|
74
|
+
|
|
75
|
+
Args:
|
|
76
|
+
extra_headers: Send extra headers
|
|
77
|
+
|
|
78
|
+
extra_query: Add additional query parameters to the request
|
|
79
|
+
|
|
80
|
+
extra_body: Add additional JSON properties to the request
|
|
81
|
+
|
|
82
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
83
|
+
"""
|
|
84
|
+
if not id:
|
|
85
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
86
|
+
return self._get(
|
|
87
|
+
f"/disputes/{id}",
|
|
88
|
+
options=make_request_options(
|
|
89
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
90
|
+
),
|
|
91
|
+
cast_to=Dispute,
|
|
92
|
+
)
|
|
93
|
+
|
|
94
|
+
def list(
|
|
95
|
+
self,
|
|
96
|
+
*,
|
|
97
|
+
company_id: str,
|
|
98
|
+
after: Optional[str] | Omit = omit,
|
|
99
|
+
before: Optional[str] | Omit = omit,
|
|
100
|
+
created_after: Union[str, datetime, None] | Omit = omit,
|
|
101
|
+
created_before: Union[str, datetime, None] | Omit = omit,
|
|
102
|
+
direction: Optional[Direction] | Omit = omit,
|
|
103
|
+
first: Optional[int] | Omit = omit,
|
|
104
|
+
last: Optional[int] | Omit = omit,
|
|
105
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
106
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
107
|
+
extra_headers: Headers | None = None,
|
|
108
|
+
extra_query: Query | None = None,
|
|
109
|
+
extra_body: Body | None = None,
|
|
110
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
111
|
+
) -> SyncCursorPage[DisputeListResponse]:
|
|
112
|
+
"""
|
|
113
|
+
Lists disputes the current actor has access to
|
|
114
|
+
|
|
115
|
+
Required permissions:
|
|
116
|
+
|
|
117
|
+
- `payment:dispute:read`
|
|
118
|
+
- `plan:basic:read`
|
|
119
|
+
- `access_pass:basic:read`
|
|
120
|
+
- `company:basic:read`
|
|
121
|
+
- `payment:basic:read`
|
|
122
|
+
|
|
123
|
+
Args:
|
|
124
|
+
company_id: The ID of the company to list disputes for
|
|
125
|
+
|
|
126
|
+
after: Returns the elements in the list that come after the specified cursor.
|
|
127
|
+
|
|
128
|
+
before: Returns the elements in the list that come before the specified cursor.
|
|
129
|
+
|
|
130
|
+
created_after: The minimum creation date to filter by
|
|
131
|
+
|
|
132
|
+
created_before: The maximum creation date to filter by
|
|
133
|
+
|
|
134
|
+
direction: The direction of the sort.
|
|
135
|
+
|
|
136
|
+
first: Returns the first _n_ elements from the list.
|
|
137
|
+
|
|
138
|
+
last: Returns the last _n_ elements from the list.
|
|
139
|
+
|
|
140
|
+
extra_headers: Send extra headers
|
|
141
|
+
|
|
142
|
+
extra_query: Add additional query parameters to the request
|
|
143
|
+
|
|
144
|
+
extra_body: Add additional JSON properties to the request
|
|
145
|
+
|
|
146
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
147
|
+
"""
|
|
148
|
+
return self._get_api_list(
|
|
149
|
+
"/disputes",
|
|
150
|
+
page=SyncCursorPage[DisputeListResponse],
|
|
151
|
+
options=make_request_options(
|
|
152
|
+
extra_headers=extra_headers,
|
|
153
|
+
extra_query=extra_query,
|
|
154
|
+
extra_body=extra_body,
|
|
155
|
+
timeout=timeout,
|
|
156
|
+
query=maybe_transform(
|
|
157
|
+
{
|
|
158
|
+
"company_id": company_id,
|
|
159
|
+
"after": after,
|
|
160
|
+
"before": before,
|
|
161
|
+
"created_after": created_after,
|
|
162
|
+
"created_before": created_before,
|
|
163
|
+
"direction": direction,
|
|
164
|
+
"first": first,
|
|
165
|
+
"last": last,
|
|
166
|
+
},
|
|
167
|
+
dispute_list_params.DisputeListParams,
|
|
168
|
+
),
|
|
169
|
+
),
|
|
170
|
+
model=DisputeListResponse,
|
|
171
|
+
)
|
|
172
|
+
|
|
173
|
+
def submit_evidence(
|
|
174
|
+
self,
|
|
175
|
+
id: str,
|
|
176
|
+
*,
|
|
177
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
178
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
179
|
+
extra_headers: Headers | None = None,
|
|
180
|
+
extra_query: Query | None = None,
|
|
181
|
+
extra_body: Body | None = None,
|
|
182
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
183
|
+
) -> Dispute:
|
|
184
|
+
"""Submit a payment dispute to the payment processor for review.
|
|
185
|
+
|
|
186
|
+
Once submitted, no
|
|
187
|
+
further edits can be made.
|
|
188
|
+
|
|
189
|
+
Required permissions:
|
|
190
|
+
|
|
191
|
+
- `payment:dispute`
|
|
192
|
+
- `plan:basic:read`
|
|
193
|
+
- `access_pass:basic:read`
|
|
194
|
+
- `company:basic:read`
|
|
195
|
+
- `payment:basic:read`
|
|
196
|
+
- `member:email:read`
|
|
197
|
+
- `member:basic:read`
|
|
198
|
+
- `member:phone:read`
|
|
199
|
+
|
|
200
|
+
Args:
|
|
201
|
+
extra_headers: Send extra headers
|
|
202
|
+
|
|
203
|
+
extra_query: Add additional query parameters to the request
|
|
204
|
+
|
|
205
|
+
extra_body: Add additional JSON properties to the request
|
|
206
|
+
|
|
207
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
208
|
+
"""
|
|
209
|
+
if not id:
|
|
210
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
211
|
+
return self._post(
|
|
212
|
+
f"/disputes/{id}/submit_evidence",
|
|
213
|
+
options=make_request_options(
|
|
214
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
215
|
+
),
|
|
216
|
+
cast_to=Dispute,
|
|
217
|
+
)
|
|
218
|
+
|
|
219
|
+
def update_evidence(
|
|
220
|
+
self,
|
|
221
|
+
id: str,
|
|
222
|
+
*,
|
|
223
|
+
access_activity_log: Optional[str] | Omit = omit,
|
|
224
|
+
billing_address: Optional[str] | Omit = omit,
|
|
225
|
+
cancellation_policy_attachment: Optional[dispute_update_evidence_params.CancellationPolicyAttachment]
|
|
226
|
+
| Omit = omit,
|
|
227
|
+
cancellation_policy_disclosure: Optional[str] | Omit = omit,
|
|
228
|
+
customer_communication_attachment: Optional[dispute_update_evidence_params.CustomerCommunicationAttachment]
|
|
229
|
+
| Omit = omit,
|
|
230
|
+
customer_email_address: Optional[str] | Omit = omit,
|
|
231
|
+
customer_name: Optional[str] | Omit = omit,
|
|
232
|
+
notes: Optional[str] | Omit = omit,
|
|
233
|
+
product_description: Optional[str] | Omit = omit,
|
|
234
|
+
refund_policy_attachment: Optional[dispute_update_evidence_params.RefundPolicyAttachment] | Omit = omit,
|
|
235
|
+
refund_policy_disclosure: Optional[str] | Omit = omit,
|
|
236
|
+
refund_refusal_explanation: Optional[str] | Omit = omit,
|
|
237
|
+
service_date: Optional[str] | Omit = omit,
|
|
238
|
+
uncategorized_attachment: Optional[dispute_update_evidence_params.UncategorizedAttachment] | Omit = omit,
|
|
239
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
240
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
241
|
+
extra_headers: Headers | None = None,
|
|
242
|
+
extra_query: Query | None = None,
|
|
243
|
+
extra_body: Body | None = None,
|
|
244
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
245
|
+
) -> Dispute:
|
|
246
|
+
"""
|
|
247
|
+
Update a dispute with evidence data to attempt to win the dispute.
|
|
248
|
+
|
|
249
|
+
Required permissions:
|
|
250
|
+
|
|
251
|
+
- `payment:dispute`
|
|
252
|
+
- `plan:basic:read`
|
|
253
|
+
- `access_pass:basic:read`
|
|
254
|
+
- `company:basic:read`
|
|
255
|
+
- `payment:basic:read`
|
|
256
|
+
- `member:email:read`
|
|
257
|
+
- `member:basic:read`
|
|
258
|
+
- `member:phone:read`
|
|
259
|
+
|
|
260
|
+
Args:
|
|
261
|
+
access_activity_log: An IP access log for the user from Whop.
|
|
262
|
+
|
|
263
|
+
billing_address: The billing address of the user from their payment details.
|
|
264
|
+
|
|
265
|
+
cancellation_policy_attachment: A file containing the cancellation policy from the company.
|
|
266
|
+
|
|
267
|
+
cancellation_policy_disclosure: A cancellation policy disclosure from the company.
|
|
268
|
+
|
|
269
|
+
customer_communication_attachment: A file containing the customer communication from the company (An image).
|
|
270
|
+
|
|
271
|
+
customer_email_address: The email of the customer from their payment details.
|
|
272
|
+
|
|
273
|
+
customer_name: The name of the customer from their payment details.
|
|
274
|
+
|
|
275
|
+
notes: Additional notes the company chooses to submit regarding the dispute.
|
|
276
|
+
|
|
277
|
+
product_description: The description of the product from the company.
|
|
278
|
+
|
|
279
|
+
refund_policy_attachment: A file containing the refund policy from the company.
|
|
280
|
+
|
|
281
|
+
refund_policy_disclosure: A refund policy disclosure from the company.
|
|
282
|
+
|
|
283
|
+
refund_refusal_explanation: A description on why the refund is being refused by the company.
|
|
284
|
+
|
|
285
|
+
service_date: When the product was delivered by the company.
|
|
286
|
+
|
|
287
|
+
uncategorized_attachment: A file that does not fit in the other categories.
|
|
288
|
+
|
|
289
|
+
extra_headers: Send extra headers
|
|
290
|
+
|
|
291
|
+
extra_query: Add additional query parameters to the request
|
|
292
|
+
|
|
293
|
+
extra_body: Add additional JSON properties to the request
|
|
294
|
+
|
|
295
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
296
|
+
"""
|
|
297
|
+
if not id:
|
|
298
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
299
|
+
return self._post(
|
|
300
|
+
f"/disputes/{id}/update_evidence",
|
|
301
|
+
body=maybe_transform(
|
|
302
|
+
{
|
|
303
|
+
"access_activity_log": access_activity_log,
|
|
304
|
+
"billing_address": billing_address,
|
|
305
|
+
"cancellation_policy_attachment": cancellation_policy_attachment,
|
|
306
|
+
"cancellation_policy_disclosure": cancellation_policy_disclosure,
|
|
307
|
+
"customer_communication_attachment": customer_communication_attachment,
|
|
308
|
+
"customer_email_address": customer_email_address,
|
|
309
|
+
"customer_name": customer_name,
|
|
310
|
+
"notes": notes,
|
|
311
|
+
"product_description": product_description,
|
|
312
|
+
"refund_policy_attachment": refund_policy_attachment,
|
|
313
|
+
"refund_policy_disclosure": refund_policy_disclosure,
|
|
314
|
+
"refund_refusal_explanation": refund_refusal_explanation,
|
|
315
|
+
"service_date": service_date,
|
|
316
|
+
"uncategorized_attachment": uncategorized_attachment,
|
|
317
|
+
},
|
|
318
|
+
dispute_update_evidence_params.DisputeUpdateEvidenceParams,
|
|
319
|
+
),
|
|
320
|
+
options=make_request_options(
|
|
321
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
322
|
+
),
|
|
323
|
+
cast_to=Dispute,
|
|
324
|
+
)
|
|
325
|
+
|
|
326
|
+
|
|
327
|
+
class AsyncDisputesResource(AsyncAPIResource):
|
|
328
|
+
@cached_property
|
|
329
|
+
def with_raw_response(self) -> AsyncDisputesResourceWithRawResponse:
|
|
330
|
+
"""
|
|
331
|
+
This property can be used as a prefix for any HTTP method call to return
|
|
332
|
+
the raw response object instead of the parsed content.
|
|
333
|
+
|
|
334
|
+
For more information, see https://www.github.com/whopio/whopsdk-python#accessing-raw-response-data-eg-headers
|
|
335
|
+
"""
|
|
336
|
+
return AsyncDisputesResourceWithRawResponse(self)
|
|
337
|
+
|
|
338
|
+
@cached_property
|
|
339
|
+
def with_streaming_response(self) -> AsyncDisputesResourceWithStreamingResponse:
|
|
340
|
+
"""
|
|
341
|
+
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
342
|
+
|
|
343
|
+
For more information, see https://www.github.com/whopio/whopsdk-python#with_streaming_response
|
|
344
|
+
"""
|
|
345
|
+
return AsyncDisputesResourceWithStreamingResponse(self)
|
|
346
|
+
|
|
347
|
+
async def retrieve(
|
|
348
|
+
self,
|
|
349
|
+
id: str,
|
|
350
|
+
*,
|
|
351
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
352
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
353
|
+
extra_headers: Headers | None = None,
|
|
354
|
+
extra_query: Query | None = None,
|
|
355
|
+
extra_body: Body | None = None,
|
|
356
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
357
|
+
) -> Dispute:
|
|
358
|
+
"""
|
|
359
|
+
Retrieves a Dispute by ID
|
|
360
|
+
|
|
361
|
+
Required permissions:
|
|
362
|
+
|
|
363
|
+
- `payment:dispute:read`
|
|
364
|
+
- `plan:basic:read`
|
|
365
|
+
- `access_pass:basic:read`
|
|
366
|
+
- `company:basic:read`
|
|
367
|
+
- `payment:basic:read`
|
|
368
|
+
- `member:email:read`
|
|
369
|
+
- `member:basic:read`
|
|
370
|
+
- `member:phone:read`
|
|
371
|
+
|
|
372
|
+
Args:
|
|
373
|
+
extra_headers: Send extra headers
|
|
374
|
+
|
|
375
|
+
extra_query: Add additional query parameters to the request
|
|
376
|
+
|
|
377
|
+
extra_body: Add additional JSON properties to the request
|
|
378
|
+
|
|
379
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
380
|
+
"""
|
|
381
|
+
if not id:
|
|
382
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
383
|
+
return await self._get(
|
|
384
|
+
f"/disputes/{id}",
|
|
385
|
+
options=make_request_options(
|
|
386
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
387
|
+
),
|
|
388
|
+
cast_to=Dispute,
|
|
389
|
+
)
|
|
390
|
+
|
|
391
|
+
def list(
|
|
392
|
+
self,
|
|
393
|
+
*,
|
|
394
|
+
company_id: str,
|
|
395
|
+
after: Optional[str] | Omit = omit,
|
|
396
|
+
before: Optional[str] | Omit = omit,
|
|
397
|
+
created_after: Union[str, datetime, None] | Omit = omit,
|
|
398
|
+
created_before: Union[str, datetime, None] | Omit = omit,
|
|
399
|
+
direction: Optional[Direction] | Omit = omit,
|
|
400
|
+
first: Optional[int] | Omit = omit,
|
|
401
|
+
last: Optional[int] | Omit = omit,
|
|
402
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
403
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
404
|
+
extra_headers: Headers | None = None,
|
|
405
|
+
extra_query: Query | None = None,
|
|
406
|
+
extra_body: Body | None = None,
|
|
407
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
408
|
+
) -> AsyncPaginator[DisputeListResponse, AsyncCursorPage[DisputeListResponse]]:
|
|
409
|
+
"""
|
|
410
|
+
Lists disputes the current actor has access to
|
|
411
|
+
|
|
412
|
+
Required permissions:
|
|
413
|
+
|
|
414
|
+
- `payment:dispute:read`
|
|
415
|
+
- `plan:basic:read`
|
|
416
|
+
- `access_pass:basic:read`
|
|
417
|
+
- `company:basic:read`
|
|
418
|
+
- `payment:basic:read`
|
|
419
|
+
|
|
420
|
+
Args:
|
|
421
|
+
company_id: The ID of the company to list disputes for
|
|
422
|
+
|
|
423
|
+
after: Returns the elements in the list that come after the specified cursor.
|
|
424
|
+
|
|
425
|
+
before: Returns the elements in the list that come before the specified cursor.
|
|
426
|
+
|
|
427
|
+
created_after: The minimum creation date to filter by
|
|
428
|
+
|
|
429
|
+
created_before: The maximum creation date to filter by
|
|
430
|
+
|
|
431
|
+
direction: The direction of the sort.
|
|
432
|
+
|
|
433
|
+
first: Returns the first _n_ elements from the list.
|
|
434
|
+
|
|
435
|
+
last: Returns the last _n_ elements from the list.
|
|
436
|
+
|
|
437
|
+
extra_headers: Send extra headers
|
|
438
|
+
|
|
439
|
+
extra_query: Add additional query parameters to the request
|
|
440
|
+
|
|
441
|
+
extra_body: Add additional JSON properties to the request
|
|
442
|
+
|
|
443
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
444
|
+
"""
|
|
445
|
+
return self._get_api_list(
|
|
446
|
+
"/disputes",
|
|
447
|
+
page=AsyncCursorPage[DisputeListResponse],
|
|
448
|
+
options=make_request_options(
|
|
449
|
+
extra_headers=extra_headers,
|
|
450
|
+
extra_query=extra_query,
|
|
451
|
+
extra_body=extra_body,
|
|
452
|
+
timeout=timeout,
|
|
453
|
+
query=maybe_transform(
|
|
454
|
+
{
|
|
455
|
+
"company_id": company_id,
|
|
456
|
+
"after": after,
|
|
457
|
+
"before": before,
|
|
458
|
+
"created_after": created_after,
|
|
459
|
+
"created_before": created_before,
|
|
460
|
+
"direction": direction,
|
|
461
|
+
"first": first,
|
|
462
|
+
"last": last,
|
|
463
|
+
},
|
|
464
|
+
dispute_list_params.DisputeListParams,
|
|
465
|
+
),
|
|
466
|
+
),
|
|
467
|
+
model=DisputeListResponse,
|
|
468
|
+
)
|
|
469
|
+
|
|
470
|
+
async def submit_evidence(
|
|
471
|
+
self,
|
|
472
|
+
id: str,
|
|
473
|
+
*,
|
|
474
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
475
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
476
|
+
extra_headers: Headers | None = None,
|
|
477
|
+
extra_query: Query | None = None,
|
|
478
|
+
extra_body: Body | None = None,
|
|
479
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
480
|
+
) -> Dispute:
|
|
481
|
+
"""Submit a payment dispute to the payment processor for review.
|
|
482
|
+
|
|
483
|
+
Once submitted, no
|
|
484
|
+
further edits can be made.
|
|
485
|
+
|
|
486
|
+
Required permissions:
|
|
487
|
+
|
|
488
|
+
- `payment:dispute`
|
|
489
|
+
- `plan:basic:read`
|
|
490
|
+
- `access_pass:basic:read`
|
|
491
|
+
- `company:basic:read`
|
|
492
|
+
- `payment:basic:read`
|
|
493
|
+
- `member:email:read`
|
|
494
|
+
- `member:basic:read`
|
|
495
|
+
- `member:phone:read`
|
|
496
|
+
|
|
497
|
+
Args:
|
|
498
|
+
extra_headers: Send extra headers
|
|
499
|
+
|
|
500
|
+
extra_query: Add additional query parameters to the request
|
|
501
|
+
|
|
502
|
+
extra_body: Add additional JSON properties to the request
|
|
503
|
+
|
|
504
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
505
|
+
"""
|
|
506
|
+
if not id:
|
|
507
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
508
|
+
return await self._post(
|
|
509
|
+
f"/disputes/{id}/submit_evidence",
|
|
510
|
+
options=make_request_options(
|
|
511
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
512
|
+
),
|
|
513
|
+
cast_to=Dispute,
|
|
514
|
+
)
|
|
515
|
+
|
|
516
|
+
async def update_evidence(
|
|
517
|
+
self,
|
|
518
|
+
id: str,
|
|
519
|
+
*,
|
|
520
|
+
access_activity_log: Optional[str] | Omit = omit,
|
|
521
|
+
billing_address: Optional[str] | Omit = omit,
|
|
522
|
+
cancellation_policy_attachment: Optional[dispute_update_evidence_params.CancellationPolicyAttachment]
|
|
523
|
+
| Omit = omit,
|
|
524
|
+
cancellation_policy_disclosure: Optional[str] | Omit = omit,
|
|
525
|
+
customer_communication_attachment: Optional[dispute_update_evidence_params.CustomerCommunicationAttachment]
|
|
526
|
+
| Omit = omit,
|
|
527
|
+
customer_email_address: Optional[str] | Omit = omit,
|
|
528
|
+
customer_name: Optional[str] | Omit = omit,
|
|
529
|
+
notes: Optional[str] | Omit = omit,
|
|
530
|
+
product_description: Optional[str] | Omit = omit,
|
|
531
|
+
refund_policy_attachment: Optional[dispute_update_evidence_params.RefundPolicyAttachment] | Omit = omit,
|
|
532
|
+
refund_policy_disclosure: Optional[str] | Omit = omit,
|
|
533
|
+
refund_refusal_explanation: Optional[str] | Omit = omit,
|
|
534
|
+
service_date: Optional[str] | Omit = omit,
|
|
535
|
+
uncategorized_attachment: Optional[dispute_update_evidence_params.UncategorizedAttachment] | Omit = omit,
|
|
536
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
537
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
538
|
+
extra_headers: Headers | None = None,
|
|
539
|
+
extra_query: Query | None = None,
|
|
540
|
+
extra_body: Body | None = None,
|
|
541
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
542
|
+
) -> Dispute:
|
|
543
|
+
"""
|
|
544
|
+
Update a dispute with evidence data to attempt to win the dispute.
|
|
545
|
+
|
|
546
|
+
Required permissions:
|
|
547
|
+
|
|
548
|
+
- `payment:dispute`
|
|
549
|
+
- `plan:basic:read`
|
|
550
|
+
- `access_pass:basic:read`
|
|
551
|
+
- `company:basic:read`
|
|
552
|
+
- `payment:basic:read`
|
|
553
|
+
- `member:email:read`
|
|
554
|
+
- `member:basic:read`
|
|
555
|
+
- `member:phone:read`
|
|
556
|
+
|
|
557
|
+
Args:
|
|
558
|
+
access_activity_log: An IP access log for the user from Whop.
|
|
559
|
+
|
|
560
|
+
billing_address: The billing address of the user from their payment details.
|
|
561
|
+
|
|
562
|
+
cancellation_policy_attachment: A file containing the cancellation policy from the company.
|
|
563
|
+
|
|
564
|
+
cancellation_policy_disclosure: A cancellation policy disclosure from the company.
|
|
565
|
+
|
|
566
|
+
customer_communication_attachment: A file containing the customer communication from the company (An image).
|
|
567
|
+
|
|
568
|
+
customer_email_address: The email of the customer from their payment details.
|
|
569
|
+
|
|
570
|
+
customer_name: The name of the customer from their payment details.
|
|
571
|
+
|
|
572
|
+
notes: Additional notes the company chooses to submit regarding the dispute.
|
|
573
|
+
|
|
574
|
+
product_description: The description of the product from the company.
|
|
575
|
+
|
|
576
|
+
refund_policy_attachment: A file containing the refund policy from the company.
|
|
577
|
+
|
|
578
|
+
refund_policy_disclosure: A refund policy disclosure from the company.
|
|
579
|
+
|
|
580
|
+
refund_refusal_explanation: A description on why the refund is being refused by the company.
|
|
581
|
+
|
|
582
|
+
service_date: When the product was delivered by the company.
|
|
583
|
+
|
|
584
|
+
uncategorized_attachment: A file that does not fit in the other categories.
|
|
585
|
+
|
|
586
|
+
extra_headers: Send extra headers
|
|
587
|
+
|
|
588
|
+
extra_query: Add additional query parameters to the request
|
|
589
|
+
|
|
590
|
+
extra_body: Add additional JSON properties to the request
|
|
591
|
+
|
|
592
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
593
|
+
"""
|
|
594
|
+
if not id:
|
|
595
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
596
|
+
return await self._post(
|
|
597
|
+
f"/disputes/{id}/update_evidence",
|
|
598
|
+
body=await async_maybe_transform(
|
|
599
|
+
{
|
|
600
|
+
"access_activity_log": access_activity_log,
|
|
601
|
+
"billing_address": billing_address,
|
|
602
|
+
"cancellation_policy_attachment": cancellation_policy_attachment,
|
|
603
|
+
"cancellation_policy_disclosure": cancellation_policy_disclosure,
|
|
604
|
+
"customer_communication_attachment": customer_communication_attachment,
|
|
605
|
+
"customer_email_address": customer_email_address,
|
|
606
|
+
"customer_name": customer_name,
|
|
607
|
+
"notes": notes,
|
|
608
|
+
"product_description": product_description,
|
|
609
|
+
"refund_policy_attachment": refund_policy_attachment,
|
|
610
|
+
"refund_policy_disclosure": refund_policy_disclosure,
|
|
611
|
+
"refund_refusal_explanation": refund_refusal_explanation,
|
|
612
|
+
"service_date": service_date,
|
|
613
|
+
"uncategorized_attachment": uncategorized_attachment,
|
|
614
|
+
},
|
|
615
|
+
dispute_update_evidence_params.DisputeUpdateEvidenceParams,
|
|
616
|
+
),
|
|
617
|
+
options=make_request_options(
|
|
618
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
619
|
+
),
|
|
620
|
+
cast_to=Dispute,
|
|
621
|
+
)
|
|
622
|
+
|
|
623
|
+
|
|
624
|
+
class DisputesResourceWithRawResponse:
|
|
625
|
+
def __init__(self, disputes: DisputesResource) -> None:
|
|
626
|
+
self._disputes = disputes
|
|
627
|
+
|
|
628
|
+
self.retrieve = to_raw_response_wrapper(
|
|
629
|
+
disputes.retrieve,
|
|
630
|
+
)
|
|
631
|
+
self.list = to_raw_response_wrapper(
|
|
632
|
+
disputes.list,
|
|
633
|
+
)
|
|
634
|
+
self.submit_evidence = to_raw_response_wrapper(
|
|
635
|
+
disputes.submit_evidence,
|
|
636
|
+
)
|
|
637
|
+
self.update_evidence = to_raw_response_wrapper(
|
|
638
|
+
disputes.update_evidence,
|
|
639
|
+
)
|
|
640
|
+
|
|
641
|
+
|
|
642
|
+
class AsyncDisputesResourceWithRawResponse:
|
|
643
|
+
def __init__(self, disputes: AsyncDisputesResource) -> None:
|
|
644
|
+
self._disputes = disputes
|
|
645
|
+
|
|
646
|
+
self.retrieve = async_to_raw_response_wrapper(
|
|
647
|
+
disputes.retrieve,
|
|
648
|
+
)
|
|
649
|
+
self.list = async_to_raw_response_wrapper(
|
|
650
|
+
disputes.list,
|
|
651
|
+
)
|
|
652
|
+
self.submit_evidence = async_to_raw_response_wrapper(
|
|
653
|
+
disputes.submit_evidence,
|
|
654
|
+
)
|
|
655
|
+
self.update_evidence = async_to_raw_response_wrapper(
|
|
656
|
+
disputes.update_evidence,
|
|
657
|
+
)
|
|
658
|
+
|
|
659
|
+
|
|
660
|
+
class DisputesResourceWithStreamingResponse:
|
|
661
|
+
def __init__(self, disputes: DisputesResource) -> None:
|
|
662
|
+
self._disputes = disputes
|
|
663
|
+
|
|
664
|
+
self.retrieve = to_streamed_response_wrapper(
|
|
665
|
+
disputes.retrieve,
|
|
666
|
+
)
|
|
667
|
+
self.list = to_streamed_response_wrapper(
|
|
668
|
+
disputes.list,
|
|
669
|
+
)
|
|
670
|
+
self.submit_evidence = to_streamed_response_wrapper(
|
|
671
|
+
disputes.submit_evidence,
|
|
672
|
+
)
|
|
673
|
+
self.update_evidence = to_streamed_response_wrapper(
|
|
674
|
+
disputes.update_evidence,
|
|
675
|
+
)
|
|
676
|
+
|
|
677
|
+
|
|
678
|
+
class AsyncDisputesResourceWithStreamingResponse:
|
|
679
|
+
def __init__(self, disputes: AsyncDisputesResource) -> None:
|
|
680
|
+
self._disputes = disputes
|
|
681
|
+
|
|
682
|
+
self.retrieve = async_to_streamed_response_wrapper(
|
|
683
|
+
disputes.retrieve,
|
|
684
|
+
)
|
|
685
|
+
self.list = async_to_streamed_response_wrapper(
|
|
686
|
+
disputes.list,
|
|
687
|
+
)
|
|
688
|
+
self.submit_evidence = async_to_streamed_response_wrapper(
|
|
689
|
+
disputes.submit_evidence,
|
|
690
|
+
)
|
|
691
|
+
self.update_evidence = async_to_streamed_response_wrapper(
|
|
692
|
+
disputes.update_evidence,
|
|
693
|
+
)
|