maxio-advanced-billing-sdk 4.0.0 → 5.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (127) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +45 -45
  3. data/lib/advanced_billing/configuration.rb +2 -2
  4. data/lib/advanced_billing/controllers/advance_invoice_controller.rb +24 -24
  5. data/lib/advanced_billing/controllers/api_exports_controller.rb +57 -57
  6. data/lib/advanced_billing/controllers/base_controller.rb +10 -10
  7. data/lib/advanced_billing/controllers/billing_portal_controller.rb +33 -32
  8. data/lib/advanced_billing/controllers/component_price_points_controller.rb +60 -60
  9. data/lib/advanced_billing/controllers/components_controller.rb +110 -107
  10. data/lib/advanced_billing/controllers/coupons_controller.rb +89 -89
  11. data/lib/advanced_billing/controllers/custom_fields_controller.rb +76 -76
  12. data/lib/advanced_billing/controllers/customers_controller.rb +45 -41
  13. data/lib/advanced_billing/controllers/events_based_billing_segments_controller.rb +53 -53
  14. data/lib/advanced_billing/controllers/events_controller.rb +16 -15
  15. data/lib/advanced_billing/controllers/insights_controller.rb +17 -17
  16. data/lib/advanced_billing/controllers/invoices_controller.rb +99 -99
  17. data/lib/advanced_billing/controllers/offers_controller.rb +18 -15
  18. data/lib/advanced_billing/controllers/payment_profiles_controller.rb +107 -104
  19. data/lib/advanced_billing/controllers/product_families_controller.rb +26 -26
  20. data/lib/advanced_billing/controllers/product_price_points_controller.rb +62 -62
  21. data/lib/advanced_billing/controllers/products_controller.rb +37 -37
  22. data/lib/advanced_billing/controllers/proforma_invoices_controller.rb +61 -61
  23. data/lib/advanced_billing/controllers/reason_codes_controller.rb +35 -35
  24. data/lib/advanced_billing/controllers/referral_codes_controller.rb +9 -8
  25. data/lib/advanced_billing/controllers/sales_commissions_controller.rb +13 -13
  26. data/lib/advanced_billing/controllers/sites_controller.rb +11 -10
  27. data/lib/advanced_billing/controllers/subscription_components_controller.rb +170 -161
  28. data/lib/advanced_billing/controllers/subscription_group_invoice_account_controller.rb +23 -23
  29. data/lib/advanced_billing/controllers/subscription_group_status_controller.rb +21 -21
  30. data/lib/advanced_billing/controllers/subscription_groups_controller.rb +54 -54
  31. data/lib/advanced_billing/controllers/subscription_invoice_account_controller.rb +37 -37
  32. data/lib/advanced_billing/controllers/subscription_notes_controller.rb +20 -16
  33. data/lib/advanced_billing/controllers/subscription_products_controller.rb +20 -18
  34. data/lib/advanced_billing/controllers/subscription_status_controller.rb +74 -74
  35. data/lib/advanced_billing/controllers/subscriptions_controller.rb +163 -160
  36. data/lib/advanced_billing/controllers/webhooks_controller.rb +45 -44
  37. data/lib/advanced_billing/exceptions/component_allocation_error_exception.rb +15 -15
  38. data/lib/advanced_billing/exceptions/component_price_point_error_exception.rb +15 -15
  39. data/lib/advanced_billing/exceptions/customer_error_response_exception.rb +15 -15
  40. data/lib/advanced_billing/exceptions/error_array_map_response_exception.rb +15 -15
  41. data/lib/advanced_billing/exceptions/error_list_response_exception.rb +15 -15
  42. data/lib/advanced_billing/exceptions/error_string_map_response_exception.rb +15 -15
  43. data/lib/advanced_billing/exceptions/event_based_billing_list_segments_errors_exception.rb +15 -15
  44. data/lib/advanced_billing/exceptions/event_based_billing_segment_errors_exception.rb +15 -15
  45. data/lib/advanced_billing/exceptions/event_based_billing_segment_exception.rb +15 -15
  46. data/lib/advanced_billing/exceptions/product_price_point_error_response_exception.rb +15 -15
  47. data/lib/advanced_billing/exceptions/proforma_bad_request_error_response_exception.rb +15 -15
  48. data/lib/advanced_billing/exceptions/refund_prepayment_base_errors_response_exception.rb +15 -15
  49. data/lib/advanced_billing/exceptions/single_error_response_exception.rb +15 -15
  50. data/lib/advanced_billing/exceptions/single_string_error_response_exception.rb +15 -15
  51. data/lib/advanced_billing/exceptions/subscription_add_coupon_error_exception.rb +15 -15
  52. data/lib/advanced_billing/exceptions/subscription_component_allocation_error_exception.rb +15 -15
  53. data/lib/advanced_billing/exceptions/subscription_group_create_error_response_exception.rb +15 -15
  54. data/lib/advanced_billing/exceptions/subscription_group_signup_error_response_exception.rb +15 -15
  55. data/lib/advanced_billing/exceptions/subscription_group_update_error_response_exception.rb +15 -15
  56. data/lib/advanced_billing/exceptions/subscription_remove_coupon_errors_exception.rb +15 -15
  57. data/lib/advanced_billing/exceptions/subscriptions_mrr_error_response_exception.rb +15 -15
  58. data/lib/advanced_billing/exceptions/too_many_management_link_requests_error_exception.rb +15 -15
  59. data/lib/advanced_billing/models/activate_event_based_component.rb +84 -0
  60. data/lib/advanced_billing/models/{current_vault.rb → all_vaults.rb} +28 -7
  61. data/lib/advanced_billing/models/allocation.rb +1 -0
  62. data/lib/advanced_billing/models/allocation_preview_item.rb +1 -0
  63. data/lib/advanced_billing/models/apple_pay_payment_profile.rb +232 -0
  64. data/lib/advanced_billing/models/apple_pay_vault.rb +20 -0
  65. data/lib/advanced_billing/models/bank_account_attributes.rb +2 -0
  66. data/lib/advanced_billing/models/bank_account_payment_profile.rb +25 -20
  67. data/lib/advanced_billing/models/bank_account_vault.rb +19 -9
  68. data/lib/advanced_billing/models/change_invoice_status_event_data.rb +6 -6
  69. data/lib/advanced_billing/models/component.rb +1 -0
  70. data/lib/advanced_billing/models/component_custom_price.rb +33 -14
  71. data/lib/advanced_billing/models/component_price_point_item.rb +3 -1
  72. data/lib/advanced_billing/models/create_component_price_point.rb +3 -1
  73. data/lib/advanced_billing/models/create_customer.rb +11 -1
  74. data/lib/advanced_billing/models/create_metafield.rb +2 -1
  75. data/lib/advanced_billing/models/create_or_update_product.rb +7 -4
  76. data/lib/advanced_billing/models/create_payment_profile.rb +1 -1
  77. data/lib/advanced_billing/models/create_prepaid_usage_component_price_point.rb +6 -5
  78. data/lib/advanced_billing/models/create_product_price_point.rb +5 -3
  79. data/lib/advanced_billing/models/create_subscription.rb +27 -25
  80. data/lib/advanced_billing/models/credit_card_payment_profile.rb +17 -16
  81. data/lib/advanced_billing/models/credit_card_vault.rb +117 -0
  82. data/lib/advanced_billing/models/credit_note.rb +2 -2
  83. data/lib/advanced_billing/models/customer.rb +11 -1
  84. data/lib/advanced_billing/models/customer_attributes.rb +12 -1
  85. data/lib/advanced_billing/models/ebb_component.rb +1 -0
  86. data/lib/advanced_billing/models/{extended_interval_unit.rb → expiration_interval_unit.rb} +4 -4
  87. data/lib/advanced_billing/models/full_subscription_group_response.rb +65 -50
  88. data/lib/advanced_billing/models/get_one_time_token_payment_profile.rb +1 -1
  89. data/lib/advanced_billing/models/invoice.rb +19 -9
  90. data/lib/advanced_billing/models/invoice_consolidation_level.rb +2 -2
  91. data/lib/advanced_billing/models/invoice_refund.rb +13 -1
  92. data/lib/advanced_billing/models/invoice_status.rb +2 -2
  93. data/lib/advanced_billing/models/invoice_tax.rb +29 -0
  94. data/lib/advanced_billing/models/invoice_tax_component_breakout.rb +101 -1
  95. data/lib/advanced_billing/models/issue_invoice_event_data.rb +6 -6
  96. data/lib/advanced_billing/models/metered_component.rb +4 -3
  97. data/lib/advanced_billing/models/offer_item.rb +3 -1
  98. data/lib/advanced_billing/models/on_off_component.rb +3 -2
  99. data/lib/advanced_billing/models/paid_invoice.rb +2 -2
  100. data/lib/advanced_billing/models/pay_pal_vault.rb +29 -0
  101. data/lib/advanced_billing/models/payment_profile_attributes.rb +5 -5
  102. data/lib/advanced_billing/models/payment_profile_response.rb +3 -3
  103. data/lib/advanced_billing/models/payment_type.rb +4 -1
  104. data/lib/advanced_billing/models/paypal_payment_profile.rb +242 -0
  105. data/lib/advanced_billing/models/prepaid_usage_component.rb +5 -4
  106. data/lib/advanced_billing/models/product.rb +2 -2
  107. data/lib/advanced_billing/models/product_price_point.rb +2 -2
  108. data/lib/advanced_billing/models/proforma_invoice.rb +6 -6
  109. data/lib/advanced_billing/models/quantity_based_component.rb +4 -3
  110. data/lib/advanced_billing/models/refund_invoice_event_data.rb +4 -4
  111. data/lib/advanced_billing/models/resent_invitation.rb +36 -0
  112. data/lib/advanced_billing/models/subscription.rb +13 -10
  113. data/lib/advanced_billing/models/subscription_component.rb +1 -0
  114. data/lib/advanced_billing/models/subscription_component_subscription.rb +26 -20
  115. data/lib/advanced_billing/models/subscription_custom_price.rb +5 -2
  116. data/lib/advanced_billing/models/subscription_group_bank_account.rb +2 -0
  117. data/lib/advanced_billing/models/subscription_group_credit_card.rb +1 -1
  118. data/lib/advanced_billing/models/subscription_group_signup_response.rb +39 -30
  119. data/lib/advanced_billing/models/subscription_state.rb +30 -30
  120. data/lib/advanced_billing/models/tax_configuration.rb +1 -2
  121. data/lib/advanced_billing/models/update_component_price_point.rb +3 -1
  122. data/lib/advanced_billing/models/update_customer.rb +12 -1
  123. data/lib/advanced_billing/models/update_payment_profile.rb +1 -1
  124. data/lib/advanced_billing/utilities/file_wrapper.rb +9 -9
  125. data/lib/advanced_billing/utilities/union_type_lookup.rb +17 -3
  126. data/lib/advanced_billing.rb +10 -4
  127. 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-chargify.zendesk.com/hc/en-us/articles/54055051410
75
- # 05) settings to have a Final Action of `mark the subscription unpaid`.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
81
- # 05) process without payment. See the
82
- # [Reactivation](https://maxio-chargify.zendesk.com/hc/en-us/articles/540455
83
- # 9291021) documentation for info on how to restart a canceled subscription.
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-chargify.zendesk.com/hc/en-us/articles/5405246782221
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-chargify.zendesk.com/hc/en-us/articles/5404222005773
109
- # ) for more info about subscription states and state transitions.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
147
- # 05) settings to have a Final Action of `mark the subscription unpaid`.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
153
- # 05) process without payment. See the
154
- # [Reactivation](https://maxio-chargify.zendesk.com/hc/en-us/articles/540455
155
- # 9291021) documentation for info on how to restart a canceled subscription.
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-chargify.zendesk.com/hc/en-us/articles/5405246782221
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-chargify.zendesk.com/hc/en-us/articles/5404222005773
181
- # ) for more info about subscription states and state transitions.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
219
- # 05) settings to have a Final Action of `mark the subscription unpaid`.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
225
- # 05) process without payment. See the
226
- # [Reactivation](https://maxio-chargify.zendesk.com/hc/en-us/articles/540455
227
- # 9291021) documentation for info on how to restart a canceled subscription.
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-chargify.zendesk.com/hc/en-us/articles/5405246782221
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-chargify.zendesk.com/hc/en-us/articles/5404222005773
253
- # ) for more info about subscription states and state transitions.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
291
- # 05) settings to have a Final Action of `mark the subscription unpaid`.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
297
- # 05) process without payment. See the
298
- # [Reactivation](https://maxio-chargify.zendesk.com/hc/en-us/articles/540455
299
- # 9291021) documentation for info on how to restart a canceled subscription.
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-chargify.zendesk.com/hc/en-us/articles/5405246782221
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-chargify.zendesk.com/hc/en-us/articles/5404222005773
325
- # ) for more info about subscription states and state transitions.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
363
- # 05) settings to have a Final Action of `mark the subscription unpaid`.
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-chargify.zendesk.com/hc/en-us/articles/54055051410
369
- # 05) process without payment. See the
370
- # [Reactivation](https://maxio-chargify.zendesk.com/hc/en-us/articles/540455
371
- # 9291021) documentation for info on how to restart a canceled subscription.
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-chargify.zendesk.com/hc/en-us/articles/5405246782221
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-chargify.zendesk.com/hc/en-us/articles/5404222005773
397
- # ) for more info about subscription states and state transitions.
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 [CurrentVault]
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-chargify.zendesk.com/hc/en-us/articles/54050787942
85
- # 53-Introduction-to-Invoices#invoice-statuses) for more.
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-chargify.zendesk.com/hc/en-us/articles/54050787942
91
- # 53-Introduction-to-Invoices#invoice-statuses) for more.
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-chargify.zendesk.com/hc/en-us/articles/54050787942
97
- # 53-Introduction-to-Invoices#invoice-statuses) for more.
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://chargify.zendesk.com/hc/en-us/articles/440774639183
130
- # 5).
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://chargify.zendesk.com/hc/en-us/articles/4407746391835)
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, additional_properties: {})
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-chargify.zendesk.com/hc/en-us/articles/5405078794253
9
- # -Introduction-to-Invoices#invoice-statuses) for more.
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, additional_properties: {})
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://chargify.zendesk.com/hc/en-us/articles/440774639183
23
- # 5).
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-chargify.zendesk.com/hc/en-us/articles/54050787942
29
- # 53-Introduction-to-Invoices#invoice-statusess) for more.
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-chargify.zendesk.com/hc/en-us/articles/54050787942
35
- # 53-Introduction-to-Invoices#invoice-statusess) for more.
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