maxio-advanced-billing-sdk 8.0.0 → 9.1.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.
Files changed (120) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE +1 -1
  3. data/README.md +48 -47
  4. data/lib/advanced_billing/client.rb +6 -0
  5. data/lib/advanced_billing/controllers/advance_invoice_controller.rb +7 -7
  6. data/lib/advanced_billing/controllers/api_exports_controller.rb +12 -15
  7. data/lib/advanced_billing/controllers/base_controller.rb +1 -1
  8. data/lib/advanced_billing/controllers/billing_portal_controller.rb +10 -10
  9. data/lib/advanced_billing/controllers/component_price_points_controller.rb +74 -21
  10. data/lib/advanced_billing/controllers/components_controller.rb +26 -30
  11. data/lib/advanced_billing/controllers/coupons_controller.rb +34 -39
  12. data/lib/advanced_billing/controllers/custom_fields_controller.rb +4 -3
  13. data/lib/advanced_billing/controllers/customers_controller.rb +10 -9
  14. data/lib/advanced_billing/controllers/events_based_billing_segments_controller.rb +12 -13
  15. data/lib/advanced_billing/controllers/events_controller.rb +6 -5
  16. data/lib/advanced_billing/controllers/insights_controller.rb +4 -5
  17. data/lib/advanced_billing/controllers/invoices_controller.rb +34 -27
  18. data/lib/advanced_billing/controllers/offers_controller.rb +7 -8
  19. data/lib/advanced_billing/controllers/payment_profiles_controller.rb +33 -98
  20. data/lib/advanced_billing/controllers/product_families_controller.rb +2 -2
  21. data/lib/advanced_billing/controllers/product_price_points_controller.rb +4 -5
  22. data/lib/advanced_billing/controllers/products_controller.rb +3 -3
  23. data/lib/advanced_billing/controllers/proforma_invoices_controller.rb +71 -33
  24. data/lib/advanced_billing/controllers/reason_codes_controller.rb +9 -12
  25. data/lib/advanced_billing/controllers/referral_codes_controller.rb +3 -3
  26. data/lib/advanced_billing/controllers/sales_commissions_controller.rb +3 -3
  27. data/lib/advanced_billing/controllers/sites_controller.rb +9 -8
  28. data/lib/advanced_billing/controllers/subscription_components_controller.rb +79 -106
  29. data/lib/advanced_billing/controllers/subscription_group_invoice_account_controller.rb +9 -12
  30. data/lib/advanced_billing/controllers/subscription_group_status_controller.rb +21 -11
  31. data/lib/advanced_billing/controllers/subscription_groups_controller.rb +18 -16
  32. data/lib/advanced_billing/controllers/subscription_invoice_account_controller.rb +28 -20
  33. data/lib/advanced_billing/controllers/subscription_notes_controller.rb +11 -12
  34. data/lib/advanced_billing/controllers/subscription_products_controller.rb +17 -75
  35. data/lib/advanced_billing/controllers/subscription_renewals_controller.rb +351 -0
  36. data/lib/advanced_billing/controllers/subscription_status_controller.rb +62 -45
  37. data/lib/advanced_billing/controllers/subscriptions_controller.rb +50 -41
  38. data/lib/advanced_billing/controllers/webhooks_controller.rb +5 -5
  39. data/lib/advanced_billing/models/activate_event_based_component.rb +4 -3
  40. data/lib/advanced_billing/models/allocate_components.rb +0 -2
  41. data/lib/advanced_billing/models/allocation.rb +0 -6
  42. data/lib/advanced_billing/models/allocation_preview_item.rb +0 -3
  43. data/lib/advanced_billing/models/allocation_settings.rb +0 -2
  44. data/lib/advanced_billing/models/available_actions.rb +73 -0
  45. data/lib/advanced_billing/models/bank_account_payment_profile.rb +21 -23
  46. data/lib/advanced_billing/models/billing_schedule.rb +11 -7
  47. data/lib/advanced_billing/models/calendar_billing.rb +1 -3
  48. data/lib/advanced_billing/models/cancellation_options.rb +71 -6
  49. data/lib/advanced_billing/models/chjs_tokenization_failure.rb +98 -0
  50. data/lib/advanced_billing/models/chjs_tokenization_success.rb +102 -0
  51. data/lib/advanced_billing/models/clone_component_price_point.rb +81 -0
  52. data/lib/advanced_billing/models/clone_component_price_point_request.rb +71 -0
  53. data/lib/advanced_billing/models/component.rb +0 -2
  54. data/lib/advanced_billing/models/component_custom_price.rb +35 -9
  55. data/lib/advanced_billing/models/component_price_point.rb +2 -1
  56. data/lib/advanced_billing/models/component_price_point_currency_overage_response.rb +71 -0
  57. data/lib/advanced_billing/models/contract.rb +104 -0
  58. data/lib/advanced_billing/models/create_allocation.rb +101 -38
  59. data/lib/advanced_billing/models/create_invoice.rb +4 -1
  60. data/lib/advanced_billing/models/create_payment_profile.rb +8 -5
  61. data/lib/advanced_billing/models/create_subscription.rb +5 -4
  62. data/lib/advanced_billing/models/create_usage.rb +4 -3
  63. data/lib/advanced_billing/models/credit_card_payment_profile.rb +6 -6
  64. data/lib/advanced_billing/models/credit_note_line_item.rb +51 -17
  65. data/lib/advanced_billing/models/credit_type.rb +1 -2
  66. data/lib/advanced_billing/models/currency_overage_prices.rb +433 -0
  67. data/lib/advanced_billing/models/customer.rb +15 -5
  68. data/lib/advanced_billing/models/deliver_proforma_invoice_request.rb +97 -0
  69. data/lib/advanced_billing/models/downgrade_credit_credit_type.rb +43 -0
  70. data/lib/advanced_billing/models/event.rb +2 -0
  71. data/lib/advanced_billing/models/event_key.rb +12 -0
  72. data/lib/advanced_billing/models/invoice_line_item.rb +58 -21
  73. data/lib/advanced_billing/models/nested_subscription_group.rb +0 -10
  74. data/lib/advanced_billing/models/on_off_component.rb +0 -3
  75. data/lib/advanced_billing/models/payment_profile_attributes.rb +6 -6
  76. data/lib/advanced_billing/models/payment_profile_params.rb +103 -0
  77. data/lib/advanced_billing/models/prepaid_configuration.rb +0 -10
  78. data/lib/advanced_billing/models/prepaid_usage_component.rb +0 -3
  79. data/lib/advanced_billing/models/preview_allocations_request.rb +0 -2
  80. data/lib/advanced_billing/models/product.rb +0 -10
  81. data/lib/advanced_billing/models/product_family.rb +22 -12
  82. data/lib/advanced_billing/models/proforma_invoice.rb +17 -3
  83. data/lib/advanced_billing/models/public_signup_page.rb +0 -10
  84. data/lib/advanced_billing/models/quantity_based_component.rb +0 -3
  85. data/lib/advanced_billing/models/reactivate_subscription_request.rb +8 -7
  86. data/lib/advanced_billing/models/register.rb +103 -0
  87. data/lib/advanced_billing/models/scheduled_renewal_component_custom_price.rb +127 -0
  88. data/lib/advanced_billing/models/scheduled_renewal_configuration.rb +212 -0
  89. data/lib/advanced_billing/models/scheduled_renewal_configuration_item.rb +195 -0
  90. data/lib/advanced_billing/models/scheduled_renewal_configuration_item_request.rb +87 -0
  91. data/lib/advanced_billing/models/scheduled_renewal_configuration_item_response.rb +82 -0
  92. data/lib/advanced_billing/models/scheduled_renewal_configuration_request.rb +73 -0
  93. data/lib/advanced_billing/models/scheduled_renewal_configuration_request_body.rb +141 -0
  94. data/lib/advanced_billing/models/scheduled_renewal_configuration_response.rb +81 -0
  95. data/lib/advanced_billing/models/scheduled_renewal_configurations_response.rb +88 -0
  96. data/lib/advanced_billing/models/scheduled_renewal_item_request_body_component.rb +132 -0
  97. data/lib/advanced_billing/models/scheduled_renewal_item_request_body_product.rb +132 -0
  98. data/lib/advanced_billing/models/scheduled_renewal_lock_in_request.rb +71 -0
  99. data/lib/advanced_billing/models/scheduled_renewal_product_price_point.rb +192 -0
  100. data/lib/advanced_billing/models/scheduled_renewal_update_request.rb +87 -0
  101. data/lib/advanced_billing/models/send_email.rb +79 -0
  102. data/lib/advanced_billing/models/send_invoice_request.rb +17 -4
  103. data/lib/advanced_billing/models/site.rb +42 -5
  104. data/lib/advanced_billing/models/status.rb +52 -0
  105. data/lib/advanced_billing/models/subscription.rb +6 -18
  106. data/lib/advanced_billing/models/subscription_component.rb +0 -14
  107. data/lib/advanced_billing/models/subscription_custom_price.rb +2 -1
  108. data/lib/advanced_billing/models/subscription_group.rb +16 -7
  109. data/lib/advanced_billing/models/subscription_group_signup_item.rb +2 -1
  110. data/lib/advanced_billing/models/subscription_included_coupon.rb +0 -10
  111. data/lib/advanced_billing/models/subscription_sort.rb +17 -1
  112. data/lib/advanced_billing/models/tokenized_payment_profile.rb +121 -0
  113. data/lib/advanced_billing/models/update_component.rb +0 -1
  114. data/lib/advanced_billing/models/update_subscription.rb +4 -4
  115. data/lib/advanced_billing/models/upgrade_charge_credit_type.rb +44 -0
  116. data/lib/advanced_billing/models/webhook_subscription.rb +12 -0
  117. data/lib/advanced_billing/utilities/union_type_lookup.rb +50 -19
  118. data/lib/advanced_billing.rb +41 -1
  119. metadata +33 -3
  120. data/lib/advanced_billing/models/snap_day.rb +0 -26
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4162d051ddc0cf07b64fd725db7e949703d79f1d4f6d2392f6eebc7bab3d4a93
4
- data.tar.gz: 219842157f663b67e9abbc765cd0789d7493a74638c104352bcf599877ec4d40
3
+ metadata.gz: 55931a03c7a222eba4a541573e8a59b031224dc88744d3504e0dd2097075572e
4
+ data.tar.gz: d695f27b17a21691cb870dc43362491654d457799027c4603e625a3364488474
5
5
  SHA512:
6
- metadata.gz: 9b036081cec516a5b4a0029890bf667539a4907509c3547b86a84456e3a119b95ab8d0ed1ec35cd3be15fb3a6dc32847918e2f745122d579b78d2c8477a31ccf
7
- data.tar.gz: 6f10a8b2cae2905d8bb8a6b110de110f2408173f0d6a61713e3a54b5ac2252cabddbab1654fb4ec0821703e2a662aba37c31e0d4c0f239c879003acb3011349d
6
+ metadata.gz: 7c1123ccfa7205b6405f78a912abc2e8230192e204d26dd8a6bfa24c9e682ba22e612b7fbf6f05fa42b61385d86cfa7f0e7c0d8f97b2c619112240dcdd7f9a10
7
+ data.tar.gz: ddd4b84372a1946ef74331db82d3ba3173d55803d824f272bdc0719edf25575d959240ba35bbafa9f792dfd1b54238150bfba341096dd0a45c7181ce14d06470
data/LICENSE CHANGED
@@ -3,7 +3,7 @@ License:
3
3
  The MIT License (MIT)
4
4
  http://opensource.org/licenses/MIT
5
5
 
6
- Copyright (c) 2014 - 2025 APIMATIC Limited
6
+ Copyright (c) 2014 - 2026 APIMATIC Limited
7
7
 
8
8
  Permission is hereby granted, free of charge, to any person obtaining a copy
9
9
  of this software and associated documentation files (the "Software"), to deal
data/README.md CHANGED
@@ -29,16 +29,16 @@ curl -u <api_key>:x -H Accept:application/json -H Content-Type:application/json
29
29
  Install the gem from the command line:
30
30
 
31
31
  ```bash
32
- gem install maxio-advanced-billing-sdk -v 8.0.0
32
+ gem install maxio-advanced-billing-sdk -v 9.1.0
33
33
  ```
34
34
 
35
35
  Or add the gem to your Gemfile and run `bundle`:
36
36
 
37
37
  ```ruby
38
- gem 'maxio-advanced-billing-sdk', '8.0.0'
38
+ gem 'maxio-advanced-billing-sdk', '9.1.0'
39
39
  ```
40
40
 
41
- For additional gem details, see the [RubyGems page for the maxio-advanced-billing-sdk gem](https://rubygems.org/gems/maxio-advanced-billing-sdk/versions/8.0.0).
41
+ For additional gem details, see the [RubyGems page for the maxio-advanced-billing-sdk gem](https://rubygems.org/gems/maxio-advanced-billing-sdk/versions/9.1.0).
42
42
 
43
43
  ## IRB Console Usage
44
44
 
@@ -77,14 +77,14 @@ ruby bin/console
77
77
 
78
78
  ## Initialize the API Client
79
79
 
80
- **_Note:_** Documentation for the client can be found [here.](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/client.md)
80
+ **_Note:_** Documentation for the client can be found [here.](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/client.md)
81
81
 
82
82
  The following parameters are configurable for the API Client:
83
83
 
84
84
  | Parameter | Type | Description |
85
85
  | --- | --- | --- |
86
86
  | site | `String` | The subdomain for your Advanced Billing site.<br>*Default*: `'subdomain'` |
87
- | environment | `Environment` | The API environment. <br> **Default: `Environment.US`** |
87
+ | environment | [`Environment`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/README.md#environments) | The API environment. <br> **Default: `Environment.US`** |
88
88
  | connection | `Faraday::Connection` | The Faraday connection object passed by the SDK user for making requests |
89
89
  | adapter | `Faraday::Adapter` | The Faraday adapter object passed by the SDK user for performing http requests |
90
90
  | timeout | `Float` | The value to use for connection timeout. <br> **Default: 120** |
@@ -94,8 +94,8 @@ The following parameters are configurable for the API Client:
94
94
  | retry_statuses | `Array` | A list of HTTP statuses to retry. <br> **Default: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524]** |
95
95
  | retry_methods | `Array` | A list of HTTP methods to retry. <br> **Default: %i[get put]** |
96
96
  | http_callback | `HttpCallBack` | The Http CallBack allows defining callables for pre and post API calls. |
97
- | proxy_settings | [`ProxySettings`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/proxy-settings.md) | Optional proxy configuration to route HTTP requests through a proxy server. |
98
- | basic_auth_credentials | [`BasicAuthCredentials`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/auth/basic-authentication.md) | The credential object for Basic Authentication |
97
+ | proxy_settings | [`ProxySettings`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/proxy-settings.md) | Optional proxy configuration to route HTTP requests through a proxy server. |
98
+ | basic_auth_credentials | [`BasicAuthCredentials`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/auth/basic-authentication.md) | The credential object for Basic Authentication |
99
99
 
100
100
  The API client can be initialized as follows:
101
101
 
@@ -125,7 +125,7 @@ include AdvancedBilling
125
125
  client = Client.from_env
126
126
  ```
127
127
 
128
- See the [`Environment-Based Client Initialization`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/environment-based-client-initialization.md) section for details.
128
+ See the [`Environment-Based Client Initialization`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/environment-based-client-initialization.md) section for details.
129
129
 
130
130
  ## Environments
131
131
 
@@ -142,57 +142,58 @@ The SDK can be configured to use a different environment for making API calls. A
142
142
 
143
143
  This API uses the following authentication schemes.
144
144
 
145
- * [`BasicAuth (Basic Authentication)`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/auth/basic-authentication.md)
145
+ * [`BasicAuth (Basic Authentication)`](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/auth/basic-authentication.md)
146
146
 
147
147
  ## List of APIs
148
148
 
149
- * [API Exports](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/api-exports.md)
150
- * [Advance Invoice](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/advance-invoice.md)
151
- * [Billing Portal](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/billing-portal.md)
152
- * [Component Price Points](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/component-price-points.md)
153
- * [Custom Fields](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/custom-fields.md)
154
- * [Events-Based Billing Segments](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/events-based-billing-segments.md)
155
- * [Payment Profiles](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/payment-profiles.md)
156
- * [Product Families](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/product-families.md)
157
- * [Product Price Points](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/product-price-points.md)
158
- * [Proforma Invoices](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/proforma-invoices.md)
159
- * [Reason Codes](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/reason-codes.md)
160
- * [Referral Codes](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/referral-codes.md)
161
- * [Sales Commissions](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/sales-commissions.md)
162
- * [Subscription Components](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-components.md)
163
- * [Subscription Groups](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-groups.md)
164
- * [Subscription Group Invoice Account](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-group-invoice-account.md)
165
- * [Subscription Group Status](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-group-status.md)
166
- * [Subscription Invoice Account](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-invoice-account.md)
167
- * [Subscription Notes](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-notes.md)
168
- * [Subscription Products](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-products.md)
169
- * [Subscription Status](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscription-status.md)
170
- * [Coupons](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/coupons.md)
171
- * [Components](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/components.md)
172
- * [Customers](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/customers.md)
173
- * [Events](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/events.md)
174
- * [Insights](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/insights.md)
175
- * [Invoices](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/invoices.md)
176
- * [Offers](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/offers.md)
177
- * [Products](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/products.md)
178
- * [Sites](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/sites.md)
179
- * [Subscriptions](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/subscriptions.md)
180
- * [Webhooks](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/controllers/webhooks.md)
149
+ * [API Exports](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/api-exports.md)
150
+ * [Advance Invoice](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/advance-invoice.md)
151
+ * [Billing Portal](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/billing-portal.md)
152
+ * [Component Price Points](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/component-price-points.md)
153
+ * [Custom Fields](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/custom-fields.md)
154
+ * [Events-Based Billing Segments](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/events-based-billing-segments.md)
155
+ * [Payment Profiles](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/payment-profiles.md)
156
+ * [Product Families](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/product-families.md)
157
+ * [Product Price Points](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/product-price-points.md)
158
+ * [Proforma Invoices](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/proforma-invoices.md)
159
+ * [Reason Codes](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/reason-codes.md)
160
+ * [Referral Codes](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/referral-codes.md)
161
+ * [Sales Commissions](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/sales-commissions.md)
162
+ * [Subscription Components](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-components.md)
163
+ * [Subscription Groups](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-groups.md)
164
+ * [Subscription Group Invoice Account](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-group-invoice-account.md)
165
+ * [Subscription Group Status](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-group-status.md)
166
+ * [Subscription Invoice Account](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-invoice-account.md)
167
+ * [Subscription Notes](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-notes.md)
168
+ * [Subscription Products](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-products.md)
169
+ * [Subscription Renewals](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-renewals.md)
170
+ * [Subscription Status](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscription-status.md)
171
+ * [Coupons](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/coupons.md)
172
+ * [Components](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/components.md)
173
+ * [Customers](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/customers.md)
174
+ * [Events](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/events.md)
175
+ * [Insights](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/insights.md)
176
+ * [Invoices](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/invoices.md)
177
+ * [Offers](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/offers.md)
178
+ * [Products](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/products.md)
179
+ * [Sites](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/sites.md)
180
+ * [Subscriptions](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/subscriptions.md)
181
+ * [Webhooks](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/controllers/webhooks.md)
181
182
 
182
183
  ## SDK Infrastructure
183
184
 
184
185
  ### Configuration
185
186
 
186
- * [ProxySettings](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/proxy-settings.md)
187
- * [Environment-Based Client Initialization](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/environment-based-client-initialization.md)
187
+ * [ProxySettings](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/proxy-settings.md)
188
+ * [Environment-Based Client Initialization](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/environment-based-client-initialization.md)
188
189
 
189
190
  ### HTTP
190
191
 
191
- * [HttpResponse](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/http-response.md)
192
- * [HttpRequest](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/http-request.md)
192
+ * [HttpResponse](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/http-response.md)
193
+ * [HttpRequest](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/http-request.md)
193
194
 
194
195
  ### Utilities
195
196
 
196
- * [ApiHelper](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/api-helper.md)
197
- * [DateTimeHelper](https://www.github.com/maxio-com/ab-ruby-sdk/tree/8.0.0/doc/date-time-helper.md)
197
+ * [ApiHelper](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/api-helper.md)
198
+ * [DateTimeHelper](https://www.github.com/maxio-com/ab-ruby-sdk/tree/9.1.0/doc/date-time-helper.md)
198
199
 
@@ -193,6 +193,12 @@ module AdvancedBilling
193
193
  @subscription_products ||= SubscriptionProductsController.new @global_configuration
194
194
  end
195
195
 
196
+ # Access to subscription_renewals controller.
197
+ # @return [SubscriptionRenewalsController] Returns the controller instance.
198
+ def subscription_renewals
199
+ @subscription_renewals ||= SubscriptionRenewalsController.new @global_configuration
200
+ end
201
+
196
202
  # Access to subscription_status controller.
197
203
  # @return [SubscriptionStatusController] Returns the controller instance.
198
204
  def subscription_status
@@ -10,7 +10,7 @@ module AdvancedBilling
10
10
  # [See our
11
11
  # docs](https://maxio.zendesk.com/hc/en-us/articles/24252026404749-Issue-Inv
12
12
  # oice-In-Advance) for more information on advance invoices, including
13
- # eligibility on generating one; for the most part, they function like any
13
+ # eligibility for generating one; for the most part, they function like any
14
14
  # other invoice, except they are issued early and have special behavior upon
15
15
  # being voided.
16
16
  # A subscription may only have one advance invoice per billing period.
@@ -24,7 +24,7 @@ module AdvancedBilling
24
24
  # invoices to preview this advance invoice before using this endpoint to
25
25
  # generate it.
26
26
  # @param [Integer] subscription_id Required parameter: The Chargify id of
27
- # the subscription
27
+ # the subscription.
28
28
  # @param [IssueAdvanceInvoiceRequest] body Optional parameter: TODO: type
29
29
  # description here
30
30
  # @return [Invoice] Response from the API call.
@@ -55,11 +55,11 @@ module AdvancedBilling
55
55
  .execute
56
56
  end
57
57
 
58
- # Once an advance invoice has been generated for a subscription's upcoming
59
- # renewal, it can be viewed through this endpoint. There can only be one
60
- # advance invoice per subscription per billing cycle.
58
+ # Returns the advance invoice generated for a subscription's upcoming
59
+ # renewal. There can only be one advance invoice per subscription per
60
+ # billing cycle.
61
61
  # @param [Integer] subscription_id Required parameter: The Chargify id of
62
- # the subscription
62
+ # the subscription.
63
63
  # @return [Invoice] Response from the API call.
64
64
  def read_advance_invoice(subscription_id)
65
65
  @api_call
@@ -87,7 +87,7 @@ module AdvancedBilling
87
87
  # to the invoice to be returned to the subscription. For a full overview of
88
88
  # the impact of voiding, [see our help docs]($m/Invoice).
89
89
  # @param [Integer] subscription_id Required parameter: The Chargify id of
90
- # the subscription
90
+ # the subscription.
91
91
  # @param [VoidInvoiceRequest] body Optional parameter: TODO: type
92
92
  # description here
93
93
  # @return [Invoice] Response from the API call.
@@ -6,9 +6,8 @@
6
6
  module AdvancedBilling
7
7
  # APIExportsController
8
8
  class APIExportsController < BaseController
9
- # This API returns an array of exported proforma invoices for a provided
10
- # `batch_id`. Pay close attention to pagination in order to control
11
- # responses from the server.
9
+ # Lists exported proforma invoices for a provided `batch_id`. Use pagination
10
+ # to control responses returned from the server.
12
11
  # Example: `GET
13
12
  # https://{subdomain}.chargify.com/api_exports/proforma_invoices/123/rows?pe
14
13
  # r_page=10000&page=1`.
@@ -47,9 +46,8 @@ module AdvancedBilling
47
46
  .execute
48
47
  end
49
48
 
50
- # This API returns an array of exported invoices for a provided `batch_id`.
51
- # Pay close attention to pagination in order to control responses from the
52
- # server.
49
+ # Lists exported invoices for a provided `batch_id`. Use pagination to
50
+ # control responses returned from the server.
53
51
  # Example: `GET
54
52
  # https://{subdomain}.chargify.com/api_exports/invoices/123/rows?per_page=10
55
53
  # 000&page=1`.
@@ -88,9 +86,8 @@ module AdvancedBilling
88
86
  .execute
89
87
  end
90
88
 
91
- # This API returns an array of exported subscriptions for a provided
92
- # `batch_id`. Pay close attention to pagination in order to control
93
- # responses from the server.
89
+ # Lists exported subscriptions for a provided `batch_id`. Use pagination to
90
+ # control responses returned from the server.
94
91
  # Example: `GET
95
92
  # https://{subdomain}.chargify.com/api_exports/subscriptions/123/rows?per_pa
96
93
  # ge=200&page=1`.
@@ -129,7 +126,7 @@ module AdvancedBilling
129
126
  .execute
130
127
  end
131
128
 
132
- # This API creates a proforma invoices export and returns a batchjob object.
129
+ # Creates a proforma invoices export and returns a batch job object.
133
130
  # It is only available for Relationship Invoicing architecture.
134
131
  # @return [BatchJobResponse] Response from the API call.
135
132
  def export_proforma_invoices
@@ -152,7 +149,7 @@ module AdvancedBilling
152
149
  .execute
153
150
  end
154
151
 
155
- # This API creates an invoices export and returns a batchjob object.
152
+ # Creates an invoices export and returns a batch job object.
156
153
  # @return [BatchJobResponse] Response from the API call.
157
154
  def export_invoices
158
155
  @api_call
@@ -174,7 +171,7 @@ module AdvancedBilling
174
171
  .execute
175
172
  end
176
173
 
177
- # This API creates a subscriptions export and returns a batchjob object.
174
+ # Creates a subscriptions export and returns a batch job object.
178
175
  # @return [BatchJobResponse] Response from the API call.
179
176
  def export_subscriptions
180
177
  @api_call
@@ -193,7 +190,7 @@ module AdvancedBilling
193
190
  .execute
194
191
  end
195
192
 
196
- # This API returns a batchjob object for proforma invoices export.
193
+ # Returns a batch job object for a proforma invoices export.
197
194
  # @param [String] batch_id Required parameter: Id of a Batch Job.
198
195
  # @return [BatchJobResponse] Response from the API call.
199
196
  def read_proforma_invoices_export(batch_id)
@@ -215,7 +212,7 @@ module AdvancedBilling
215
212
  .execute
216
213
  end
217
214
 
218
- # This API returns a batchjob object for invoices export.
215
+ # Returns a batch job object for an invoices export.
219
216
  # @param [String] batch_id Required parameter: Id of a Batch Job.
220
217
  # @return [BatchJobResponse] Response from the API call.
221
218
  def read_invoices_export(batch_id)
@@ -237,7 +234,7 @@ module AdvancedBilling
237
234
  .execute
238
235
  end
239
236
 
240
- # This API returns a batchjob object for subscriptions export.
237
+ # Returns a batch job object for a subscriptions export.
241
238
  # @param [String] batch_id Required parameter: Id of a Batch Job.
242
239
  # @return [BatchJobResponse] Response from the API call.
243
240
  def read_subscriptions_export(batch_id)
@@ -10,7 +10,7 @@ module AdvancedBilling
10
10
  attr_accessor :config, :http_call_back
11
11
 
12
12
  def self.user_agent
13
- 'AB SDK Ruby:8.0.0 on OS {os-info}'
13
+ 'AB SDK Ruby:9.1.0 on OS {os-info}'
14
14
  end
15
15
 
16
16
  def self.user_agent_parameters
@@ -6,12 +6,14 @@
6
6
  module AdvancedBilling
7
7
  # BillingPortalController
8
8
  class BillingPortalController < BaseController
9
+ # Enables Billing Portal access for a customer, with an option to send an
10
+ # invitation email at the same time.
9
11
  # ## Billing Portal Documentation
10
12
  # Full documentation on how the Billing Portal operates within the Advanced
11
13
  # Billing UI can be located
12
14
  # [here](https://maxio.zendesk.com/hc/en-us/articles/24252412965133-Billing-
13
15
  # Portal-Overview).
14
- # This documentation is focused on how the to configure the Billing Portal
16
+ # This documentation is focused on how to configure the Billing Portal
15
17
  # Settings, as well as Subscriber Interaction and Merchant Management of the
16
18
  # Billing Portal.
17
19
  # You can use this endpoint to enable Billing Portal access for a Customer,
@@ -60,8 +62,8 @@ module AdvancedBilling
60
62
  .execute
61
63
  end
62
64
 
63
- # This method will provide to the API user the exact URL required for a
64
- # subscriber to access the Billing Portal.
65
+ # Returns the exact URL required for a subscriber to access the Billing
66
+ # Portal.
65
67
  # ## Rules for Management Link API
66
68
  # + When retrieving a management URL, multiple requests for the same
67
69
  # customer in a short period will return the **same** URL
@@ -99,15 +101,13 @@ module AdvancedBilling
99
101
  .execute
100
102
  end
101
103
 
102
- # You can resend a customer's Billing Portal invitation.
104
+ # Resends a customer's Billing Portal invitation.
103
105
  # If you attempt to resend an invitation 5 times within 30 minutes, you will
104
- # receive a `422` response with `error` message in the body.
106
+ # receive a `422` response with an `error` message in the body.
105
107
  # If you attempt to resend an invitation when the Billing Portal is already
106
108
  # disabled for a Customer, you will receive a `422` error response.
107
- # If you attempt to resend an invitation when the Billing Portal is already
108
- # disabled for a Customer, you will receive a `422` error response.
109
- # If you attempt to resend an invitation when the Customer does not exist a
110
- # Customer, you will receive a `404` error response.
109
+ # If you attempt to resend an invitation when the Customer does not exist,
110
+ # you will receive a `404` error response.
111
111
  # ## Limitations
112
112
  # This endpoint will only return a JSON response.
113
113
  # @param [Integer] customer_id Required parameter: The Chargify id of the
@@ -136,7 +136,7 @@ module AdvancedBilling
136
136
  .execute
137
137
  end
138
138
 
139
- # You can revoke a customer's Billing Portal invitation.
139
+ # Revokes a customer's Billing Portal invitation.
140
140
  # If you attempt to revoke an invitation when the Billing Portal is already
141
141
  # disabled for a Customer, you will receive a 422 error response.
142
142
  # ## Limitations
@@ -70,8 +70,7 @@ module AdvancedBilling
70
70
  .execute
71
71
  end
72
72
 
73
- # Use this endpoint to read current price points that are associated with a
74
- # component.
73
+ # Lists the price points associated with a component.
75
74
  # You may specify the component by using either the numeric id or the
76
75
  # `handle:gold` syntax.
77
76
  # When fetching a component's price points, if you have defined multiple
@@ -120,8 +119,7 @@ module AdvancedBilling
120
119
  .execute
121
120
  end
122
121
 
123
- # Use this endpoint to create multiple component price points in one
124
- # request.
122
+ # Creates multiple component price points in one request.
125
123
  # @param [String] component_id Required parameter: The Advanced Billing id
126
124
  # of the component for which you want to fetch price points.
127
125
  # @param [CreateComponentPricePointsRequest] body Optional parameter: TODO:
@@ -151,8 +149,67 @@ module AdvancedBilling
151
149
  .execute
152
150
  end
153
151
 
154
- # When updating a price point, prices can be updated as well by creating new
155
- # prices or editing / removing existing ones.
152
+ # Clones a component price point. Custom price points (tied to a specific
153
+ # subscription) cannot be cloned. The following attributes are copied from
154
+ # the source price point:
155
+ # - Pricing scheme
156
+ # - All price tiers (with starting/ending quantities and unit prices)
157
+ # - Tax included setting
158
+ # - Currency prices (if definitive pricing is set)
159
+ # - Overage pricing (for prepaid usage components)
160
+ # - Interval settings (if multi-frequency is enabled)
161
+ # - Event-based billing segments (if applicable)
162
+ # @param [Integer | String] component_id Required parameter: The id or
163
+ # handle of the component. When using the handle, it must be prefixed with
164
+ # `handle:`. Example: `123` for an integer ID, or
165
+ # `handle:example-product-handle` for a string handle.
166
+ # @param [Integer | String] price_point_id Required parameter: The id or
167
+ # handle of the price point. When using the handle, it must be prefixed with
168
+ # `handle:`. Example: `123` for an integer ID, or
169
+ # `handle:example-price_point-handle` for a string handle.
170
+ # @param [CloneComponentPricePointRequest] body Optional parameter: TODO:
171
+ # type description here
172
+ # @return [ComponentPricePointCurrencyOverageResponse] Response from the API call.
173
+ def clone_component_price_point(component_id,
174
+ price_point_id,
175
+ body: nil)
176
+ @api_call
177
+ .request(new_request_builder(HttpMethodEnum::POST,
178
+ '/components/{component_id}/price_points/{price_point_id}/clone.json',
179
+ Server::PRODUCTION)
180
+ .template_param(new_parameter(component_id, key: 'component_id')
181
+ .is_required(true)
182
+ .should_encode(true)
183
+ .validator(proc do |value|
184
+ UnionTypeLookUp.get(:CloneComponentPricePointComponentId)
185
+ .validate(value)
186
+ end))
187
+ .template_param(new_parameter(price_point_id, key: 'price_point_id')
188
+ .is_required(true)
189
+ .should_encode(true)
190
+ .validator(proc do |value|
191
+ UnionTypeLookUp.get(:CloneComponentPricePointPricePointId)
192
+ .validate(value)
193
+ end))
194
+ .header_param(new_parameter('application/json', key: 'Content-Type'))
195
+ .body_param(new_parameter(body))
196
+ .header_param(new_parameter('application/json', key: 'accept'))
197
+ .body_serializer(proc do |param| param.to_json unless param.nil? end)
198
+ .auth(Single.new('BasicAuth')))
199
+ .response(new_response_handler
200
+ .deserializer(APIHelper.method(:custom_type_deserializer))
201
+ .deserialize_into(ComponentPricePointCurrencyOverageResponse.method(:from_hash))
202
+ .local_error_template('404',
203
+ 'Not Found:\'{$response.body}\'',
204
+ APIException)
205
+ .local_error_template('422',
206
+ 'HTTP Response Not OK. Status code: {$statusCode}.'\
207
+ ' Response: \'{$response.body}\'.',
208
+ ErrorListResponseException))
209
+ .execute
210
+ end
211
+
212
+ # Updates a component price point and its associated prices.
156
213
  # Passing in a price bracket without an `id` will attempt to create a new
157
214
  # price.
158
215
  # Including an `id` will update the corresponding price, and including the
@@ -206,9 +263,8 @@ module AdvancedBilling
206
263
  .execute
207
264
  end
208
265
 
209
- # Use this endpoint to retrieve details for a specific component price
210
- # point. You can achieve this by using either the component price point ID
211
- # or handle.
266
+ # Returns details for a specific component price point. You can achieve this
267
+ # by using either the component price point ID or handle.
212
268
  # @param [Integer | String] component_id Required parameter: The id or
213
269
  # handle of the component. When using the handle, it must be prefixed with
214
270
  # `handle:`. Example: `123` for an integer ID, or
@@ -219,7 +275,7 @@ module AdvancedBilling
219
275
  # `handle:example-price_point-handle` for a string handle.
220
276
  # @param [TrueClass | FalseClass] currency_prices Optional parameter:
221
277
  # Include an array of currency price data
222
- # @return [ComponentPricePointResponse] Response from the API call.
278
+ # @return [ComponentPricePointCurrencyOverageResponse] Response from the API call.
223
279
  def read_component_price_point(component_id,
224
280
  price_point_id,
225
281
  currency_prices: nil)
@@ -246,13 +302,13 @@ module AdvancedBilling
246
302
  .auth(Single.new('BasicAuth')))
247
303
  .response(new_response_handler
248
304
  .deserializer(APIHelper.method(:custom_type_deserializer))
249
- .deserialize_into(ComponentPricePointResponse.method(:from_hash)))
305
+ .deserialize_into(ComponentPricePointCurrencyOverageResponse.method(:from_hash)))
250
306
  .execute
251
307
  end
252
308
 
253
- # A price point can be archived at any time. Subscriptions using a price
254
- # point that has been archived will continue using it until they're moved to
255
- # another price point.
309
+ # Archives a component price point. Subscriptions using a price point that
310
+ # has been archived will continue using it until they're moved to another
311
+ # price point.
256
312
  # @param [Integer | String] component_id Required parameter: The id or
257
313
  # handle of the component. When using the handle, it must be prefixed with
258
314
  # `handle:`. Example: `123` for an integer ID, or
@@ -294,7 +350,7 @@ module AdvancedBilling
294
350
  .execute
295
351
  end
296
352
 
297
- # Use this endpoint to unarchive a component price point.
353
+ # Unarchives a component price point.
298
354
  # @param [Integer] component_id Required parameter: The Advanced Billing id
299
355
  # of the component to which the price point belongs
300
356
  # @param [Integer] price_point_id Required parameter: The Advanced Billing
@@ -320,8 +376,7 @@ module AdvancedBilling
320
376
  .execute
321
377
  end
322
378
 
323
- # This endpoint allows you to create currency prices for a given currency
324
- # that has been defined on the site level in your settings.
379
+ # Creates currency prices for a given currency defined at the site level.
325
380
  # When creating currency prices, they need to mirror the structure of your
326
381
  # primary pricing. For each price level defined on the component price
327
382
  # point, there should be a matching price level created in the given
@@ -356,8 +411,7 @@ module AdvancedBilling
356
411
  .execute
357
412
  end
358
413
 
359
- # This endpoint allows you to update currency prices for a given currency
360
- # that has been defined on the site level in your settings.
414
+ # Updates currency prices for a given currency defined at the site level.
361
415
  # Note: Currency Prices are not able to be updated for custom price points.
362
416
  # @param [Integer] price_point_id Required parameter: The Advanced Billing
363
417
  # id of the price point
@@ -388,8 +442,7 @@ module AdvancedBilling
388
442
  .execute
389
443
  end
390
444
 
391
- # This method allows to retrieve a list of Components Price Points belonging
392
- # to a Site.
445
+ # Lists all component price points belonging to a site.
393
446
  # @param [ListComponentsPricePointsInclude] include Optional parameter:
394
447
  # Allows including additional data in the response. Use in query:
395
448
  # `include=currency_prices`.