maxio-advanced-billing-sdk 4.0.0 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +45 -45
- data/lib/advanced_billing/configuration.rb +2 -2
- data/lib/advanced_billing/controllers/advance_invoice_controller.rb +24 -24
- data/lib/advanced_billing/controllers/api_exports_controller.rb +57 -57
- data/lib/advanced_billing/controllers/base_controller.rb +10 -10
- data/lib/advanced_billing/controllers/billing_portal_controller.rb +33 -32
- data/lib/advanced_billing/controllers/component_price_points_controller.rb +60 -60
- data/lib/advanced_billing/controllers/components_controller.rb +110 -107
- data/lib/advanced_billing/controllers/coupons_controller.rb +89 -89
- data/lib/advanced_billing/controllers/custom_fields_controller.rb +76 -76
- data/lib/advanced_billing/controllers/customers_controller.rb +45 -41
- data/lib/advanced_billing/controllers/events_based_billing_segments_controller.rb +53 -53
- data/lib/advanced_billing/controllers/events_controller.rb +16 -15
- data/lib/advanced_billing/controllers/insights_controller.rb +17 -17
- data/lib/advanced_billing/controllers/invoices_controller.rb +99 -99
- data/lib/advanced_billing/controllers/offers_controller.rb +18 -15
- data/lib/advanced_billing/controllers/payment_profiles_controller.rb +107 -104
- data/lib/advanced_billing/controllers/product_families_controller.rb +26 -26
- data/lib/advanced_billing/controllers/product_price_points_controller.rb +62 -62
- data/lib/advanced_billing/controllers/products_controller.rb +37 -37
- data/lib/advanced_billing/controllers/proforma_invoices_controller.rb +61 -61
- data/lib/advanced_billing/controllers/reason_codes_controller.rb +35 -35
- data/lib/advanced_billing/controllers/referral_codes_controller.rb +9 -8
- data/lib/advanced_billing/controllers/sales_commissions_controller.rb +13 -13
- data/lib/advanced_billing/controllers/sites_controller.rb +11 -10
- data/lib/advanced_billing/controllers/subscription_components_controller.rb +170 -161
- data/lib/advanced_billing/controllers/subscription_group_invoice_account_controller.rb +23 -23
- data/lib/advanced_billing/controllers/subscription_group_status_controller.rb +21 -21
- data/lib/advanced_billing/controllers/subscription_groups_controller.rb +54 -54
- data/lib/advanced_billing/controllers/subscription_invoice_account_controller.rb +37 -37
- data/lib/advanced_billing/controllers/subscription_notes_controller.rb +20 -16
- data/lib/advanced_billing/controllers/subscription_products_controller.rb +20 -18
- data/lib/advanced_billing/controllers/subscription_status_controller.rb +74 -74
- data/lib/advanced_billing/controllers/subscriptions_controller.rb +163 -160
- data/lib/advanced_billing/controllers/webhooks_controller.rb +45 -44
- data/lib/advanced_billing/exceptions/component_allocation_error_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/component_price_point_error_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/customer_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/error_array_map_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/error_list_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/error_string_map_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/event_based_billing_list_segments_errors_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/event_based_billing_segment_errors_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/event_based_billing_segment_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/product_price_point_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/proforma_bad_request_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/refund_prepayment_base_errors_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/single_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/single_string_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/subscription_add_coupon_error_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/subscription_component_allocation_error_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/subscription_group_create_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/subscription_group_signup_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/subscription_group_update_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/subscription_remove_coupon_errors_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/subscriptions_mrr_error_response_exception.rb +15 -15
- data/lib/advanced_billing/exceptions/too_many_management_link_requests_error_exception.rb +15 -15
- data/lib/advanced_billing/models/activate_event_based_component.rb +84 -0
- data/lib/advanced_billing/models/{current_vault.rb → all_vaults.rb} +28 -7
- data/lib/advanced_billing/models/allocation.rb +1 -0
- data/lib/advanced_billing/models/allocation_preview_item.rb +1 -0
- data/lib/advanced_billing/models/apple_pay_payment_profile.rb +232 -0
- data/lib/advanced_billing/models/apple_pay_vault.rb +20 -0
- data/lib/advanced_billing/models/bank_account_attributes.rb +2 -0
- data/lib/advanced_billing/models/bank_account_payment_profile.rb +25 -20
- data/lib/advanced_billing/models/bank_account_vault.rb +19 -9
- data/lib/advanced_billing/models/change_invoice_status_event_data.rb +6 -6
- data/lib/advanced_billing/models/component.rb +1 -0
- data/lib/advanced_billing/models/component_custom_price.rb +33 -14
- data/lib/advanced_billing/models/component_price_point_item.rb +3 -1
- data/lib/advanced_billing/models/create_component_price_point.rb +3 -1
- data/lib/advanced_billing/models/create_customer.rb +11 -1
- data/lib/advanced_billing/models/create_metafield.rb +2 -1
- data/lib/advanced_billing/models/create_or_update_product.rb +7 -4
- data/lib/advanced_billing/models/create_payment_profile.rb +1 -1
- data/lib/advanced_billing/models/create_prepaid_usage_component_price_point.rb +6 -5
- data/lib/advanced_billing/models/create_product_price_point.rb +5 -3
- data/lib/advanced_billing/models/create_subscription.rb +27 -25
- data/lib/advanced_billing/models/credit_card_payment_profile.rb +17 -16
- data/lib/advanced_billing/models/credit_card_vault.rb +117 -0
- data/lib/advanced_billing/models/credit_note.rb +2 -2
- data/lib/advanced_billing/models/customer.rb +11 -1
- data/lib/advanced_billing/models/customer_attributes.rb +12 -1
- data/lib/advanced_billing/models/ebb_component.rb +1 -0
- data/lib/advanced_billing/models/{extended_interval_unit.rb → expiration_interval_unit.rb} +4 -4
- data/lib/advanced_billing/models/full_subscription_group_response.rb +65 -50
- data/lib/advanced_billing/models/get_one_time_token_payment_profile.rb +1 -1
- data/lib/advanced_billing/models/invoice.rb +19 -9
- data/lib/advanced_billing/models/invoice_consolidation_level.rb +2 -2
- data/lib/advanced_billing/models/invoice_refund.rb +13 -1
- data/lib/advanced_billing/models/invoice_status.rb +2 -2
- data/lib/advanced_billing/models/invoice_tax.rb +29 -0
- data/lib/advanced_billing/models/invoice_tax_component_breakout.rb +101 -1
- data/lib/advanced_billing/models/issue_invoice_event_data.rb +6 -6
- data/lib/advanced_billing/models/metered_component.rb +4 -3
- data/lib/advanced_billing/models/offer_item.rb +3 -1
- data/lib/advanced_billing/models/on_off_component.rb +3 -2
- data/lib/advanced_billing/models/paid_invoice.rb +2 -2
- data/lib/advanced_billing/models/pay_pal_vault.rb +29 -0
- data/lib/advanced_billing/models/payment_profile_attributes.rb +5 -5
- data/lib/advanced_billing/models/payment_profile_response.rb +3 -3
- data/lib/advanced_billing/models/payment_type.rb +4 -1
- data/lib/advanced_billing/models/paypal_payment_profile.rb +242 -0
- data/lib/advanced_billing/models/prepaid_usage_component.rb +5 -4
- data/lib/advanced_billing/models/product.rb +2 -2
- data/lib/advanced_billing/models/product_price_point.rb +2 -2
- data/lib/advanced_billing/models/proforma_invoice.rb +6 -6
- data/lib/advanced_billing/models/quantity_based_component.rb +4 -3
- data/lib/advanced_billing/models/refund_invoice_event_data.rb +4 -4
- data/lib/advanced_billing/models/resent_invitation.rb +36 -0
- data/lib/advanced_billing/models/subscription.rb +13 -10
- data/lib/advanced_billing/models/subscription_component.rb +1 -0
- data/lib/advanced_billing/models/subscription_component_subscription.rb +26 -20
- data/lib/advanced_billing/models/subscription_custom_price.rb +5 -2
- data/lib/advanced_billing/models/subscription_group_bank_account.rb +2 -0
- data/lib/advanced_billing/models/subscription_group_credit_card.rb +1 -1
- data/lib/advanced_billing/models/subscription_group_signup_response.rb +39 -30
- data/lib/advanced_billing/models/subscription_state.rb +30 -30
- data/lib/advanced_billing/models/tax_configuration.rb +1 -2
- data/lib/advanced_billing/models/update_component_price_point.rb +3 -1
- data/lib/advanced_billing/models/update_customer.rb +12 -1
- data/lib/advanced_billing/models/update_payment_profile.rb +1 -1
- data/lib/advanced_billing/utilities/file_wrapper.rb +9 -9
- data/lib/advanced_billing/utilities/union_type_lookup.rb +17 -3
- data/lib/advanced_billing.rb +10 -4
- metadata +16 -10
@@ -71,16 +71,18 @@ module AdvancedBilling
|
|
71
71
|
# resulting from these events to take manual action when needed.
|
72
72
|
# * `unpaid` - Indicates an unpaid subscription. A subscription is
|
73
73
|
# marked unpaid if the retry period expires and you have configured your
|
74
|
-
# [Dunning](https://maxio
|
75
|
-
#
|
74
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
75
|
+
# ng-Overview) settings to have a Final Action of `mark the subscription
|
76
|
+
# unpaid`.
|
76
77
|
# * **End of Life States**
|
77
78
|
# * `canceled` - Indicates a canceled subscription. This may happen at
|
78
79
|
# your request (via the API or the web interface) or due to the expiration
|
79
80
|
# of the
|
80
|
-
# [Dunning](https://maxio
|
81
|
-
#
|
82
|
-
# [Reactivation](https://maxio
|
83
|
-
#
|
81
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
82
|
+
# ng-Overview) process without payment. See the
|
83
|
+
# [Reactivation](https://maxio.zendesk.com/hc/en-us/articles/24252109503629-
|
84
|
+
# Reactivating-and-Resuming) documentation for info on how to restart a
|
85
|
+
# canceled subscription.
|
84
86
|
# While a subscription is canceled, its period will not advance, it will
|
85
87
|
# not accrue any new charges, and Advanced Billing will not attempt to
|
86
88
|
# collect the overdue balance.
|
@@ -102,11 +104,12 @@ module AdvancedBilling
|
|
102
104
|
# subscription that completed a no-obligation trial and did not have a card
|
103
105
|
# on file at the expiration of the trial period. See [Product Pricing – No
|
104
106
|
# Obligation
|
105
|
-
# Trials](https://maxio
|
106
|
-
# ) for more details.
|
107
|
+
# Trials](https://maxio.zendesk.com/hc/en-us/articles/24261076617869-Product
|
108
|
+
# -Editing) for more details.
|
107
109
|
# See [Subscription
|
108
|
-
# States](https://maxio
|
109
|
-
# ) for more info about subscription states and state
|
110
|
+
# States](https://maxio.zendesk.com/hc/en-us/articles/24252119027853-Subscri
|
111
|
+
# ption-States) for more info about subscription states and state
|
112
|
+
# transitions.
|
110
113
|
# @return [SubscriptionState]
|
111
114
|
attr_accessor :state
|
112
115
|
|
@@ -143,16 +146,18 @@ module AdvancedBilling
|
|
143
146
|
# resulting from these events to take manual action when needed.
|
144
147
|
# * `unpaid` - Indicates an unpaid subscription. A subscription is
|
145
148
|
# marked unpaid if the retry period expires and you have configured your
|
146
|
-
# [Dunning](https://maxio
|
147
|
-
#
|
149
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
150
|
+
# ng-Overview) settings to have a Final Action of `mark the subscription
|
151
|
+
# unpaid`.
|
148
152
|
# * **End of Life States**
|
149
153
|
# * `canceled` - Indicates a canceled subscription. This may happen at
|
150
154
|
# your request (via the API or the web interface) or due to the expiration
|
151
155
|
# of the
|
152
|
-
# [Dunning](https://maxio
|
153
|
-
#
|
154
|
-
# [Reactivation](https://maxio
|
155
|
-
#
|
156
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
157
|
+
# ng-Overview) process without payment. See the
|
158
|
+
# [Reactivation](https://maxio.zendesk.com/hc/en-us/articles/24252109503629-
|
159
|
+
# Reactivating-and-Resuming) documentation for info on how to restart a
|
160
|
+
# canceled subscription.
|
156
161
|
# While a subscription is canceled, its period will not advance, it will
|
157
162
|
# not accrue any new charges, and Advanced Billing will not attempt to
|
158
163
|
# collect the overdue balance.
|
@@ -174,11 +179,12 @@ module AdvancedBilling
|
|
174
179
|
# subscription that completed a no-obligation trial and did not have a card
|
175
180
|
# on file at the expiration of the trial period. See [Product Pricing – No
|
176
181
|
# Obligation
|
177
|
-
# Trials](https://maxio
|
178
|
-
# ) for more details.
|
182
|
+
# Trials](https://maxio.zendesk.com/hc/en-us/articles/24261076617869-Product
|
183
|
+
# -Editing) for more details.
|
179
184
|
# See [Subscription
|
180
|
-
# States](https://maxio
|
181
|
-
# ) for more info about subscription states and state
|
185
|
+
# States](https://maxio.zendesk.com/hc/en-us/articles/24252119027853-Subscri
|
186
|
+
# ption-States) for more info about subscription states and state
|
187
|
+
# transitions.
|
182
188
|
# @return [TrueClass | FalseClass]
|
183
189
|
attr_accessor :cancel_at_end_of_period
|
184
190
|
|
@@ -215,16 +221,18 @@ module AdvancedBilling
|
|
215
221
|
# resulting from these events to take manual action when needed.
|
216
222
|
# * `unpaid` - Indicates an unpaid subscription. A subscription is
|
217
223
|
# marked unpaid if the retry period expires and you have configured your
|
218
|
-
# [Dunning](https://maxio
|
219
|
-
#
|
224
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
225
|
+
# ng-Overview) settings to have a Final Action of `mark the subscription
|
226
|
+
# unpaid`.
|
220
227
|
# * **End of Life States**
|
221
228
|
# * `canceled` - Indicates a canceled subscription. This may happen at
|
222
229
|
# your request (via the API or the web interface) or due to the expiration
|
223
230
|
# of the
|
224
|
-
# [Dunning](https://maxio
|
225
|
-
#
|
226
|
-
# [Reactivation](https://maxio
|
227
|
-
#
|
231
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
232
|
+
# ng-Overview) process without payment. See the
|
233
|
+
# [Reactivation](https://maxio.zendesk.com/hc/en-us/articles/24252109503629-
|
234
|
+
# Reactivating-and-Resuming) documentation for info on how to restart a
|
235
|
+
# canceled subscription.
|
228
236
|
# While a subscription is canceled, its period will not advance, it will
|
229
237
|
# not accrue any new charges, and Advanced Billing will not attempt to
|
230
238
|
# collect the overdue balance.
|
@@ -246,11 +254,12 @@ module AdvancedBilling
|
|
246
254
|
# subscription that completed a no-obligation trial and did not have a card
|
247
255
|
# on file at the expiration of the trial period. See [Product Pricing – No
|
248
256
|
# Obligation
|
249
|
-
# Trials](https://maxio
|
250
|
-
# ) for more details.
|
257
|
+
# Trials](https://maxio.zendesk.com/hc/en-us/articles/24261076617869-Product
|
258
|
+
# -Editing) for more details.
|
251
259
|
# See [Subscription
|
252
|
-
# States](https://maxio
|
253
|
-
# ) for more info about subscription states and state
|
260
|
+
# States](https://maxio.zendesk.com/hc/en-us/articles/24252119027853-Subscri
|
261
|
+
# ption-States) for more info about subscription states and state
|
262
|
+
# transitions.
|
254
263
|
# @return [Integer]
|
255
264
|
attr_accessor :current_billing_amount_in_cents
|
256
265
|
|
@@ -287,16 +296,18 @@ module AdvancedBilling
|
|
287
296
|
# resulting from these events to take manual action when needed.
|
288
297
|
# * `unpaid` - Indicates an unpaid subscription. A subscription is
|
289
298
|
# marked unpaid if the retry period expires and you have configured your
|
290
|
-
# [Dunning](https://maxio
|
291
|
-
#
|
299
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
300
|
+
# ng-Overview) settings to have a Final Action of `mark the subscription
|
301
|
+
# unpaid`.
|
292
302
|
# * **End of Life States**
|
293
303
|
# * `canceled` - Indicates a canceled subscription. This may happen at
|
294
304
|
# your request (via the API or the web interface) or due to the expiration
|
295
305
|
# of the
|
296
|
-
# [Dunning](https://maxio
|
297
|
-
#
|
298
|
-
# [Reactivation](https://maxio
|
299
|
-
#
|
306
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
307
|
+
# ng-Overview) process without payment. See the
|
308
|
+
# [Reactivation](https://maxio.zendesk.com/hc/en-us/articles/24252109503629-
|
309
|
+
# Reactivating-and-Resuming) documentation for info on how to restart a
|
310
|
+
# canceled subscription.
|
300
311
|
# While a subscription is canceled, its period will not advance, it will
|
301
312
|
# not accrue any new charges, and Advanced Billing will not attempt to
|
302
313
|
# collect the overdue balance.
|
@@ -318,11 +329,12 @@ module AdvancedBilling
|
|
318
329
|
# subscription that completed a no-obligation trial and did not have a card
|
319
330
|
# on file at the expiration of the trial period. See [Product Pricing – No
|
320
331
|
# Obligation
|
321
|
-
# Trials](https://maxio
|
322
|
-
# ) for more details.
|
332
|
+
# Trials](https://maxio.zendesk.com/hc/en-us/articles/24261076617869-Product
|
333
|
+
# -Editing) for more details.
|
323
334
|
# See [Subscription
|
324
|
-
# States](https://maxio
|
325
|
-
# ) for more info about subscription states and state
|
335
|
+
# States](https://maxio.zendesk.com/hc/en-us/articles/24252119027853-Subscri
|
336
|
+
# ption-States) for more info about subscription states and state
|
337
|
+
# transitions.
|
326
338
|
# @return [SubscriptionGroupCustomer]
|
327
339
|
attr_accessor :customer
|
328
340
|
|
@@ -359,16 +371,18 @@ module AdvancedBilling
|
|
359
371
|
# resulting from these events to take manual action when needed.
|
360
372
|
# * `unpaid` - Indicates an unpaid subscription. A subscription is
|
361
373
|
# marked unpaid if the retry period expires and you have configured your
|
362
|
-
# [Dunning](https://maxio
|
363
|
-
#
|
374
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
375
|
+
# ng-Overview) settings to have a Final Action of `mark the subscription
|
376
|
+
# unpaid`.
|
364
377
|
# * **End of Life States**
|
365
378
|
# * `canceled` - Indicates a canceled subscription. This may happen at
|
366
379
|
# your request (via the API or the web interface) or due to the expiration
|
367
380
|
# of the
|
368
|
-
# [Dunning](https://maxio
|
369
|
-
#
|
370
|
-
# [Reactivation](https://maxio
|
371
|
-
#
|
381
|
+
# [Dunning](https://maxio.zendesk.com/hc/en-us/articles/24287076583565-Dunni
|
382
|
+
# ng-Overview) process without payment. See the
|
383
|
+
# [Reactivation](https://maxio.zendesk.com/hc/en-us/articles/24252109503629-
|
384
|
+
# Reactivating-and-Resuming) documentation for info on how to restart a
|
385
|
+
# canceled subscription.
|
372
386
|
# While a subscription is canceled, its period will not advance, it will
|
373
387
|
# not accrue any new charges, and Advanced Billing will not attempt to
|
374
388
|
# collect the overdue balance.
|
@@ -390,11 +404,12 @@ module AdvancedBilling
|
|
390
404
|
# subscription that completed a no-obligation trial and did not have a card
|
391
405
|
# on file at the expiration of the trial period. See [Product Pricing – No
|
392
406
|
# Obligation
|
393
|
-
# Trials](https://maxio
|
394
|
-
# ) for more details.
|
407
|
+
# Trials](https://maxio.zendesk.com/hc/en-us/articles/24261076617869-Product
|
408
|
+
# -Editing) for more details.
|
395
409
|
# See [Subscription
|
396
|
-
# States](https://maxio
|
397
|
-
# ) for more info about subscription states and state
|
410
|
+
# States](https://maxio.zendesk.com/hc/en-us/articles/24252119027853-Subscri
|
411
|
+
# ption-States) for more info about subscription states and state
|
412
|
+
# transitions.
|
398
413
|
# @return [SubscriptionGroupBalances]
|
399
414
|
attr_accessor :account_balances
|
400
415
|
|
@@ -43,7 +43,7 @@ module AdvancedBilling
|
|
43
43
|
|
44
44
|
# The vault that stores the payment profile with the provided `vault_token`.
|
45
45
|
# Use `bogus` for testing.
|
46
|
-
# @return [
|
46
|
+
# @return [CreditCardVault]
|
47
47
|
attr_accessor :current_vault
|
48
48
|
|
49
49
|
# The vault that stores the payment profile with the provided `vault_token`.
|
@@ -81,20 +81,20 @@ module AdvancedBilling
|
|
81
81
|
attr_accessor :paid_date
|
82
82
|
|
83
83
|
# The current status of the invoice. See [Invoice
|
84
|
-
# Statuses](https://maxio
|
85
|
-
#
|
84
|
+
# Statuses](https://maxio.zendesk.com/hc/en-us/articles/24252287829645-Advan
|
85
|
+
# ced-Billing-Invoices-Overview#invoice-statuses) for more.
|
86
86
|
# @return [InvoiceStatus]
|
87
87
|
attr_accessor :status
|
88
88
|
|
89
89
|
# The current status of the invoice. See [Invoice
|
90
|
-
# Statuses](https://maxio
|
91
|
-
#
|
90
|
+
# Statuses](https://maxio.zendesk.com/hc/en-us/articles/24252287829645-Advan
|
91
|
+
# ced-Billing-Invoices-Overview#invoice-statuses) for more.
|
92
92
|
# @return [InvoiceRole]
|
93
93
|
attr_accessor :role
|
94
94
|
|
95
95
|
# The current status of the invoice. See [Invoice
|
96
|
-
# Statuses](https://maxio
|
97
|
-
#
|
96
|
+
# Statuses](https://maxio.zendesk.com/hc/en-us/articles/24252287829645-Advan
|
97
|
+
# ced-Billing-Invoices-Overview#invoice-statuses) for more.
|
98
98
|
# @return [Integer]
|
99
99
|
attr_accessor :parent_invoice_id
|
100
100
|
|
@@ -126,8 +126,8 @@ module AdvancedBilling
|
|
126
126
|
# "Parent" invoices do not have lines of their own, but they have subtotals
|
127
127
|
# and totals which aggregate the member invoice segments.
|
128
128
|
# See also the [invoice consolidation
|
129
|
-
# documentation](https://
|
130
|
-
#
|
129
|
+
# documentation](https://maxio.zendesk.com/hc/en-us/articles/24252269909389-
|
130
|
+
# Invoice-Consolidation).
|
131
131
|
# @return [InvoiceConsolidationLevel]
|
132
132
|
attr_accessor :consolidation_level
|
133
133
|
|
@@ -275,6 +275,10 @@ module AdvancedBilling
|
|
275
275
|
# @return [InvoicePreviousBalance]
|
276
276
|
attr_accessor :previous_balance_data
|
277
277
|
|
278
|
+
# The format is `"YYYY-MM-DD"`.
|
279
|
+
# @return [Date]
|
280
|
+
attr_accessor :public_url_expires_on
|
281
|
+
|
278
282
|
# A mapping from model property names to API property names.
|
279
283
|
def self.names
|
280
284
|
@_hash = {} if @_hash.nil?
|
@@ -331,6 +335,7 @@ module AdvancedBilling
|
|
331
335
|
@_hash['display_settings'] = 'display_settings'
|
332
336
|
@_hash['public_url'] = 'public_url'
|
333
337
|
@_hash['previous_balance_data'] = 'previous_balance_data'
|
338
|
+
@_hash['public_url_expires_on'] = 'public_url_expires_on'
|
334
339
|
@_hash
|
335
340
|
end
|
336
341
|
|
@@ -389,6 +394,7 @@ module AdvancedBilling
|
|
389
394
|
display_settings
|
390
395
|
public_url
|
391
396
|
previous_balance_data
|
397
|
+
public_url_expires_on
|
392
398
|
]
|
393
399
|
end
|
394
400
|
|
@@ -424,7 +430,7 @@ module AdvancedBilling
|
|
424
430
|
credits: SKIP, refunds: SKIP, payments: SKIP,
|
425
431
|
custom_fields: SKIP, display_settings: SKIP,
|
426
432
|
public_url: SKIP, previous_balance_data: SKIP,
|
427
|
-
additional_properties: {})
|
433
|
+
public_url_expires_on: SKIP, additional_properties: {})
|
428
434
|
@id = id unless id == SKIP
|
429
435
|
@uid = uid unless uid == SKIP
|
430
436
|
@site_id = site_id unless site_id == SKIP
|
@@ -480,6 +486,7 @@ module AdvancedBilling
|
|
480
486
|
@display_settings = display_settings unless display_settings == SKIP
|
481
487
|
@public_url = public_url unless public_url == SKIP
|
482
488
|
@previous_balance_data = previous_balance_data unless previous_balance_data == SKIP
|
489
|
+
@public_url_expires_on = public_url_expires_on unless public_url_expires_on == SKIP
|
483
490
|
|
484
491
|
# Add additional model properties to the instance.
|
485
492
|
additional_properties.each do |_name, _value|
|
@@ -637,6 +644,8 @@ module AdvancedBilling
|
|
637
644
|
public_url = hash.key?('public_url') ? hash['public_url'] : SKIP
|
638
645
|
previous_balance_data = InvoicePreviousBalance.from_hash(hash['previous_balance_data']) if
|
639
646
|
hash['previous_balance_data']
|
647
|
+
public_url_expires_on =
|
648
|
+
hash.key?('public_url_expires_on') ? hash['public_url_expires_on'] : SKIP
|
640
649
|
|
641
650
|
# Clean out expected properties from Hash.
|
642
651
|
names.each_value { |k| hash.delete(k) }
|
@@ -694,6 +703,7 @@ module AdvancedBilling
|
|
694
703
|
display_settings: display_settings,
|
695
704
|
public_url: public_url,
|
696
705
|
previous_balance_data: previous_balance_data,
|
706
|
+
public_url_expires_on: public_url_expires_on,
|
697
707
|
additional_properties: hash)
|
698
708
|
end
|
699
709
|
|
@@ -11,8 +11,8 @@ module AdvancedBilling
|
|
11
11
|
# whose contents are composed of invoice segments. "Parent" invoices do not
|
12
12
|
# have lines of their own, but they have subtotals and totals which aggregate
|
13
13
|
# the member invoice segments. See also the [invoice consolidation
|
14
|
-
# documentation](https://
|
15
|
-
# .
|
14
|
+
# documentation](https://maxio.zendesk.com/hc/en-us/articles/24252269909389-In
|
15
|
+
# voice-Consolidation).
|
16
16
|
class InvoiceConsolidationLevel
|
17
17
|
INVOICE_CONSOLIDATION_LEVEL = [
|
18
18
|
# TODO: Write general description for NONE
|
@@ -41,6 +41,10 @@ module AdvancedBilling
|
|
41
41
|
# @return [String]
|
42
42
|
attr_accessor :gateway_handle
|
43
43
|
|
44
|
+
# The transaction ID for the refund as returned from the payment gateway
|
45
|
+
# @return [TrueClass | FalseClass]
|
46
|
+
attr_accessor :ach_late_reject
|
47
|
+
|
44
48
|
# A mapping from model property names to API property names.
|
45
49
|
def self.names
|
46
50
|
@_hash = {} if @_hash.nil?
|
@@ -52,6 +56,7 @@ module AdvancedBilling
|
|
52
56
|
@_hash['gateway_transaction_id'] = 'gateway_transaction_id'
|
53
57
|
@_hash['gateway_used'] = 'gateway_used'
|
54
58
|
@_hash['gateway_handle'] = 'gateway_handle'
|
59
|
+
@_hash['ach_late_reject'] = 'ach_late_reject'
|
55
60
|
@_hash
|
56
61
|
end
|
57
62
|
|
@@ -66,6 +71,7 @@ module AdvancedBilling
|
|
66
71
|
gateway_transaction_id
|
67
72
|
gateway_used
|
68
73
|
gateway_handle
|
74
|
+
ach_late_reject
|
69
75
|
]
|
70
76
|
end
|
71
77
|
|
@@ -74,13 +80,15 @@ module AdvancedBilling
|
|
74
80
|
%w[
|
75
81
|
gateway_transaction_id
|
76
82
|
gateway_handle
|
83
|
+
ach_late_reject
|
77
84
|
]
|
78
85
|
end
|
79
86
|
|
80
87
|
def initialize(transaction_id: SKIP, payment_id: SKIP, memo: SKIP,
|
81
88
|
original_amount: SKIP, applied_amount: SKIP,
|
82
89
|
gateway_transaction_id: SKIP, gateway_used: SKIP,
|
83
|
-
gateway_handle: SKIP,
|
90
|
+
gateway_handle: SKIP, ach_late_reject: SKIP,
|
91
|
+
additional_properties: {})
|
84
92
|
@transaction_id = transaction_id unless transaction_id == SKIP
|
85
93
|
@payment_id = payment_id unless payment_id == SKIP
|
86
94
|
@memo = memo unless memo == SKIP
|
@@ -89,6 +97,7 @@ module AdvancedBilling
|
|
89
97
|
@gateway_transaction_id = gateway_transaction_id unless gateway_transaction_id == SKIP
|
90
98
|
@gateway_used = gateway_used unless gateway_used == SKIP
|
91
99
|
@gateway_handle = gateway_handle unless gateway_handle == SKIP
|
100
|
+
@ach_late_reject = ach_late_reject unless ach_late_reject == SKIP
|
92
101
|
|
93
102
|
# Add additional model properties to the instance.
|
94
103
|
additional_properties.each do |_name, _value|
|
@@ -114,6 +123,8 @@ module AdvancedBilling
|
|
114
123
|
gateway_used = hash.key?('gateway_used') ? hash['gateway_used'] : SKIP
|
115
124
|
gateway_handle =
|
116
125
|
hash.key?('gateway_handle') ? hash['gateway_handle'] : SKIP
|
126
|
+
ach_late_reject =
|
127
|
+
hash.key?('ach_late_reject') ? hash['ach_late_reject'] : SKIP
|
117
128
|
|
118
129
|
# Clean out expected properties from Hash.
|
119
130
|
names.each_value { |k| hash.delete(k) }
|
@@ -127,6 +138,7 @@ module AdvancedBilling
|
|
127
138
|
gateway_transaction_id: gateway_transaction_id,
|
128
139
|
gateway_used: gateway_used,
|
129
140
|
gateway_handle: gateway_handle,
|
141
|
+
ach_late_reject: ach_late_reject,
|
130
142
|
additional_properties: hash)
|
131
143
|
end
|
132
144
|
|
@@ -5,8 +5,8 @@
|
|
5
5
|
|
6
6
|
module AdvancedBilling
|
7
7
|
# The current status of the invoice. See [Invoice
|
8
|
-
# Statuses](https://maxio
|
9
|
-
# -
|
8
|
+
# Statuses](https://maxio.zendesk.com/hc/en-us/articles/24252287829645-Advance
|
9
|
+
# d-Billing-Invoices-Overview#invoice-statuses) for more.
|
10
10
|
class InvoiceStatus
|
11
11
|
INVOICE_STATUS = [
|
12
12
|
# TODO: Write general description for DRAFT
|
@@ -53,6 +53,18 @@ module AdvancedBilling
|
|
53
53
|
# @return [Array[InvoiceTaxComponentBreakout]]
|
54
54
|
attr_accessor :tax_component_breakouts
|
55
55
|
|
56
|
+
# TODO: Write general description for this method
|
57
|
+
# @return [TrueClass | FalseClass]
|
58
|
+
attr_accessor :eu_vat
|
59
|
+
|
60
|
+
# TODO: Write general description for this method
|
61
|
+
# @return [String]
|
62
|
+
attr_accessor :type
|
63
|
+
|
64
|
+
# TODO: Write general description for this method
|
65
|
+
# @return [String]
|
66
|
+
attr_accessor :tax_exempt_amount
|
67
|
+
|
56
68
|
# A mapping from model property names to API property names.
|
57
69
|
def self.names
|
58
70
|
@_hash = {} if @_hash.nil?
|
@@ -67,6 +79,9 @@ module AdvancedBilling
|
|
67
79
|
@_hash['transaction_id'] = 'transaction_id'
|
68
80
|
@_hash['line_item_breakouts'] = 'line_item_breakouts'
|
69
81
|
@_hash['tax_component_breakouts'] = 'tax_component_breakouts'
|
82
|
+
@_hash['eu_vat'] = 'eu_vat'
|
83
|
+
@_hash['type'] = 'type'
|
84
|
+
@_hash['tax_exempt_amount'] = 'tax_exempt_amount'
|
70
85
|
@_hash
|
71
86
|
end
|
72
87
|
|
@@ -84,6 +99,9 @@ module AdvancedBilling
|
|
84
99
|
transaction_id
|
85
100
|
line_item_breakouts
|
86
101
|
tax_component_breakouts
|
102
|
+
eu_vat
|
103
|
+
type
|
104
|
+
tax_exempt_amount
|
87
105
|
]
|
88
106
|
end
|
89
107
|
|
@@ -98,6 +116,7 @@ module AdvancedBilling
|
|
98
116
|
source_id: SKIP, percentage: SKIP, taxable_amount: SKIP,
|
99
117
|
tax_amount: SKIP, transaction_id: SKIP,
|
100
118
|
line_item_breakouts: SKIP, tax_component_breakouts: SKIP,
|
119
|
+
eu_vat: SKIP, type: SKIP, tax_exempt_amount: SKIP,
|
101
120
|
additional_properties: {})
|
102
121
|
@uid = uid unless uid == SKIP
|
103
122
|
@title = title unless title == SKIP
|
@@ -110,6 +129,9 @@ module AdvancedBilling
|
|
110
129
|
@transaction_id = transaction_id unless transaction_id == SKIP
|
111
130
|
@line_item_breakouts = line_item_breakouts unless line_item_breakouts == SKIP
|
112
131
|
@tax_component_breakouts = tax_component_breakouts unless tax_component_breakouts == SKIP
|
132
|
+
@eu_vat = eu_vat unless eu_vat == SKIP
|
133
|
+
@type = type unless type == SKIP
|
134
|
+
@tax_exempt_amount = tax_exempt_amount unless tax_exempt_amount == SKIP
|
113
135
|
|
114
136
|
# Add additional model properties to the instance.
|
115
137
|
additional_properties.each do |_name, _value|
|
@@ -153,6 +175,10 @@ module AdvancedBilling
|
|
153
175
|
end
|
154
176
|
|
155
177
|
tax_component_breakouts = SKIP unless hash.key?('tax_component_breakouts')
|
178
|
+
eu_vat = hash.key?('eu_vat') ? hash['eu_vat'] : SKIP
|
179
|
+
type = hash.key?('type') ? hash['type'] : SKIP
|
180
|
+
tax_exempt_amount =
|
181
|
+
hash.key?('tax_exempt_amount') ? hash['tax_exempt_amount'] : SKIP
|
156
182
|
|
157
183
|
# Clean out expected properties from Hash.
|
158
184
|
names.each_value { |k| hash.delete(k) }
|
@@ -169,6 +195,9 @@ module AdvancedBilling
|
|
169
195
|
transaction_id: transaction_id,
|
170
196
|
line_item_breakouts: line_item_breakouts,
|
171
197
|
tax_component_breakouts: tax_component_breakouts,
|
198
|
+
eu_vat: eu_vat,
|
199
|
+
type: type,
|
200
|
+
tax_exempt_amount: tax_exempt_amount,
|
172
201
|
additional_properties: hash)
|
173
202
|
end
|
174
203
|
|
@@ -25,6 +25,46 @@ module AdvancedBilling
|
|
25
25
|
# @return [String]
|
26
26
|
attr_accessor :subdivision_code
|
27
27
|
|
28
|
+
# TODO: Write general description for this method
|
29
|
+
# @return [String]
|
30
|
+
attr_accessor :tax_amount
|
31
|
+
|
32
|
+
# TODO: Write general description for this method
|
33
|
+
# @return [String]
|
34
|
+
attr_accessor :taxable_amount
|
35
|
+
|
36
|
+
# TODO: Write general description for this method
|
37
|
+
# @return [String]
|
38
|
+
attr_accessor :tax_exempt_amount
|
39
|
+
|
40
|
+
# TODO: Write general description for this method
|
41
|
+
# @return [String]
|
42
|
+
attr_accessor :non_taxable_amount
|
43
|
+
|
44
|
+
# TODO: Write general description for this method
|
45
|
+
# @return [String]
|
46
|
+
attr_accessor :tax_name
|
47
|
+
|
48
|
+
# TODO: Write general description for this method
|
49
|
+
# @return [String]
|
50
|
+
attr_accessor :tax_type
|
51
|
+
|
52
|
+
# TODO: Write general description for this method
|
53
|
+
# @return [String]
|
54
|
+
attr_accessor :rate_type
|
55
|
+
|
56
|
+
# TODO: Write general description for this method
|
57
|
+
# @return [Integer]
|
58
|
+
attr_accessor :tax_authority_type
|
59
|
+
|
60
|
+
# TODO: Write general description for this method
|
61
|
+
# @return [String]
|
62
|
+
attr_accessor :state_assigned_no
|
63
|
+
|
64
|
+
# TODO: Write general description for this method
|
65
|
+
# @return [String]
|
66
|
+
attr_accessor :tax_sub_type
|
67
|
+
|
28
68
|
# A mapping from model property names to API property names.
|
29
69
|
def self.names
|
30
70
|
@_hash = {} if @_hash.nil?
|
@@ -32,6 +72,16 @@ module AdvancedBilling
|
|
32
72
|
@_hash['percentage'] = 'percentage'
|
33
73
|
@_hash['country_code'] = 'country_code'
|
34
74
|
@_hash['subdivision_code'] = 'subdivision_code'
|
75
|
+
@_hash['tax_amount'] = 'tax_amount'
|
76
|
+
@_hash['taxable_amount'] = 'taxable_amount'
|
77
|
+
@_hash['tax_exempt_amount'] = 'tax_exempt_amount'
|
78
|
+
@_hash['non_taxable_amount'] = 'non_taxable_amount'
|
79
|
+
@_hash['tax_name'] = 'tax_name'
|
80
|
+
@_hash['tax_type'] = 'tax_type'
|
81
|
+
@_hash['rate_type'] = 'rate_type'
|
82
|
+
@_hash['tax_authority_type'] = 'tax_authority_type'
|
83
|
+
@_hash['state_assigned_no'] = 'state_assigned_no'
|
84
|
+
@_hash['tax_sub_type'] = 'tax_sub_type'
|
35
85
|
@_hash
|
36
86
|
end
|
37
87
|
|
@@ -42,6 +92,16 @@ module AdvancedBilling
|
|
42
92
|
percentage
|
43
93
|
country_code
|
44
94
|
subdivision_code
|
95
|
+
tax_amount
|
96
|
+
taxable_amount
|
97
|
+
tax_exempt_amount
|
98
|
+
non_taxable_amount
|
99
|
+
tax_name
|
100
|
+
tax_type
|
101
|
+
rate_type
|
102
|
+
tax_authority_type
|
103
|
+
state_assigned_no
|
104
|
+
tax_sub_type
|
45
105
|
]
|
46
106
|
end
|
47
107
|
|
@@ -51,11 +111,26 @@ module AdvancedBilling
|
|
51
111
|
end
|
52
112
|
|
53
113
|
def initialize(tax_rule_id: SKIP, percentage: SKIP, country_code: SKIP,
|
54
|
-
subdivision_code: SKIP,
|
114
|
+
subdivision_code: SKIP, tax_amount: SKIP,
|
115
|
+
taxable_amount: SKIP, tax_exempt_amount: SKIP,
|
116
|
+
non_taxable_amount: SKIP, tax_name: SKIP, tax_type: SKIP,
|
117
|
+
rate_type: SKIP, tax_authority_type: SKIP,
|
118
|
+
state_assigned_no: SKIP, tax_sub_type: SKIP,
|
119
|
+
additional_properties: {})
|
55
120
|
@tax_rule_id = tax_rule_id unless tax_rule_id == SKIP
|
56
121
|
@percentage = percentage unless percentage == SKIP
|
57
122
|
@country_code = country_code unless country_code == SKIP
|
58
123
|
@subdivision_code = subdivision_code unless subdivision_code == SKIP
|
124
|
+
@tax_amount = tax_amount unless tax_amount == SKIP
|
125
|
+
@taxable_amount = taxable_amount unless taxable_amount == SKIP
|
126
|
+
@tax_exempt_amount = tax_exempt_amount unless tax_exempt_amount == SKIP
|
127
|
+
@non_taxable_amount = non_taxable_amount unless non_taxable_amount == SKIP
|
128
|
+
@tax_name = tax_name unless tax_name == SKIP
|
129
|
+
@tax_type = tax_type unless tax_type == SKIP
|
130
|
+
@rate_type = rate_type unless rate_type == SKIP
|
131
|
+
@tax_authority_type = tax_authority_type unless tax_authority_type == SKIP
|
132
|
+
@state_assigned_no = state_assigned_no unless state_assigned_no == SKIP
|
133
|
+
@tax_sub_type = tax_sub_type unless tax_sub_type == SKIP
|
59
134
|
|
60
135
|
# Add additional model properties to the instance.
|
61
136
|
additional_properties.each do |_name, _value|
|
@@ -73,6 +148,21 @@ module AdvancedBilling
|
|
73
148
|
country_code = hash.key?('country_code') ? hash['country_code'] : SKIP
|
74
149
|
subdivision_code =
|
75
150
|
hash.key?('subdivision_code') ? hash['subdivision_code'] : SKIP
|
151
|
+
tax_amount = hash.key?('tax_amount') ? hash['tax_amount'] : SKIP
|
152
|
+
taxable_amount =
|
153
|
+
hash.key?('taxable_amount') ? hash['taxable_amount'] : SKIP
|
154
|
+
tax_exempt_amount =
|
155
|
+
hash.key?('tax_exempt_amount') ? hash['tax_exempt_amount'] : SKIP
|
156
|
+
non_taxable_amount =
|
157
|
+
hash.key?('non_taxable_amount') ? hash['non_taxable_amount'] : SKIP
|
158
|
+
tax_name = hash.key?('tax_name') ? hash['tax_name'] : SKIP
|
159
|
+
tax_type = hash.key?('tax_type') ? hash['tax_type'] : SKIP
|
160
|
+
rate_type = hash.key?('rate_type') ? hash['rate_type'] : SKIP
|
161
|
+
tax_authority_type =
|
162
|
+
hash.key?('tax_authority_type') ? hash['tax_authority_type'] : SKIP
|
163
|
+
state_assigned_no =
|
164
|
+
hash.key?('state_assigned_no') ? hash['state_assigned_no'] : SKIP
|
165
|
+
tax_sub_type = hash.key?('tax_sub_type') ? hash['tax_sub_type'] : SKIP
|
76
166
|
|
77
167
|
# Clean out expected properties from Hash.
|
78
168
|
names.each_value { |k| hash.delete(k) }
|
@@ -82,6 +172,16 @@ module AdvancedBilling
|
|
82
172
|
percentage: percentage,
|
83
173
|
country_code: country_code,
|
84
174
|
subdivision_code: subdivision_code,
|
175
|
+
tax_amount: tax_amount,
|
176
|
+
taxable_amount: taxable_amount,
|
177
|
+
tax_exempt_amount: tax_exempt_amount,
|
178
|
+
non_taxable_amount: non_taxable_amount,
|
179
|
+
tax_name: tax_name,
|
180
|
+
tax_type: tax_type,
|
181
|
+
rate_type: rate_type,
|
182
|
+
tax_authority_type: tax_authority_type,
|
183
|
+
state_assigned_no: state_assigned_no,
|
184
|
+
tax_sub_type: tax_sub_type,
|
85
185
|
additional_properties: hash)
|
86
186
|
end
|
87
187
|
|
@@ -19,20 +19,20 @@ module AdvancedBilling
|
|
19
19
|
# "Parent" invoices do not have lines of their own, but they have subtotals
|
20
20
|
# and totals which aggregate the member invoice segments.
|
21
21
|
# See also the [invoice consolidation
|
22
|
-
# documentation](https://
|
23
|
-
#
|
22
|
+
# documentation](https://maxio.zendesk.com/hc/en-us/articles/24252269909389-
|
23
|
+
# Invoice-Consolidation).
|
24
24
|
# @return [InvoiceConsolidationLevel]
|
25
25
|
attr_accessor :consolidation_level
|
26
26
|
|
27
27
|
# The status of the invoice before event occurrence. See [Invoice
|
28
|
-
# Statuses](https://maxio
|
29
|
-
#
|
28
|
+
# Statuses](https://maxio.zendesk.com/hc/en-us/articles/24252287829645-Advan
|
29
|
+
# ced-Billing-Invoices-Overview#invoice-statuses) for more.
|
30
30
|
# @return [InvoiceStatus]
|
31
31
|
attr_accessor :from_status
|
32
32
|
|
33
33
|
# The status of the invoice after event occurrence. See [Invoice
|
34
|
-
# Statuses](https://maxio
|
35
|
-
#
|
34
|
+
# Statuses](https://maxio.zendesk.com/hc/en-us/articles/24252287829645-Advan
|
35
|
+
# ced-Billing-Invoices-Overview#invoice-statuses) for more.
|
36
36
|
# @return [InvoiceStatus]
|
37
37
|
attr_accessor :to_status
|
38
38
|
|