stigg 0.1.0.pre.alpha.1 → 0.1.0.pre.alpha.3

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 (190) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +22 -0
  3. data/README.md +29 -1
  4. data/lib/stigg/internal/my_cursor_id_page.rb +32 -4
  5. data/lib/stigg/internal/type/base_model.rb +2 -2
  6. data/lib/stigg/models/v1/{coupon_create_response.rb → coupon.rb} +31 -26
  7. data/lib/stigg/models/v1/coupon_create_params.rb +2 -0
  8. data/lib/stigg/models/v1/coupon_list_params.rb +14 -14
  9. data/lib/stigg/models/v1/coupon_list_response.rb +262 -278
  10. data/lib/stigg/models/v1/customer_import_params.rb +75 -0
  11. data/lib/stigg/models/v1/customer_import_response.rb +35 -0
  12. data/lib/stigg/models/v1/customer_list_params.rb +14 -14
  13. data/lib/stigg/models/v1/customer_list_response.rb +160 -174
  14. data/lib/stigg/models/v1/{customer_create_params.rb → customer_provision_params.rb} +18 -16
  15. data/lib/stigg/models/v1/customer_response.rb +9 -2
  16. data/lib/stigg/models/v1/customer_update_params.rb +2 -0
  17. data/lib/stigg/models/v1/customers/payment_method_attach_params.rb +3 -1
  18. data/lib/stigg/models/v1/customers/{promotional_create_params.rb → promotional_entitlement_grant_params.rb} +46 -44
  19. data/lib/stigg/models/v1/customers/{promotional_create_response.rb → promotional_entitlement_grant_response.rb} +105 -32
  20. data/lib/stigg/models/v1/customers/{promotional_revoke_params.rb → promotional_entitlement_revoke_params.rb} +2 -2
  21. data/lib/stigg/models/v1/customers/{promotional_revoke_response.rb → promotional_entitlement_revoke_response.rb} +107 -33
  22. data/lib/stigg/models/v1/event_report_params.rb +91 -0
  23. data/lib/stigg/models/v1/event_report_response.rb +25 -0
  24. data/lib/stigg/models/v1/{subscription_retrieve_response.rb → subscription.rb} +67 -26
  25. data/lib/stigg/models/v1/subscription_cancel_params.rb +75 -0
  26. data/lib/stigg/models/v1/subscription_delegate_params.rb +7 -2
  27. data/lib/stigg/models/v1/subscription_import_params.rb +92 -0
  28. data/lib/stigg/models/v1/subscription_import_response.rb +32 -0
  29. data/lib/stigg/models/v1/subscription_list_params.rb +20 -24
  30. data/lib/stigg/models/v1/subscription_list_response.rb +255 -236
  31. data/lib/stigg/models/v1/subscription_migrate_params.rb +3 -3
  32. data/lib/stigg/models/v1/subscription_preview_params.rb +139 -46
  33. data/lib/stigg/models/v1/subscription_preview_response.rb +164 -49
  34. data/lib/stigg/models/v1/subscription_provision_params.rb +1693 -0
  35. data/lib/stigg/models/v1/subscription_provision_response.rb +1038 -0
  36. data/lib/stigg/models/v1/subscription_transfer_params.rb +2 -6
  37. data/lib/stigg/models/v1/subscription_update_params.rb +1114 -0
  38. data/lib/stigg/models/v1/subscriptions/{future_update_cancel_pending_payment_response.rb → cancel_subscription.rb} +9 -5
  39. data/lib/stigg/models/v1/usage_history_params.rb +54 -0
  40. data/lib/stigg/models/v1/usage_history_response.rb +155 -0
  41. data/lib/stigg/models/v1/usage_report_params.rb +114 -0
  42. data/lib/stigg/models/v1/usage_report_response.rb +120 -0
  43. data/lib/stigg/models.rb +0 -4
  44. data/lib/stigg/resources/v1/coupons.rb +16 -14
  45. data/lib/stigg/resources/v1/customers/payment_method.rb +6 -5
  46. data/lib/stigg/resources/v1/customers/{promotional.rb → promotional_entitlements.rb} +17 -17
  47. data/lib/stigg/resources/v1/customers.rb +78 -56
  48. data/lib/stigg/resources/v1/events.rb +38 -0
  49. data/lib/stigg/resources/v1/subscriptions/future_update.rb +10 -8
  50. data/lib/stigg/resources/v1/subscriptions.rb +206 -79
  51. data/lib/stigg/resources/v1/usage.rb +79 -0
  52. data/lib/stigg/resources/v1.rb +6 -42
  53. data/lib/stigg/version.rb +1 -1
  54. data/lib/stigg.rb +25 -23
  55. data/rbi/stigg/internal/my_cursor_id_page.rbi +27 -0
  56. data/rbi/stigg/models/v1/coupon.rbi +891 -0
  57. data/rbi/stigg/models/v1/coupon_create_params.rbi +1 -0
  58. data/rbi/stigg/models/v1/coupon_list_params.rbi +21 -21
  59. data/rbi/stigg/models/v1/coupon_list_response.rbi +812 -869
  60. data/rbi/stigg/models/v1/customer_import_params.rbi +130 -0
  61. data/rbi/stigg/models/v1/customer_import_response.rbi +76 -0
  62. data/rbi/stigg/models/v1/customer_list_params.rbi +21 -21
  63. data/rbi/stigg/models/v1/customer_list_response.rbi +307 -347
  64. data/rbi/stigg/models/v1/{customer_create_params.rbi → customer_provision_params.rbi} +36 -35
  65. data/rbi/stigg/models/v1/customer_response.rbi +8 -1
  66. data/rbi/stigg/models/v1/customer_update_params.rbi +1 -0
  67. data/rbi/stigg/models/v1/customers/payment_method_attach_params.rbi +3 -0
  68. data/rbi/stigg/models/v1/customers/{promotional_create_params.rbi → promotional_entitlement_grant_params.rbi} +78 -77
  69. data/rbi/stigg/models/v1/customers/promotional_entitlement_grant_response.rbi +690 -0
  70. data/rbi/stigg/models/v1/customers/{promotional_revoke_params.rbi → promotional_entitlement_revoke_params.rbi} +2 -2
  71. data/rbi/stigg/models/v1/customers/promotional_entitlement_revoke_response.rbi +696 -0
  72. data/rbi/stigg/models/v1/event_report_params.rbi +168 -0
  73. data/rbi/stigg/models/v1/event_report_response.rbi +35 -0
  74. data/rbi/stigg/models/v1/{subscription_migrate_response.rbi → subscription.rbi} +130 -98
  75. data/rbi/stigg/models/v1/subscription_cancel_params.rbi +182 -0
  76. data/rbi/stigg/models/v1/subscription_delegate_params.rbi +6 -2
  77. data/rbi/stigg/models/v1/subscription_import_params.rbi +148 -0
  78. data/rbi/stigg/models/v1/subscription_import_response.rbi +69 -0
  79. data/rbi/stigg/models/v1/subscription_list_params.rbi +26 -28
  80. data/rbi/stigg/models/v1/subscription_list_response.rbi +460 -435
  81. data/rbi/stigg/models/v1/subscription_migrate_params.rbi +3 -3
  82. data/rbi/stigg/models/v1/subscription_preview_params.rbi +112 -14
  83. data/rbi/stigg/models/v1/subscription_preview_response.rbi +139 -6
  84. data/rbi/stigg/models/v1/subscription_provision_params.rbi +5306 -0
  85. data/rbi/stigg/models/v1/subscription_provision_response.rbi +3175 -0
  86. data/rbi/stigg/models/v1/subscription_transfer_params.rbi +2 -4
  87. data/rbi/stigg/models/v1/subscription_update_params.rbi +3578 -0
  88. data/rbi/stigg/models/v1/subscriptions/{future_update_cancel_schedule_response.rbi → cancel_subscription.rbi} +10 -16
  89. data/rbi/stigg/models/v1/usage_history_params.rbi +79 -0
  90. data/rbi/stigg/models/v1/usage_history_response.rbi +347 -0
  91. data/rbi/stigg/models/v1/usage_report_params.rbi +227 -0
  92. data/rbi/stigg/models/v1/usage_report_response.rbi +162 -0
  93. data/rbi/stigg/models.rbi +0 -4
  94. data/rbi/stigg/resources/v1/coupons.rbi +22 -14
  95. data/rbi/stigg/resources/v1/customers/payment_method.rbi +9 -3
  96. data/rbi/stigg/resources/v1/customers/{promotional.rbi → promotional_entitlements.rbi} +13 -9
  97. data/rbi/stigg/resources/v1/customers.rbi +84 -53
  98. data/rbi/stigg/resources/v1/events.rbi +28 -0
  99. data/rbi/stigg/resources/v1/subscriptions/future_update.rbi +14 -10
  100. data/rbi/stigg/resources/v1/subscriptions.rbi +242 -58
  101. data/rbi/stigg/resources/v1/usage.rbi +57 -0
  102. data/rbi/stigg/resources/v1.rbi +4 -26
  103. data/sig/stigg/internal/my_cursor_id_page.rbs +17 -0
  104. data/sig/stigg/models/v1/{coupon_create_response.rbs → coupon.rbs} +29 -32
  105. data/sig/stigg/models/v1/coupon_list_params.rbs +11 -11
  106. data/sig/stigg/models/v1/coupon_list_response.rbs +331 -351
  107. data/sig/stigg/models/v1/customer_import_params.rbs +74 -0
  108. data/sig/stigg/models/v1/customer_import_response.rbs +30 -0
  109. data/sig/stigg/models/v1/customer_list_params.rbs +11 -11
  110. data/sig/stigg/models/v1/customer_list_response.rbs +133 -153
  111. data/sig/stigg/models/v1/{customer_create_params.rbs → customer_provision_params.rbs} +22 -22
  112. data/sig/stigg/models/v1/customers/{promotional_create_params.rbs → promotional_entitlement_grant_params.rbs} +43 -43
  113. data/sig/stigg/models/v1/customers/promotional_entitlement_grant_response.rbs +281 -0
  114. data/sig/stigg/models/v1/customers/{promotional_revoke_params.rbs → promotional_entitlement_revoke_params.rbs} +2 -2
  115. data/sig/stigg/models/v1/customers/promotional_entitlement_revoke_response.rbs +281 -0
  116. data/sig/stigg/models/v1/event_report_params.rbs +82 -0
  117. data/sig/stigg/models/v1/event_report_response.rbs +15 -0
  118. data/sig/stigg/models/v1/{subscription_retrieve_response.rbs → subscription.rbs} +61 -35
  119. data/sig/stigg/models/v1/subscription_cancel_params.rbs +79 -0
  120. data/sig/stigg/models/v1/subscription_import_params.rbs +84 -0
  121. data/sig/stigg/models/v1/subscription_import_response.rbs +30 -0
  122. data/sig/stigg/models/v1/subscription_list_params.rbs +14 -14
  123. data/sig/stigg/models/v1/subscription_list_response.rbs +196 -189
  124. data/sig/stigg/models/v1/subscription_preview_params.rbs +2 -6
  125. data/sig/stigg/models/v1/subscription_provision_params.rbs +2223 -0
  126. data/sig/stigg/models/v1/subscription_provision_response.rbs +1305 -0
  127. data/sig/stigg/models/v1/subscription_update_params.rbs +1544 -0
  128. data/sig/stigg/models/v1/subscriptions/cancel_subscription.rbs +34 -0
  129. data/sig/stigg/models/v1/usage_history_params.rbs +52 -0
  130. data/sig/stigg/models/v1/usage_history_response.rbs +129 -0
  131. data/sig/stigg/models/v1/usage_report_params.rbs +102 -0
  132. data/sig/stigg/models/v1/usage_report_response.rbs +87 -0
  133. data/sig/stigg/models.rbs +0 -4
  134. data/sig/stigg/resources/v1/coupons.rbs +5 -5
  135. data/sig/stigg/resources/v1/customers/{promotional.rbs → promotional_entitlements.rbs} +5 -5
  136. data/sig/stigg/resources/v1/customers.rbs +20 -17
  137. data/sig/stigg/resources/v1/events.rbs +14 -0
  138. data/sig/stigg/resources/v1/subscriptions/future_update.rbs +2 -2
  139. data/sig/stigg/resources/v1/subscriptions.rbs +68 -20
  140. data/sig/stigg/resources/v1/usage.rbs +24 -0
  141. data/sig/stigg/resources/v1.rbs +2 -8
  142. metadata +77 -71
  143. data/lib/stigg/models/v1/coupon_retrieve_response.rb +0 -317
  144. data/lib/stigg/models/v1/customers/usage_retrieve_params.rb +0 -56
  145. data/lib/stigg/models/v1/customers/usage_retrieve_response.rb +0 -145
  146. data/lib/stigg/models/v1/subscription_create_params.rb +0 -214
  147. data/lib/stigg/models/v1/subscription_create_response.rb +0 -338
  148. data/lib/stigg/models/v1/subscription_delegate_response.rb +0 -274
  149. data/lib/stigg/models/v1/subscription_migrate_response.rb +0 -274
  150. data/lib/stigg/models/v1/subscription_transfer_response.rb +0 -274
  151. data/lib/stigg/models/v1/subscriptions/future_update_cancel_schedule_response.rb +0 -32
  152. data/lib/stigg/models/v1_create_event_params.rb +0 -87
  153. data/lib/stigg/models/v1_create_event_response.rb +0 -16
  154. data/lib/stigg/models/v1_create_usage_params.rb +0 -96
  155. data/lib/stigg/models/v1_create_usage_response.rb +0 -112
  156. data/lib/stigg/resources/v1/customers/usage.rb +0 -59
  157. data/rbi/stigg/models/v1/coupon_create_response.rbi +0 -986
  158. data/rbi/stigg/models/v1/coupon_retrieve_response.rbi +0 -986
  159. data/rbi/stigg/models/v1/customers/promotional_create_response.rbi +0 -495
  160. data/rbi/stigg/models/v1/customers/promotional_revoke_response.rbi +0 -497
  161. data/rbi/stigg/models/v1/customers/usage_retrieve_params.rbi +0 -84
  162. data/rbi/stigg/models/v1/customers/usage_retrieve_response.rbi +0 -353
  163. data/rbi/stigg/models/v1/subscription_create_params.rbi +0 -394
  164. data/rbi/stigg/models/v1/subscription_create_response.rbi +0 -668
  165. data/rbi/stigg/models/v1/subscription_delegate_response.rbi +0 -535
  166. data/rbi/stigg/models/v1/subscription_retrieve_response.rbi +0 -535
  167. data/rbi/stigg/models/v1/subscription_transfer_response.rbi +0 -535
  168. data/rbi/stigg/models/v1/subscriptions/future_update_cancel_pending_payment_response.rbi +0 -79
  169. data/rbi/stigg/models/v1_create_event_params.rbi +0 -160
  170. data/rbi/stigg/models/v1_create_event_response.rbi +0 -23
  171. data/rbi/stigg/models/v1_create_usage_params.rbi +0 -177
  172. data/rbi/stigg/models/v1_create_usage_response.rbi +0 -150
  173. data/rbi/stigg/resources/v1/customers/usage.rbi +0 -45
  174. data/sig/stigg/models/v1/coupon_retrieve_response.rbs +0 -394
  175. data/sig/stigg/models/v1/customers/promotional_create_response.rbs +0 -209
  176. data/sig/stigg/models/v1/customers/promotional_revoke_response.rbs +0 -209
  177. data/sig/stigg/models/v1/customers/usage_retrieve_params.rbs +0 -54
  178. data/sig/stigg/models/v1/customers/usage_retrieve_response.rbs +0 -134
  179. data/sig/stigg/models/v1/subscription_create_params.rbs +0 -199
  180. data/sig/stigg/models/v1/subscription_create_response.rbs +0 -283
  181. data/sig/stigg/models/v1/subscription_delegate_response.rbs +0 -224
  182. data/sig/stigg/models/v1/subscription_migrate_response.rbs +0 -224
  183. data/sig/stigg/models/v1/subscription_transfer_response.rbs +0 -224
  184. data/sig/stigg/models/v1/subscriptions/future_update_cancel_pending_payment_response.rbs +0 -34
  185. data/sig/stigg/models/v1/subscriptions/future_update_cancel_schedule_response.rbs +0 -34
  186. data/sig/stigg/models/v1_create_event_params.rbs +0 -80
  187. data/sig/stigg/models/v1_create_event_response.rbs +0 -13
  188. data/sig/stigg/models/v1_create_usage_params.rbs +0 -90
  189. data/sig/stigg/models/v1_create_usage_response.rbs +0 -85
  190. data/sig/stigg/resources/v1/customers/usage.rbs +0 -21
@@ -2,25 +2,25 @@ module Stigg
2
2
  module Models
3
3
  module V1
4
4
  module Customers
5
- type promotional_create_params =
5
+ type promotional_entitlement_grant_params =
6
6
  {
7
- promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement]
7
+ promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement]
8
8
  }
9
9
  & Stigg::Internal::Type::request_parameters
10
10
 
11
- class PromotionalCreateParams < Stigg::Internal::Type::BaseModel
11
+ class PromotionalEntitlementGrantParams < Stigg::Internal::Type::BaseModel
12
12
  extend Stigg::Internal::Type::RequestParameters::Converter
13
13
  include Stigg::Internal::Type::RequestParameters
14
14
 
15
- attr_accessor promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement]
15
+ attr_accessor promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement]
16
16
 
17
17
  def initialize: (
18
- promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement],
18
+ promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement],
19
19
  ?request_options: Stigg::request_opts
20
20
  ) -> void
21
21
 
22
22
  def to_hash: -> {
23
- promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement],
23
+ promotional_entitlements: ::Array[Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement],
24
24
  request_options: Stigg::RequestOptions
25
25
  }
26
26
 
@@ -32,12 +32,12 @@ module Stigg
32
32
  has_soft_limit: bool?,
33
33
  has_unlimited_usage: bool?,
34
34
  is_visible: bool?,
35
- monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?,
36
- period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::period,
37
- reset_period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::reset_period?,
35
+ monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?,
36
+ period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::period,
37
+ reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::reset_period?,
38
38
  usage_limit: Integer?,
39
- weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?,
40
- yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
39
+ weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?,
40
+ yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
41
41
  }
42
42
 
43
43
  class PromotionalEntitlement < Stigg::Internal::Type::BaseModel
@@ -53,17 +53,17 @@ module Stigg
53
53
 
54
54
  attr_accessor is_visible: bool?
55
55
 
56
- attr_accessor monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?
56
+ attr_accessor monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?
57
57
 
58
- attr_accessor period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::period
58
+ attr_accessor period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::period
59
59
 
60
- attr_accessor reset_period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::reset_period?
60
+ attr_accessor reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::reset_period?
61
61
 
62
62
  attr_accessor usage_limit: Integer?
63
63
 
64
- attr_accessor weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?
64
+ attr_accessor weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?
65
65
 
66
- attr_accessor yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
66
+ attr_accessor yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
67
67
 
68
68
  def initialize: (
69
69
  custom_end_date: Time?,
@@ -72,12 +72,12 @@ module Stigg
72
72
  has_soft_limit: bool?,
73
73
  has_unlimited_usage: bool?,
74
74
  is_visible: bool?,
75
- monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?,
76
- period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::period,
77
- reset_period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::reset_period?,
75
+ monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?,
76
+ period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::period,
77
+ reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::reset_period?,
78
78
  usage_limit: Integer?,
79
- weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?,
80
- yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
79
+ weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?,
80
+ yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
81
81
  ) -> void
82
82
 
83
83
  def to_hash: -> {
@@ -87,28 +87,28 @@ module Stigg
87
87
  has_soft_limit: bool?,
88
88
  has_unlimited_usage: bool?,
89
89
  is_visible: bool?,
90
- monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?,
91
- period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::period,
92
- reset_period: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::reset_period?,
90
+ monthly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration?,
91
+ period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::period,
92
+ reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::reset_period?,
93
93
  usage_limit: Integer?,
94
- weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?,
95
- yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
94
+ weekly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration?,
95
+ yearly_reset_period_configuration: Stigg::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration?
96
96
  }
97
97
 
98
98
  type monthly_reset_period_configuration =
99
99
  {
100
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
100
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
101
101
  }
102
102
 
103
103
  class MonthlyResetPeriodConfiguration < Stigg::Internal::Type::BaseModel
104
- attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
104
+ attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
105
105
 
106
106
  def initialize: (
107
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
107
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
108
108
  ) -> void
109
109
 
110
110
  def to_hash: -> {
111
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
111
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to
112
112
  }
113
113
 
114
114
  type according_to = :SubscriptionStart | :StartOfTheMonth
@@ -119,7 +119,7 @@ module Stigg
119
119
  SUBSCRIPTION_START: :SubscriptionStart
120
120
  START_OF_THE_MONTH: :StartOfTheMonth
121
121
 
122
- def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to]
122
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::MonthlyResetPeriodConfiguration::according_to]
123
123
  end
124
124
  end
125
125
 
@@ -141,7 +141,7 @@ module Stigg
141
141
  LIFETIME: :lifetime
142
142
  CUSTOM: :custom
143
143
 
144
- def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::period]
144
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::period]
145
145
  end
146
146
 
147
147
  type reset_period = :YEAR | :MONTH | :WEEK | :DAY | :HOUR
@@ -155,23 +155,23 @@ module Stigg
155
155
  DAY: :DAY
156
156
  HOUR: :HOUR
157
157
 
158
- def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::reset_period]
158
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::reset_period]
159
159
  end
160
160
 
161
161
  type weekly_reset_period_configuration =
162
162
  {
163
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
163
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
164
164
  }
165
165
 
166
166
  class WeeklyResetPeriodConfiguration < Stigg::Internal::Type::BaseModel
167
- attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
167
+ attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
168
168
 
169
169
  def initialize: (
170
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
170
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
171
171
  ) -> void
172
172
 
173
173
  def to_hash: -> {
174
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
174
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to
175
175
  }
176
176
 
177
177
  type according_to =
@@ -196,24 +196,24 @@ module Stigg
196
196
  EVERY_FRIDAY: :EveryFriday
197
197
  EVERY_SATURDAY: :EverySaturday
198
198
 
199
- def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to]
199
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::WeeklyResetPeriodConfiguration::according_to]
200
200
  end
201
201
  end
202
202
 
203
203
  type yearly_reset_period_configuration =
204
204
  {
205
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
205
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
206
206
  }
207
207
 
208
208
  class YearlyResetPeriodConfiguration < Stigg::Internal::Type::BaseModel
209
- attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
209
+ attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
210
210
 
211
211
  def initialize: (
212
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
212
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
213
213
  ) -> void
214
214
 
215
215
  def to_hash: -> {
216
- according_to: Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
216
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to
217
217
  }
218
218
 
219
219
  type according_to = :SubscriptionStart
@@ -223,7 +223,7 @@ module Stigg
223
223
 
224
224
  SUBSCRIPTION_START: :SubscriptionStart
225
225
 
226
- def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalCreateParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to]
226
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantParams::PromotionalEntitlement::YearlyResetPeriodConfiguration::according_to]
227
227
  end
228
228
  end
229
229
  end
@@ -0,0 +1,281 @@
1
+ module Stigg
2
+ module Models
3
+ module V1
4
+ module Customers
5
+ type promotional_entitlement_grant_response =
6
+ {
7
+ data: ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data]
8
+ }
9
+
10
+ class PromotionalEntitlementGrantResponse < Stigg::Internal::Type::BaseModel
11
+ attr_accessor data: ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data]
12
+
13
+ def initialize: (
14
+ data: ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data]
15
+ ) -> void
16
+
17
+ def to_hash: -> {
18
+ data: ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data]
19
+ }
20
+
21
+ type data =
22
+ {
23
+ id: String,
24
+ created_at: Time,
25
+ description: String?,
26
+ end_date: Time?,
27
+ enum_values: ::Array[String]?,
28
+ environment_id: String,
29
+ feature_group_ids: ::Array[String]?,
30
+ feature_id: String,
31
+ has_soft_limit: bool?,
32
+ has_unlimited_usage: bool?,
33
+ is_visible: bool,
34
+ period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::period,
35
+ reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period?,
36
+ reset_period_configuration: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period_configuration?,
37
+ start_date: Time,
38
+ status: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::status,
39
+ updated_at: Time,
40
+ usage_limit: Float?
41
+ }
42
+
43
+ class Data < Stigg::Internal::Type::BaseModel
44
+ attr_accessor id: String
45
+
46
+ attr_accessor created_at: Time
47
+
48
+ attr_accessor description: String?
49
+
50
+ attr_accessor end_date: Time?
51
+
52
+ attr_accessor enum_values: ::Array[String]?
53
+
54
+ attr_accessor environment_id: String
55
+
56
+ attr_accessor feature_group_ids: ::Array[String]?
57
+
58
+ attr_accessor feature_id: String
59
+
60
+ attr_accessor has_soft_limit: bool?
61
+
62
+ attr_accessor has_unlimited_usage: bool?
63
+
64
+ attr_accessor is_visible: bool
65
+
66
+ attr_accessor period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::period
67
+
68
+ attr_accessor reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period?
69
+
70
+ attr_accessor reset_period_configuration: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period_configuration?
71
+
72
+ attr_accessor start_date: Time
73
+
74
+ attr_accessor status: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::status
75
+
76
+ attr_accessor updated_at: Time
77
+
78
+ attr_accessor usage_limit: Float?
79
+
80
+ def initialize: (
81
+ id: String,
82
+ created_at: Time,
83
+ description: String?,
84
+ end_date: Time?,
85
+ enum_values: ::Array[String]?,
86
+ environment_id: String,
87
+ feature_group_ids: ::Array[String]?,
88
+ feature_id: String,
89
+ has_soft_limit: bool?,
90
+ has_unlimited_usage: bool?,
91
+ is_visible: bool,
92
+ period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::period,
93
+ reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period?,
94
+ reset_period_configuration: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period_configuration?,
95
+ start_date: Time,
96
+ status: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::status,
97
+ updated_at: Time,
98
+ usage_limit: Float?
99
+ ) -> void
100
+
101
+ def to_hash: -> {
102
+ id: String,
103
+ created_at: Time,
104
+ description: String?,
105
+ end_date: Time?,
106
+ enum_values: ::Array[String]?,
107
+ environment_id: String,
108
+ feature_group_ids: ::Array[String]?,
109
+ feature_id: String,
110
+ has_soft_limit: bool?,
111
+ has_unlimited_usage: bool?,
112
+ is_visible: bool,
113
+ period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::period,
114
+ reset_period: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period?,
115
+ reset_period_configuration: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period_configuration?,
116
+ start_date: Time,
117
+ status: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::status,
118
+ updated_at: Time,
119
+ usage_limit: Float?
120
+ }
121
+
122
+ type period =
123
+ :"1 week"
124
+ | :"1 month"
125
+ | :"6 month"
126
+ | :"1 year"
127
+ | :lifetime
128
+ | :custom
129
+
130
+ module Period
131
+ extend Stigg::Internal::Type::Enum
132
+
133
+ PERIOD_1_WEEK: :"1 week"
134
+ PERIOD_1_MONTH: :"1 month"
135
+ PERIOD_6_MONTH: :"6 month"
136
+ PERIOD_1_YEAR: :"1 year"
137
+ LIFETIME: :lifetime
138
+ CUSTOM: :custom
139
+
140
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::period]
141
+ end
142
+
143
+ type reset_period = :YEAR | :MONTH | :WEEK | :DAY | :HOUR
144
+
145
+ module ResetPeriod
146
+ extend Stigg::Internal::Type::Enum
147
+
148
+ YEAR: :YEAR
149
+ MONTH: :MONTH
150
+ WEEK: :WEEK
151
+ DAY: :DAY
152
+ HOUR: :HOUR
153
+
154
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period]
155
+ end
156
+
157
+ type reset_period_configuration =
158
+ Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::YearlyResetPeriodConfig
159
+ | Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::MonthlyResetPeriodConfig
160
+ | Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::WeeklyResetPeriodConfig
161
+
162
+ module ResetPeriodConfiguration
163
+ extend Stigg::Internal::Type::Union
164
+
165
+ type yearly_reset_period_config =
166
+ {
167
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::YearlyResetPeriodConfig::according_to
168
+ }
169
+
170
+ class YearlyResetPeriodConfig < Stigg::Internal::Type::BaseModel
171
+ attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::YearlyResetPeriodConfig::according_to
172
+
173
+ def initialize: (
174
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::YearlyResetPeriodConfig::according_to
175
+ ) -> void
176
+
177
+ def to_hash: -> {
178
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::YearlyResetPeriodConfig::according_to
179
+ }
180
+
181
+ type according_to = :SubscriptionStart
182
+
183
+ module AccordingTo
184
+ extend Stigg::Internal::Type::Enum
185
+
186
+ SUBSCRIPTION_START: :SubscriptionStart
187
+
188
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::YearlyResetPeriodConfig::according_to]
189
+ end
190
+ end
191
+
192
+ type monthly_reset_period_config =
193
+ {
194
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::MonthlyResetPeriodConfig::according_to
195
+ }
196
+
197
+ class MonthlyResetPeriodConfig < Stigg::Internal::Type::BaseModel
198
+ attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::MonthlyResetPeriodConfig::according_to
199
+
200
+ def initialize: (
201
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::MonthlyResetPeriodConfig::according_to
202
+ ) -> void
203
+
204
+ def to_hash: -> {
205
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::MonthlyResetPeriodConfig::according_to
206
+ }
207
+
208
+ type according_to = :SubscriptionStart | :StartOfTheMonth
209
+
210
+ module AccordingTo
211
+ extend Stigg::Internal::Type::Enum
212
+
213
+ SUBSCRIPTION_START: :SubscriptionStart
214
+ START_OF_THE_MONTH: :StartOfTheMonth
215
+
216
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::MonthlyResetPeriodConfig::according_to]
217
+ end
218
+ end
219
+
220
+ type weekly_reset_period_config =
221
+ {
222
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::WeeklyResetPeriodConfig::according_to
223
+ }
224
+
225
+ class WeeklyResetPeriodConfig < Stigg::Internal::Type::BaseModel
226
+ attr_accessor according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::WeeklyResetPeriodConfig::according_to
227
+
228
+ def initialize: (
229
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::WeeklyResetPeriodConfig::according_to
230
+ ) -> void
231
+
232
+ def to_hash: -> {
233
+ according_to: Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::WeeklyResetPeriodConfig::according_to
234
+ }
235
+
236
+ type according_to =
237
+ :SubscriptionStart
238
+ | :EverySunday
239
+ | :EveryMonday
240
+ | :EveryTuesday
241
+ | :EveryWednesday
242
+ | :EveryThursday
243
+ | :EveryFriday
244
+ | :EverySaturday
245
+
246
+ module AccordingTo
247
+ extend Stigg::Internal::Type::Enum
248
+
249
+ SUBSCRIPTION_START: :SubscriptionStart
250
+ EVERY_SUNDAY: :EverySunday
251
+ EVERY_MONDAY: :EveryMonday
252
+ EVERY_TUESDAY: :EveryTuesday
253
+ EVERY_WEDNESDAY: :EveryWednesday
254
+ EVERY_THURSDAY: :EveryThursday
255
+ EVERY_FRIDAY: :EveryFriday
256
+ EVERY_SATURDAY: :EverySaturday
257
+
258
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::ResetPeriodConfiguration::WeeklyResetPeriodConfig::according_to]
259
+ end
260
+ end
261
+
262
+ def self?.variants: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::reset_period_configuration]
263
+ end
264
+
265
+ type status = :Active | :Expired | :Paused
266
+
267
+ module Status
268
+ extend Stigg::Internal::Type::Enum
269
+
270
+ ACTIVE: :Active
271
+ EXPIRED: :Expired
272
+ PAUSED: :Paused
273
+
274
+ def self?.values: -> ::Array[Stigg::Models::V1::Customers::PromotionalEntitlementGrantResponse::Data::status]
275
+ end
276
+ end
277
+ end
278
+ end
279
+ end
280
+ end
281
+ end
@@ -2,10 +2,10 @@ module Stigg
2
2
  module Models
3
3
  module V1
4
4
  module Customers
5
- type promotional_revoke_params =
5
+ type promotional_entitlement_revoke_params =
6
6
  { customer_id: String } & Stigg::Internal::Type::request_parameters
7
7
 
8
- class PromotionalRevokeParams < Stigg::Internal::Type::BaseModel
8
+ class PromotionalEntitlementRevokeParams < Stigg::Internal::Type::BaseModel
9
9
  extend Stigg::Internal::Type::RequestParameters::Converter
10
10
  include Stigg::Internal::Type::RequestParameters
11
11