whop_sdk 0.0.3 → 0.0.5
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +47 -0
- data/README.md +1 -1
- data/lib/whop_sdk/client.rb +8 -0
- data/lib/whop_sdk/internal/transport/base_client.rb +7 -1
- data/lib/whop_sdk/internal/transport/pooled_net_requester.rb +6 -2
- data/lib/whop_sdk/models/access_level.rb +1 -1
- data/lib/whop_sdk/models/access_pass_type.rb +2 -1
- data/lib/whop_sdk/models/access_token_create_params.rb +67 -0
- data/lib/whop_sdk/models/access_token_create_response.rb +27 -0
- data/lib/whop_sdk/models/app_build_create_params.rb +53 -29
- data/lib/whop_sdk/models/app_update_params.rb +53 -29
- data/lib/whop_sdk/models/checkout_configuration_create_params.rb +119 -43
- data/lib/whop_sdk/models/company.rb +13 -1
- data/lib/whop_sdk/models/company_create_params.rb +46 -0
- data/lib/whop_sdk/models/company_list_params.rb +62 -0
- data/lib/whop_sdk/models/company_list_response.rb +175 -0
- data/lib/whop_sdk/models/course.rb +18 -1
- data/lib/whop_sdk/models/course_create_params.rb +94 -30
- data/lib/whop_sdk/models/course_lesson_create_params.rb +77 -1
- data/lib/whop_sdk/models/course_lesson_list_response.rb +43 -1
- data/lib/whop_sdk/models/course_lesson_update_params.rb +280 -83
- data/lib/whop_sdk/models/course_list_response.rb +18 -1
- data/lib/whop_sdk/models/course_student_list_params.rb +62 -0
- data/lib/whop_sdk/models/course_student_list_response.rb +97 -0
- data/lib/whop_sdk/models/course_student_retrieve_params.rb +14 -0
- data/lib/whop_sdk/models/course_student_retrieve_response.rb +149 -0
- data/lib/whop_sdk/models/course_update_params.rb +70 -28
- data/lib/whop_sdk/models/course_visibilities.rb +17 -0
- data/lib/whop_sdk/models/embed_type.rb +16 -0
- data/lib/whop_sdk/models/entry.rb +3 -3
- data/lib/whop_sdk/models/entry_list_response.rb +3 -3
- data/lib/whop_sdk/models/experience.rb +5 -6
- data/lib/whop_sdk/models/experience_update_params.rb +53 -29
- data/lib/whop_sdk/models/forum_post.rb +2 -2
- data/lib/whop_sdk/models/forum_post_create_params.rb +51 -27
- data/lib/whop_sdk/models/forum_post_list_response.rb +2 -2
- data/lib/whop_sdk/models/forum_post_update_params.rb +51 -27
- data/lib/whop_sdk/models/global_affiliate_status.rb +1 -1
- data/lib/whop_sdk/models/invoice_create_params.rb +50 -34
- data/lib/whop_sdk/models/invoice_list_params.rb +27 -40
- data/lib/whop_sdk/models/lesson.rb +59 -9
- data/lib/whop_sdk/models/member_list_params.rb +11 -11
- data/lib/whop_sdk/models/member_list_response.rb +3 -3
- data/lib/whop_sdk/models/member_retrieve_response.rb +3 -3
- data/lib/whop_sdk/models/membership_list_params.rb +9 -9
- data/lib/whop_sdk/models/message.rb +2 -2
- data/lib/whop_sdk/models/message_create_params.rb +51 -27
- data/lib/whop_sdk/models/message_list_response.rb +2 -2
- data/lib/whop_sdk/models/message_update_params.rb +51 -27
- data/lib/whop_sdk/models/payment.rb +13 -4
- data/lib/whop_sdk/models/payment_list_response.rb +13 -4
- data/lib/whop_sdk/models/payment_method_types.rb +2 -1
- data/lib/whop_sdk/models/plan.rb +54 -5
- data/lib/whop_sdk/models/plan_create_params.rb +99 -24
- data/lib/whop_sdk/models/plan_list_response.rb +57 -5
- data/lib/whop_sdk/models/plan_type.rb +1 -1
- data/lib/whop_sdk/models/plan_update_params.rb +97 -22
- data/lib/whop_sdk/models/product.rb +1 -1
- data/lib/whop_sdk/models/product_create_params.rb +6 -6
- data/lib/whop_sdk/models/product_list_item.rb +1 -1
- data/lib/whop_sdk/models/product_update_params.rb +57 -33
- data/lib/whop_sdk/models/promo_code.rb +3 -3
- data/lib/whop_sdk/models/promo_code_list_response.rb +3 -3
- data/lib/whop_sdk/models/transfer.rb +9 -1
- data/lib/whop_sdk/models/transfer_create_params.rb +9 -1
- data/lib/whop_sdk/models/transfer_list_response.rb +9 -1
- data/lib/whop_sdk/models.rb +14 -0
- data/lib/whop_sdk/resources/access_tokens.rb +46 -0
- data/lib/whop_sdk/resources/app_builds.rb +5 -3
- data/lib/whop_sdk/resources/apps.rb +4 -3
- data/lib/whop_sdk/resources/authorized_users.rb +2 -1
- data/lib/whop_sdk/resources/chat_channels.rb +9 -2
- data/lib/whop_sdk/resources/checkout_configurations.rb +8 -7
- data/lib/whop_sdk/resources/companies.rb +72 -1
- data/lib/whop_sdk/resources/course_chapters.rb +5 -3
- data/lib/whop_sdk/resources/course_lesson_interactions.rb +4 -3
- data/lib/whop_sdk/resources/course_lessons.rb +25 -7
- data/lib/whop_sdk/resources/course_students.rb +77 -0
- data/lib/whop_sdk/resources/courses.rb +24 -7
- data/lib/whop_sdk/resources/entries.rb +6 -3
- data/lib/whop_sdk/resources/experiences.rb +9 -7
- data/lib/whop_sdk/resources/forum_posts.rb +5 -4
- data/lib/whop_sdk/resources/forums.rb +3 -2
- data/lib/whop_sdk/resources/invoices.rb +22 -16
- data/lib/whop_sdk/resources/ledger_accounts.rb +6 -2
- data/lib/whop_sdk/resources/members.rb +6 -5
- data/lib/whop_sdk/resources/memberships.rb +10 -8
- data/lib/whop_sdk/resources/messages.rb +5 -4
- data/lib/whop_sdk/resources/payments.rb +7 -4
- data/lib/whop_sdk/resources/plans.rb +14 -8
- data/lib/whop_sdk/resources/products.rb +10 -8
- data/lib/whop_sdk/resources/promo_codes.rb +4 -2
- data/lib/whop_sdk/resources/reactions.rb +2 -1
- data/lib/whop_sdk/resources/reviews.rb +2 -1
- data/lib/whop_sdk/resources/shipments.rb +2 -1
- data/lib/whop_sdk/resources/support_channels.rb +2 -1
- data/lib/whop_sdk/resources/transfers.rb +5 -2
- data/lib/whop_sdk/resources/users.rb +9 -3
- data/lib/whop_sdk/version.rb +1 -1
- data/lib/whop_sdk.rb +14 -1
- data/manifest.yaml +1 -0
- data/rbi/whop_sdk/client.rbi +6 -0
- data/rbi/whop_sdk/internal/transport/base_client.rbi +5 -0
- data/rbi/whop_sdk/internal/transport/pooled_net_requester.rbi +6 -2
- data/rbi/whop_sdk/internal/type/base_model.rbi +8 -4
- data/rbi/whop_sdk/models/access_level.rbi +1 -1
- data/rbi/whop_sdk/models/access_pass_type.rbi +2 -1
- data/rbi/whop_sdk/models/access_token_create_params.rbi +126 -0
- data/rbi/whop_sdk/models/access_token_create_response.rbi +37 -0
- data/rbi/whop_sdk/models/app_build_create_params.rbi +80 -40
- data/rbi/whop_sdk/models/app_update_params.rbi +86 -37
- data/rbi/whop_sdk/models/checkout_configuration_create_params.rbi +196 -68
- data/rbi/whop_sdk/models/company.rbi +10 -0
- data/rbi/whop_sdk/models/company_create_params.rbi +67 -0
- data/rbi/whop_sdk/models/company_list_params.rbi +83 -0
- data/rbi/whop_sdk/models/company_list_response.rbi +235 -0
- data/rbi/whop_sdk/models/course.rbi +21 -3
- data/rbi/whop_sdk/models/course_create_params.rbi +126 -38
- data/rbi/whop_sdk/models/course_lesson_create_params.rbi +126 -0
- data/rbi/whop_sdk/models/course_lesson_list_response.rbi +68 -0
- data/rbi/whop_sdk/models/course_lesson_update_params.rbi +449 -111
- data/rbi/whop_sdk/models/course_list_response.rbi +21 -3
- data/rbi/whop_sdk/models/course_student_list_params.rbi +83 -0
- data/rbi/whop_sdk/models/course_student_list_response.rbi +142 -0
- data/rbi/whop_sdk/models/course_student_retrieve_params.rbi +30 -0
- data/rbi/whop_sdk/models/course_student_retrieve_response.rbi +250 -0
- data/rbi/whop_sdk/models/course_update_params.rbi +104 -38
- data/rbi/whop_sdk/models/course_visibilities.rbi +23 -0
- data/rbi/whop_sdk/models/embed_type.rbi +20 -0
- data/rbi/whop_sdk/models/entry.rbi +3 -3
- data/rbi/whop_sdk/models/entry_list_response.rbi +3 -3
- data/rbi/whop_sdk/models/experience.rbi +7 -9
- data/rbi/whop_sdk/models/experience_update_params.rbi +84 -38
- data/rbi/whop_sdk/models/forum_post.rbi +2 -2
- data/rbi/whop_sdk/models/forum_post_create_params.rbi +85 -32
- data/rbi/whop_sdk/models/forum_post_list_response.rbi +2 -2
- data/rbi/whop_sdk/models/forum_post_update_params.rbi +85 -32
- data/rbi/whop_sdk/models/global_affiliate_status.rbi +1 -1
- data/rbi/whop_sdk/models/invoice_create_params.rbi +60 -46
- data/rbi/whop_sdk/models/invoice_list_params.rbi +26 -71
- data/rbi/whop_sdk/models/lesson.rbi +68 -10
- data/rbi/whop_sdk/models/member_list_params.rbi +10 -10
- data/rbi/whop_sdk/models/member_list_response.rbi +6 -6
- data/rbi/whop_sdk/models/member_retrieve_response.rbi +6 -6
- data/rbi/whop_sdk/models/membership_list_params.rbi +8 -8
- data/rbi/whop_sdk/models/message.rbi +2 -2
- data/rbi/whop_sdk/models/message_create_params.rbi +85 -32
- data/rbi/whop_sdk/models/message_list_response.rbi +2 -2
- data/rbi/whop_sdk/models/message_update_params.rbi +85 -32
- data/rbi/whop_sdk/models/payment.rbi +13 -3
- data/rbi/whop_sdk/models/payment_list_response.rbi +13 -3
- data/rbi/whop_sdk/models/payment_method_types.rbi +3 -1
- data/rbi/whop_sdk/models/plan.rbi +88 -4
- data/rbi/whop_sdk/models/plan_create_params.rbi +176 -34
- data/rbi/whop_sdk/models/plan_list_response.rbi +100 -4
- data/rbi/whop_sdk/models/plan_type.rbi +1 -1
- data/rbi/whop_sdk/models/plan_update_params.rbi +174 -32
- data/rbi/whop_sdk/models/product.rbi +1 -1
- data/rbi/whop_sdk/models/product_create_params.rbi +6 -6
- data/rbi/whop_sdk/models/product_list_item.rbi +1 -1
- data/rbi/whop_sdk/models/product_update_params.rbi +87 -43
- data/rbi/whop_sdk/models/promo_code.rbi +3 -3
- data/rbi/whop_sdk/models/promo_code_list_response.rbi +3 -3
- data/rbi/whop_sdk/models/transfer.rbi +8 -0
- data/rbi/whop_sdk/models/transfer_create_params.rbi +8 -0
- data/rbi/whop_sdk/models/transfer_list_response.rbi +8 -0
- data/rbi/whop_sdk/models.rbi +14 -0
- data/rbi/whop_sdk/resources/access_tokens.rbi +41 -0
- data/rbi/whop_sdk/resources/app_builds.rbi +15 -3
- data/rbi/whop_sdk/resources/apps.rbi +13 -2
- data/rbi/whop_sdk/resources/authorized_users.rbi +5 -1
- data/rbi/whop_sdk/resources/chat_channels.rbi +8 -1
- data/rbi/whop_sdk/resources/checkout_configurations.rbi +11 -8
- data/rbi/whop_sdk/resources/companies.rbi +68 -1
- data/rbi/whop_sdk/resources/course_chapters.rbi +11 -2
- data/rbi/whop_sdk/resources/course_lesson_interactions.rbi +7 -3
- data/rbi/whop_sdk/resources/course_lessons.rbi +62 -4
- data/rbi/whop_sdk/resources/course_students.rbi +69 -0
- data/rbi/whop_sdk/resources/courses.rbi +50 -4
- data/rbi/whop_sdk/resources/entries.rbi +15 -3
- data/rbi/whop_sdk/resources/experiences.rbi +21 -3
- data/rbi/whop_sdk/resources/forum_posts.rbi +18 -3
- data/rbi/whop_sdk/resources/forums.rbi +6 -1
- data/rbi/whop_sdk/resources/invoices.rbi +38 -23
- data/rbi/whop_sdk/resources/ledger_accounts.rbi +7 -2
- data/rbi/whop_sdk/resources/members.rbi +9 -5
- data/rbi/whop_sdk/resources/memberships.rbi +16 -5
- data/rbi/whop_sdk/resources/messages.rbi +18 -3
- data/rbi/whop_sdk/resources/payments.rbi +16 -3
- data/rbi/whop_sdk/resources/plans.rbi +40 -5
- data/rbi/whop_sdk/resources/products.rbi +21 -7
- data/rbi/whop_sdk/resources/promo_codes.rbi +10 -2
- data/rbi/whop_sdk/resources/reactions.rbi +5 -1
- data/rbi/whop_sdk/resources/reviews.rbi +5 -1
- data/rbi/whop_sdk/resources/shipments.rbi +5 -1
- data/rbi/whop_sdk/resources/support_channels.rbi +5 -1
- data/rbi/whop_sdk/resources/transfers.rbi +8 -1
- data/rbi/whop_sdk/resources/users.rbi +13 -2
- data/sig/whop_sdk/client.rbs +4 -0
- data/sig/whop_sdk/internal/transport/base_client.rbs +2 -0
- data/sig/whop_sdk/internal/transport/pooled_net_requester.rbs +4 -1
- data/sig/whop_sdk/models/access_token_create_params.rbs +56 -0
- data/sig/whop_sdk/models/access_token_create_response.rbs +15 -0
- data/sig/whop_sdk/models/app_build_create_params.rbs +29 -10
- data/sig/whop_sdk/models/app_update_params.rbs +29 -10
- data/sig/whop_sdk/models/checkout_configuration_create_params.rbs +72 -21
- data/sig/whop_sdk/models/company.rbs +5 -0
- data/sig/whop_sdk/models/company_create_params.rbs +41 -0
- data/sig/whop_sdk/models/company_list_params.rbs +51 -0
- data/sig/whop_sdk/models/company_list_response.rbs +109 -0
- data/sig/whop_sdk/models/course.rbs +13 -3
- data/sig/whop_sdk/models/course_create_params.rbs +49 -10
- data/sig/whop_sdk/models/course_lesson_create_params.rbs +46 -0
- data/sig/whop_sdk/models/course_lesson_list_response.rbs +25 -0
- data/sig/whop_sdk/models/course_lesson_update_params.rbs +162 -30
- data/sig/whop_sdk/models/course_list_response.rbs +13 -3
- data/sig/whop_sdk/models/course_student_list_params.rbs +51 -0
- data/sig/whop_sdk/models/course_student_list_response.rbs +64 -0
- data/sig/whop_sdk/models/course_student_retrieve_params.rbs +15 -0
- data/sig/whop_sdk/models/course_student_retrieve_response.rbs +106 -0
- data/sig/whop_sdk/models/course_update_params.rbs +40 -11
- data/sig/whop_sdk/models/course_visibilities.rbs +14 -0
- data/sig/whop_sdk/models/embed_type.rbs +14 -0
- data/sig/whop_sdk/models/experience_update_params.rbs +29 -10
- data/sig/whop_sdk/models/forum_post_create_params.rbs +29 -10
- data/sig/whop_sdk/models/forum_post_update_params.rbs +29 -10
- data/sig/whop_sdk/models/invoice_create_params.rbs +28 -18
- data/sig/whop_sdk/models/invoice_list_params.rbs +16 -33
- data/sig/whop_sdk/models/lesson.rbs +33 -8
- data/sig/whop_sdk/models/member_list_params.rbs +5 -5
- data/sig/whop_sdk/models/membership_list_params.rbs +5 -5
- data/sig/whop_sdk/models/message_create_params.rbs +29 -10
- data/sig/whop_sdk/models/message_update_params.rbs +29 -10
- data/sig/whop_sdk/models/payment.rbs +5 -0
- data/sig/whop_sdk/models/payment_list_response.rbs +5 -0
- data/sig/whop_sdk/models/payment_method_types.rbs +4 -2
- data/sig/whop_sdk/models/plan.rbs +32 -0
- data/sig/whop_sdk/models/plan_create_params.rbs +61 -10
- data/sig/whop_sdk/models/plan_list_response.rbs +32 -0
- data/sig/whop_sdk/models/plan_update_params.rbs +61 -10
- data/sig/whop_sdk/models/product_update_params.rbs +29 -10
- data/sig/whop_sdk/models/transfer.rbs +5 -0
- data/sig/whop_sdk/models/transfer_create_params.rbs +5 -0
- data/sig/whop_sdk/models/transfer_list_response.rbs +5 -0
- data/sig/whop_sdk/models.rbs +14 -0
- data/sig/whop_sdk/resources/access_tokens.rbs +15 -0
- data/sig/whop_sdk/resources/app_builds.rbs +1 -1
- data/sig/whop_sdk/resources/apps.rbs +1 -1
- data/sig/whop_sdk/resources/checkout_configurations.rbs +2 -2
- data/sig/whop_sdk/resources/companies.rbs +18 -0
- data/sig/whop_sdk/resources/course_lessons.rbs +10 -2
- data/sig/whop_sdk/resources/course_students.rbs +22 -0
- data/sig/whop_sdk/resources/courses.rbs +8 -2
- data/sig/whop_sdk/resources/experiences.rbs +1 -1
- data/sig/whop_sdk/resources/forum_posts.rbs +2 -2
- data/sig/whop_sdk/resources/invoices.rbs +8 -6
- data/sig/whop_sdk/resources/members.rbs +1 -1
- data/sig/whop_sdk/resources/memberships.rbs +1 -1
- data/sig/whop_sdk/resources/messages.rbs +2 -2
- data/sig/whop_sdk/resources/plans.rbs +4 -2
- data/sig/whop_sdk/resources/products.rbs +1 -1
- data/sig/whop_sdk/resources/transfers.rbs +1 -0
- metadata +41 -5
- data/lib/whop_sdk/models/invoice_create_response.rb +0 -27
- data/rbi/whop_sdk/models/invoice_create_response.rbi +0 -49
- data/sig/whop_sdk/models/invoice_create_response.rbs +0 -19
|
@@ -7,12 +7,6 @@ module WhopSDK
|
|
|
7
7
|
extend WhopSDK::Internal::Type::RequestParameters::Converter
|
|
8
8
|
include WhopSDK::Internal::Type::RequestParameters
|
|
9
9
|
|
|
10
|
-
# @!attribute access_pass_ids
|
|
11
|
-
# The access pass IDs to filter the memberships by
|
|
12
|
-
#
|
|
13
|
-
# @return [Array<String>, nil]
|
|
14
|
-
optional :access_pass_ids, WhopSDK::Internal::Type::ArrayOf[String], nil?: true
|
|
15
|
-
|
|
16
10
|
# @!attribute after
|
|
17
11
|
# Returns the elements in the list that come after the specified cursor.
|
|
18
12
|
#
|
|
@@ -81,6 +75,12 @@ module WhopSDK
|
|
|
81
75
|
# @return [Array<String>, nil]
|
|
82
76
|
optional :plan_ids, WhopSDK::Internal::Type::ArrayOf[String], nil?: true
|
|
83
77
|
|
|
78
|
+
# @!attribute product_ids
|
|
79
|
+
# The product IDs to filter the memberships by
|
|
80
|
+
#
|
|
81
|
+
# @return [Array<String>, nil]
|
|
82
|
+
optional :product_ids, WhopSDK::Internal::Type::ArrayOf[String], nil?: true
|
|
83
|
+
|
|
84
84
|
# @!attribute promo_code_ids
|
|
85
85
|
# The promo code IDs to filter the memberships by
|
|
86
86
|
#
|
|
@@ -99,9 +99,7 @@ module WhopSDK
|
|
|
99
99
|
# @return [Array<String>, nil]
|
|
100
100
|
optional :user_ids, WhopSDK::Internal::Type::ArrayOf[String], nil?: true
|
|
101
101
|
|
|
102
|
-
# @!method initialize(
|
|
103
|
-
# @param access_pass_ids [Array<String>, nil] The access pass IDs to filter the memberships by
|
|
104
|
-
#
|
|
102
|
+
# @!method initialize(after: nil, before: nil, cancel_options: nil, company_id: nil, created_after: nil, created_before: nil, direction: nil, first: nil, last: nil, order: nil, plan_ids: nil, product_ids: nil, promo_code_ids: nil, statuses: nil, user_ids: nil, request_options: {})
|
|
105
103
|
# @param after [String, nil] Returns the elements in the list that come after the specified cursor.
|
|
106
104
|
#
|
|
107
105
|
# @param before [String, nil] Returns the elements in the list that come before the specified cursor.
|
|
@@ -124,6 +122,8 @@ module WhopSDK
|
|
|
124
122
|
#
|
|
125
123
|
# @param plan_ids [Array<String>, nil] The plan IDs to filter the memberships by
|
|
126
124
|
#
|
|
125
|
+
# @param product_ids [Array<String>, nil] The product IDs to filter the memberships by
|
|
126
|
+
#
|
|
127
127
|
# @param promo_code_ids [Array<String>, nil] The promo code IDs to filter the memberships by
|
|
128
128
|
#
|
|
129
129
|
# @param statuses [Array<Symbol, WhopSDK::Models::MembershipStatus>, nil] The membership status to filter the memberships by
|
|
@@ -4,7 +4,7 @@ module WhopSDK
|
|
|
4
4
|
module Models
|
|
5
5
|
class Message < WhopSDK::Internal::Type::BaseModel
|
|
6
6
|
# @!attribute id
|
|
7
|
-
# The unique identifier
|
|
7
|
+
# The unique identifier of the resource.
|
|
8
8
|
#
|
|
9
9
|
# @return [String]
|
|
10
10
|
required :id, String
|
|
@@ -84,7 +84,7 @@ module WhopSDK
|
|
|
84
84
|
# @!method initialize(id:, content:, created_at:, is_edited:, is_pinned:, message_type:, poll:, poll_votes:, reaction_counts:, replying_to_message_id:, updated_at:, user:, view_count:)
|
|
85
85
|
# Represents a message in a DM channel
|
|
86
86
|
#
|
|
87
|
-
# @param id [String] The unique identifier
|
|
87
|
+
# @param id [String] The unique identifier of the resource.
|
|
88
88
|
#
|
|
89
89
|
# @param content [String, nil] The content of the message in Markdown format
|
|
90
90
|
#
|
|
@@ -22,9 +22,9 @@ module WhopSDK
|
|
|
22
22
|
# @!attribute attachments
|
|
23
23
|
# The attachments for this message, such as videos or images.
|
|
24
24
|
#
|
|
25
|
-
# @return [Array<WhopSDK::Models::MessageCreateParams::Attachment>, nil]
|
|
25
|
+
# @return [Array<WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithDirectUploadID, WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithID>, nil]
|
|
26
26
|
optional :attachments,
|
|
27
|
-
-> { WhopSDK::Internal::Type::ArrayOf[WhopSDK::MessageCreateParams::Attachment] },
|
|
27
|
+
-> { WhopSDK::Internal::Type::ArrayOf[union: WhopSDK::MessageCreateParams::Attachment] },
|
|
28
28
|
nil?: true
|
|
29
29
|
|
|
30
30
|
# @!attribute poll
|
|
@@ -38,38 +38,62 @@ module WhopSDK
|
|
|
38
38
|
#
|
|
39
39
|
# @param content [String] The content of the message in Markdown format.
|
|
40
40
|
#
|
|
41
|
-
# @param attachments [Array<WhopSDK::Models::MessageCreateParams::Attachment>, nil] The attachments for this message, such as videos or images.
|
|
41
|
+
# @param attachments [Array<WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithDirectUploadID, WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithID>, nil] The attachments for this message, such as videos or images.
|
|
42
42
|
#
|
|
43
43
|
# @param poll [WhopSDK::Models::MessageCreateParams::Poll, nil] The poll for this message
|
|
44
44
|
#
|
|
45
45
|
# @param request_options [WhopSDK::RequestOptions, Hash{Symbol=>Object}]
|
|
46
46
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
# keeping a subset of the attachments. Don't use this unless you know what you're
|
|
51
|
-
# doing.
|
|
52
|
-
#
|
|
53
|
-
# @return [String, nil]
|
|
54
|
-
optional :id, String, nil?: true
|
|
47
|
+
# Input for an attachment
|
|
48
|
+
module Attachment
|
|
49
|
+
extend WhopSDK::Internal::Type::Union
|
|
55
50
|
|
|
56
|
-
#
|
|
57
|
-
|
|
58
|
-
# the direct upload that was created when uploading the file to S3 via the
|
|
59
|
-
# mediaDirectUpload mutation.
|
|
60
|
-
#
|
|
61
|
-
# @return [String, nil]
|
|
62
|
-
optional :direct_upload_id, String, nil?: true
|
|
51
|
+
# Input for an attachment
|
|
52
|
+
variant -> { WhopSDK::MessageCreateParams::Attachment::AttachmentInputWithDirectUploadID }
|
|
63
53
|
|
|
64
|
-
#
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
54
|
+
# Input for an attachment
|
|
55
|
+
variant -> { WhopSDK::MessageCreateParams::Attachment::AttachmentInputWithID }
|
|
56
|
+
|
|
57
|
+
class AttachmentInputWithDirectUploadID < WhopSDK::Internal::Type::BaseModel
|
|
58
|
+
# @!attribute direct_upload_id
|
|
59
|
+
# This ID should be used the first time you upload an attachment. It is the ID of
|
|
60
|
+
# the direct upload that was created when uploading the file to S3 via the
|
|
61
|
+
# mediaDirectUpload mutation.
|
|
62
|
+
#
|
|
63
|
+
# @return [String]
|
|
64
|
+
required :direct_upload_id, String
|
|
65
|
+
|
|
66
|
+
# @!method initialize(direct_upload_id:)
|
|
67
|
+
# Some parameter documentations has been truncated, see
|
|
68
|
+
# {WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithDirectUploadID}
|
|
69
|
+
# for more details.
|
|
70
|
+
#
|
|
71
|
+
# Input for an attachment
|
|
72
|
+
#
|
|
73
|
+
# @param direct_upload_id [String] This ID should be used the first time you upload an attachment. It is the ID of
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
class AttachmentInputWithID < WhopSDK::Internal::Type::BaseModel
|
|
77
|
+
# @!attribute id
|
|
78
|
+
# The ID of an existing attachment object. Use this when updating a resource and
|
|
79
|
+
# keeping a subset of the attachments. Don't use this unless you know what you're
|
|
80
|
+
# doing.
|
|
81
|
+
#
|
|
82
|
+
# @return [String]
|
|
83
|
+
required :id, String
|
|
84
|
+
|
|
85
|
+
# @!method initialize(id:)
|
|
86
|
+
# Some parameter documentations has been truncated, see
|
|
87
|
+
# {WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithID} for
|
|
88
|
+
# more details.
|
|
89
|
+
#
|
|
90
|
+
# Input for an attachment
|
|
91
|
+
#
|
|
92
|
+
# @param id [String] The ID of an existing attachment object. Use this when updating a resource and k
|
|
93
|
+
end
|
|
94
|
+
|
|
95
|
+
# @!method self.variants
|
|
96
|
+
# @return [Array(WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithDirectUploadID, WhopSDK::Models::MessageCreateParams::Attachment::AttachmentInputWithID)]
|
|
73
97
|
end
|
|
74
98
|
|
|
75
99
|
class Poll < WhopSDK::Internal::Type::BaseModel
|
|
@@ -5,7 +5,7 @@ module WhopSDK
|
|
|
5
5
|
# @see WhopSDK::Resources::Messages#list
|
|
6
6
|
class MessageListResponse < WhopSDK::Internal::Type::BaseModel
|
|
7
7
|
# @!attribute id
|
|
8
|
-
# The unique identifier
|
|
8
|
+
# The unique identifier of the resource.
|
|
9
9
|
#
|
|
10
10
|
# @return [String]
|
|
11
11
|
required :id, String
|
|
@@ -87,7 +87,7 @@ module WhopSDK
|
|
|
87
87
|
# @!method initialize(id:, content:, created_at:, is_edited:, is_pinned:, message_type:, poll:, poll_votes:, reaction_counts:, replying_to_message_id:, updated_at:, user:, view_count:)
|
|
88
88
|
# Represents a message in a DM channel
|
|
89
89
|
#
|
|
90
|
-
# @param id [String] The unique identifier
|
|
90
|
+
# @param id [String] The unique identifier of the resource.
|
|
91
91
|
#
|
|
92
92
|
# @param content [String, nil] The content of the message in Markdown format
|
|
93
93
|
#
|
|
@@ -10,9 +10,9 @@ module WhopSDK
|
|
|
10
10
|
# @!attribute attachments
|
|
11
11
|
# The attachments for this message
|
|
12
12
|
#
|
|
13
|
-
# @return [Array<WhopSDK::Models::MessageUpdateParams::Attachment>, nil]
|
|
13
|
+
# @return [Array<WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithDirectUploadID, WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithID>, nil]
|
|
14
14
|
optional :attachments,
|
|
15
|
-
-> { WhopSDK::Internal::Type::ArrayOf[WhopSDK::MessageUpdateParams::Attachment] },
|
|
15
|
+
-> { WhopSDK::Internal::Type::ArrayOf[union: WhopSDK::MessageUpdateParams::Attachment] },
|
|
16
16
|
nil?: true
|
|
17
17
|
|
|
18
18
|
# @!attribute content
|
|
@@ -28,7 +28,7 @@ module WhopSDK
|
|
|
28
28
|
optional :is_pinned, WhopSDK::Internal::Type::Boolean, nil?: true
|
|
29
29
|
|
|
30
30
|
# @!method initialize(attachments: nil, content: nil, is_pinned: nil, request_options: {})
|
|
31
|
-
# @param attachments [Array<WhopSDK::Models::MessageUpdateParams::Attachment>, nil] The attachments for this message
|
|
31
|
+
# @param attachments [Array<WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithDirectUploadID, WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithID>, nil] The attachments for this message
|
|
32
32
|
#
|
|
33
33
|
# @param content [String, nil] The content of the message in Markdown format
|
|
34
34
|
#
|
|
@@ -36,32 +36,56 @@ module WhopSDK
|
|
|
36
36
|
#
|
|
37
37
|
# @param request_options [WhopSDK::RequestOptions, Hash{Symbol=>Object}]
|
|
38
38
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
# keeping a subset of the attachments. Don't use this unless you know what you're
|
|
43
|
-
# doing.
|
|
44
|
-
#
|
|
45
|
-
# @return [String, nil]
|
|
46
|
-
optional :id, String, nil?: true
|
|
39
|
+
# Input for an attachment
|
|
40
|
+
module Attachment
|
|
41
|
+
extend WhopSDK::Internal::Type::Union
|
|
47
42
|
|
|
48
|
-
#
|
|
49
|
-
|
|
50
|
-
# the direct upload that was created when uploading the file to S3 via the
|
|
51
|
-
# mediaDirectUpload mutation.
|
|
52
|
-
#
|
|
53
|
-
# @return [String, nil]
|
|
54
|
-
optional :direct_upload_id, String, nil?: true
|
|
43
|
+
# Input for an attachment
|
|
44
|
+
variant -> { WhopSDK::MessageUpdateParams::Attachment::AttachmentInputWithDirectUploadID }
|
|
55
45
|
|
|
56
|
-
#
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
46
|
+
# Input for an attachment
|
|
47
|
+
variant -> { WhopSDK::MessageUpdateParams::Attachment::AttachmentInputWithID }
|
|
48
|
+
|
|
49
|
+
class AttachmentInputWithDirectUploadID < WhopSDK::Internal::Type::BaseModel
|
|
50
|
+
# @!attribute direct_upload_id
|
|
51
|
+
# This ID should be used the first time you upload an attachment. It is the ID of
|
|
52
|
+
# the direct upload that was created when uploading the file to S3 via the
|
|
53
|
+
# mediaDirectUpload mutation.
|
|
54
|
+
#
|
|
55
|
+
# @return [String]
|
|
56
|
+
required :direct_upload_id, String
|
|
57
|
+
|
|
58
|
+
# @!method initialize(direct_upload_id:)
|
|
59
|
+
# Some parameter documentations has been truncated, see
|
|
60
|
+
# {WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithDirectUploadID}
|
|
61
|
+
# for more details.
|
|
62
|
+
#
|
|
63
|
+
# Input for an attachment
|
|
64
|
+
#
|
|
65
|
+
# @param direct_upload_id [String] This ID should be used the first time you upload an attachment. It is the ID of
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
class AttachmentInputWithID < WhopSDK::Internal::Type::BaseModel
|
|
69
|
+
# @!attribute id
|
|
70
|
+
# The ID of an existing attachment object. Use this when updating a resource and
|
|
71
|
+
# keeping a subset of the attachments. Don't use this unless you know what you're
|
|
72
|
+
# doing.
|
|
73
|
+
#
|
|
74
|
+
# @return [String]
|
|
75
|
+
required :id, String
|
|
76
|
+
|
|
77
|
+
# @!method initialize(id:)
|
|
78
|
+
# Some parameter documentations has been truncated, see
|
|
79
|
+
# {WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithID} for
|
|
80
|
+
# more details.
|
|
81
|
+
#
|
|
82
|
+
# Input for an attachment
|
|
83
|
+
#
|
|
84
|
+
# @param id [String] The ID of an existing attachment object. Use this when updating a resource and k
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
# @!method self.variants
|
|
88
|
+
# @return [Array(WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithDirectUploadID, WhopSDK::Models::MessageUpdateParams::Attachment::AttachmentInputWithID)]
|
|
65
89
|
end
|
|
66
90
|
end
|
|
67
91
|
end
|
|
@@ -93,6 +93,13 @@ module WhopSDK
|
|
|
93
93
|
# @return [WhopSDK::Models::Payment::Membership, nil]
|
|
94
94
|
required :membership, -> { WhopSDK::Payment::Membership }, nil?: true
|
|
95
95
|
|
|
96
|
+
# @!attribute metadata
|
|
97
|
+
# The custom metadata stored on this payment. This will be copied the checkout
|
|
98
|
+
# configuration for which this payment was made
|
|
99
|
+
#
|
|
100
|
+
# @return [Hash{Symbol=>Object}, nil]
|
|
101
|
+
required :metadata, WhopSDK::Internal::Type::HashOf[WhopSDK::Internal::Type::Unknown], nil?: true
|
|
102
|
+
|
|
96
103
|
# @!attribute paid_at
|
|
97
104
|
# The datetime the payment was paid
|
|
98
105
|
#
|
|
@@ -112,7 +119,7 @@ module WhopSDK
|
|
|
112
119
|
required :plan, -> { WhopSDK::Payment::Plan }, nil?: true
|
|
113
120
|
|
|
114
121
|
# @!attribute product
|
|
115
|
-
# The
|
|
122
|
+
# The product this payment was made for
|
|
116
123
|
#
|
|
117
124
|
# @return [WhopSDK::Models::Payment::Product, nil]
|
|
118
125
|
required :product, -> { WhopSDK::Payment::Product }, nil?: true
|
|
@@ -193,7 +200,7 @@ module WhopSDK
|
|
|
193
200
|
# @return [Boolean]
|
|
194
201
|
required :voidable, WhopSDK::Internal::Type::Boolean
|
|
195
202
|
|
|
196
|
-
# @!method initialize(id:, amount_after_fees:, auto_refunded:, billing_address:, billing_reason:, card_brand:, card_last4:, company:, created_at:, currency:, dispute_alerted_at:, failure_message:, last_payment_attempt:, member:, membership:, paid_at:, payment_method_type:, plan:, product:, promo_code:, refundable:, refunded_amount:, refunded_at:, retryable:, status:, substatus:, subtotal:, total:, usd_total:, user:, voidable:)
|
|
203
|
+
# @!method initialize(id:, amount_after_fees:, auto_refunded:, billing_address:, billing_reason:, card_brand:, card_last4:, company:, created_at:, currency:, dispute_alerted_at:, failure_message:, last_payment_attempt:, member:, membership:, metadata:, paid_at:, payment_method_type:, plan:, product:, promo_code:, refundable:, refunded_amount:, refunded_at:, retryable:, status:, substatus:, subtotal:, total:, usd_total:, user:, voidable:)
|
|
197
204
|
# Some parameter documentations has been truncated, see {WhopSDK::Models::Payment}
|
|
198
205
|
# for more details.
|
|
199
206
|
#
|
|
@@ -229,13 +236,15 @@ module WhopSDK
|
|
|
229
236
|
#
|
|
230
237
|
# @param membership [WhopSDK::Models::Payment::Membership, nil] The membership attached to this payment.
|
|
231
238
|
#
|
|
239
|
+
# @param metadata [Hash{Symbol=>Object}, nil] The custom metadata stored on this payment. This will be copied the checkout con
|
|
240
|
+
#
|
|
232
241
|
# @param paid_at [Time, nil] The datetime the payment was paid
|
|
233
242
|
#
|
|
234
243
|
# @param payment_method_type [Symbol, WhopSDK::Models::PaymentMethodTypes, nil] The different types of payment methods that can be used.
|
|
235
244
|
#
|
|
236
245
|
# @param plan [WhopSDK::Models::Payment::Plan, nil] The plan attached to this payment.
|
|
237
246
|
#
|
|
238
|
-
# @param product [WhopSDK::Models::Payment::Product, nil] The
|
|
247
|
+
# @param product [WhopSDK::Models::Payment::Product, nil] The product this payment was made for
|
|
239
248
|
#
|
|
240
249
|
# @param promo_code [WhopSDK::Models::Payment::PromoCode, nil] The promo code used for this payment.
|
|
241
250
|
#
|
|
@@ -432,7 +441,7 @@ module WhopSDK
|
|
|
432
441
|
required :title, String
|
|
433
442
|
|
|
434
443
|
# @!method initialize(id:, route:, title:)
|
|
435
|
-
# The
|
|
444
|
+
# The product this payment was made for
|
|
436
445
|
#
|
|
437
446
|
# @param id [String] The internal ID of the public product.
|
|
438
447
|
#
|
|
@@ -94,6 +94,13 @@ module WhopSDK
|
|
|
94
94
|
# @return [WhopSDK::Models::PaymentListResponse::Membership, nil]
|
|
95
95
|
required :membership, -> { WhopSDK::Models::PaymentListResponse::Membership }, nil?: true
|
|
96
96
|
|
|
97
|
+
# @!attribute metadata
|
|
98
|
+
# The custom metadata stored on this payment. This will be copied the checkout
|
|
99
|
+
# configuration for which this payment was made
|
|
100
|
+
#
|
|
101
|
+
# @return [Hash{Symbol=>Object}, nil]
|
|
102
|
+
required :metadata, WhopSDK::Internal::Type::HashOf[WhopSDK::Internal::Type::Unknown], nil?: true
|
|
103
|
+
|
|
97
104
|
# @!attribute paid_at
|
|
98
105
|
# The datetime the payment was paid
|
|
99
106
|
#
|
|
@@ -113,7 +120,7 @@ module WhopSDK
|
|
|
113
120
|
required :plan, -> { WhopSDK::Models::PaymentListResponse::Plan }, nil?: true
|
|
114
121
|
|
|
115
122
|
# @!attribute product
|
|
116
|
-
# The
|
|
123
|
+
# The product this payment was made for
|
|
117
124
|
#
|
|
118
125
|
# @return [WhopSDK::Models::PaymentListResponse::Product, nil]
|
|
119
126
|
required :product, -> { WhopSDK::Models::PaymentListResponse::Product }, nil?: true
|
|
@@ -194,7 +201,7 @@ module WhopSDK
|
|
|
194
201
|
# @return [Boolean]
|
|
195
202
|
required :voidable, WhopSDK::Internal::Type::Boolean
|
|
196
203
|
|
|
197
|
-
# @!method initialize(id:, amount_after_fees:, auto_refunded:, billing_address:, billing_reason:, card_brand:, card_last4:, company:, created_at:, currency:, dispute_alerted_at:, failure_message:, last_payment_attempt:, member:, membership:, paid_at:, payment_method_type:, plan:, product:, promo_code:, refundable:, refunded_amount:, refunded_at:, retryable:, status:, substatus:, subtotal:, total:, usd_total:, user:, voidable:)
|
|
204
|
+
# @!method initialize(id:, amount_after_fees:, auto_refunded:, billing_address:, billing_reason:, card_brand:, card_last4:, company:, created_at:, currency:, dispute_alerted_at:, failure_message:, last_payment_attempt:, member:, membership:, metadata:, paid_at:, payment_method_type:, plan:, product:, promo_code:, refundable:, refunded_amount:, refunded_at:, retryable:, status:, substatus:, subtotal:, total:, usd_total:, user:, voidable:)
|
|
198
205
|
# Some parameter documentations has been truncated, see
|
|
199
206
|
# {WhopSDK::Models::PaymentListResponse} for more details.
|
|
200
207
|
#
|
|
@@ -230,13 +237,15 @@ module WhopSDK
|
|
|
230
237
|
#
|
|
231
238
|
# @param membership [WhopSDK::Models::PaymentListResponse::Membership, nil] The membership attached to this payment.
|
|
232
239
|
#
|
|
240
|
+
# @param metadata [Hash{Symbol=>Object}, nil] The custom metadata stored on this payment. This will be copied the checkout con
|
|
241
|
+
#
|
|
233
242
|
# @param paid_at [Time, nil] The datetime the payment was paid
|
|
234
243
|
#
|
|
235
244
|
# @param payment_method_type [Symbol, WhopSDK::Models::PaymentMethodTypes, nil] The different types of payment methods that can be used.
|
|
236
245
|
#
|
|
237
246
|
# @param plan [WhopSDK::Models::PaymentListResponse::Plan, nil] The plan attached to this payment.
|
|
238
247
|
#
|
|
239
|
-
# @param product [WhopSDK::Models::PaymentListResponse::Product, nil] The
|
|
248
|
+
# @param product [WhopSDK::Models::PaymentListResponse::Product, nil] The product this payment was made for
|
|
240
249
|
#
|
|
241
250
|
# @param promo_code [WhopSDK::Models::PaymentListResponse::PromoCode, nil] The promo code used for this payment.
|
|
242
251
|
#
|
|
@@ -433,7 +442,7 @@ module WhopSDK
|
|
|
433
442
|
required :title, String
|
|
434
443
|
|
|
435
444
|
# @!method initialize(id:, route:, title:)
|
|
436
|
-
# The
|
|
445
|
+
# The product this payment was made for
|
|
437
446
|
#
|
|
438
447
|
# @param id [String] The internal ID of the public product.
|
|
439
448
|
#
|
|
@@ -85,10 +85,11 @@ module WhopSDK
|
|
|
85
85
|
ID_BANK_TRANSFER = :id_bank_transfer
|
|
86
86
|
DEMO_PAY = :demo_pay
|
|
87
87
|
SHOP_PAY = :shop_pay
|
|
88
|
-
APPLE = :apple
|
|
89
88
|
SEZZLE = :sezzle
|
|
90
89
|
COINBASE = :coinbase
|
|
91
90
|
SPLITIT = :splitit
|
|
91
|
+
PLATFORM_BALANCE = :platform_balance
|
|
92
|
+
APPLE = :apple
|
|
92
93
|
UNKNOWN = :unknown
|
|
93
94
|
|
|
94
95
|
# @!method self.values
|
data/lib/whop_sdk/models/plan.rb
CHANGED
|
@@ -81,6 +81,12 @@ module WhopSDK
|
|
|
81
81
|
# @return [Integer, nil]
|
|
82
82
|
required :member_count, Integer, nil?: true
|
|
83
83
|
|
|
84
|
+
# @!attribute payment_method_configuration
|
|
85
|
+
# The explicit payment method configuration for the plan, if any.
|
|
86
|
+
#
|
|
87
|
+
# @return [WhopSDK::Models::Plan::PaymentMethodConfiguration, nil]
|
|
88
|
+
required :payment_method_configuration, -> { WhopSDK::Plan::PaymentMethodConfiguration }, nil?: true
|
|
89
|
+
|
|
84
90
|
# @!attribute plan_type
|
|
85
91
|
# Indicates if the plan is a one time payment or recurring.
|
|
86
92
|
#
|
|
@@ -88,7 +94,7 @@ module WhopSDK
|
|
|
88
94
|
required :plan_type, enum: -> { WhopSDK::PlanType }
|
|
89
95
|
|
|
90
96
|
# @!attribute product
|
|
91
|
-
# The
|
|
97
|
+
# The product that this plan belongs to.
|
|
92
98
|
#
|
|
93
99
|
# @return [WhopSDK::Models::Plan::Product, nil]
|
|
94
100
|
required :product, -> { WhopSDK::Plan::Product }, nil?: true
|
|
@@ -153,8 +159,10 @@ module WhopSDK
|
|
|
153
159
|
# @return [Symbol, WhopSDK::Models::Visibility]
|
|
154
160
|
required :visibility, enum: -> { WhopSDK::Visibility }
|
|
155
161
|
|
|
156
|
-
# @!method initialize(id:, billing_period:, collect_tax:, company:, created_at:, currency:, custom_fields:, description:, expiration_days:, initial_price:, internal_notes:, invoice:, member_count:, plan_type:, product:, purchase_url:, release_method:, renewal_price:, stock:, tax_type:, title:, trial_period_days:, unlimited_stock:, updated_at:, visibility:)
|
|
157
|
-
#
|
|
162
|
+
# @!method initialize(id:, billing_period:, collect_tax:, company:, created_at:, currency:, custom_fields:, description:, expiration_days:, initial_price:, internal_notes:, invoice:, member_count:, payment_method_configuration:, plan_type:, product:, purchase_url:, release_method:, renewal_price:, stock:, tax_type:, title:, trial_period_days:, unlimited_stock:, updated_at:, visibility:)
|
|
163
|
+
# A plan for an product. Plans define the core parameters that define a checkout
|
|
164
|
+
# and payment on whop. Use plans to create different ways to price your products
|
|
165
|
+
# (Eg renewal / one_time)
|
|
158
166
|
#
|
|
159
167
|
# @param id [String] The internal ID of the plan.
|
|
160
168
|
#
|
|
@@ -182,9 +190,11 @@ module WhopSDK
|
|
|
182
190
|
#
|
|
183
191
|
# @param member_count [Integer, nil] The number of members for the plan.
|
|
184
192
|
#
|
|
193
|
+
# @param payment_method_configuration [WhopSDK::Models::Plan::PaymentMethodConfiguration, nil] The explicit payment method configuration for the plan, if any.
|
|
194
|
+
#
|
|
185
195
|
# @param plan_type [Symbol, WhopSDK::Models::PlanType] Indicates if the plan is a one time payment or recurring.
|
|
186
196
|
#
|
|
187
|
-
# @param product [WhopSDK::Models::Plan::Product, nil] The
|
|
197
|
+
# @param product [WhopSDK::Models::Plan::Product, nil] The product that this plan belongs to.
|
|
188
198
|
#
|
|
189
199
|
# @param purchase_url [String] The direct link to purchase the product.
|
|
190
200
|
#
|
|
@@ -295,6 +305,45 @@ module WhopSDK
|
|
|
295
305
|
# @param id [String] The ID of the invoice.
|
|
296
306
|
end
|
|
297
307
|
|
|
308
|
+
# @see WhopSDK::Models::Plan#payment_method_configuration
|
|
309
|
+
class PaymentMethodConfiguration < WhopSDK::Internal::Type::BaseModel
|
|
310
|
+
# @!attribute disabled
|
|
311
|
+
# An array of payment method identifiers that are explicitly disabled. Only
|
|
312
|
+
# applies if the include_platform_defaults is true.
|
|
313
|
+
#
|
|
314
|
+
# @return [Array<Symbol, WhopSDK::Models::PaymentMethodTypes>]
|
|
315
|
+
required :disabled, -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::PaymentMethodTypes] }
|
|
316
|
+
|
|
317
|
+
# @!attribute enabled
|
|
318
|
+
# An array of payment method identifiers that are explicitly enabled. This means
|
|
319
|
+
# these payment methods will be shown on checkout. Example use case is to only
|
|
320
|
+
# enable a specific payment method like cashapp, or extending the platform
|
|
321
|
+
# defaults with additional methods.
|
|
322
|
+
#
|
|
323
|
+
# @return [Array<Symbol, WhopSDK::Models::PaymentMethodTypes>]
|
|
324
|
+
required :enabled, -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::PaymentMethodTypes] }
|
|
325
|
+
|
|
326
|
+
# @!attribute include_platform_defaults
|
|
327
|
+
# Whether Whop's platform default payment method enablement settings are included
|
|
328
|
+
# in this configuration. The full list of default payment methods can be found in
|
|
329
|
+
# the documentation at docs.whop.com/payments.
|
|
330
|
+
#
|
|
331
|
+
# @return [Boolean]
|
|
332
|
+
required :include_platform_defaults, WhopSDK::Internal::Type::Boolean
|
|
333
|
+
|
|
334
|
+
# @!method initialize(disabled:, enabled:, include_platform_defaults:)
|
|
335
|
+
# Some parameter documentations has been truncated, see
|
|
336
|
+
# {WhopSDK::Models::Plan::PaymentMethodConfiguration} for more details.
|
|
337
|
+
#
|
|
338
|
+
# The explicit payment method configuration for the plan, if any.
|
|
339
|
+
#
|
|
340
|
+
# @param disabled [Array<Symbol, WhopSDK::Models::PaymentMethodTypes>] An array of payment method identifiers that are explicitly disabled. Only applie
|
|
341
|
+
#
|
|
342
|
+
# @param enabled [Array<Symbol, WhopSDK::Models::PaymentMethodTypes>] An array of payment method identifiers that are explicitly enabled. This means t
|
|
343
|
+
#
|
|
344
|
+
# @param include_platform_defaults [Boolean] Whether Whop's platform default payment method enablement settings are included
|
|
345
|
+
end
|
|
346
|
+
|
|
298
347
|
# @see WhopSDK::Models::Plan#product
|
|
299
348
|
class Product < WhopSDK::Internal::Type::BaseModel
|
|
300
349
|
# @!attribute id
|
|
@@ -310,7 +359,7 @@ module WhopSDK
|
|
|
310
359
|
required :title, String
|
|
311
360
|
|
|
312
361
|
# @!method initialize(id:, title:)
|
|
313
|
-
# The
|
|
362
|
+
# The product that this plan belongs to.
|
|
314
363
|
#
|
|
315
364
|
# @param id [String] The internal ID of the public product.
|
|
316
365
|
#
|