solifyn 1.0.0 → 1.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.
Files changed (155) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +20 -7
  3. data/docs/BalanceApi.md +1 -1
  4. data/docs/CheckoutApi.md +1 -1
  5. data/docs/CheckoutLinksApi.md +1 -1
  6. data/docs/CheckoutSessionDetailsDto.md +3 -1
  7. data/docs/CollectionProductDto.md +12 -0
  8. data/docs/CollectionsApi.md +1 -1
  9. data/docs/CustomersApi.md +1 -1
  10. data/docs/DefaultApi.md +285 -1
  11. data/docs/DeveloperApi.md +1 -1
  12. data/docs/DigitalFileApi.md +1 -1
  13. data/docs/DiscordIntegrationApi.md +135 -0
  14. data/docs/DiscordRolesResponseDto.md +24 -0
  15. data/docs/DiscountsApi.md +1 -1
  16. data/docs/DisputesApi.md +1 -1
  17. data/docs/EntitlementGrantResponseDto.md +54 -0
  18. data/docs/EntitlementGrantsApi.md +289 -0
  19. data/docs/GitHubIntegrationApi.md +145 -0
  20. data/docs/GithubReposResponseDto.md +22 -0
  21. data/docs/LicenseApi.md +1 -1
  22. data/docs/LicenseKeysApi.md +1 -1
  23. data/docs/LicenseKeysClientApi.md +1 -1
  24. data/docs/MetersApi.md +1 -1
  25. data/docs/OrdersApi.md +1 -1
  26. data/docs/Product.md +12 -0
  27. data/docs/ProductAddOnsApi.md +1 -1
  28. data/docs/ProductCreate.md +12 -0
  29. data/docs/ProductUpdate.md +12 -0
  30. data/docs/ProductsApi.md +1 -1
  31. data/docs/RefundRequestsApi.md +1 -1
  32. data/docs/RefundsChargebacksApi.md +1 -1
  33. data/docs/SubscriptionsApi.md +1 -1
  34. data/docs/SyncLoginDto.md +18 -0
  35. data/docs/WebhookApi.md +1 -1
  36. data/docs/WebhookEndpointApi.md +55 -10
  37. data/docs/WebhookEntitlementGrantPayload.md +44 -0
  38. data/git_push.sh +2 -2
  39. data/lib/solifyn/api/default_api.rb +248 -0
  40. data/lib/solifyn/api/{partner_api.rb → discord_integration_api.rb} +32 -19
  41. data/lib/solifyn/api/entitlement_grants_api.rb +271 -0
  42. data/lib/solifyn/api/git_hub_integration_api.rb +137 -0
  43. data/lib/solifyn/api/webhook_endpoint_api.rb +9 -9
  44. data/lib/solifyn/configuration.rb +4 -4
  45. data/lib/solifyn/models/checkout_session_details_dto.rb +16 -4
  46. data/lib/solifyn/models/collection_product_dto.rb +115 -1
  47. data/lib/solifyn/models/{payout_method.rb → discord_roles_response_dto.rb} +41 -34
  48. data/lib/solifyn/models/{withdrawal.rb → entitlement_grant_response_dto.rb} +149 -109
  49. data/lib/solifyn/models/{payout_account.rb → github_repos_response_dto.rb} +31 -24
  50. data/lib/solifyn/models/product.rb +115 -1
  51. data/lib/solifyn/models/product_create.rb +77 -1
  52. data/lib/solifyn/models/product_update.rb +77 -1
  53. data/lib/solifyn/models/{payout_method_list.rb → sync_login_dto.rb} +15 -17
  54. data/lib/solifyn/models/{payout_verification.rb → webhook_entitlement_grant_payload.rb} +118 -41
  55. data/lib/solifyn/version.rb +1 -1
  56. data/lib/solifyn.rb +8 -0
  57. data/spec/api/checkout_api_spec.rb +12 -0
  58. data/spec/api/default_api_spec.rb +59 -11
  59. data/spec/api/developer_api_spec.rb +52 -29
  60. data/spec/api/{partner_api_spec.rb → discord_integration_api_spec.rb} +16 -11
  61. data/spec/api/entitlement_grants_api_spec.rb +83 -0
  62. data/spec/api/git_hub_integration_api_spec.rb +58 -0
  63. data/spec/models/checkout_session_details_dto_spec.rb +6 -0
  64. data/spec/models/collection_product_dto_spec.rb +28 -0
  65. data/spec/models/{payout_method_spec.rb → discord_roles_response_dto_spec.rb} +9 -9
  66. data/spec/models/{withdrawal_spec.rb → entitlement_grant_response_dto_spec.rb} +18 -18
  67. data/spec/models/{payout_account_spec.rb → github_repos_response_dto_spec.rb} +8 -8
  68. data/spec/models/order_spec.rb +6 -0
  69. data/spec/models/product_create_spec.rb +28 -0
  70. data/spec/models/product_spec.rb +28 -0
  71. data/spec/models/product_update_spec.rb +28 -0
  72. data/spec/models/{business_create_spec.rb → sync_login_dto_spec.rb} +7 -7
  73. data/spec/models/{business_spec.rb → webhook_entitlement_grant_payload_spec.rb} +17 -53
  74. metadata +162 -254
  75. data/docs/AffiliateApi.md +0 -845
  76. data/docs/BillingApi.md +0 -68
  77. data/docs/BrandsApi.md +0 -286
  78. data/docs/Business.md +0 -56
  79. data/docs/BusinessCreate.md +0 -18
  80. data/docs/BusinessFullCreate.md +0 -26
  81. data/docs/BusinessFullCreateResponse.md +0 -20
  82. data/docs/BusinessesApi.md +0 -350
  83. data/docs/ChatApi.md +0 -246
  84. data/docs/CommunityApi.md +0 -497
  85. data/docs/PartnerApi.md +0 -125
  86. data/docs/PayoutAccessToken.md +0 -20
  87. data/docs/PayoutAccount.md +0 -22
  88. data/docs/PayoutAccountLink.md +0 -20
  89. data/docs/PayoutMethod.md +0 -24
  90. data/docs/PayoutMethodList.md +0 -18
  91. data/docs/PayoutVerification.md +0 -24
  92. data/docs/PayoutVerificationList.md +0 -18
  93. data/docs/PayoutsApi.md +0 -579
  94. data/docs/TicketApi.md +0 -318
  95. data/docs/UserPage.md +0 -26
  96. data/docs/UserProfileThemesApi.md +0 -345
  97. data/docs/UserSettings.md +0 -34
  98. data/docs/UserSettingsUpdate.md +0 -76
  99. data/docs/UserStats.md +0 -20
  100. data/docs/UserTheme.md +0 -26
  101. data/docs/UserThemeUpdate.md +0 -22
  102. data/docs/WhopApiKeysRotation.md +0 -18
  103. data/docs/Withdrawal.md +0 -46
  104. data/docs/WithdrawalCreate.md +0 -22
  105. data/docs/WithdrawalList.md +0 -20
  106. data/lib/solifyn/api/affiliate_api.rb +0 -760
  107. data/lib/solifyn/api/billing_api.rb +0 -77
  108. data/lib/solifyn/api/brands_api.rb +0 -284
  109. data/lib/solifyn/api/businesses_api.rb +0 -338
  110. data/lib/solifyn/api/chat_api.rb +0 -232
  111. data/lib/solifyn/api/community_api.rb +0 -466
  112. data/lib/solifyn/api/payouts_api.rb +0 -520
  113. data/lib/solifyn/api/ticket_api.rb +0 -328
  114. data/lib/solifyn/api/user_profile_themes_api.rb +0 -313
  115. data/lib/solifyn/models/business.rb +0 -482
  116. data/lib/solifyn/models/business_create.rb +0 -241
  117. data/lib/solifyn/models/business_full_create.rb +0 -288
  118. data/lib/solifyn/models/business_full_create_response.rb +0 -239
  119. data/lib/solifyn/models/payout_access_token.rb +0 -239
  120. data/lib/solifyn/models/payout_account_link.rb +0 -239
  121. data/lib/solifyn/models/payout_verification_list.rb +0 -224
  122. data/lib/solifyn/models/user_page.rb +0 -290
  123. data/lib/solifyn/models/user_settings.rb +0 -337
  124. data/lib/solifyn/models/user_settings_update.rb +0 -505
  125. data/lib/solifyn/models/user_stats.rb +0 -241
  126. data/lib/solifyn/models/user_theme.rb +0 -276
  127. data/lib/solifyn/models/user_theme_update.rb +0 -235
  128. data/lib/solifyn/models/whop_api_keys_rotation.rb +0 -222
  129. data/lib/solifyn/models/withdrawal_create.rb +0 -249
  130. data/lib/solifyn/models/withdrawal_list.rb +0 -241
  131. data/spec/api/affiliate_api_spec.rb +0 -165
  132. data/spec/api/billing_api_spec.rb +0 -46
  133. data/spec/api/brands_api_spec.rb +0 -83
  134. data/spec/api/businesses_api_spec.rb +0 -93
  135. data/spec/api/chat_api_spec.rb +0 -72
  136. data/spec/api/community_api_spec.rb +0 -113
  137. data/spec/api/payouts_api_spec.rb +0 -133
  138. data/spec/api/ticket_api_spec.rb +0 -86
  139. data/spec/api/user_profile_themes_api_spec.rb +0 -91
  140. data/spec/models/business_full_create_response_spec.rb +0 -42
  141. data/spec/models/business_full_create_spec.rb +0 -60
  142. data/spec/models/payout_access_token_spec.rb +0 -42
  143. data/spec/models/payout_account_link_spec.rb +0 -42
  144. data/spec/models/payout_method_list_spec.rb +0 -36
  145. data/spec/models/payout_verification_list_spec.rb +0 -36
  146. data/spec/models/payout_verification_spec.rb +0 -54
  147. data/spec/models/user_page_spec.rb +0 -60
  148. data/spec/models/user_settings_spec.rb +0 -84
  149. data/spec/models/user_settings_update_spec.rb +0 -210
  150. data/spec/models/user_stats_spec.rb +0 -42
  151. data/spec/models/user_theme_spec.rb +0 -60
  152. data/spec/models/user_theme_update_spec.rb +0 -48
  153. data/spec/models/whop_api_keys_rotation_spec.rb +0 -36
  154. data/spec/models/withdrawal_create_spec.rb +0 -48
  155. data/spec/models/withdrawal_list_spec.rb +0 -42
@@ -52,6 +52,24 @@ module Solifyn
52
52
  # Whether the product includes digital file downloads upon purchase.
53
53
  attr_accessor :has_digital_delivery
54
54
 
55
+ # Whether the product includes GitHub repository access.
56
+ attr_accessor :has_github_access
57
+
58
+ # GitHub repository to grant access to (format: owner/repo).
59
+ attr_accessor :github_repo
60
+
61
+ # GitHub collaborator permission level.
62
+ attr_accessor :github_permission
63
+
64
+ # Whether the product includes Discord role access.
65
+ attr_accessor :has_discord_access
66
+
67
+ # Discord Guild (Server) ID to grant access to.
68
+ attr_accessor :discord_guild_id
69
+
70
+ # Discord Role ID to assign to the user.
71
+ attr_accessor :discord_role_id
72
+
55
73
  # Whether the product price already includes applicable sales taxes.
56
74
  attr_accessor :is_tax_inclusive
57
75
 
@@ -152,6 +170,12 @@ module Solifyn
152
170
  :'discount' => :'discount',
153
171
  :'has_license_key' => :'hasLicenseKey',
154
172
  :'has_digital_delivery' => :'hasDigitalDelivery',
173
+ :'has_github_access' => :'hasGithubAccess',
174
+ :'github_repo' => :'githubRepo',
175
+ :'github_permission' => :'githubPermission',
176
+ :'has_discord_access' => :'hasDiscordAccess',
177
+ :'discord_guild_id' => :'discordGuildId',
178
+ :'discord_role_id' => :'discordRoleId',
155
179
  :'is_tax_inclusive' => :'isTaxInclusive',
156
180
  :'billing_period' => :'billingPeriod',
157
181
  :'trial_period_days' => :'trialPeriodDays',
@@ -196,6 +220,12 @@ module Solifyn
196
220
  :'discount' => :'Float',
197
221
  :'has_license_key' => :'Boolean',
198
222
  :'has_digital_delivery' => :'Boolean',
223
+ :'has_github_access' => :'Boolean',
224
+ :'github_repo' => :'String',
225
+ :'github_permission' => :'String',
226
+ :'has_discord_access' => :'Boolean',
227
+ :'discord_guild_id' => :'String',
228
+ :'discord_role_id' => :'String',
199
229
  :'is_tax_inclusive' => :'Boolean',
200
230
  :'billing_period' => :'Integer',
201
231
  :'trial_period_days' => :'Integer',
@@ -311,6 +341,42 @@ module Solifyn
311
341
  self.has_digital_delivery = nil
312
342
  end
313
343
 
344
+ if attributes.key?(:'has_github_access')
345
+ self.has_github_access = attributes[:'has_github_access']
346
+ else
347
+ self.has_github_access = nil
348
+ end
349
+
350
+ if attributes.key?(:'github_repo')
351
+ self.github_repo = attributes[:'github_repo']
352
+ else
353
+ self.github_repo = nil
354
+ end
355
+
356
+ if attributes.key?(:'github_permission')
357
+ self.github_permission = attributes[:'github_permission']
358
+ else
359
+ self.github_permission = nil
360
+ end
361
+
362
+ if attributes.key?(:'has_discord_access')
363
+ self.has_discord_access = attributes[:'has_discord_access']
364
+ else
365
+ self.has_discord_access = nil
366
+ end
367
+
368
+ if attributes.key?(:'discord_guild_id')
369
+ self.discord_guild_id = attributes[:'discord_guild_id']
370
+ else
371
+ self.discord_guild_id = nil
372
+ end
373
+
374
+ if attributes.key?(:'discord_role_id')
375
+ self.discord_role_id = attributes[:'discord_role_id']
376
+ else
377
+ self.discord_role_id = nil
378
+ end
379
+
314
380
  if attributes.key?(:'is_tax_inclusive')
315
381
  self.is_tax_inclusive = attributes[:'is_tax_inclusive']
316
382
  else
@@ -491,6 +557,30 @@ module Solifyn
491
557
  invalid_properties.push('invalid value for "has_digital_delivery", has_digital_delivery cannot be nil.')
492
558
  end
493
559
 
560
+ if @has_github_access.nil?
561
+ invalid_properties.push('invalid value for "has_github_access", has_github_access cannot be nil.')
562
+ end
563
+
564
+ if @github_repo.nil?
565
+ invalid_properties.push('invalid value for "github_repo", github_repo cannot be nil.')
566
+ end
567
+
568
+ if @github_permission.nil?
569
+ invalid_properties.push('invalid value for "github_permission", github_permission cannot be nil.')
570
+ end
571
+
572
+ if @has_discord_access.nil?
573
+ invalid_properties.push('invalid value for "has_discord_access", has_discord_access cannot be nil.')
574
+ end
575
+
576
+ if @discord_guild_id.nil?
577
+ invalid_properties.push('invalid value for "discord_guild_id", discord_guild_id cannot be nil.')
578
+ end
579
+
580
+ if @discord_role_id.nil?
581
+ invalid_properties.push('invalid value for "discord_role_id", discord_role_id cannot be nil.')
582
+ end
583
+
494
584
  if @is_tax_inclusive.nil?
495
585
  invalid_properties.push('invalid value for "is_tax_inclusive", is_tax_inclusive cannot be nil.')
496
586
  end
@@ -597,6 +687,14 @@ module Solifyn
597
687
  return false if @discount.nil?
598
688
  return false if @has_license_key.nil?
599
689
  return false if @has_digital_delivery.nil?
690
+ return false if @has_github_access.nil?
691
+ return false if @github_repo.nil?
692
+ return false if @github_permission.nil?
693
+ github_permission_validator = EnumAttributeValidator.new('String', ["pull", "triage", "push", "maintain", "admin"])
694
+ return false unless github_permission_validator.valid?(@github_permission)
695
+ return false if @has_discord_access.nil?
696
+ return false if @discord_guild_id.nil?
697
+ return false if @discord_role_id.nil?
600
698
  return false if @is_tax_inclusive.nil?
601
699
  return false if @billing_period.nil?
602
700
  return false if @trial_period_days.nil?
@@ -641,6 +739,16 @@ module Solifyn
641
739
  @pricing_type = pricing_type
642
740
  end
643
741
 
742
+ # Custom attribute writer method checking allowed values (enum).
743
+ # @param [Object] github_permission Object to be assigned
744
+ def github_permission=(github_permission)
745
+ validator = EnumAttributeValidator.new('String', ["pull", "triage", "push", "maintain", "admin"])
746
+ unless validator.valid?(github_permission)
747
+ fail ArgumentError, "invalid value for \"github_permission\", must be one of #{validator.allowable_values}."
748
+ end
749
+ @github_permission = github_permission
750
+ end
751
+
644
752
  # Checks equality by comparing each attribute.
645
753
  # @param [Object] Object to be compared
646
754
  def ==(o)
@@ -658,6 +766,12 @@ module Solifyn
658
766
  discount == o.discount &&
659
767
  has_license_key == o.has_license_key &&
660
768
  has_digital_delivery == o.has_digital_delivery &&
769
+ has_github_access == o.has_github_access &&
770
+ github_repo == o.github_repo &&
771
+ github_permission == o.github_permission &&
772
+ has_discord_access == o.has_discord_access &&
773
+ discord_guild_id == o.discord_guild_id &&
774
+ discord_role_id == o.discord_role_id &&
661
775
  is_tax_inclusive == o.is_tax_inclusive &&
662
776
  billing_period == o.billing_period &&
663
777
  trial_period_days == o.trial_period_days &&
@@ -690,7 +804,7 @@ module Solifyn
690
804
  # Calculates hash code according to all attributes.
691
805
  # @return [Integer] Hash code
692
806
  def hash
693
- [id, name, price, currency, description, status, image_url, tax_category, pricing_type, discount, has_license_key, has_digital_delivery, is_tax_inclusive, billing_period, trial_period_days, expiration_days, statement_descriptor, pay_what_you_want, metadata, custom_fields, stock, activation_limit, is_listed, is_free, created_at, updated_at, is_permanently_deleted, brand_id, digital_link, instructions, activation_message, expiry_hours, business_id].hash
807
+ [id, name, price, currency, description, status, image_url, tax_category, pricing_type, discount, has_license_key, has_digital_delivery, has_github_access, github_repo, github_permission, has_discord_access, discord_guild_id, discord_role_id, is_tax_inclusive, billing_period, trial_period_days, expiration_days, statement_descriptor, pay_what_you_want, metadata, custom_fields, stock, activation_limit, is_listed, is_free, created_at, updated_at, is_permanently_deleted, brand_id, digital_link, instructions, activation_message, expiry_hours, business_id].hash
694
808
  end
695
809
 
696
810
  # Builds the object from hash
@@ -42,6 +42,24 @@ module Solifyn
42
42
  # Whether the purchase includes downloadable files.
43
43
  attr_accessor :has_digital_delivery
44
44
 
45
+ # Whether the purchase includes GitHub repository access.
46
+ attr_accessor :has_github_access
47
+
48
+ # GitHub repository to grant access to (format: owner/repo).
49
+ attr_accessor :github_repo
50
+
51
+ # GitHub collaborator permission level.
52
+ attr_accessor :github_permission
53
+
54
+ # Whether the purchase includes Discord server role access.
55
+ attr_accessor :has_discord_access
56
+
57
+ # Discord Guild (Server) ID to grant access to.
58
+ attr_accessor :discord_guild_id
59
+
60
+ # Discord Role ID to assign to the user.
61
+ attr_accessor :discord_role_id
62
+
45
63
  # Whether tax is included in the base price.
46
64
  attr_accessor :is_tax_inclusive
47
65
 
@@ -118,6 +136,12 @@ module Solifyn
118
136
  :'discount' => :'discount',
119
137
  :'has_license_key' => :'hasLicenseKey',
120
138
  :'has_digital_delivery' => :'hasDigitalDelivery',
139
+ :'has_github_access' => :'hasGithubAccess',
140
+ :'github_repo' => :'githubRepo',
141
+ :'github_permission' => :'githubPermission',
142
+ :'has_discord_access' => :'hasDiscordAccess',
143
+ :'discord_guild_id' => :'discordGuildId',
144
+ :'discord_role_id' => :'discordRoleId',
121
145
  :'is_tax_inclusive' => :'isTaxInclusive',
122
146
  :'activation_limit' => :'activationLimit',
123
147
  :'brand_id' => :'brandId',
@@ -152,6 +176,12 @@ module Solifyn
152
176
  :'discount' => :'Float',
153
177
  :'has_license_key' => :'Boolean',
154
178
  :'has_digital_delivery' => :'Boolean',
179
+ :'has_github_access' => :'Boolean',
180
+ :'github_repo' => :'String',
181
+ :'github_permission' => :'String',
182
+ :'has_discord_access' => :'Boolean',
183
+ :'discord_guild_id' => :'String',
184
+ :'discord_role_id' => :'String',
155
185
  :'is_tax_inclusive' => :'Boolean',
156
186
  :'activation_limit' => :'Integer',
157
187
  :'brand_id' => :'String',
@@ -238,6 +268,34 @@ module Solifyn
238
268
  self.has_digital_delivery = false
239
269
  end
240
270
 
271
+ if attributes.key?(:'has_github_access')
272
+ self.has_github_access = attributes[:'has_github_access']
273
+ else
274
+ self.has_github_access = false
275
+ end
276
+
277
+ if attributes.key?(:'github_repo')
278
+ self.github_repo = attributes[:'github_repo']
279
+ end
280
+
281
+ if attributes.key?(:'github_permission')
282
+ self.github_permission = attributes[:'github_permission']
283
+ end
284
+
285
+ if attributes.key?(:'has_discord_access')
286
+ self.has_discord_access = attributes[:'has_discord_access']
287
+ else
288
+ self.has_discord_access = false
289
+ end
290
+
291
+ if attributes.key?(:'discord_guild_id')
292
+ self.discord_guild_id = attributes[:'discord_guild_id']
293
+ end
294
+
295
+ if attributes.key?(:'discord_role_id')
296
+ self.discord_role_id = attributes[:'discord_role_id']
297
+ end
298
+
241
299
  if attributes.key?(:'is_tax_inclusive')
242
300
  self.is_tax_inclusive = attributes[:'is_tax_inclusive']
243
301
  else
@@ -345,6 +403,8 @@ module Solifyn
345
403
  return false if @tax_category.nil?
346
404
  tax_category_validator = EnumAttributeValidator.new('String', ["digital_products", "saas", "physical_products", "service"])
347
405
  return false unless tax_category_validator.valid?(@tax_category)
406
+ github_permission_validator = EnumAttributeValidator.new('String', ["pull", "triage", "push", "maintain", "admin"])
407
+ return false unless github_permission_validator.valid?(@github_permission)
348
408
  true
349
409
  end
350
410
 
@@ -368,6 +428,16 @@ module Solifyn
368
428
  @tax_category = tax_category
369
429
  end
370
430
 
431
+ # Custom attribute writer method checking allowed values (enum).
432
+ # @param [Object] github_permission Object to be assigned
433
+ def github_permission=(github_permission)
434
+ validator = EnumAttributeValidator.new('String', ["pull", "triage", "push", "maintain", "admin"])
435
+ unless validator.valid?(github_permission)
436
+ fail ArgumentError, "invalid value for \"github_permission\", must be one of #{validator.allowable_values}."
437
+ end
438
+ @github_permission = github_permission
439
+ end
440
+
371
441
  # Checks equality by comparing each attribute.
372
442
  # @param [Object] Object to be compared
373
443
  def ==(o)
@@ -382,6 +452,12 @@ module Solifyn
382
452
  discount == o.discount &&
383
453
  has_license_key == o.has_license_key &&
384
454
  has_digital_delivery == o.has_digital_delivery &&
455
+ has_github_access == o.has_github_access &&
456
+ github_repo == o.github_repo &&
457
+ github_permission == o.github_permission &&
458
+ has_discord_access == o.has_discord_access &&
459
+ discord_guild_id == o.discord_guild_id &&
460
+ discord_role_id == o.discord_role_id &&
385
461
  is_tax_inclusive == o.is_tax_inclusive &&
386
462
  activation_limit == o.activation_limit &&
387
463
  brand_id == o.brand_id &&
@@ -407,7 +483,7 @@ module Solifyn
407
483
  # Calculates hash code according to all attributes.
408
484
  # @return [Integer] Hash code
409
485
  def hash
410
- [name, description, price, currency, image_url, tax_category, discount, has_license_key, has_digital_delivery, is_tax_inclusive, activation_limit, brand_id, billing_period, trial_period_days, expiration_days, statement_descriptor, pay_what_you_want, metadata, custom_fields, stock, is_listed, is_free, addons].hash
486
+ [name, description, price, currency, image_url, tax_category, discount, has_license_key, has_digital_delivery, has_github_access, github_repo, github_permission, has_discord_access, discord_guild_id, discord_role_id, is_tax_inclusive, activation_limit, brand_id, billing_period, trial_period_days, expiration_days, statement_descriptor, pay_what_you_want, metadata, custom_fields, stock, is_listed, is_free, addons].hash
411
487
  end
412
488
 
413
489
  # Builds the object from hash
@@ -42,6 +42,24 @@ module Solifyn
42
42
  # Whether the purchase includes downloadable files.
43
43
  attr_accessor :has_digital_delivery
44
44
 
45
+ # Whether the purchase includes GitHub repository access.
46
+ attr_accessor :has_github_access
47
+
48
+ # GitHub repository to grant access to (format: owner/repo).
49
+ attr_accessor :github_repo
50
+
51
+ # GitHub collaborator permission level.
52
+ attr_accessor :github_permission
53
+
54
+ # Whether the purchase includes Discord server role access.
55
+ attr_accessor :has_discord_access
56
+
57
+ # Discord Guild (Server) ID to grant access to.
58
+ attr_accessor :discord_guild_id
59
+
60
+ # Discord Role ID to assign to the user.
61
+ attr_accessor :discord_role_id
62
+
45
63
  # Whether tax is included in the base price.
46
64
  attr_accessor :is_tax_inclusive
47
65
 
@@ -118,6 +136,12 @@ module Solifyn
118
136
  :'discount' => :'discount',
119
137
  :'has_license_key' => :'hasLicenseKey',
120
138
  :'has_digital_delivery' => :'hasDigitalDelivery',
139
+ :'has_github_access' => :'hasGithubAccess',
140
+ :'github_repo' => :'githubRepo',
141
+ :'github_permission' => :'githubPermission',
142
+ :'has_discord_access' => :'hasDiscordAccess',
143
+ :'discord_guild_id' => :'discordGuildId',
144
+ :'discord_role_id' => :'discordRoleId',
121
145
  :'is_tax_inclusive' => :'isTaxInclusive',
122
146
  :'activation_limit' => :'activationLimit',
123
147
  :'brand_id' => :'brandId',
@@ -152,6 +176,12 @@ module Solifyn
152
176
  :'discount' => :'Float',
153
177
  :'has_license_key' => :'Boolean',
154
178
  :'has_digital_delivery' => :'Boolean',
179
+ :'has_github_access' => :'Boolean',
180
+ :'github_repo' => :'String',
181
+ :'github_permission' => :'String',
182
+ :'has_discord_access' => :'Boolean',
183
+ :'discord_guild_id' => :'String',
184
+ :'discord_role_id' => :'String',
155
185
  :'is_tax_inclusive' => :'Boolean',
156
186
  :'activation_limit' => :'Integer',
157
187
  :'brand_id' => :'String',
@@ -232,6 +262,34 @@ module Solifyn
232
262
  self.has_digital_delivery = false
233
263
  end
234
264
 
265
+ if attributes.key?(:'has_github_access')
266
+ self.has_github_access = attributes[:'has_github_access']
267
+ else
268
+ self.has_github_access = false
269
+ end
270
+
271
+ if attributes.key?(:'github_repo')
272
+ self.github_repo = attributes[:'github_repo']
273
+ end
274
+
275
+ if attributes.key?(:'github_permission')
276
+ self.github_permission = attributes[:'github_permission']
277
+ end
278
+
279
+ if attributes.key?(:'has_discord_access')
280
+ self.has_discord_access = attributes[:'has_discord_access']
281
+ else
282
+ self.has_discord_access = false
283
+ end
284
+
285
+ if attributes.key?(:'discord_guild_id')
286
+ self.discord_guild_id = attributes[:'discord_guild_id']
287
+ end
288
+
289
+ if attributes.key?(:'discord_role_id')
290
+ self.discord_role_id = attributes[:'discord_role_id']
291
+ end
292
+
235
293
  if attributes.key?(:'is_tax_inclusive')
236
294
  self.is_tax_inclusive = attributes[:'is_tax_inclusive']
237
295
  else
@@ -319,6 +377,8 @@ module Solifyn
319
377
  return false unless currency_validator.valid?(@currency)
320
378
  tax_category_validator = EnumAttributeValidator.new('String', ["digital_products", "saas", "physical_products", "service"])
321
379
  return false unless tax_category_validator.valid?(@tax_category)
380
+ github_permission_validator = EnumAttributeValidator.new('String', ["pull", "triage", "push", "maintain", "admin"])
381
+ return false unless github_permission_validator.valid?(@github_permission)
322
382
  true
323
383
  end
324
384
 
@@ -342,6 +402,16 @@ module Solifyn
342
402
  @tax_category = tax_category
343
403
  end
344
404
 
405
+ # Custom attribute writer method checking allowed values (enum).
406
+ # @param [Object] github_permission Object to be assigned
407
+ def github_permission=(github_permission)
408
+ validator = EnumAttributeValidator.new('String', ["pull", "triage", "push", "maintain", "admin"])
409
+ unless validator.valid?(github_permission)
410
+ fail ArgumentError, "invalid value for \"github_permission\", must be one of #{validator.allowable_values}."
411
+ end
412
+ @github_permission = github_permission
413
+ end
414
+
345
415
  # Checks equality by comparing each attribute.
346
416
  # @param [Object] Object to be compared
347
417
  def ==(o)
@@ -356,6 +426,12 @@ module Solifyn
356
426
  discount == o.discount &&
357
427
  has_license_key == o.has_license_key &&
358
428
  has_digital_delivery == o.has_digital_delivery &&
429
+ has_github_access == o.has_github_access &&
430
+ github_repo == o.github_repo &&
431
+ github_permission == o.github_permission &&
432
+ has_discord_access == o.has_discord_access &&
433
+ discord_guild_id == o.discord_guild_id &&
434
+ discord_role_id == o.discord_role_id &&
359
435
  is_tax_inclusive == o.is_tax_inclusive &&
360
436
  activation_limit == o.activation_limit &&
361
437
  brand_id == o.brand_id &&
@@ -381,7 +457,7 @@ module Solifyn
381
457
  # Calculates hash code according to all attributes.
382
458
  # @return [Integer] Hash code
383
459
  def hash
384
- [name, description, price, currency, image_url, tax_category, discount, has_license_key, has_digital_delivery, is_tax_inclusive, activation_limit, brand_id, billing_period, trial_period_days, expiration_days, statement_descriptor, pay_what_you_want, metadata, custom_fields, stock, is_listed, is_free, addons].hash
460
+ [name, description, price, currency, image_url, tax_category, discount, has_license_key, has_digital_delivery, has_github_access, github_repo, github_permission, has_discord_access, discord_guild_id, discord_role_id, is_tax_inclusive, activation_limit, brand_id, billing_period, trial_period_days, expiration_days, statement_descriptor, pay_what_you_want, metadata, custom_fields, stock, is_listed, is_free, addons].hash
385
461
  end
386
462
 
387
463
  # Builds the object from hash
@@ -14,14 +14,14 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Solifyn
17
- class PayoutMethodList
18
- # List of payout methods available for the business
19
- attr_accessor :data
17
+ class SyncLoginDto
18
+ # The JWT access token from the Live API server
19
+ attr_accessor :live_token
20
20
 
21
21
  # Attribute mapping from ruby-style variable name to JSON key.
22
22
  def self.attribute_map
23
23
  {
24
- :'data' => :'data'
24
+ :'live_token' => :'liveToken'
25
25
  }
26
26
  end
27
27
 
@@ -33,7 +33,7 @@ module Solifyn
33
33
  # Attribute type mapping.
34
34
  def self.openapi_types
35
35
  {
36
- :'data' => :'Array<PayoutMethod>'
36
+ :'live_token' => :'String'
37
37
  }
38
38
  end
39
39
 
@@ -47,23 +47,21 @@ module Solifyn
47
47
  # @param [Hash] attributes Model attributes in the form of hash
48
48
  def initialize(attributes = {})
49
49
  if (!attributes.is_a?(Hash))
50
- fail ArgumentError, "The input argument (attributes) must be a hash in `Solifyn::PayoutMethodList` initialize method"
50
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Solifyn::SyncLoginDto` initialize method"
51
51
  end
52
52
 
53
53
  # check to see if the attribute exists and convert string to symbol for hash key
54
54
  attributes = attributes.each_with_object({}) { |(k, v), h|
55
55
  if (!self.class.attribute_map.key?(k.to_sym))
56
- fail ArgumentError, "`#{k}` is not a valid attribute in `Solifyn::PayoutMethodList`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Solifyn::SyncLoginDto`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
57
57
  end
58
58
  h[k.to_sym] = v
59
59
  }
60
60
 
61
- if attributes.key?(:'data')
62
- if (value = attributes[:'data']).is_a?(Array)
63
- self.data = value
64
- end
61
+ if attributes.key?(:'live_token')
62
+ self.live_token = attributes[:'live_token']
65
63
  else
66
- self.data = nil
64
+ self.live_token = nil
67
65
  end
68
66
  end
69
67
 
@@ -72,8 +70,8 @@ module Solifyn
72
70
  def list_invalid_properties
73
71
  warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
74
72
  invalid_properties = Array.new
75
- if @data.nil?
76
- invalid_properties.push('invalid value for "data", data cannot be nil.')
73
+ if @live_token.nil?
74
+ invalid_properties.push('invalid value for "live_token", live_token cannot be nil.')
77
75
  end
78
76
 
79
77
  invalid_properties
@@ -83,7 +81,7 @@ module Solifyn
83
81
  # @return true if the model is valid
84
82
  def valid?
85
83
  warn '[DEPRECATED] the `valid?` method is obsolete'
86
- return false if @data.nil?
84
+ return false if @live_token.nil?
87
85
  true
88
86
  end
89
87
 
@@ -92,7 +90,7 @@ module Solifyn
92
90
  def ==(o)
93
91
  return true if self.equal?(o)
94
92
  self.class == o.class &&
95
- data == o.data
93
+ live_token == o.live_token
96
94
  end
97
95
 
98
96
  # @see the `==` method
@@ -104,7 +102,7 @@ module Solifyn
104
102
  # Calculates hash code according to all attributes.
105
103
  # @return [Integer] Hash code
106
104
  def hash
107
- [data].hash
105
+ [live_token].hash
108
106
  end
109
107
 
110
108
  # Builds the object from hash