whop_sdk 0.0.31 → 0.0.32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +12 -0
  3. data/README.md +1 -1
  4. data/lib/whop_sdk/client.rb +12 -0
  5. data/lib/whop_sdk/models/ai_chat_list_params.rb +9 -1
  6. data/lib/whop_sdk/models/{authorized_user_create_response.rb → authorized_user.rb} +10 -10
  7. data/lib/whop_sdk/models/payment.rb +17 -93
  8. data/lib/whop_sdk/models/product_create_params.rb +10 -1
  9. data/lib/whop_sdk/models/product_update_params.rb +10 -1
  10. data/lib/whop_sdk/models/resolution_center_case_customer_response.rb +17 -0
  11. data/lib/whop_sdk/models/resolution_center_case_issue_type.rb +19 -0
  12. data/lib/whop_sdk/models/resolution_center_case_list_params.rb +88 -0
  13. data/lib/whop_sdk/models/resolution_center_case_list_response.rb +191 -0
  14. data/lib/whop_sdk/models/resolution_center_case_merchant_response.rb +19 -0
  15. data/lib/whop_sdk/models/resolution_center_case_platform_response.rb +19 -0
  16. data/lib/whop_sdk/models/resolution_center_case_retrieve_params.rb +20 -0
  17. data/lib/whop_sdk/models/resolution_center_case_retrieve_response.rb +372 -0
  18. data/lib/whop_sdk/models/resolution_center_case_status.rb +22 -0
  19. data/lib/whop_sdk/models.rb +16 -0
  20. data/lib/whop_sdk/resources/ai_chats.rb +3 -1
  21. data/lib/whop_sdk/resources/authorized_users.rb +4 -4
  22. data/lib/whop_sdk/resources/products.rb +6 -2
  23. data/lib/whop_sdk/resources/resolution_center_cases.rb +84 -0
  24. data/lib/whop_sdk/resources/webhooks.rb +11 -1
  25. data/lib/whop_sdk/version.rb +1 -1
  26. data/lib/whop_sdk.rb +12 -2
  27. data/rbi/whop_sdk/client.rbi +10 -0
  28. data/rbi/whop_sdk/models/ai_chat_list_params.rbi +8 -0
  29. data/rbi/whop_sdk/models/{authorized_user_create_response.rbi → authorized_user.rbi} +12 -31
  30. data/rbi/whop_sdk/models/payment.rbi +17 -265
  31. data/rbi/whop_sdk/models/product_create_params.rbi +10 -0
  32. data/rbi/whop_sdk/models/product_update_params.rbi +10 -0
  33. data/rbi/whop_sdk/models/resolution_center_case_customer_response.rbi +40 -0
  34. data/rbi/whop_sdk/models/resolution_center_case_issue_type.rbi +48 -0
  35. data/rbi/whop_sdk/models/resolution_center_case_list_params.rbi +118 -0
  36. data/rbi/whop_sdk/models/resolution_center_case_list_response.rbi +303 -0
  37. data/rbi/whop_sdk/models/resolution_center_case_merchant_response.rbi +50 -0
  38. data/rbi/whop_sdk/models/resolution_center_case_platform_response.rbi +50 -0
  39. data/rbi/whop_sdk/models/resolution_center_case_retrieve_params.rbi +38 -0
  40. data/rbi/whop_sdk/models/resolution_center_case_retrieve_response.rbi +673 -0
  41. data/rbi/whop_sdk/models/resolution_center_case_status.rbi +57 -0
  42. data/rbi/whop_sdk/models.rbi +21 -0
  43. data/rbi/whop_sdk/resources/ai_chats.rbi +3 -0
  44. data/rbi/whop_sdk/resources/authorized_users.rbi +2 -2
  45. data/rbi/whop_sdk/resources/products.rbi +8 -0
  46. data/rbi/whop_sdk/resources/resolution_center_cases.rbi +79 -0
  47. data/rbi/whop_sdk/resources/webhooks.rbi +10 -2
  48. data/sig/whop_sdk/client.rbs +5 -0
  49. data/sig/whop_sdk/models/ai_chat_list_params.rbs +11 -1
  50. data/sig/whop_sdk/models/{authorized_user_create_response.rbs → authorized_user.rbs} +10 -10
  51. data/sig/whop_sdk/models/payment.rbs +20 -110
  52. data/sig/whop_sdk/models/product_create_params.rbs +5 -0
  53. data/sig/whop_sdk/models/product_update_params.rbs +5 -0
  54. data/sig/whop_sdk/models/resolution_center_case_customer_response.rbs +16 -0
  55. data/sig/whop_sdk/models/resolution_center_case_issue_type.rbs +22 -0
  56. data/sig/whop_sdk/models/resolution_center_case_list_params.rbs +66 -0
  57. data/sig/whop_sdk/models/resolution_center_case_list_response.rbs +116 -0
  58. data/sig/whop_sdk/models/resolution_center_case_merchant_response.rbs +18 -0
  59. data/sig/whop_sdk/models/resolution_center_case_platform_response.rbs +22 -0
  60. data/sig/whop_sdk/models/resolution_center_case_retrieve_params.rbs +20 -0
  61. data/sig/whop_sdk/models/resolution_center_case_retrieve_response.rbs +254 -0
  62. data/sig/whop_sdk/models/resolution_center_case_status.rbs +28 -0
  63. data/sig/whop_sdk/models.rbs +16 -0
  64. data/sig/whop_sdk/resources/ai_chats.rbs +1 -0
  65. data/sig/whop_sdk/resources/authorized_users.rbs +2 -2
  66. data/sig/whop_sdk/resources/products.rbs +2 -0
  67. data/sig/whop_sdk/resources/resolution_center_cases.rbs +25 -0
  68. data/sig/whop_sdk/resources/webhooks.rbs +3 -1
  69. metadata +49 -8
  70. data/lib/whop_sdk/models/authorized_user_retrieve_response.rb +0 -108
  71. data/rbi/whop_sdk/models/authorized_user_retrieve_response.rbi +0 -176
  72. data/sig/whop_sdk/models/authorized_user_retrieve_response.rbs +0 -74
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 12e9969a7eac42ce7a80ee6ccf72f945dcdfe7ebbe7ee04e562fe96cb50a44ae
4
- data.tar.gz: 2f1bbca753b5cac0e0200cbdf52871659fe31d5362ad65ecfca049f1a4b025af
3
+ metadata.gz: 5b1e90098a29bdefdc04f776aeca2ed2c5cf4f89cf0f5b3896beffcd04f8e12c
4
+ data.tar.gz: dbef416ee6ab388e3706fe55ebb11d1843d662b6f990d1ec3167d8f6f29b6146
5
5
  SHA512:
6
- metadata.gz: 669077efe6b16a885c17b811eeb5e6dc33680ed905d34cf8ae01ed56e8c80f906a4f1e98eb280d479fe376e24d13c38bb3059364611fefebc4cdc7c8edf18878
7
- data.tar.gz: 798aa8286ae4168a76cd10d34e6aad867baa9d49257186923b2568d383a0844c62001bbc966eecd0fd70dc9400412afcbe11fd561fb46959921e1bbe09d496b1
6
+ metadata.gz: 554be6f8643c5c20475a0a344101c1e346c4ad637ddeb79673b92a2b175ad43371c3871961ef2be56afb6317bba7494c4a19948cc9f3185543e23c6458a57532
7
+ data.tar.gz: 31eec9f0026c2d02bb8ec14a1a054c63a3de8bffe94d09e16df5708d7e513fe925633e4466e811cde56a9cab531e9cc44c5e764e5c8dadbed018e4ddffe69f7e
data/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.0.32 (2026-03-11)
4
+
5
+ Full Changelog: [v0.0.31...v0.0.32](https://github.com/whopio/whopsdk-ruby/compare/v0.0.31...v0.0.32)
6
+
7
+ ### Features
8
+
9
+ * **api:** api update ([6736597](https://github.com/whopio/whopsdk-ruby/commit/67365979c3472172bef736fc73574bb5719614e5))
10
+ * **api:** api update ([d6af2cc](https://github.com/whopio/whopsdk-ruby/commit/d6af2cc7ea14659053aff192953d4062ce31a293))
11
+ * **api:** api update ([e764995](https://github.com/whopio/whopsdk-ruby/commit/e764995aa75bd2b92fdc29592c81f75afd0abd49))
12
+ * **api:** manual updates ([3539993](https://github.com/whopio/whopsdk-ruby/commit/3539993a158657780bdc730aecb8c3cad3c16d12))
13
+ * **client:** add webhook support ([f1b05ca](https://github.com/whopio/whopsdk-ruby/commit/f1b05ca076a06579625ec9c3a78dc96b59d867fd))
14
+
3
15
  ## 0.0.31 (2026-03-10)
4
16
 
5
17
  Full Changelog: [v0.0.30...v0.0.31](https://github.com/whopio/whopsdk-ruby/compare/v0.0.30...v0.0.31)
data/README.md CHANGED
@@ -26,7 +26,7 @@ To use this gem, install via Bundler by adding the following to your application
26
26
  <!-- x-release-please-start-version -->
27
27
 
28
28
  ```ruby
29
- gem "whop_sdk", "~> 0.0.31"
29
+ gem "whop_sdk", "~> 0.0.32"
30
30
  ```
31
31
 
32
32
  <!-- x-release-please-end -->
@@ -21,6 +21,9 @@ module WhopSDK
21
21
  # @return [String]
22
22
  attr_reader :api_key
23
23
 
24
+ # @return [String, nil]
25
+ attr_reader :webhook_key
26
+
24
27
  # When using the SDK in app mode pass this parameter to allow verifying user
25
28
  # tokens
26
29
  # @return [String, nil]
@@ -226,6 +229,10 @@ module WhopSDK
226
229
  # @return [WhopSDK::Resources::DisputeAlerts]
227
230
  attr_reader :dispute_alerts
228
231
 
232
+ # Resolution center cases
233
+ # @return [WhopSDK::Resources::ResolutionCenterCases]
234
+ attr_reader :resolution_center_cases
235
+
229
236
  # @api private
230
237
  #
231
238
  # @return [Hash{String=>String}]
@@ -241,6 +248,8 @@ module WhopSDK
241
248
  # must prepend your key/token with the word 'Bearer', which will look like
242
249
  # `Bearer ***************************` Defaults to `ENV["WHOP_API_KEY"]`
243
250
  #
251
+ # @param webhook_key [String, nil] Defaults to `ENV["WHOP_WEBHOOK_SECRET"]`
252
+ #
244
253
  # @param app_id [String, nil] When using the SDK in app mode pass this parameter to allow verifying user
245
254
  # tokens Defaults to `ENV["WHOP_APP_ID"]`
246
255
  #
@@ -256,6 +265,7 @@ module WhopSDK
256
265
  # @param max_retry_delay [Float]
257
266
  def initialize(
258
267
  api_key: ENV["WHOP_API_KEY"],
268
+ webhook_key: ENV["WHOP_WEBHOOK_SECRET"],
259
269
  app_id: ENV["WHOP_APP_ID"],
260
270
  base_url: ENV["WHOP_BASE_URL"],
261
271
  max_retries: self.class::DEFAULT_MAX_RETRIES,
@@ -274,6 +284,7 @@ module WhopSDK
274
284
  }
275
285
 
276
286
  @api_key = api_key.to_s
287
+ @webhook_key = webhook_key&.to_s
277
288
 
278
289
  super(
279
290
  base_url: base_url,
@@ -334,6 +345,7 @@ module WhopSDK
334
345
  @ai_chats = WhopSDK::Resources::AIChats.new(client: self)
335
346
  @dm_channels = WhopSDK::Resources::DmChannels.new(client: self)
336
347
  @dispute_alerts = WhopSDK::Resources::DisputeAlerts.new(client: self)
348
+ @resolution_center_cases = WhopSDK::Resources::ResolutionCenterCases.new(client: self)
337
349
  end
338
350
 
339
351
  # Verifies a Whop user token
@@ -31,7 +31,13 @@ module WhopSDK
31
31
  # @return [Integer, nil]
32
32
  optional :last, Integer, nil?: true
33
33
 
34
- # @!method initialize(after: nil, before: nil, first: nil, last: nil, request_options: {})
34
+ # @!attribute only_active_crons
35
+ # When true, returns only chats with an active cron schedule
36
+ #
37
+ # @return [Boolean, nil]
38
+ optional :only_active_crons, WhopSDK::Internal::Type::Boolean, nil?: true
39
+
40
+ # @!method initialize(after: nil, before: nil, first: nil, last: nil, only_active_crons: nil, request_options: {})
35
41
  # @param after [String, nil] Returns the elements in the list that come after the specified cursor.
36
42
  #
37
43
  # @param before [String, nil] Returns the elements in the list that come before the specified cursor.
@@ -40,6 +46,8 @@ module WhopSDK
40
46
  #
41
47
  # @param last [Integer, nil] Returns the last _n_ elements from the list.
42
48
  #
49
+ # @param only_active_crons [Boolean, nil] When true, returns only chats with an active cron schedule
50
+ #
43
51
  # @param request_options [WhopSDK::RequestOptions, Hash{Symbol=>Object}]
44
52
  end
45
53
  end
@@ -3,7 +3,7 @@
3
3
  module WhopSDK
4
4
  module Models
5
5
  # @see WhopSDK::Resources::AuthorizedUsers#create
6
- class AuthorizedUserCreateResponse < WhopSDK::Internal::Type::BaseModel
6
+ class AuthorizedUser < WhopSDK::Internal::Type::BaseModel
7
7
  # @!attribute id
8
8
  # The unique identifier for the authorized user.
9
9
  #
@@ -13,8 +13,8 @@ module WhopSDK
13
13
  # @!attribute company
14
14
  # The company this authorized user has access to.
15
15
  #
16
- # @return [WhopSDK::Models::AuthorizedUserCreateResponse::Company]
17
- required :company, -> { WhopSDK::Models::AuthorizedUserCreateResponse::Company }
16
+ # @return [WhopSDK::Models::AuthorizedUser::Company]
17
+ required :company, -> { WhopSDK::AuthorizedUser::Company }
18
18
 
19
19
  # @!attribute role
20
20
  # The permission role assigned to this authorized user within the company.
@@ -25,8 +25,8 @@ module WhopSDK
25
25
  # @!attribute user
26
26
  # The user account linked to this authorized user record.
27
27
  #
28
- # @return [WhopSDK::Models::AuthorizedUserCreateResponse::User]
29
- required :user, -> { WhopSDK::Models::AuthorizedUserCreateResponse::User }
28
+ # @return [WhopSDK::Models::AuthorizedUser::User]
29
+ required :user, -> { WhopSDK::AuthorizedUser::User }
30
30
 
31
31
  # @!method initialize(id:, company:, role:, user:)
32
32
  # A user who has been granted administrative access to manage a company's
@@ -34,13 +34,13 @@ module WhopSDK
34
34
  #
35
35
  # @param id [String] The unique identifier for the authorized user.
36
36
  #
37
- # @param company [WhopSDK::Models::AuthorizedUserCreateResponse::Company] The company this authorized user has access to.
37
+ # @param company [WhopSDK::Models::AuthorizedUser::Company] The company this authorized user has access to.
38
38
  #
39
39
  # @param role [Symbol, WhopSDK::Models::AuthorizedUserRoles] The permission role assigned to this authorized user within the company.
40
40
  #
41
- # @param user [WhopSDK::Models::AuthorizedUserCreateResponse::User] The user account linked to this authorized user record.
41
+ # @param user [WhopSDK::Models::AuthorizedUser::User] The user account linked to this authorized user record.
42
42
 
43
- # @see WhopSDK::Models::AuthorizedUserCreateResponse#company
43
+ # @see WhopSDK::Models::AuthorizedUser#company
44
44
  class Company < WhopSDK::Internal::Type::BaseModel
45
45
  # @!attribute id
46
46
  # The unique identifier for the company.
@@ -62,7 +62,7 @@ module WhopSDK
62
62
  # @param title [String] The display name of the company shown to customers.
63
63
  end
64
64
 
65
- # @see WhopSDK::Models::AuthorizedUserCreateResponse#user
65
+ # @see WhopSDK::Models::AuthorizedUser#user
66
66
  class User < WhopSDK::Internal::Type::BaseModel
67
67
  # @!attribute id
68
68
  # The unique identifier for the user.
@@ -91,7 +91,7 @@ module WhopSDK
91
91
 
92
92
  # @!method initialize(id:, email:, name:, username:)
93
93
  # Some parameter documentations has been truncated, see
94
- # {WhopSDK::Models::AuthorizedUserCreateResponse::User} for more details.
94
+ # {WhopSDK::Models::AuthorizedUser::User} for more details.
95
95
  #
96
96
  # The user account linked to this authorized user record.
97
97
  #
@@ -932,9 +932,9 @@ module WhopSDK
932
932
  # @!attribute customer_response_actions
933
933
  # The list of actions currently available to the customer.
934
934
  #
935
- # @return [Array<Symbol, WhopSDK::Models::Payment::Resolution::CustomerResponseAction>]
935
+ # @return [Array<Symbol, WhopSDK::Models::ResolutionCenterCaseCustomerResponse>]
936
936
  required :customer_response_actions,
937
- -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::Payment::Resolution::CustomerResponseAction] }
937
+ -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::ResolutionCenterCaseCustomerResponse] }
938
938
 
939
939
  # @!attribute due_date
940
940
  # The deadline by which the next response is required. Null if no deadline is
@@ -946,8 +946,8 @@ module WhopSDK
946
946
  # @!attribute issue
947
947
  # The category of the dispute.
948
948
  #
949
- # @return [Symbol, WhopSDK::Models::Payment::Resolution::Issue]
950
- required :issue, enum: -> { WhopSDK::Payment::Resolution::Issue }
949
+ # @return [Symbol, WhopSDK::Models::ResolutionCenterCaseIssueType]
950
+ required :issue, enum: -> { WhopSDK::ResolutionCenterCaseIssueType }
951
951
 
952
952
  # @!attribute merchant_appealed
953
953
  # Whether the merchant has filed an appeal after the initial resolution decision.
@@ -958,125 +958,49 @@ module WhopSDK
958
958
  # @!attribute merchant_response_actions
959
959
  # The list of actions currently available to the merchant.
960
960
  #
961
- # @return [Array<Symbol, WhopSDK::Models::Payment::Resolution::MerchantResponseAction>]
961
+ # @return [Array<Symbol, WhopSDK::Models::ResolutionCenterCaseMerchantResponse>]
962
962
  required :merchant_response_actions,
963
- -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::Payment::Resolution::MerchantResponseAction] }
963
+ -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::ResolutionCenterCaseMerchantResponse] }
964
964
 
965
965
  # @!attribute platform_response_actions
966
966
  # The list of actions currently available to the Whop platform for moderating this
967
967
  # resolution.
968
968
  #
969
- # @return [Array<Symbol, WhopSDK::Models::Payment::Resolution::PlatformResponseAction>]
969
+ # @return [Array<Symbol, WhopSDK::Models::ResolutionCenterCasePlatformResponse>]
970
970
  required :platform_response_actions,
971
- -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::Payment::Resolution::PlatformResponseAction] }
971
+ -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::ResolutionCenterCasePlatformResponse] }
972
972
 
973
973
  # @!attribute status
974
974
  # The current status of the resolution case, indicating which party needs to
975
975
  # respond or if the case is closed.
976
976
  #
977
- # @return [Symbol, WhopSDK::Models::Payment::Resolution::Status]
978
- required :status, enum: -> { WhopSDK::Payment::Resolution::Status }
977
+ # @return [Symbol, WhopSDK::Models::ResolutionCenterCaseStatus]
978
+ required :status, enum: -> { WhopSDK::ResolutionCenterCaseStatus }
979
979
 
980
980
  # @!method initialize(id:, customer_appealed:, customer_response_actions:, due_date:, issue:, merchant_appealed:, merchant_response_actions:, platform_response_actions:, status:)
981
981
  # Some parameter documentations has been truncated, see
982
982
  # {WhopSDK::Models::Payment::Resolution} for more details.
983
983
  #
984
- # A resolution is a dispute or support case between a buyer and seller, tracking
985
- # the issue, status, and outcome.
984
+ # A resolution center case is a dispute or support case between a user and a
985
+ # company, tracking the issue, status, and outcome.
986
986
  #
987
987
  # @param id [String] The unique identifier for the resolution.
988
988
  #
989
989
  # @param customer_appealed [Boolean] Whether the customer has filed an appeal after the initial resolution decision.
990
990
  #
991
- # @param customer_response_actions [Array<Symbol, WhopSDK::Models::Payment::Resolution::CustomerResponseAction>] The list of actions currently available to the customer.
991
+ # @param customer_response_actions [Array<Symbol, WhopSDK::Models::ResolutionCenterCaseCustomerResponse>] The list of actions currently available to the customer.
992
992
  #
993
993
  # @param due_date [Time, nil] The deadline by which the next response is required. Null if no deadline is curr
994
994
  #
995
- # @param issue [Symbol, WhopSDK::Models::Payment::Resolution::Issue] The category of the dispute.
995
+ # @param issue [Symbol, WhopSDK::Models::ResolutionCenterCaseIssueType] The category of the dispute.
996
996
  #
997
997
  # @param merchant_appealed [Boolean] Whether the merchant has filed an appeal after the initial resolution decision.
998
998
  #
999
- # @param merchant_response_actions [Array<Symbol, WhopSDK::Models::Payment::Resolution::MerchantResponseAction>] The list of actions currently available to the merchant.
999
+ # @param merchant_response_actions [Array<Symbol, WhopSDK::Models::ResolutionCenterCaseMerchantResponse>] The list of actions currently available to the merchant.
1000
1000
  #
1001
- # @param platform_response_actions [Array<Symbol, WhopSDK::Models::Payment::Resolution::PlatformResponseAction>] The list of actions currently available to the Whop platform for moderating this
1001
+ # @param platform_response_actions [Array<Symbol, WhopSDK::Models::ResolutionCenterCasePlatformResponse>] The list of actions currently available to the Whop platform for moderating this
1002
1002
  #
1003
- # @param status [Symbol, WhopSDK::Models::Payment::Resolution::Status] The current status of the resolution case, indicating which party needs to respo
1004
-
1005
- # The types of responses a customer can make to a resolution.
1006
- module CustomerResponseAction
1007
- extend WhopSDK::Internal::Type::Enum
1008
-
1009
- RESPOND = :respond
1010
- APPEAL = :appeal
1011
- WITHDRAW = :withdraw
1012
-
1013
- # @!method self.values
1014
- # @return [Array<Symbol>]
1015
- end
1016
-
1017
- # The category of the dispute.
1018
- #
1019
- # @see WhopSDK::Models::Payment::Resolution#issue
1020
- module Issue
1021
- extend WhopSDK::Internal::Type::Enum
1022
-
1023
- FORGOT_TO_CANCEL = :forgot_to_cancel
1024
- ITEM_NOT_RECEIVED = :item_not_received
1025
- SIGNIFICANTLY_NOT_AS_DESCRIBED = :significantly_not_as_described
1026
- UNAUTHORIZED_TRANSACTION = :unauthorized_transaction
1027
- PRODUCT_UNACCEPTABLE = :product_unacceptable
1028
-
1029
- # @!method self.values
1030
- # @return [Array<Symbol>]
1031
- end
1032
-
1033
- # The types of responses a merchant can make to a resolution.
1034
- module MerchantResponseAction
1035
- extend WhopSDK::Internal::Type::Enum
1036
-
1037
- ACCEPT = :accept
1038
- DENY = :deny
1039
- REQUEST_MORE_INFO = :request_more_info
1040
- APPEAL = :appeal
1041
- RESPOND = :respond
1042
-
1043
- # @!method self.values
1044
- # @return [Array<Symbol>]
1045
- end
1046
-
1047
- # The types of responses the platform can make to a resolution.
1048
- module PlatformResponseAction
1049
- extend WhopSDK::Internal::Type::Enum
1050
-
1051
- REQUEST_BUYER_INFO = :request_buyer_info
1052
- REQUEST_MERCHANT_INFO = :request_merchant_info
1053
- MERCHANT_WINS = :merchant_wins
1054
- PLATFORM_REFUND = :platform_refund
1055
- MERCHANT_REFUND = :merchant_refund
1056
-
1057
- # @!method self.values
1058
- # @return [Array<Symbol>]
1059
- end
1060
-
1061
- # The current status of the resolution case, indicating which party needs to
1062
- # respond or if the case is closed.
1063
- #
1064
- # @see WhopSDK::Models::Payment::Resolution#status
1065
- module Status
1066
- extend WhopSDK::Internal::Type::Enum
1067
-
1068
- MERCHANT_RESPONSE_NEEDED = :merchant_response_needed
1069
- CUSTOMER_RESPONSE_NEEDED = :customer_response_needed
1070
- MERCHANT_INFO_NEEDED = :merchant_info_needed
1071
- CUSTOMER_INFO_NEEDED = :customer_info_needed
1072
- UNDER_PLATFORM_REVIEW = :under_platform_review
1073
- CUSTOMER_WON = :customer_won
1074
- MERCHANT_WON = :merchant_won
1075
- CUSTOMER_WITHDREW = :customer_withdrew
1076
-
1077
- # @!method self.values
1078
- # @return [Array<Symbol>]
1079
- end
1003
+ # @param status [Symbol, WhopSDK::Models::ResolutionCenterCaseStatus] The current status of the resolution case, indicating which party needs to respo
1080
1004
  end
1081
1005
 
1082
1006
  # @see WhopSDK::Models::Payment#user
@@ -114,13 +114,20 @@ module WhopSDK
114
114
  # @return [String, nil]
115
115
  optional :route, String, nil?: true
116
116
 
117
+ # @!attribute send_welcome_message
118
+ # Whether to send an automated welcome message via support chat when a user joins
119
+ # this product. Defaults to true.
120
+ #
121
+ # @return [Boolean, nil]
122
+ optional :send_welcome_message, WhopSDK::Internal::Type::Boolean, nil?: true
123
+
117
124
  # @!attribute visibility
118
125
  # Visibility of a resource
119
126
  #
120
127
  # @return [Symbol, WhopSDK::Models::Visibility, nil]
121
128
  optional :visibility, enum: -> { WhopSDK::Visibility }, nil?: true
122
129
 
123
- # @!method initialize(company_id:, title:, collect_shipping_address: nil, custom_cta: nil, custom_cta_url: nil, custom_statement_descriptor: nil, description: nil, experience_ids: nil, global_affiliate_percentage: nil, global_affiliate_status: nil, headline: nil, member_affiliate_percentage: nil, member_affiliate_status: nil, plan_options: nil, product_tax_code_id: nil, redirect_purchase_url: nil, route: nil, visibility: nil, request_options: {})
130
+ # @!method initialize(company_id:, title:, collect_shipping_address: nil, custom_cta: nil, custom_cta_url: nil, custom_statement_descriptor: nil, description: nil, experience_ids: nil, global_affiliate_percentage: nil, global_affiliate_status: nil, headline: nil, member_affiliate_percentage: nil, member_affiliate_status: nil, plan_options: nil, product_tax_code_id: nil, redirect_purchase_url: nil, route: nil, send_welcome_message: nil, visibility: nil, request_options: {})
124
131
  # Some parameter documentations has been truncated, see
125
132
  # {WhopSDK::Models::ProductCreateParams} for more details.
126
133
  #
@@ -158,6 +165,8 @@ module WhopSDK
158
165
  #
159
166
  # @param route [String, nil] The URL slug for the product's public link.
160
167
  #
168
+ # @param send_welcome_message [Boolean, nil] Whether to send an automated welcome message via support chat when a user joins
169
+ #
161
170
  # @param visibility [Symbol, WhopSDK::Models::Visibility, nil] Visibility of a resource
162
171
  #
163
172
  # @param request_options [WhopSDK::RequestOptions, Hash{Symbol=>Object}]
@@ -103,6 +103,13 @@ module WhopSDK
103
103
  # @return [String, nil]
104
104
  optional :route, String, nil?: true
105
105
 
106
+ # @!attribute send_welcome_message
107
+ # Whether to send an automated welcome message via support chat when a user joins
108
+ # this product.
109
+ #
110
+ # @return [Boolean, nil]
111
+ optional :send_welcome_message, WhopSDK::Internal::Type::Boolean, nil?: true
112
+
106
113
  # @!attribute store_page_config
107
114
  # Layout and display configuration for this product on the company's store page.
108
115
  #
@@ -121,7 +128,7 @@ module WhopSDK
121
128
  # @return [Symbol, WhopSDK::Models::Visibility, nil]
122
129
  optional :visibility, enum: -> { WhopSDK::Visibility }, nil?: true
123
130
 
124
- # @!method initialize(id:, collect_shipping_address: nil, custom_cta: nil, custom_cta_url: nil, custom_statement_descriptor: nil, description: nil, gallery_images: nil, global_affiliate_percentage: nil, global_affiliate_status: nil, headline: nil, member_affiliate_percentage: nil, member_affiliate_status: nil, product_tax_code_id: nil, redirect_purchase_url: nil, route: nil, store_page_config: nil, title: nil, visibility: nil, request_options: {})
131
+ # @!method initialize(id:, collect_shipping_address: nil, custom_cta: nil, custom_cta_url: nil, custom_statement_descriptor: nil, description: nil, gallery_images: nil, global_affiliate_percentage: nil, global_affiliate_status: nil, headline: nil, member_affiliate_percentage: nil, member_affiliate_status: nil, product_tax_code_id: nil, redirect_purchase_url: nil, route: nil, send_welcome_message: nil, store_page_config: nil, title: nil, visibility: nil, request_options: {})
125
132
  # Some parameter documentations has been truncated, see
126
133
  # {WhopSDK::Models::ProductUpdateParams} for more details.
127
134
  #
@@ -155,6 +162,8 @@ module WhopSDK
155
162
  #
156
163
  # @param route [String, nil] The URL slug for the product's public link.
157
164
  #
165
+ # @param send_welcome_message [Boolean, nil] Whether to send an automated welcome message via support chat when a user joins
166
+ #
158
167
  # @param store_page_config [WhopSDK::Models::ProductUpdateParams::StorePageConfig, nil] Layout and display configuration for this product on the company's store page.
159
168
  #
160
169
  # @param title [String, nil] The display name of the product. Maximum 40 characters.
@@ -0,0 +1,17 @@
1
+ # frozen_string_literal: true
2
+
3
+ module WhopSDK
4
+ module Models
5
+ # The types of responses a customer can make to a resolution.
6
+ module ResolutionCenterCaseCustomerResponse
7
+ extend WhopSDK::Internal::Type::Enum
8
+
9
+ RESPOND = :respond
10
+ APPEAL = :appeal
11
+ WITHDRAW = :withdraw
12
+
13
+ # @!method self.values
14
+ # @return [Array<Symbol>]
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,19 @@
1
+ # frozen_string_literal: true
2
+
3
+ module WhopSDK
4
+ module Models
5
+ # The different types of issues a resolution can be
6
+ module ResolutionCenterCaseIssueType
7
+ extend WhopSDK::Internal::Type::Enum
8
+
9
+ FORGOT_TO_CANCEL = :forgot_to_cancel
10
+ ITEM_NOT_RECEIVED = :item_not_received
11
+ SIGNIFICANTLY_NOT_AS_DESCRIBED = :significantly_not_as_described
12
+ UNAUTHORIZED_TRANSACTION = :unauthorized_transaction
13
+ PRODUCT_UNACCEPTABLE = :product_unacceptable
14
+
15
+ # @!method self.values
16
+ # @return [Array<Symbol>]
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,88 @@
1
+ # frozen_string_literal: true
2
+
3
+ module WhopSDK
4
+ module Models
5
+ # @see WhopSDK::Resources::ResolutionCenterCases#list
6
+ class ResolutionCenterCaseListParams < WhopSDK::Internal::Type::BaseModel
7
+ extend WhopSDK::Internal::Type::RequestParameters::Converter
8
+ include WhopSDK::Internal::Type::RequestParameters
9
+
10
+ # @!attribute after
11
+ # Returns the elements in the list that come after the specified cursor.
12
+ #
13
+ # @return [String, nil]
14
+ optional :after, String, nil?: true
15
+
16
+ # @!attribute before
17
+ # Returns the elements in the list that come before the specified cursor.
18
+ #
19
+ # @return [String, nil]
20
+ optional :before, String, nil?: true
21
+
22
+ # @!attribute company_id
23
+ # The unique identifier of the company to list resolution center cases for.
24
+ #
25
+ # @return [String, nil]
26
+ optional :company_id, String, nil?: true
27
+
28
+ # @!attribute created_after
29
+ # Only return cases created after this timestamp.
30
+ #
31
+ # @return [Time, nil]
32
+ optional :created_after, Time, nil?: true
33
+
34
+ # @!attribute created_before
35
+ # Only return cases created before this timestamp.
36
+ #
37
+ # @return [Time, nil]
38
+ optional :created_before, Time, nil?: true
39
+
40
+ # @!attribute direction
41
+ # The direction of the sort.
42
+ #
43
+ # @return [Symbol, WhopSDK::Models::Direction, nil]
44
+ optional :direction, enum: -> { WhopSDK::Direction }, nil?: true
45
+
46
+ # @!attribute first
47
+ # Returns the first _n_ elements from the list.
48
+ #
49
+ # @return [Integer, nil]
50
+ optional :first, Integer, nil?: true
51
+
52
+ # @!attribute last
53
+ # Returns the last _n_ elements from the list.
54
+ #
55
+ # @return [Integer, nil]
56
+ optional :last, Integer, nil?: true
57
+
58
+ # @!attribute statuses
59
+ # Filter by resolution center case status.
60
+ #
61
+ # @return [Array<Symbol, WhopSDK::Models::ResolutionCenterCaseStatus>, nil]
62
+ optional :statuses,
63
+ -> { WhopSDK::Internal::Type::ArrayOf[enum: WhopSDK::ResolutionCenterCaseStatus] },
64
+ nil?: true
65
+
66
+ # @!method initialize(after: nil, before: nil, company_id: nil, created_after: nil, created_before: nil, direction: nil, first: nil, last: nil, statuses: nil, request_options: {})
67
+ # @param after [String, nil] Returns the elements in the list that come after the specified cursor.
68
+ #
69
+ # @param before [String, nil] Returns the elements in the list that come before the specified cursor.
70
+ #
71
+ # @param company_id [String, nil] The unique identifier of the company to list resolution center cases for.
72
+ #
73
+ # @param created_after [Time, nil] Only return cases created after this timestamp.
74
+ #
75
+ # @param created_before [Time, nil] Only return cases created before this timestamp.
76
+ #
77
+ # @param direction [Symbol, WhopSDK::Models::Direction, nil] The direction of the sort.
78
+ #
79
+ # @param first [Integer, nil] Returns the first _n_ elements from the list.
80
+ #
81
+ # @param last [Integer, nil] Returns the last _n_ elements from the list.
82
+ #
83
+ # @param statuses [Array<Symbol, WhopSDK::Models::ResolutionCenterCaseStatus>, nil] Filter by resolution center case status.
84
+ #
85
+ # @param request_options [WhopSDK::RequestOptions, Hash{Symbol=>Object}]
86
+ end
87
+ end
88
+ end