recurly 4.25.0 → 4.27.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 83cc9874a222552398eccba8e97f844e448644398831199e20e9eeb09d91443a
4
- data.tar.gz: dab0e9563f9771f46d4be709e33394305f8c59bc77fa2cd4394106cef1edd8a6
3
+ metadata.gz: 640a24b929e9682d7617c76acc1a64e15e7ffab1911caf2c451d87a66879636b
4
+ data.tar.gz: 3f8a5c5064c8e7171dc6e6b0ff7159c4da7bb6e483795053455a0cd46024525e
5
5
  SHA512:
6
- metadata.gz: beeb8fd85be7c0b63d7f2ab7c786684e774d731a3d3f501aba66428bb6de7e58c79fd0e4ab6786790e58195cd675c286f259bb98cb0652366a0ab49b885fed11
7
- data.tar.gz: a2bb85d2f395c94dbe172aabbc281d0e30f6ffd034d85368616a2a921cee68fc6836ae75dbb023299edc2b8b4d31a61f382d9e43e6f130e10a9130bd5d7a2148
6
+ metadata.gz: add90da54e5859f423bb14382674297aab1cd4807e3238c31bb7b8edc23ee2c963efa0acdeae40a4943678960d375c1d19dfea7666c753b422e54782c5cc1d7f
7
+ data.tar.gz: 116106098e2251a1cf36031e2f15e51853052ffe7ec5da674a441a1b231ae3b81327cb00264d7cab48e43b4c925ae21c39b7d979c89e3082e39208b263d29e0f
data/.bumpversion.cfg CHANGED
@@ -1,5 +1,5 @@
1
1
  [bumpversion]
2
- current_version = 4.25.0
2
+ current_version = 4.27.0
3
3
  parse = (?P<major>\d+)
4
4
  \.(?P<minor>\d+)
5
5
  \.(?P<patch>\d+)
data/CHANGELOG.md CHANGED
@@ -1,5 +1,27 @@
1
1
  # Changelog
2
2
 
3
+ ## [4.27.0](https://github.com/recurly/recurly-client-ruby/tree/4.27.0) (2023-01-11)
4
+
5
+ [Full Changelog](https://github.com/recurly/recurly-client-ruby/compare/4.26.0...4.27.0)
6
+
7
+
8
+ **Merged Pull Requests**
9
+
10
+ - Generated Latest Changes for v2021-02-25 (Account Preferred Time Zone) [#816](https://github.com/recurly/recurly-client-ruby/pull/816) ([douglasmiller](https://github.com/douglasmiller))
11
+
12
+
13
+
14
+ ## [4.26.0](https://github.com/recurly/recurly-client-ruby/tree/4.26.0) (2022-11-17)
15
+
16
+ [Full Changelog](https://github.com/recurly/recurly-client-ruby/compare/4.25.0...4.26.0)
17
+
18
+
19
+ **Merged Pull Requests**
20
+
21
+ - Generated Latest Changes for v2021-02-25 (Apply Credit Balance feature) [#811](https://github.com/recurly/recurly-client-ruby/pull/811) ([recurly-integrations](https://github.com/recurly-integrations))
22
+
23
+
24
+
3
25
  ## [4.25.0](https://github.com/recurly/recurly-client-ruby/tree/4.25.0) (2022-11-15)
4
26
 
5
27
  [Full Changelog](https://github.com/recurly/recurly-client-ruby/compare/4.24.0...4.25.0)
data/GETTING_STARTED.md CHANGED
@@ -5,7 +5,7 @@ This repository houses the official ruby client for Recurly's V3 API.
5
5
  In your Gemfile, add `recurly` as a dependency.
6
6
 
7
7
  ```ruby
8
- gem 'recurly', '~> 4.25'
8
+ gem 'recurly', '~> 4.27'
9
9
  ```
10
10
 
11
11
  > *Note*: We try to follow [semantic versioning](https://semver.org/) and will only apply breaking changes to major versions.
@@ -2236,6 +2236,30 @@ module Recurly
2236
2236
  get(path, **options)
2237
2237
  end
2238
2238
 
2239
+ # Apply available credit to a pending or past due charge invoice
2240
+ #
2241
+ # {https://developers.recurly.com/api/v2021-02-25#operation/apply_credit_balance apply_credit_balance api documentation}
2242
+ #
2243
+ # @param invoice_id [String] Invoice ID or number. For ID no prefix is used e.g. +e28zov4fw0v2+. For number use prefix +number-+, e.g. +number-1000+.
2244
+ # @param params [Hash] Optional query string parameters:
2245
+ # :site_id [String] Site ID or subdomain. For ID no prefix is used e.g. +e28zov4fw0v2+. For subdomain use prefix +subdomain-+, e.g. +subdomain-recurly+.
2246
+ #
2247
+ # @return [Resources::Invoice] The updated invoice.
2248
+ # @example
2249
+ # begin
2250
+ # invoice = @client.apply_credit_balance(invoice_id: invoice_id)
2251
+ # puts "Applied credit balance to invoice #{invoice}"
2252
+ # rescue Recurly::Errors::NotFoundError
2253
+ # # If the resource was not found, you may want to alert the user or
2254
+ # # just return nil
2255
+ # puts "Resource Not Found"
2256
+ # end
2257
+ #
2258
+ def apply_credit_balance(invoice_id:, **options)
2259
+ path = interpolate_path("/invoices/{invoice_id}/apply_credit_balance", invoice_id: invoice_id)
2260
+ put(path, **options)
2261
+ end
2262
+
2239
2263
  # Collect a pending or past due, automatic invoice
2240
2264
  #
2241
2265
  # {https://developers.recurly.com/api/v2021-02-25#operation/collect_invoice collect_invoice api documentation}
@@ -74,6 +74,10 @@ module Recurly
74
74
  # @return [String] Used to determine the language and locale of emails sent on behalf of the merchant to the customer. The list of locales is restricted to those the merchant has enabled on the site.
75
75
  define_attribute :preferred_locale, String
76
76
 
77
+ # @!attribute preferred_time_zone
78
+ # @return [String] Used to determine the time zone of emails sent on behalf of the merchant to the customer. Must be a [supported IANA time zone name](https://docs.recurly.com/docs/email-time-zones-and-time-stamps#supported-api-iana-time-zone-names)
79
+ define_attribute :preferred_time_zone, String
80
+
77
81
  # @!attribute shipping_addresses
78
82
  # @return [Array[ShippingAddressCreate]]
79
83
  define_attribute :shipping_addresses, Array, { :item_type => :ShippingAddressCreate }
@@ -78,6 +78,10 @@ module Recurly
78
78
  # @return [String] Used to determine the language and locale of emails sent on behalf of the merchant to the customer. The list of locales is restricted to those the merchant has enabled on the site.
79
79
  define_attribute :preferred_locale, String
80
80
 
81
+ # @!attribute preferred_time_zone
82
+ # @return [String] Used to determine the time zone of emails sent on behalf of the merchant to the customer. Must be a [supported IANA time zone name](https://docs.recurly.com/docs/email-time-zones-and-time-stamps#supported-api-iana-time-zone-names)
83
+ define_attribute :preferred_time_zone, String
84
+
81
85
  # @!attribute tax_exempt
82
86
  # @return [Boolean] The tax status of the account. `true` exempts tax on the account, `false` applies tax on the account.
83
87
  define_attribute :tax_exempt, :Boolean
@@ -66,6 +66,10 @@ module Recurly
66
66
  # @return [String] Used to determine the language and locale of emails sent on behalf of the merchant to the customer. The list of locales is restricted to those the merchant has enabled on the site.
67
67
  define_attribute :preferred_locale, String
68
68
 
69
+ # @!attribute preferred_time_zone
70
+ # @return [String] Used to determine the time zone of emails sent on behalf of the merchant to the customer. Must be a [supported IANA time zone name](https://docs.recurly.com/docs/email-time-zones-and-time-stamps#supported-api-iana-time-zone-names)
71
+ define_attribute :preferred_time_zone, String
72
+
69
73
  # @!attribute tax_exempt
70
74
  # @return [Boolean] The tax status of the account. `true` exempts tax on the account, `false` applies tax on the account.
71
75
  define_attribute :tax_exempt, :Boolean
@@ -63,7 +63,7 @@ module Recurly
63
63
  define_attribute :optional, :Boolean
64
64
 
65
65
  # @!attribute percentage_tiers
66
- # @return [Array[PercentageTiersByCurrency]] Array of objects which must have at least one set of tiers per currency and the currency code. The tier_type must be `volume` or `tiered`, if not, it must be absent. There must be one tier without an `ending_amount` value which represents the final tier.
66
+ # @return [Array[PercentageTiersByCurrency]] Array of objects which must have at least one set of tiers per currency and the currency code. The tier_type must be `volume` or `tiered`, if not, it must be absent. There must be one tier without an `ending_amount` value which represents the final tier. This feature is currently in development and requires approval and enablement, please contact support.
67
67
  define_attribute :percentage_tiers, Array, { :item_type => :PercentageTiersByCurrency }
68
68
 
69
69
  # @!attribute plan_id
@@ -55,7 +55,7 @@ module Recurly
55
55
  define_attribute :optional, :Boolean
56
56
 
57
57
  # @!attribute percentage_tiers
58
- # @return [Array[PercentageTiersByCurrency]] `percentage_tiers` is an array of objects, which must have the set of tiers per currency and the currency code. The tier_type must be `volume` or `tiered`, if not, it must be absent. There must be one tier without an `ending_amount` value which represents the final tier.
58
+ # @return [Array[PercentageTiersByCurrency]] `percentage_tiers` is an array of objects, which must have the set of tiers per currency and the currency code. The tier_type must be `volume` or `tiered`, if not, it must be absent. There must be one tier without an `ending_amount` value which represents the final tier. This feature is currently in development and requires approval and enablement, please contact support.
59
59
  define_attribute :percentage_tiers, Array, { :item_type => :PercentageTiersByCurrency }
60
60
 
61
61
  # @!attribute revenue_schedule_type
@@ -15,7 +15,7 @@ module Recurly
15
15
  define_attribute :code, String
16
16
 
17
17
  # @!attribute percentage_tiers
18
- # @return [Array[SubscriptionAddOnPercentageTier]] If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be removed and replaced by the percentage tiers in the request. There must be one tier without ending_amount value which represents the final tier. Use only if add_on.tier_type is tiered or volume and add_on.usage_type is percentage.
18
+ # @return [Array[SubscriptionAddOnPercentageTier]] If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be removed and replaced by the percentage tiers in the request. There must be one tier without ending_amount value which represents the final tier. Use only if add_on.tier_type is tiered or volume and add_on.usage_type is percentage. This feature is currently in development and requires approval and enablement, please contact support.
19
19
  define_attribute :percentage_tiers, Array, { :item_type => :SubscriptionAddOnPercentageTier }
20
20
 
21
21
  # @!attribute quantity
@@ -19,7 +19,7 @@ module Recurly
19
19
  define_attribute :id, String
20
20
 
21
21
  # @!attribute percentage_tiers
22
- # @return [Array[SubscriptionAddOnPercentageTier]] If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be removed and replaced by the percentage tiers in the request. Use only if add_on.tier_type is tiered or volume and add_on.usage_type is percentage. There must be one tier without an `ending_amount` value which represents the final tier.
22
+ # @return [Array[SubscriptionAddOnPercentageTier]] If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be removed and replaced by the percentage tiers in the request. Use only if add_on.tier_type is tiered or volume and add_on.usage_type is percentage. There must be one tier without an `ending_amount` value which represents the final tier. This feature is currently in development and requires approval and enablement, please contact support.
23
23
  define_attribute :percentage_tiers, Array, { :item_type => :SubscriptionAddOnPercentageTier }
24
24
 
25
25
  # @!attribute quantity
@@ -110,6 +110,10 @@ module Recurly
110
110
  # @return [String] Used to determine the language and locale of emails sent on behalf of the merchant to the customer.
111
111
  define_attribute :preferred_locale, String
112
112
 
113
+ # @!attribute preferred_time_zone
114
+ # @return [String] The [IANA time zone name](https://docs.recurly.com/docs/email-time-zones-and-time-stamps#supported-api-iana-time-zone-names) used to determine the time zone of emails sent on behalf of the merchant to the customer.
115
+ define_attribute :preferred_time_zone, String
116
+
113
117
  # @!attribute shipping_addresses
114
118
  # @return [Array[ShippingAddress]] The shipping addresses on the account.
115
119
  define_attribute :shipping_addresses, Array, { :item_type => :ShippingAddress }
@@ -10,6 +10,10 @@ module Recurly
10
10
  # @return [Float] Total amount the account is past due.
11
11
  define_attribute :amount, Float
12
12
 
13
+ # @!attribute available_credit_amount
14
+ # @return [Float] Total amount of the open balances on credit invoices for the account.
15
+ define_attribute :available_credit_amount, Float
16
+
13
17
  # @!attribute currency
14
18
  # @return [String] 3-letter ISO 4217 currency code.
15
19
  define_attribute :currency, String
@@ -75,7 +75,7 @@ module Recurly
75
75
  define_attribute :optional, :Boolean
76
76
 
77
77
  # @!attribute percentage_tiers
78
- # @return [Array[PercentageTiersByCurrency]] Percentage Tiers
78
+ # @return [Array[PercentageTiersByCurrency]] This feature is currently in development and requires approval and enablement, please contact support.
79
79
  define_attribute :percentage_tiers, Array, { :item_type => :PercentageTiersByCurrency }
80
80
 
81
81
  # @!attribute plan_id
@@ -103,7 +103,7 @@ module Recurly
103
103
  define_attribute :po_number, String
104
104
 
105
105
  # @!attribute previous_invoice_id
106
- # @return [String] On refund invoices, this value will exist and show the invoice ID of the purchase invoice the refund was created from.
106
+ # @return [String] On refund invoices, this value will exist and show the invoice ID of the purchase invoice the refund was created from. This field is only populated for sites without the [Only Bill What Changed](https://docs.recurly.com/docs/only-bill-what-changed) feature enabled. Sites with Only Bill What Changed enabled should use the [related_invoices endpoint](https://recurly.com/developers/api/v2021-02-25/index.html#operation/list_related_invoices) to see purchase invoices refunded by this invoice.
107
107
  define_attribute :previous_invoice_id, String
108
108
 
109
109
  # @!attribute refundable_amount
@@ -31,7 +31,7 @@ module Recurly
31
31
  define_attribute :object, String
32
32
 
33
33
  # @!attribute percentage_tiers
34
- # @return [Array[SubscriptionAddOnPercentageTier]] If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be removed and replaced by the percentage tiers in the request. Use only if add_on.tier_type is tiered or volume and add_on.usage_type is percentage. There must be one tier without an `ending_amount` value which represents the final tier.
34
+ # @return [Array[SubscriptionAddOnPercentageTier]] If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be removed and replaced by the percentage tiers in the request. Use only if add_on.tier_type is tiered or volume and add_on.usage_type is percentage. There must be one tier without an `ending_amount` value which represents the final tier. This feature is currently in development and requires approval and enablement, please contact support.
35
35
  define_attribute :percentage_tiers, Array, { :item_type => :SubscriptionAddOnPercentageTier }
36
36
 
37
37
  # @!attribute quantity
@@ -35,7 +35,7 @@ module Recurly
35
35
  define_attribute :object, String
36
36
 
37
37
  # @!attribute percentage_tiers
38
- # @return [Array[SubscriptionAddOnPercentageTier]] The percentage tiers of the subscription based on the usage_timestamp. If tier_type = flat, percentage_tiers = []
38
+ # @return [Array[SubscriptionAddOnPercentageTier]] The percentage tiers of the subscription based on the usage_timestamp. If tier_type = flat, percentage_tiers = []. This feature is currently in development and requires approval and enablement, please contact support.
39
39
  define_attribute :percentage_tiers, Array, { :item_type => :SubscriptionAddOnPercentageTier }
40
40
 
41
41
  # @!attribute recording_timestamp
@@ -1,3 +1,3 @@
1
1
  module Recurly
2
- VERSION = "4.25.0"
2
+ VERSION = "4.27.0"
3
3
  end
data/openapi/api.yaml CHANGED
@@ -343,13 +343,13 @@ tags:
343
343
  - name: external_subscriptions
344
344
  x-displayName: External Subscription
345
345
  description: A subscription from an external resource that is not managed by the
346
- Recurly platform and instead is managed by third-party platforms like Apple Store
347
- and Google Play.
346
+ Recurly platform and instead is managed by third-party platforms like Apple App
347
+ Store and Google Play Store.
348
348
  - name: external_products
349
349
  x-displayName: External Product
350
350
  description: A product from an external resource that is not managed by the Recurly
351
- platform and instead is managed by third-party platforms like Apple Store and
352
- Google Play.
351
+ platform and instead is managed by third-party platforms like Apple App Store
352
+ and Google Play Store.
353
353
  paths:
354
354
  "/sites":
355
355
  get:
@@ -358,7 +358,7 @@ paths:
358
358
  description: |
359
359
  This route is most useful for finding a site's ID for subsequent requests.
360
360
 
361
- See the [Pagination Guide](/guides/pagination.html) to learn how to use pagination in the API and Client Libraries.
361
+ See the [Pagination Guide](/developers/guides/pagination.html) to learn how to use pagination in the API and Client Libraries.
362
362
  tags:
363
363
  - site
364
364
  parameters:
@@ -571,8 +571,8 @@ paths:
571
571
  - account
572
572
  operationId: list_accounts
573
573
  summary: List a site's accounts
574
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
575
- to use pagination in the API and Client Libraries.
574
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
575
+ to learn how to use pagination in the API and Client Libraries.
576
576
  parameters:
577
577
  - "$ref": "#/components/parameters/ids"
578
578
  - "$ref": "#/components/parameters/limit"
@@ -2502,8 +2502,8 @@ paths:
2502
2502
  - billing_infos
2503
2503
  operationId: list_billing_infos
2504
2504
  summary: Get the list of billing information associated with an account
2505
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
2506
- to use pagination in the API and Client Libraries.
2505
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
2506
+ to learn how to use pagination in the API and Client Libraries.
2507
2507
  parameters:
2508
2508
  - "$ref": "#/components/parameters/account_id"
2509
2509
  - "$ref": "#/components/parameters/ids"
@@ -2707,8 +2707,8 @@ paths:
2707
2707
  - coupon_redemption
2708
2708
  operationId: list_account_coupon_redemptions
2709
2709
  summary: List the coupon redemptions for an account
2710
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
2711
- to use pagination in the API and Client Libraries.
2710
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
2711
+ to learn how to use pagination in the API and Client Libraries.
2712
2712
  parameters:
2713
2713
  - "$ref": "#/components/parameters/account_id"
2714
2714
  - "$ref": "#/components/parameters/ids"
@@ -2804,8 +2804,8 @@ paths:
2804
2804
  - coupon_redemption
2805
2805
  operationId: list_active_coupon_redemptions
2806
2806
  summary: List the coupon redemptions that are active on an account
2807
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
2808
- to use pagination in the API and Client Libraries.
2807
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
2808
+ to learn how to use pagination in the API and Client Libraries.
2809
2809
  parameters:
2810
2810
  - "$ref": "#/components/parameters/account_id"
2811
2811
  responses:
@@ -3132,8 +3132,8 @@ paths:
3132
3132
  - credit_payment
3133
3133
  operationId: list_account_credit_payments
3134
3134
  summary: List an account's credit payments
3135
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
3136
- to use pagination in the API and Client Libraries.
3135
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
3136
+ to learn how to use pagination in the API and Client Libraries.
3137
3137
  parameters:
3138
3138
  - "$ref": "#/components/parameters/account_id"
3139
3139
  - "$ref": "#/components/parameters/limit"
@@ -3239,8 +3239,8 @@ paths:
3239
3239
  - invoice
3240
3240
  operationId: list_account_invoices
3241
3241
  summary: List an account's invoices
3242
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
3243
- to use pagination in the API and Client Libraries.
3242
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
3243
+ to learn how to use pagination in the API and Client Libraries.
3244
3244
  parameters:
3245
3245
  - "$ref": "#/components/parameters/account_id"
3246
3246
  - "$ref": "#/components/parameters/ids"
@@ -3681,8 +3681,8 @@ paths:
3681
3681
  - line_item
3682
3682
  operationId: list_account_line_items
3683
3683
  summary: List an account's line items
3684
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
3685
- to use pagination in the API and Client Libraries.
3684
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
3685
+ to learn how to use pagination in the API and Client Libraries.
3686
3686
  parameters:
3687
3687
  - "$ref": "#/components/parameters/account_id"
3688
3688
  - "$ref": "#/components/parameters/ids"
@@ -3957,8 +3957,8 @@ paths:
3957
3957
  - note
3958
3958
  operationId: list_account_notes
3959
3959
  summary: List an account's notes
3960
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
3961
- to use pagination in the API and Client Libraries.
3960
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
3961
+ to learn how to use pagination in the API and Client Libraries.
3962
3962
  parameters:
3963
3963
  - "$ref": "#/components/parameters/account_id"
3964
3964
  - "$ref": "#/components/parameters/ids"
@@ -4171,8 +4171,8 @@ paths:
4171
4171
  - shipping_address
4172
4172
  operationId: list_shipping_addresses
4173
4173
  summary: Fetch a list of an account's shipping addresses
4174
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
4175
- to use pagination in the API and Client Libraries.
4174
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
4175
+ to learn how to use pagination in the API and Client Libraries.
4176
4176
  parameters:
4177
4177
  - "$ref": "#/components/parameters/account_id"
4178
4178
  - "$ref": "#/components/parameters/ids"
@@ -4853,8 +4853,8 @@ paths:
4853
4853
  - subscription
4854
4854
  operationId: list_account_subscriptions
4855
4855
  summary: List an account's subscriptions
4856
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
4857
- to use pagination in the API and Client Libraries.
4856
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
4857
+ to learn how to use pagination in the API and Client Libraries.
4858
4858
  parameters:
4859
4859
  - "$ref": "#/components/parameters/account_id"
4860
4860
  - "$ref": "#/components/parameters/ids"
@@ -4957,8 +4957,8 @@ paths:
4957
4957
  - transaction
4958
4958
  operationId: list_account_transactions
4959
4959
  summary: List an account's transactions
4960
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
4961
- to use pagination in the API and Client Libraries.
4960
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
4961
+ to learn how to use pagination in the API and Client Libraries.
4962
4962
  parameters:
4963
4963
  - "$ref": "#/components/parameters/account_id"
4964
4964
  - "$ref": "#/components/parameters/ids"
@@ -5063,8 +5063,8 @@ paths:
5063
5063
  - account
5064
5064
  operationId: list_child_accounts
5065
5065
  summary: List an account's child accounts
5066
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
5067
- to use pagination in the API and Client Libraries.
5066
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
5067
+ to learn how to use pagination in the API and Client Libraries.
5068
5068
  parameters:
5069
5069
  - "$ref": "#/components/parameters/account_id"
5070
5070
  - "$ref": "#/components/parameters/ids"
@@ -5146,8 +5146,8 @@ paths:
5146
5146
  - account_acquisition
5147
5147
  operationId: list_account_acquisition
5148
5148
  summary: List a site's account acquisition data
5149
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
5150
- to use pagination in the API and Client Libraries.
5149
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
5150
+ to learn how to use pagination in the API and Client Libraries.
5151
5151
  parameters:
5152
5152
  - "$ref": "#/components/parameters/ids"
5153
5153
  - "$ref": "#/components/parameters/limit"
@@ -5245,8 +5245,8 @@ paths:
5245
5245
  - coupon
5246
5246
  operationId: list_coupons
5247
5247
  summary: List a site's coupons
5248
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
5249
- to use pagination in the API and Client Libraries.
5248
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
5249
+ to learn how to use pagination in the API and Client Libraries.
5250
5250
  parameters:
5251
5251
  - "$ref": "#/components/parameters/ids"
5252
5252
  - "$ref": "#/components/parameters/limit"
@@ -6009,8 +6009,8 @@ paths:
6009
6009
  - unique_coupon_code
6010
6010
  operationId: list_unique_coupon_codes
6011
6011
  summary: List unique coupon codes associated with a bulk coupon
6012
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
6013
- to use pagination in the API and Client Libraries.
6012
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
6013
+ to learn how to use pagination in the API and Client Libraries.
6014
6014
  parameters:
6015
6015
  - "$ref": "#/components/parameters/coupon_id"
6016
6016
  - "$ref": "#/components/parameters/ids"
@@ -6045,8 +6045,8 @@ paths:
6045
6045
  - credit_payment
6046
6046
  operationId: list_credit_payments
6047
6047
  summary: List a site's credit payments
6048
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
6049
- to use pagination in the API and Client Libraries.
6048
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
6049
+ to learn how to use pagination in the API and Client Libraries.
6050
6050
  parameters:
6051
6051
  - "$ref": "#/components/parameters/limit"
6052
6052
  - "$ref": "#/components/parameters/order"
@@ -6175,8 +6175,8 @@ paths:
6175
6175
  - custom_field_definition
6176
6176
  operationId: list_custom_field_definitions
6177
6177
  summary: List a site's custom field definitions
6178
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
6179
- to use pagination in the API and Client Libraries.
6178
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
6179
+ to learn how to use pagination in the API and Client Libraries.
6180
6180
  parameters:
6181
6181
  - "$ref": "#/components/parameters/ids"
6182
6182
  - "$ref": "#/components/parameters/limit"
@@ -6400,8 +6400,8 @@ paths:
6400
6400
  - account
6401
6401
  operationId: list_invoice_template_accounts
6402
6402
  summary: List an invoice template's associated accounts
6403
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
6404
- to use pagination in the API and Client Libraries.
6403
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
6404
+ to learn how to use pagination in the API and Client Libraries.
6405
6405
  parameters:
6406
6406
  - "$ref": "#/components/parameters/invoice_template_id"
6407
6407
  - "$ref": "#/components/parameters/ids"
@@ -6445,8 +6445,8 @@ paths:
6445
6445
  - item
6446
6446
  operationId: list_items
6447
6447
  summary: List a site's items
6448
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
6449
- to use pagination in the API and Client Libraries.
6448
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
6449
+ to learn how to use pagination in the API and Client Libraries.
6450
6450
  parameters:
6451
6451
  - "$ref": "#/components/parameters/ids"
6452
6452
  - "$ref": "#/components/parameters/limit"
@@ -7280,8 +7280,8 @@ paths:
7280
7280
  - measured_unit
7281
7281
  operationId: list_measured_unit
7282
7282
  summary: List a site's measured units
7283
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
7284
- to use pagination in the API and Client Libraries.
7283
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
7284
+ to learn how to use pagination in the API and Client Libraries.
7285
7285
  parameters:
7286
7286
  - "$ref": "#/components/parameters/ids"
7287
7287
  - "$ref": "#/components/parameters/limit"
@@ -7460,8 +7460,8 @@ paths:
7460
7460
  - external_products
7461
7461
  operationId: list_external_products
7462
7462
  summary: List a site's external products
7463
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
7464
- to use pagination in the API and Client Libraries.
7463
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
7464
+ to learn how to use pagination in the API and Client Libraries.
7465
7465
  parameters:
7466
7466
  - "$ref": "#/components/parameters/sort_dates"
7467
7467
  responses:
@@ -7518,8 +7518,8 @@ paths:
7518
7518
  - external_subscriptions
7519
7519
  operationId: list_external_subscriptions
7520
7520
  summary: List a site's external subscriptions
7521
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
7522
- to use pagination in the API and Client Libraries.
7521
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
7522
+ to learn how to use pagination in the API and Client Libraries.
7523
7523
  parameters:
7524
7524
  - "$ref": "#/components/parameters/sort_dates"
7525
7525
  responses:
@@ -7583,8 +7583,8 @@ paths:
7583
7583
  - invoice
7584
7584
  operationId: list_invoices
7585
7585
  summary: List a site's invoices
7586
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
7587
- to use pagination in the API and Client Libraries.
7586
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
7587
+ to learn how to use pagination in the API and Client Libraries.
7588
7588
  parameters:
7589
7589
  - "$ref": "#/components/parameters/ids"
7590
7590
  - "$ref": "#/components/parameters/limit"
@@ -8084,6 +8084,135 @@ paths:
8084
8084
  // Something bad happened... tell the user so that they can fix it?
8085
8085
  echo 'Some unexpected Recurly error happened. Try again later.' . PHP_EOL;
8086
8086
  }
8087
+ "/invoices/{invoice_id}/apply_credit_balance":
8088
+ put:
8089
+ tags:
8090
+ - invoice
8091
+ operationId: apply_credit_balance
8092
+ summary: Apply available credit to a pending or past due charge invoice
8093
+ description: Apply credit payment to the outstanding balance on an existing
8094
+ charge invoice from an account’s available balance from existing credit invoices.
8095
+ Credit that was refunded from the invoice cannot be applied back to the invoice
8096
+ as payment.
8097
+ parameters:
8098
+ - "$ref": "#/components/parameters/site_id"
8099
+ - "$ref": "#/components/parameters/invoice_id"
8100
+ responses:
8101
+ '200':
8102
+ description: The updated invoice.
8103
+ content:
8104
+ application/json:
8105
+ schema:
8106
+ "$ref": "#/components/schemas/Invoice"
8107
+ '404':
8108
+ description: Incorrect site or invoice ID.
8109
+ content:
8110
+ application/json:
8111
+ schema:
8112
+ "$ref": "#/components/schemas/Error"
8113
+ '422':
8114
+ description: Tried applying credit to a legacy or closed invoice or there
8115
+ was an error processing the credit payment, such as no available credit
8116
+ on the account.
8117
+ content:
8118
+ application/json:
8119
+ schema:
8120
+ "$ref": "#/components/schemas/Error"
8121
+ default:
8122
+ description: Unexpected error.
8123
+ content:
8124
+ application/json:
8125
+ schema:
8126
+ "$ref": "#/components/schemas/Error"
8127
+ x-code-samples:
8128
+ - lang: Node.js
8129
+ source: |
8130
+ try {
8131
+ const invoice = await client.applyCreditBalance(invoiceId)
8132
+ console.log('Applied credit balance to invoice: ', invoice)
8133
+ } catch (err) {
8134
+ if (err instanceof recurly.errors.ValidationError) {
8135
+ // If the request was not valid, you may want to tell your user
8136
+ // why. You can find the invalid params and reasons in err.params
8137
+ console.log('Failed validation', err.params)
8138
+ } else {
8139
+ // If we don't know what to do with the err, we should
8140
+ // probably re-raise and let our web framework and logger handle it
8141
+ console.log('Unknown Error: ', err)
8142
+ }
8143
+ }
8144
+ - lang: Python
8145
+ source: |
8146
+ try:
8147
+ invoice = client.apply_credit_balance(invoice_id)
8148
+ print("Applied credit balance to invoice %s" % invoice.id)
8149
+ except recurly.errors.NotFoundError:
8150
+ # If the resource was not found, you may want to alert the user or
8151
+ # just return nil
8152
+ print("Resource Not Found")
8153
+ - lang: ".NET"
8154
+ source: |
8155
+ try
8156
+ {
8157
+ Invoice invoice = client.ApplyCreditBalance(invoiceId);
8158
+ Console.WriteLine($"Applied credit balance to invoice #{invoice.Number}");
8159
+ }
8160
+ catch (Recurly.Errors.Validation ex)
8161
+ {
8162
+ // If the request was not valid, you may want to tell your user
8163
+ // why. You can find the invalid params and reasons in ex.Error.Params
8164
+ Console.WriteLine($"Failed validation: {ex.Error.Message}");
8165
+ }
8166
+ catch (Recurly.Errors.ApiError ex)
8167
+ {
8168
+ // Use ApiError to catch a generic error from the API
8169
+ Console.WriteLine($"Unexpected Recurly Error: {ex.Error.Message}");
8170
+ }
8171
+ - lang: Ruby
8172
+ source: |
8173
+ begin
8174
+ invoice = @client.apply_credit_balance(invoice_id: invoice_id)
8175
+ puts "Applied credit balance to invoice #{invoice}"
8176
+ rescue Recurly::Errors::NotFoundError
8177
+ # If the resource was not found, you may want to alert the user or
8178
+ # just return nil
8179
+ puts "Resource Not Found"
8180
+ end
8181
+ - lang: Java
8182
+ source: |
8183
+ try {
8184
+ final Invoice invoice = client.applyCreditBalance(invoiceId);
8185
+ System.out.println("Applied credit balance to invoice " + invoice.getId());
8186
+ } catch (final ValidationException e) {
8187
+ // If the request was not valid, you may want to tell your user
8188
+ // why. You can find the invalid params and reasons in e.getError().getParams()
8189
+ System.out.println("Failed validation: " + e.getError().getMessage());
8190
+ } catch (final ApiException e) {
8191
+ // Use ApiException to catch a generic error from the API
8192
+ System.out.println("Unexpected Recurly Error: " + e.getError().getMessage());
8193
+ }
8194
+ - lang: PHP
8195
+ source: |
8196
+ try {
8197
+ $invoice = $client->applyCreditBalance($invoice_id);
8198
+
8199
+ echo 'Applied credit balance to invoice:' . PHP_EOL;
8200
+ var_dump($invoice);
8201
+ } catch (\Recurly\Errors\Validation $e) {
8202
+ // If the request was not valid, you may want to tell your user
8203
+ // why. You can find the invalid params and reasons in err.params
8204
+ var_dump($e);
8205
+ } catch (\Recurly\RecurlyError $e) {
8206
+ // If we don't know what to do with the err, we should
8207
+ // probably re-raise and let our web framework and logger handle it
8208
+ var_dump($e);
8209
+ }
8210
+ - lang: Go
8211
+ source: "invoice, err := client.ApplyCreditBalance(invoiceID)\nif e, ok :=
8212
+ err.(*recurly.Error); ok {\n\tif e.Type == recurly.ErrorTypeValidation {\n\t\tfmt.Printf(\"Failed
8213
+ validation: %v\", e)\n\t\treturn nil, err\n\t}\n\tfmt.Printf(\"Unexpected
8214
+ Recurly error: %v\", e)\n\treturn nil, err\n}\n\nfmt.Printf(\"Applied credit
8215
+ balance to invoice: %v\", invoice)"
8087
8216
  "/invoices/{invoice_id}/collect":
8088
8217
  put:
8089
8218
  tags:
@@ -8768,8 +8897,8 @@ paths:
8768
8897
  - line_item
8769
8898
  operationId: list_invoice_line_items
8770
8899
  summary: List an invoice's line items
8771
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
8772
- to use pagination in the API and Client Libraries.
8900
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
8901
+ to learn how to use pagination in the API and Client Libraries.
8773
8902
  parameters:
8774
8903
  - "$ref": "#/components/parameters/invoice_id"
8775
8904
  - "$ref": "#/components/parameters/ids"
@@ -8878,8 +9007,8 @@ paths:
8878
9007
  - coupon_redemption
8879
9008
  operationId: list_invoice_coupon_redemptions
8880
9009
  summary: List the coupon redemptions applied to an invoice
8881
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
8882
- to use pagination in the API and Client Libraries.
9010
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
9011
+ to learn how to use pagination in the API and Client Libraries.
8883
9012
  parameters:
8884
9013
  - "$ref": "#/components/parameters/invoice_id"
8885
9014
  - "$ref": "#/components/parameters/ids"
@@ -8978,7 +9107,7 @@ paths:
8978
9107
  For a charge invoice the related invoices will be credit invoices.
8979
9108
  For a credit invoice the related invoices will be charge invoices.
8980
9109
 
8981
- See the [Pagination Guide](/guides/pagination.html) to learn how to use pagination in the API and Client Libraries.
9110
+ See the [Pagination Guide](/developers/guides/pagination.html) to learn how to use pagination in the API and Client Libraries.
8982
9111
  parameters:
8983
9112
  - "$ref": "#/components/parameters/invoice_id"
8984
9113
  responses:
@@ -9232,8 +9361,8 @@ paths:
9232
9361
  - line_item
9233
9362
  operationId: list_line_items
9234
9363
  summary: List a site's line items
9235
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
9236
- to use pagination in the API and Client Libraries.
9364
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
9365
+ to learn how to use pagination in the API and Client Libraries.
9237
9366
  parameters:
9238
9367
  - "$ref": "#/components/parameters/ids"
9239
9368
  - "$ref": "#/components/parameters/limit"
@@ -9573,8 +9702,8 @@ paths:
9573
9702
  - plan
9574
9703
  operationId: list_plans
9575
9704
  summary: List a site's plans
9576
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
9577
- to use pagination in the API and Client Libraries.
9705
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
9706
+ to learn how to use pagination in the API and Client Libraries.
9578
9707
  parameters:
9579
9708
  - "$ref": "#/components/parameters/ids"
9580
9709
  - "$ref": "#/components/parameters/limit"
@@ -10242,8 +10371,8 @@ paths:
10242
10371
  - add-on
10243
10372
  operationId: list_plan_add_ons
10244
10373
  summary: List a plan's add-ons
10245
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
10246
- to use pagination in the API and Client Libraries.
10374
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
10375
+ to learn how to use pagination in the API and Client Libraries.
10247
10376
  parameters:
10248
10377
  - "$ref": "#/components/parameters/plan_id"
10249
10378
  - "$ref": "#/components/parameters/ids"
@@ -10908,8 +11037,8 @@ paths:
10908
11037
  - add-on
10909
11038
  operationId: list_add_ons
10910
11039
  summary: List a site's add-ons
10911
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
10912
- to use pagination in the API and Client Libraries.
11040
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
11041
+ to learn how to use pagination in the API and Client Libraries.
10913
11042
  parameters:
10914
11043
  - "$ref": "#/components/parameters/ids"
10915
11044
  - "$ref": "#/components/parameters/limit"
@@ -11126,8 +11255,8 @@ paths:
11126
11255
  - shipping_method
11127
11256
  operationId: list_shipping_methods
11128
11257
  summary: List a site's shipping methods
11129
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
11130
- to use pagination in the API and Client Libraries.
11258
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
11259
+ to learn how to use pagination in the API and Client Libraries.
11131
11260
  parameters:
11132
11261
  - "$ref": "#/components/parameters/ids"
11133
11262
  - "$ref": "#/components/parameters/limit"
@@ -11372,8 +11501,8 @@ paths:
11372
11501
  - subscription
11373
11502
  operationId: list_subscriptions
11374
11503
  summary: List a site's subscriptions
11375
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
11376
- to use pagination in the API and Client Libraries.
11504
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
11505
+ to learn how to use pagination in the API and Client Libraries.
11377
11506
  parameters:
11378
11507
  - "$ref": "#/components/parameters/ids"
11379
11508
  - "$ref": "#/components/parameters/limit"
@@ -13252,8 +13381,8 @@ paths:
13252
13381
  - invoice
13253
13382
  operationId: list_subscription_invoices
13254
13383
  summary: List a subscription's invoices
13255
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
13256
- to use pagination in the API and Client Libraries.
13384
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
13385
+ to learn how to use pagination in the API and Client Libraries.
13257
13386
  parameters:
13258
13387
  - "$ref": "#/components/parameters/subscription_id"
13259
13388
  - "$ref": "#/components/parameters/ids"
@@ -13356,8 +13485,8 @@ paths:
13356
13485
  - line_item
13357
13486
  operationId: list_subscription_line_items
13358
13487
  summary: List a subscription's line items
13359
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
13360
- to use pagination in the API and Client Libraries.
13488
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
13489
+ to learn how to use pagination in the API and Client Libraries.
13361
13490
  parameters:
13362
13491
  - "$ref": "#/components/parameters/subscription_id"
13363
13492
  - "$ref": "#/components/parameters/ids"
@@ -13463,8 +13592,8 @@ paths:
13463
13592
  - coupon_redemption
13464
13593
  operationId: list_subscription_coupon_redemptions
13465
13594
  summary: List the coupon redemptions for a subscription
13466
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
13467
- to use pagination in the API and Client Libraries.
13595
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
13596
+ to learn how to use pagination in the API and Client Libraries.
13468
13597
  parameters:
13469
13598
  - "$ref": "#/components/parameters/subscription_id"
13470
13599
  - "$ref": "#/components/parameters/ids"
@@ -13762,8 +13891,8 @@ paths:
13762
13891
  - transaction
13763
13892
  operationId: list_transactions
13764
13893
  summary: List a site's transactions
13765
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
13766
- to use pagination in the API and Client Libraries.
13894
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
13895
+ to learn how to use pagination in the API and Client Libraries.
13767
13896
  parameters:
13768
13897
  - "$ref": "#/components/parameters/ids"
13769
13898
  - "$ref": "#/components/parameters/limit"
@@ -15043,8 +15172,8 @@ paths:
15043
15172
  - dunning_campaigns
15044
15173
  operationId: list_dunning_campaigns
15045
15174
  summary: List the dunning campaigns for a site
15046
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
15047
- to use pagination in the API and Client Libraries.
15175
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
15176
+ to learn how to use pagination in the API and Client Libraries.
15048
15177
  parameters:
15049
15178
  - "$ref": "#/components/parameters/sort_dates"
15050
15179
  responses:
@@ -15146,8 +15275,8 @@ paths:
15146
15275
  - invoice_templates
15147
15276
  operationId: list_invoice_templates
15148
15277
  summary: Show the invoice templates for a site
15149
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
15150
- to use pagination in the API and Client Libraries.
15278
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
15279
+ to learn how to use pagination in the API and Client Libraries.
15151
15280
  parameters:
15152
15281
  - "$ref": "#/components/parameters/sort_dates"
15153
15282
  responses:
@@ -15241,8 +15370,8 @@ paths:
15241
15370
  - account
15242
15371
  operationId: list_account_external_subscriptions
15243
15372
  summary: List an account's external subscriptions
15244
- description: See the [Pagination Guide](/guides/pagination.html) to learn how
15245
- to use pagination in the API and Client Libraries.
15373
+ description: See the [Pagination Guide](/developers/guides/pagination.html)
15374
+ to learn how to use pagination in the API and Client Libraries.
15246
15375
  parameters:
15247
15376
  - "$ref": "#/components/parameters/sort_dates"
15248
15377
  responses:
@@ -16139,6 +16268,11 @@ components:
16139
16268
  behalf of the merchant to the customer. The list of locales is restricted
16140
16269
  to those the merchant has enabled on the site.
16141
16270
  "$ref": "#/components/schemas/PreferredLocaleEnum"
16271
+ preferred_time_zone:
16272
+ type: string
16273
+ example: America/Los_Angeles
16274
+ description: Used to determine the time zone of emails sent on behalf of
16275
+ the merchant to the customer. Must be a [supported IANA time zone name](https://docs.recurly.com/docs/email-time-zones-and-time-stamps#supported-api-iana-time-zone-names)
16142
16276
  cc_emails:
16143
16277
  type: string
16144
16278
  description: Additional email address that should receive account correspondence.
@@ -16241,6 +16375,12 @@ components:
16241
16375
  description: Used to determine the language and locale of emails sent on
16242
16376
  behalf of the merchant to the customer.
16243
16377
  "$ref": "#/components/schemas/PreferredLocaleEnum"
16378
+ preferred_time_zone:
16379
+ type: string
16380
+ example: America/Los_Angeles
16381
+ description: The [IANA time zone name](https://docs.recurly.com/docs/email-time-zones-and-time-stamps#supported-api-iana-time-zone-names)
16382
+ used to determine the time zone of emails sent on behalf of the merchant
16383
+ to the customer.
16244
16384
  cc_emails:
16245
16385
  type: string
16246
16386
  description: Additional email address that should receive account correspondence.
@@ -16400,9 +16540,15 @@ components:
16400
16540
  processing_prepayment_amount:
16401
16541
  type: number
16402
16542
  format: float
16403
- title: Amount
16543
+ title: Processing Prepayment Amount
16404
16544
  description: Total amount for the prepayment credit invoices in a `processing`
16405
16545
  state on the account.
16546
+ available_credit_amount:
16547
+ type: number
16548
+ format: float
16549
+ title: Available Credit Amount
16550
+ description: Total amount of the open balances on credit invoices for the
16551
+ account.
16406
16552
  InvoiceAddress:
16407
16553
  allOf:
16408
16554
  - "$ref": "#/components/schemas/Address"
@@ -16640,6 +16786,8 @@ components:
16640
16786
  percentage_tiers:
16641
16787
  type: array
16642
16788
  title: Percentage Tiers
16789
+ description: This feature is currently in development and requires approval
16790
+ and enablement, please contact support.
16643
16791
  items:
16644
16792
  "$ref": "#/components/schemas/PercentageTiersByCurrency"
16645
16793
  external_sku:
@@ -16833,7 +16981,8 @@ components:
16833
16981
  Array of objects which must have at least one set of tiers
16834
16982
  per currency and the currency code. The tier_type must be `volume` or `tiered`,
16835
16983
  if not, it must be absent. There must be one tier without an `ending_amount` value
16836
- which represents the final tier.
16984
+ which represents the final tier. This feature is currently in development and
16985
+ requires approval and enablement, please contact support.
16837
16986
  required:
16838
16987
  - code
16839
16988
  - name
@@ -16974,7 +17123,8 @@ components:
16974
17123
  `percentage_tiers` is an array of objects, which must have the set of tiers
16975
17124
  per currency and the currency code. The tier_type must be `volume` or `tiered`,
16976
17125
  if not, it must be absent. There must be one tier without an `ending_amount` value
16977
- which represents the final tier.
17126
+ which represents the final tier. This feature is currently in development and
17127
+ requires approval and enablement, please contact support.
16978
17128
  BillingInfo:
16979
17129
  type: object
16980
17130
  properties:
@@ -18212,7 +18362,11 @@ components:
18212
18362
  type: string
18213
18363
  title: Previous invoice ID
18214
18364
  description: On refund invoices, this value will exist and show the invoice
18215
- ID of the purchase invoice the refund was created from.
18365
+ ID of the purchase invoice the refund was created from. This field is
18366
+ only populated for sites without the [Only Bill What Changed](https://docs.recurly.com/docs/only-bill-what-changed)
18367
+ feature enabled. Sites with Only Bill What Changed enabled should use
18368
+ the [related_invoices endpoint](https://recurly.com/developers/api/v2021-02-25/index.html#operation/list_related_invoices)
18369
+ to see purchase invoices refunded by this invoice.
18216
18370
  maxLength: 13
18217
18371
  number:
18218
18372
  type: string
@@ -20618,8 +20772,8 @@ components:
20618
20772
  description: |
20619
20773
  If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be
20620
20774
  removed and replaced by the percentage tiers in the request. Use only if add_on.tier_type is tiered or volume and
20621
- add_on.usage_type is percentage.
20622
- There must be one tier without an `ending_amount` value which represents the final tier.
20775
+ add_on.usage_type is percentage. There must be one tier without an `ending_amount` value which represents the final tier.
20776
+ This feature is currently in development and requires approval and enablement, please contact support.
20623
20777
  usage_percentage:
20624
20778
  type: number
20625
20779
  format: float
@@ -20696,8 +20850,9 @@ components:
20696
20850
  minItems: 1
20697
20851
  description: |
20698
20852
  If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be
20699
- removed and replaced by the percentage tiers in the request. There must be one tier without ending_amount value which represents the final tier.
20700
- Use only if add_on.tier_type is tiered or volume and add_on.usage_type is percentage.
20853
+ removed and replaced by the percentage tiers in the request. There must be one tier without ending_amount value
20854
+ which represents the final tier. Use only if add_on.tier_type is tiered or volume and add_on.usage_type is
20855
+ percentage. This feature is currently in development and requires approval and enablement, please contact support.
20701
20856
  usage_percentage:
20702
20857
  type: number
20703
20858
  format: float
@@ -20776,8 +20931,8 @@ components:
20776
20931
  description: |
20777
20932
  If percentage tiers are provided in the request, all existing percentage tiers on the Subscription Add-on will be
20778
20933
  removed and replaced by the percentage tiers in the request. Use only if add_on.tier_type is tiered or volume and
20779
- add_on.usage_type is percentage.
20780
- There must be one tier without an `ending_amount` value which represents the final tier.
20934
+ add_on.usage_type is percentage. There must be one tier without an `ending_amount` value which represents the
20935
+ final tier. This feature is currently in development and requires approval and enablement, please contact support.
20781
20936
  usage_percentage:
20782
20937
  type: number
20783
20938
  format: float
@@ -21958,7 +22113,8 @@ components:
21958
22113
  items:
21959
22114
  "$ref": "#/components/schemas/SubscriptionAddOnPercentageTier"
21960
22115
  description: The percentage tiers of the subscription based on the usage_timestamp.
21961
- If tier_type = flat, percentage_tiers = []
22116
+ If tier_type = flat, percentage_tiers = []. This feature is currently
22117
+ in development and requires approval and enablement, please contact support.
21962
22118
  measured_unit_id:
21963
22119
  type: string
21964
22120
  description: The ID of the measured unit associated with the add-on the
@@ -22372,7 +22528,8 @@ components:
22372
22528
  description: Time the object was last updated
22373
22529
  ExternalProduct:
22374
22530
  type: object
22375
- description: Product from an external resource such as Apple App or Google Play.
22531
+ description: Product from an external resource such as Apple App Store or Google
22532
+ Play Store.
22376
22533
  properties:
22377
22534
  id:
22378
22535
  type: string
@@ -22452,8 +22609,8 @@ components:
22452
22609
  description: When the external product was updated in Recurly.
22453
22610
  ExternalSubscription:
22454
22611
  type: object
22455
- description: Subscription from an external resource such as Apple App or Google
22456
- Play.
22612
+ description: Subscription from an external resource such as Apple App Store
22613
+ or Google Play Store.
22457
22614
  properties:
22458
22615
  id:
22459
22616
  type: string
@@ -23314,7 +23471,9 @@ components:
23314
23471
  - Dankort
23315
23472
  - Diners Club
23316
23473
  - Discover
23474
+ - ELO
23317
23475
  - Forbrugsforeningen
23476
+ - Hipercard
23318
23477
  - JCB
23319
23478
  - Laser
23320
23479
  - Maestro
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: recurly
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.25.0
4
+ version: 4.27.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Recurly
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-11-15 00:00:00.000000000 Z
11
+ date: 2023-01-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -326,7 +326,7 @@ metadata:
326
326
  changelog_uri: https://github.com/recurly/recurly-client-ruby/blob/master/CHANGELOG.md
327
327
  documentation_uri: https://recurly.github.io/recurly-client-ruby/
328
328
  homepage_uri: https://github.com/recurly/recurly-client-ruby
329
- source_code_uri: https://github.com/recurly/recurly-client-ruby/tree/4.25.0
329
+ source_code_uri: https://github.com/recurly/recurly-client-ruby/tree/4.27.0
330
330
  post_install_message:
331
331
  rdoc_options: []
332
332
  require_paths: