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
@@ -0,0 +1,1038 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Stigg
4
+ module Models
5
+ module V1
6
+ # @see Stigg::Resources::V1::Subscriptions#provision
7
+ class SubscriptionProvisionResponse < Stigg::Internal::Type::BaseModel
8
+ # @!attribute data
9
+ # Provisioning result with status and subscription or checkout URL.
10
+ #
11
+ # @return [Stigg::Models::V1::SubscriptionProvisionResponse::Data]
12
+ required :data, -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data }
13
+
14
+ # @!method initialize(data:)
15
+ # Response object
16
+ #
17
+ # @param data [Stigg::Models::V1::SubscriptionProvisionResponse::Data] Provisioning result with status and subscription or checkout URL.
18
+
19
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse#data
20
+ class Data < Stigg::Internal::Type::BaseModel
21
+ # @!attribute id
22
+ # Unique identifier for the provisioned subscription
23
+ #
24
+ # @return [String]
25
+ required :id, String
26
+
27
+ # @!attribute entitlements
28
+ #
29
+ # @return [Array<Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement>]
30
+ required :entitlements,
31
+ -> { Stigg::Internal::Type::ArrayOf[Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement] }
32
+
33
+ # @!attribute status
34
+ # Provision status: SUCCESS or PAYMENT_REQUIRED
35
+ #
36
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Status]
37
+ required :status, enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Status }
38
+
39
+ # @!attribute checkout_billing_id
40
+ # Checkout billing ID when payment is required
41
+ #
42
+ # @return [String, nil]
43
+ optional :checkout_billing_id, String, api_name: :checkoutBillingId, nil?: true
44
+
45
+ # @!attribute checkout_url
46
+ # URL to complete payment when PAYMENT_REQUIRED
47
+ #
48
+ # @return [String, nil]
49
+ optional :checkout_url, String, api_name: :checkoutUrl, nil?: true
50
+
51
+ # @!attribute is_scheduled
52
+ # Whether the subscription is scheduled for future activation
53
+ #
54
+ # @return [Boolean, nil]
55
+ optional :is_scheduled, Stigg::Internal::Type::Boolean, api_name: :isScheduled
56
+
57
+ # @!attribute subscription
58
+ # Created subscription (when status is SUCCESS)
59
+ #
60
+ # @return [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription, nil]
61
+ optional :subscription, -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription }
62
+
63
+ # @!method initialize(id:, entitlements:, status:, checkout_billing_id: nil, checkout_url: nil, is_scheduled: nil, subscription: nil)
64
+ # Provisioning result with status and subscription or checkout URL.
65
+ #
66
+ # @param id [String] Unique identifier for the provisioned subscription
67
+ #
68
+ # @param entitlements [Array<Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement>]
69
+ #
70
+ # @param status [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Status] Provision status: SUCCESS or PAYMENT_REQUIRED
71
+ #
72
+ # @param checkout_billing_id [String, nil] Checkout billing ID when payment is required
73
+ #
74
+ # @param checkout_url [String, nil] URL to complete payment when PAYMENT_REQUIRED
75
+ #
76
+ # @param is_scheduled [Boolean] Whether the subscription is scheduled for future activation
77
+ #
78
+ # @param subscription [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription] Created subscription (when status is SUCCESS)
79
+
80
+ class Entitlement < Stigg::Internal::Type::BaseModel
81
+ # @!attribute access_denied_reason
82
+ #
83
+ # @return [String, nil]
84
+ optional :access_denied_reason, String, api_name: :accessDeniedReason, nil?: true
85
+
86
+ # @!attribute current_usage
87
+ #
88
+ # @return [Float, nil]
89
+ optional :current_usage, Float, api_name: :currentUsage
90
+
91
+ # @!attribute entitlement_updated_at
92
+ # entitlement updated at
93
+ #
94
+ # @return [Time, nil]
95
+ optional :entitlement_updated_at, Time, api_name: :entitlementUpdatedAt, nil?: true
96
+
97
+ # @!attribute feature
98
+ #
99
+ # @return [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement::Feature, nil]
100
+ optional :feature,
101
+ -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement::Feature },
102
+ nil?: true
103
+
104
+ # @!attribute has_unlimited_usage
105
+ #
106
+ # @return [Boolean, nil]
107
+ optional :has_unlimited_usage,
108
+ Stigg::Internal::Type::Boolean,
109
+ api_name: :hasUnlimitedUsage,
110
+ nil?: true
111
+
112
+ # @!attribute is_granted
113
+ #
114
+ # @return [Boolean, nil]
115
+ optional :is_granted, Stigg::Internal::Type::Boolean, api_name: :isGranted
116
+
117
+ # @!attribute reset_period
118
+ #
119
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement::ResetPeriod, nil]
120
+ optional :reset_period,
121
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement::ResetPeriod },
122
+ api_name: :resetPeriod,
123
+ nil?: true
124
+
125
+ # @!attribute usage_limit
126
+ #
127
+ # @return [Float, nil]
128
+ optional :usage_limit, Float, api_name: :usageLimit, nil?: true
129
+
130
+ # @!attribute usage_period_anchor
131
+ # usage period anchor
132
+ #
133
+ # @return [Time, nil]
134
+ optional :usage_period_anchor, Time, api_name: :usagePeriodAnchor, nil?: true
135
+
136
+ # @!attribute usage_period_end
137
+ # usage period end
138
+ #
139
+ # @return [Time, nil]
140
+ optional :usage_period_end, Time, api_name: :usagePeriodEnd, nil?: true
141
+
142
+ # @!attribute usage_period_start
143
+ # usage period start
144
+ #
145
+ # @return [Time, nil]
146
+ optional :usage_period_start, Time, api_name: :usagePeriodStart, nil?: true
147
+
148
+ # @!method initialize(access_denied_reason: nil, current_usage: nil, entitlement_updated_at: nil, feature: nil, has_unlimited_usage: nil, is_granted: nil, reset_period: nil, usage_limit: nil, usage_period_anchor: nil, usage_period_end: nil, usage_period_start: nil)
149
+ # @param access_denied_reason [String, nil]
150
+ #
151
+ # @param current_usage [Float]
152
+ #
153
+ # @param entitlement_updated_at [Time, nil] entitlement updated at
154
+ #
155
+ # @param feature [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement::Feature, nil]
156
+ #
157
+ # @param has_unlimited_usage [Boolean, nil]
158
+ #
159
+ # @param is_granted [Boolean]
160
+ #
161
+ # @param reset_period [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement::ResetPeriod, nil]
162
+ #
163
+ # @param usage_limit [Float, nil]
164
+ #
165
+ # @param usage_period_anchor [Time, nil] usage period anchor
166
+ #
167
+ # @param usage_period_end [Time, nil] usage period end
168
+ #
169
+ # @param usage_period_start [Time, nil] usage period start
170
+
171
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement#feature
172
+ class Feature < Stigg::Internal::Type::BaseModel
173
+ # @!attribute ref_id
174
+ # Feature ID
175
+ #
176
+ # @return [String]
177
+ required :ref_id, String, api_name: :refId
178
+
179
+ # @!method initialize(ref_id:)
180
+ # @param ref_id [String] Feature ID
181
+ end
182
+
183
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Entitlement#reset_period
184
+ module ResetPeriod
185
+ extend Stigg::Internal::Type::Enum
186
+
187
+ YEAR = :YEAR
188
+ MONTH = :MONTH
189
+ WEEK = :WEEK
190
+ DAY = :DAY
191
+ HOUR = :HOUR
192
+
193
+ # @!method self.values
194
+ # @return [Array<Symbol>]
195
+ end
196
+ end
197
+
198
+ # Provision status: SUCCESS or PAYMENT_REQUIRED
199
+ #
200
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data#status
201
+ module Status
202
+ extend Stigg::Internal::Type::Enum
203
+
204
+ SUCCESS = :SUCCESS
205
+ PAYMENT_REQUIRED = :PAYMENT_REQUIRED
206
+
207
+ # @!method self.values
208
+ # @return [Array<Symbol>]
209
+ end
210
+
211
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data#subscription
212
+ class Subscription < Stigg::Internal::Type::BaseModel
213
+ # @!attribute id
214
+ # Subscription ID
215
+ #
216
+ # @return [String]
217
+ required :id, String
218
+
219
+ # @!attribute billing_id
220
+ # Billing ID
221
+ #
222
+ # @return [String, nil]
223
+ required :billing_id, String, api_name: :billingId, nil?: true
224
+
225
+ # @!attribute created_at
226
+ # Created at
227
+ #
228
+ # @return [Time]
229
+ required :created_at, Time, api_name: :createdAt
230
+
231
+ # @!attribute customer_id
232
+ # Customer ID
233
+ #
234
+ # @return [String]
235
+ required :customer_id, String, api_name: :customerId
236
+
237
+ # @!attribute payment_collection
238
+ # Payment collection
239
+ #
240
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PaymentCollection]
241
+ required :payment_collection,
242
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PaymentCollection },
243
+ api_name: :paymentCollection
244
+
245
+ # @!attribute plan_id
246
+ # Plan ID
247
+ #
248
+ # @return [String]
249
+ required :plan_id, String, api_name: :planId
250
+
251
+ # @!attribute pricing_type
252
+ # Pricing type
253
+ #
254
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PricingType]
255
+ required :pricing_type,
256
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PricingType },
257
+ api_name: :pricingType
258
+
259
+ # @!attribute start_date
260
+ # Subscription start date
261
+ #
262
+ # @return [Time]
263
+ required :start_date, Time, api_name: :startDate
264
+
265
+ # @!attribute status
266
+ # Subscription status
267
+ #
268
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Status]
269
+ required :status,
270
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Status }
271
+
272
+ # @!attribute cancellation_date
273
+ # Subscription cancellation date
274
+ #
275
+ # @return [Time, nil]
276
+ optional :cancellation_date, Time, api_name: :cancellationDate, nil?: true
277
+
278
+ # @!attribute cancel_reason
279
+ # Subscription cancel reason
280
+ #
281
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::CancelReason, nil]
282
+ optional :cancel_reason,
283
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::CancelReason },
284
+ api_name: :cancelReason,
285
+ nil?: true
286
+
287
+ # @!attribute current_billing_period_end
288
+ # End of the current billing period
289
+ #
290
+ # @return [Time, nil]
291
+ optional :current_billing_period_end, Time, api_name: :currentBillingPeriodEnd, nil?: true
292
+
293
+ # @!attribute current_billing_period_start
294
+ # Start of the current billing period
295
+ #
296
+ # @return [Time, nil]
297
+ optional :current_billing_period_start, Time, api_name: :currentBillingPeriodStart, nil?: true
298
+
299
+ # @!attribute effective_end_date
300
+ # Subscription effective end date
301
+ #
302
+ # @return [Time, nil]
303
+ optional :effective_end_date, Time, api_name: :effectiveEndDate, nil?: true
304
+
305
+ # @!attribute end_date
306
+ # Subscription end date
307
+ #
308
+ # @return [Time, nil]
309
+ optional :end_date, Time, api_name: :endDate, nil?: true
310
+
311
+ # @!attribute metadata
312
+ # Additional metadata for the subscription
313
+ #
314
+ # @return [Hash{Symbol=>String}, nil]
315
+ optional :metadata, Stigg::Internal::Type::HashOf[String]
316
+
317
+ # @!attribute paying_customer_id
318
+ # Paying customer ID for delegated billing
319
+ #
320
+ # @return [String, nil]
321
+ optional :paying_customer_id, String, api_name: :payingCustomerId, nil?: true
322
+
323
+ # @!attribute payment_collection_method
324
+ # The method used to collect payments for a subscription
325
+ #
326
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PaymentCollectionMethod, nil]
327
+ optional :payment_collection_method,
328
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PaymentCollectionMethod },
329
+ api_name: :paymentCollectionMethod,
330
+ nil?: true
331
+
332
+ # @!attribute prices
333
+ #
334
+ # @return [Array<Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price>, nil]
335
+ optional :prices,
336
+ -> { Stigg::Internal::Type::ArrayOf[Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price] }
337
+
338
+ # @!attribute resource_id
339
+ # Resource ID
340
+ #
341
+ # @return [String, nil]
342
+ optional :resource_id, String, api_name: :resourceId, nil?: true
343
+
344
+ # @!attribute trial_end_date
345
+ # Subscription trial end date
346
+ #
347
+ # @return [Time, nil]
348
+ optional :trial_end_date, Time, api_name: :trialEndDate, nil?: true
349
+
350
+ # @!method initialize(id:, billing_id:, created_at:, customer_id:, payment_collection:, plan_id:, pricing_type:, start_date:, status:, cancellation_date: nil, cancel_reason: nil, current_billing_period_end: nil, current_billing_period_start: nil, effective_end_date: nil, end_date: nil, metadata: nil, paying_customer_id: nil, payment_collection_method: nil, prices: nil, resource_id: nil, trial_end_date: nil)
351
+ # Created subscription (when status is SUCCESS)
352
+ #
353
+ # @param id [String] Subscription ID
354
+ #
355
+ # @param billing_id [String, nil] Billing ID
356
+ #
357
+ # @param created_at [Time] Created at
358
+ #
359
+ # @param customer_id [String] Customer ID
360
+ #
361
+ # @param payment_collection [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PaymentCollection] Payment collection
362
+ #
363
+ # @param plan_id [String] Plan ID
364
+ #
365
+ # @param pricing_type [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PricingType] Pricing type
366
+ #
367
+ # @param start_date [Time] Subscription start date
368
+ #
369
+ # @param status [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Status] Subscription status
370
+ #
371
+ # @param cancellation_date [Time, nil] Subscription cancellation date
372
+ #
373
+ # @param cancel_reason [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::CancelReason, nil] Subscription cancel reason
374
+ #
375
+ # @param current_billing_period_end [Time, nil] End of the current billing period
376
+ #
377
+ # @param current_billing_period_start [Time, nil] Start of the current billing period
378
+ #
379
+ # @param effective_end_date [Time, nil] Subscription effective end date
380
+ #
381
+ # @param end_date [Time, nil] Subscription end date
382
+ #
383
+ # @param metadata [Hash{Symbol=>String}] Additional metadata for the subscription
384
+ #
385
+ # @param paying_customer_id [String, nil] Paying customer ID for delegated billing
386
+ #
387
+ # @param payment_collection_method [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::PaymentCollectionMethod, nil] The method used to collect payments for a subscription
388
+ #
389
+ # @param prices [Array<Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price>]
390
+ #
391
+ # @param resource_id [String, nil] Resource ID
392
+ #
393
+ # @param trial_end_date [Time, nil] Subscription trial end date
394
+
395
+ # Payment collection
396
+ #
397
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription#payment_collection
398
+ module PaymentCollection
399
+ extend Stigg::Internal::Type::Enum
400
+
401
+ NOT_REQUIRED = :NOT_REQUIRED
402
+ PROCESSING = :PROCESSING
403
+ FAILED = :FAILED
404
+ ACTION_REQUIRED = :ACTION_REQUIRED
405
+
406
+ # @!method self.values
407
+ # @return [Array<Symbol>]
408
+ end
409
+
410
+ # Pricing type
411
+ #
412
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription#pricing_type
413
+ module PricingType
414
+ extend Stigg::Internal::Type::Enum
415
+
416
+ FREE = :FREE
417
+ PAID = :PAID
418
+ CUSTOM = :CUSTOM
419
+
420
+ # @!method self.values
421
+ # @return [Array<Symbol>]
422
+ end
423
+
424
+ # Subscription status
425
+ #
426
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription#status
427
+ module Status
428
+ extend Stigg::Internal::Type::Enum
429
+
430
+ PAYMENT_PENDING = :PAYMENT_PENDING
431
+ ACTIVE = :ACTIVE
432
+ EXPIRED = :EXPIRED
433
+ IN_TRIAL = :IN_TRIAL
434
+ CANCELED = :CANCELED
435
+ NOT_STARTED = :NOT_STARTED
436
+
437
+ # @!method self.values
438
+ # @return [Array<Symbol>]
439
+ end
440
+
441
+ # Subscription cancel reason
442
+ #
443
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription#cancel_reason
444
+ module CancelReason
445
+ extend Stigg::Internal::Type::Enum
446
+
447
+ UPGRADE_OR_DOWNGRADE = :UPGRADE_OR_DOWNGRADE
448
+ CANCELLED_BY_BILLING = :CANCELLED_BY_BILLING
449
+ EXPIRED = :EXPIRED
450
+ DETACH_BILLING = :DETACH_BILLING
451
+ TRIAL_ENDED = :TRIAL_ENDED
452
+ IMMEDIATE = :Immediate
453
+ TRIAL_CONVERTED = :TRIAL_CONVERTED
454
+ PENDING_PAYMENT_EXPIRED = :PENDING_PAYMENT_EXPIRED
455
+ SCHEDULED_CANCELLATION = :ScheduledCancellation
456
+ CUSTOMER_ARCHIVED = :CustomerArchived
457
+ AUTO_CANCELLATION_RULE = :AutoCancellationRule
458
+
459
+ # @!method self.values
460
+ # @return [Array<Symbol>]
461
+ end
462
+
463
+ # The method used to collect payments for a subscription
464
+ #
465
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription#payment_collection_method
466
+ module PaymentCollectionMethod
467
+ extend Stigg::Internal::Type::Enum
468
+
469
+ CHARGE = :CHARGE
470
+ INVOICE = :INVOICE
471
+ NONE = :NONE
472
+
473
+ # @!method self.values
474
+ # @return [Array<Symbol>]
475
+ end
476
+
477
+ class Price < Stigg::Internal::Type::BaseModel
478
+ # @!attribute addon_id
479
+ # Addon identifier for the price override
480
+ #
481
+ # @return [String, nil]
482
+ optional :addon_id, String, api_name: :addonId, nil?: true
483
+
484
+ # @!attribute base_charge
485
+ # Whether this is a base charge override
486
+ #
487
+ # @return [Boolean, nil]
488
+ optional :base_charge, Stigg::Internal::Type::Boolean, api_name: :baseCharge
489
+
490
+ # @!attribute block_size
491
+ # Block size for pricing
492
+ #
493
+ # @return [Float, nil]
494
+ optional :block_size, Float, api_name: :blockSize
495
+
496
+ # @!attribute feature_id
497
+ # Feature identifier for the price override
498
+ #
499
+ # @return [String, nil]
500
+ optional :feature_id, String, api_name: :featureId, nil?: true
501
+
502
+ # @!attribute price
503
+ # Override price amount
504
+ #
505
+ # @return [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Price, nil]
506
+ optional :price, -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Price }
507
+
508
+ # @!attribute tiers
509
+ # Pricing tiers configuration
510
+ #
511
+ # @return [Array<Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier>, nil]
512
+ optional :tiers,
513
+ -> { Stigg::Internal::Type::ArrayOf[Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier] }
514
+
515
+ # @!method initialize(addon_id: nil, base_charge: nil, block_size: nil, feature_id: nil, price: nil, tiers: nil)
516
+ # @param addon_id [String, nil] Addon identifier for the price override
517
+ #
518
+ # @param base_charge [Boolean] Whether this is a base charge override
519
+ #
520
+ # @param block_size [Float] Block size for pricing
521
+ #
522
+ # @param feature_id [String, nil] Feature identifier for the price override
523
+ #
524
+ # @param price [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Price] Override price amount
525
+ #
526
+ # @param tiers [Array<Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier>] Pricing tiers configuration
527
+
528
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price#price
529
+ class Price < Stigg::Internal::Type::BaseModel
530
+ # @!attribute amount
531
+ # The price amount
532
+ #
533
+ # @return [Float, nil]
534
+ optional :amount, Float
535
+
536
+ # @!attribute billing_country_code
537
+ # The billing country code of the price
538
+ #
539
+ # @return [String, nil]
540
+ optional :billing_country_code, String, api_name: :billingCountryCode, nil?: true
541
+
542
+ # @!attribute currency
543
+ # The price currency
544
+ #
545
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Price::Currency, nil]
546
+ optional :currency,
547
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Price::Currency }
548
+
549
+ # @!method initialize(amount: nil, billing_country_code: nil, currency: nil)
550
+ # Override price amount
551
+ #
552
+ # @param amount [Float] The price amount
553
+ #
554
+ # @param billing_country_code [String, nil] The billing country code of the price
555
+ #
556
+ # @param currency [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Price::Currency] The price currency
557
+
558
+ # The price currency
559
+ #
560
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Price#currency
561
+ module Currency
562
+ extend Stigg::Internal::Type::Enum
563
+
564
+ USD = :usd
565
+ AED = :aed
566
+ ALL = :all
567
+ AMD = :amd
568
+ ANG = :ang
569
+ AUD = :aud
570
+ AWG = :awg
571
+ AZN = :azn
572
+ BAM = :bam
573
+ BBD = :bbd
574
+ BDT = :bdt
575
+ BGN = :bgn
576
+ BIF = :bif
577
+ BMD = :bmd
578
+ BND = :bnd
579
+ BSD = :bsd
580
+ BWP = :bwp
581
+ BYN = :byn
582
+ BZD = :bzd
583
+ BRL = :brl
584
+ CAD = :cad
585
+ CDF = :cdf
586
+ CHF = :chf
587
+ CNY = :cny
588
+ CZK = :czk
589
+ DKK = :dkk
590
+ DOP = :dop
591
+ DZD = :dzd
592
+ EGP = :egp
593
+ ETB = :etb
594
+ EUR = :eur
595
+ FJD = :fjd
596
+ GBP = :gbp
597
+ GEL = :gel
598
+ GIP = :gip
599
+ GMD = :gmd
600
+ GYD = :gyd
601
+ HKD = :hkd
602
+ HRK = :hrk
603
+ HTG = :htg
604
+ IDR = :idr
605
+ ILS = :ils
606
+ INR = :inr
607
+ ISK = :isk
608
+ JMD = :jmd
609
+ JPY = :jpy
610
+ KES = :kes
611
+ KGS = :kgs
612
+ KHR = :khr
613
+ KMF = :kmf
614
+ KRW = :krw
615
+ KYD = :kyd
616
+ KZT = :kzt
617
+ LBP = :lbp
618
+ LKR = :lkr
619
+ LRD = :lrd
620
+ LSL = :lsl
621
+ MAD = :mad
622
+ MDL = :mdl
623
+ MGA = :mga
624
+ MKD = :mkd
625
+ MMK = :mmk
626
+ MNT = :mnt
627
+ MOP = :mop
628
+ MRO = :mro
629
+ MVR = :mvr
630
+ MWK = :mwk
631
+ MXN = :mxn
632
+ MYR = :myr
633
+ MZN = :mzn
634
+ NAD = :nad
635
+ NGN = :ngn
636
+ NOK = :nok
637
+ NPR = :npr
638
+ NZD = :nzd
639
+ PGK = :pgk
640
+ PHP = :php
641
+ PKR = :pkr
642
+ PLN = :pln
643
+ QAR = :qar
644
+ RON = :ron
645
+ RSD = :rsd
646
+ RUB = :rub
647
+ RWF = :rwf
648
+ SAR = :sar
649
+ SBD = :sbd
650
+ SCR = :scr
651
+ SEK = :sek
652
+ SGD = :sgd
653
+ SLE = :sle
654
+ SLL = :sll
655
+ SOS = :sos
656
+ SZL = :szl
657
+ THB = :thb
658
+ TJS = :tjs
659
+ TOP = :top
660
+ TRY = :try
661
+ TTD = :ttd
662
+ TZS = :tzs
663
+ UAH = :uah
664
+ UZS = :uzs
665
+ VND = :vnd
666
+ VUV = :vuv
667
+ WST = :wst
668
+ XAF = :xaf
669
+ XCD = :xcd
670
+ YER = :yer
671
+ ZAR = :zar
672
+ ZMW = :zmw
673
+ CLP = :clp
674
+ DJF = :djf
675
+ GNF = :gnf
676
+ UGX = :ugx
677
+ PYG = :pyg
678
+ XOF = :xof
679
+ XPF = :xpf
680
+
681
+ # @!method self.values
682
+ # @return [Array<Symbol>]
683
+ end
684
+ end
685
+
686
+ class Tier < Stigg::Internal::Type::BaseModel
687
+ # @!attribute flat_price
688
+ # The flat fee price of the price tier
689
+ #
690
+ # @return [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::FlatPrice, nil]
691
+ optional :flat_price,
692
+ -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::FlatPrice },
693
+ api_name: :flatPrice
694
+
695
+ # @!attribute unit_price
696
+ # The unit price of the price tier
697
+ #
698
+ # @return [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::UnitPrice, nil]
699
+ optional :unit_price,
700
+ -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::UnitPrice },
701
+ api_name: :unitPrice
702
+
703
+ # @!attribute up_to
704
+ # The up to quantity of the price tier
705
+ #
706
+ # @return [Float, nil]
707
+ optional :up_to, Float, api_name: :upTo
708
+
709
+ # @!method initialize(flat_price: nil, unit_price: nil, up_to: nil)
710
+ # @param flat_price [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::FlatPrice] The flat fee price of the price tier
711
+ #
712
+ # @param unit_price [Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::UnitPrice] The unit price of the price tier
713
+ #
714
+ # @param up_to [Float] The up to quantity of the price tier
715
+
716
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier#flat_price
717
+ class FlatPrice < Stigg::Internal::Type::BaseModel
718
+ # @!attribute amount
719
+ # The price amount
720
+ #
721
+ # @return [Float, nil]
722
+ optional :amount, Float
723
+
724
+ # @!attribute billing_country_code
725
+ # The billing country code of the price
726
+ #
727
+ # @return [String, nil]
728
+ optional :billing_country_code, String, api_name: :billingCountryCode, nil?: true
729
+
730
+ # @!attribute currency
731
+ # The price currency
732
+ #
733
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::FlatPrice::Currency, nil]
734
+ optional :currency,
735
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::FlatPrice::Currency }
736
+
737
+ # @!method initialize(amount: nil, billing_country_code: nil, currency: nil)
738
+ # The flat fee price of the price tier
739
+ #
740
+ # @param amount [Float] The price amount
741
+ #
742
+ # @param billing_country_code [String, nil] The billing country code of the price
743
+ #
744
+ # @param currency [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::FlatPrice::Currency] The price currency
745
+
746
+ # The price currency
747
+ #
748
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::FlatPrice#currency
749
+ module Currency
750
+ extend Stigg::Internal::Type::Enum
751
+
752
+ USD = :usd
753
+ AED = :aed
754
+ ALL = :all
755
+ AMD = :amd
756
+ ANG = :ang
757
+ AUD = :aud
758
+ AWG = :awg
759
+ AZN = :azn
760
+ BAM = :bam
761
+ BBD = :bbd
762
+ BDT = :bdt
763
+ BGN = :bgn
764
+ BIF = :bif
765
+ BMD = :bmd
766
+ BND = :bnd
767
+ BSD = :bsd
768
+ BWP = :bwp
769
+ BYN = :byn
770
+ BZD = :bzd
771
+ BRL = :brl
772
+ CAD = :cad
773
+ CDF = :cdf
774
+ CHF = :chf
775
+ CNY = :cny
776
+ CZK = :czk
777
+ DKK = :dkk
778
+ DOP = :dop
779
+ DZD = :dzd
780
+ EGP = :egp
781
+ ETB = :etb
782
+ EUR = :eur
783
+ FJD = :fjd
784
+ GBP = :gbp
785
+ GEL = :gel
786
+ GIP = :gip
787
+ GMD = :gmd
788
+ GYD = :gyd
789
+ HKD = :hkd
790
+ HRK = :hrk
791
+ HTG = :htg
792
+ IDR = :idr
793
+ ILS = :ils
794
+ INR = :inr
795
+ ISK = :isk
796
+ JMD = :jmd
797
+ JPY = :jpy
798
+ KES = :kes
799
+ KGS = :kgs
800
+ KHR = :khr
801
+ KMF = :kmf
802
+ KRW = :krw
803
+ KYD = :kyd
804
+ KZT = :kzt
805
+ LBP = :lbp
806
+ LKR = :lkr
807
+ LRD = :lrd
808
+ LSL = :lsl
809
+ MAD = :mad
810
+ MDL = :mdl
811
+ MGA = :mga
812
+ MKD = :mkd
813
+ MMK = :mmk
814
+ MNT = :mnt
815
+ MOP = :mop
816
+ MRO = :mro
817
+ MVR = :mvr
818
+ MWK = :mwk
819
+ MXN = :mxn
820
+ MYR = :myr
821
+ MZN = :mzn
822
+ NAD = :nad
823
+ NGN = :ngn
824
+ NOK = :nok
825
+ NPR = :npr
826
+ NZD = :nzd
827
+ PGK = :pgk
828
+ PHP = :php
829
+ PKR = :pkr
830
+ PLN = :pln
831
+ QAR = :qar
832
+ RON = :ron
833
+ RSD = :rsd
834
+ RUB = :rub
835
+ RWF = :rwf
836
+ SAR = :sar
837
+ SBD = :sbd
838
+ SCR = :scr
839
+ SEK = :sek
840
+ SGD = :sgd
841
+ SLE = :sle
842
+ SLL = :sll
843
+ SOS = :sos
844
+ SZL = :szl
845
+ THB = :thb
846
+ TJS = :tjs
847
+ TOP = :top
848
+ TRY = :try
849
+ TTD = :ttd
850
+ TZS = :tzs
851
+ UAH = :uah
852
+ UZS = :uzs
853
+ VND = :vnd
854
+ VUV = :vuv
855
+ WST = :wst
856
+ XAF = :xaf
857
+ XCD = :xcd
858
+ YER = :yer
859
+ ZAR = :zar
860
+ ZMW = :zmw
861
+ CLP = :clp
862
+ DJF = :djf
863
+ GNF = :gnf
864
+ UGX = :ugx
865
+ PYG = :pyg
866
+ XOF = :xof
867
+ XPF = :xpf
868
+
869
+ # @!method self.values
870
+ # @return [Array<Symbol>]
871
+ end
872
+ end
873
+
874
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier#unit_price
875
+ class UnitPrice < Stigg::Internal::Type::BaseModel
876
+ # @!attribute amount
877
+ # The price amount
878
+ #
879
+ # @return [Float, nil]
880
+ optional :amount, Float
881
+
882
+ # @!attribute billing_country_code
883
+ # The billing country code of the price
884
+ #
885
+ # @return [String, nil]
886
+ optional :billing_country_code, String, api_name: :billingCountryCode, nil?: true
887
+
888
+ # @!attribute currency
889
+ # The price currency
890
+ #
891
+ # @return [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::UnitPrice::Currency, nil]
892
+ optional :currency,
893
+ enum: -> { Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::UnitPrice::Currency }
894
+
895
+ # @!method initialize(amount: nil, billing_country_code: nil, currency: nil)
896
+ # The unit price of the price tier
897
+ #
898
+ # @param amount [Float] The price amount
899
+ #
900
+ # @param billing_country_code [String, nil] The billing country code of the price
901
+ #
902
+ # @param currency [Symbol, Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::UnitPrice::Currency] The price currency
903
+
904
+ # The price currency
905
+ #
906
+ # @see Stigg::Models::V1::SubscriptionProvisionResponse::Data::Subscription::Price::Tier::UnitPrice#currency
907
+ module Currency
908
+ extend Stigg::Internal::Type::Enum
909
+
910
+ USD = :usd
911
+ AED = :aed
912
+ ALL = :all
913
+ AMD = :amd
914
+ ANG = :ang
915
+ AUD = :aud
916
+ AWG = :awg
917
+ AZN = :azn
918
+ BAM = :bam
919
+ BBD = :bbd
920
+ BDT = :bdt
921
+ BGN = :bgn
922
+ BIF = :bif
923
+ BMD = :bmd
924
+ BND = :bnd
925
+ BSD = :bsd
926
+ BWP = :bwp
927
+ BYN = :byn
928
+ BZD = :bzd
929
+ BRL = :brl
930
+ CAD = :cad
931
+ CDF = :cdf
932
+ CHF = :chf
933
+ CNY = :cny
934
+ CZK = :czk
935
+ DKK = :dkk
936
+ DOP = :dop
937
+ DZD = :dzd
938
+ EGP = :egp
939
+ ETB = :etb
940
+ EUR = :eur
941
+ FJD = :fjd
942
+ GBP = :gbp
943
+ GEL = :gel
944
+ GIP = :gip
945
+ GMD = :gmd
946
+ GYD = :gyd
947
+ HKD = :hkd
948
+ HRK = :hrk
949
+ HTG = :htg
950
+ IDR = :idr
951
+ ILS = :ils
952
+ INR = :inr
953
+ ISK = :isk
954
+ JMD = :jmd
955
+ JPY = :jpy
956
+ KES = :kes
957
+ KGS = :kgs
958
+ KHR = :khr
959
+ KMF = :kmf
960
+ KRW = :krw
961
+ KYD = :kyd
962
+ KZT = :kzt
963
+ LBP = :lbp
964
+ LKR = :lkr
965
+ LRD = :lrd
966
+ LSL = :lsl
967
+ MAD = :mad
968
+ MDL = :mdl
969
+ MGA = :mga
970
+ MKD = :mkd
971
+ MMK = :mmk
972
+ MNT = :mnt
973
+ MOP = :mop
974
+ MRO = :mro
975
+ MVR = :mvr
976
+ MWK = :mwk
977
+ MXN = :mxn
978
+ MYR = :myr
979
+ MZN = :mzn
980
+ NAD = :nad
981
+ NGN = :ngn
982
+ NOK = :nok
983
+ NPR = :npr
984
+ NZD = :nzd
985
+ PGK = :pgk
986
+ PHP = :php
987
+ PKR = :pkr
988
+ PLN = :pln
989
+ QAR = :qar
990
+ RON = :ron
991
+ RSD = :rsd
992
+ RUB = :rub
993
+ RWF = :rwf
994
+ SAR = :sar
995
+ SBD = :sbd
996
+ SCR = :scr
997
+ SEK = :sek
998
+ SGD = :sgd
999
+ SLE = :sle
1000
+ SLL = :sll
1001
+ SOS = :sos
1002
+ SZL = :szl
1003
+ THB = :thb
1004
+ TJS = :tjs
1005
+ TOP = :top
1006
+ TRY = :try
1007
+ TTD = :ttd
1008
+ TZS = :tzs
1009
+ UAH = :uah
1010
+ UZS = :uzs
1011
+ VND = :vnd
1012
+ VUV = :vuv
1013
+ WST = :wst
1014
+ XAF = :xaf
1015
+ XCD = :xcd
1016
+ YER = :yer
1017
+ ZAR = :zar
1018
+ ZMW = :zmw
1019
+ CLP = :clp
1020
+ DJF = :djf
1021
+ GNF = :gnf
1022
+ UGX = :ugx
1023
+ PYG = :pyg
1024
+ XOF = :xof
1025
+ XPF = :xpf
1026
+
1027
+ # @!method self.values
1028
+ # @return [Array<Symbol>]
1029
+ end
1030
+ end
1031
+ end
1032
+ end
1033
+ end
1034
+ end
1035
+ end
1036
+ end
1037
+ end
1038
+ end