From ef82e7dae7f63c004163eedcd50da61c78e292fb Mon Sep 17 00:00:00 2001 From: Recurly Integrations Date: Fri, 24 May 2024 16:52:03 +0000 Subject: [PATCH] Generated Latest Changes for v2019-10-10 --- openapi/api.yaml | 92 ++++++++++++++++++++++++++++++++++++++++---- recurly/client.py | 6 +++ recurly/resources.py | 23 ++++++++++- 3 files changed, 112 insertions(+), 9 deletions(-) diff --git a/openapi/api.yaml b/openapi/api.yaml index f32d168d..79338fca 100644 --- a/openapi/api.yaml +++ b/openapi/api.yaml @@ -885,7 +885,7 @@ paths: Alabama St.\"),\n\t\t\tCity: recurly.String(\"San Francisco\"),\n\t\t\tPostalCode: recurly.String(\"94110\"),\n\t\t\tCountry: recurly.String(\"US\"),\n\t\t\tRegion: \ recurly.String(\"CA\"),\n\t\t},\n\t\tNumber: recurly.String(\"4111111111111111\"),\n\t\tMonth: - \ recurly.String(\"12\"),\n\t\tYear: recurly.String(\"22\"),\n\t\tCvv: + \ recurly.String(\"12\"),\n\t\tYear: recurly.String(\"30\"),\n\t\tCvv: \ recurly.String(\"123\"),\n\t},\n}\n\naccount, err := client.CreateAccount(accountReq)\nif e, ok := err.(*recurly.Error); ok {\n\tif e.Type == recurly.ErrorTypeValidation {\n\t\tfmt.Printf(\"Failed validation: %v\", e)\n\t\treturn nil, err\n\t}\n\tfmt.Printf(\"Unexpected @@ -3195,6 +3195,7 @@ paths: - "$ref": "#/components/parameters/site_id" - "$ref": "#/components/parameters/account_id" - "$ref": "#/components/parameters/ids" + - "$ref": "#/components/parameters/invoice_state" - "$ref": "#/components/parameters/limit" - "$ref": "#/components/parameters/order" - "$ref": "#/components/parameters/sort_dates" @@ -7394,6 +7395,7 @@ paths: parameters: - "$ref": "#/components/parameters/site_id" - "$ref": "#/components/parameters/ids" + - "$ref": "#/components/parameters/invoice_state" - "$ref": "#/components/parameters/limit" - "$ref": "#/components/parameters/order" - "$ref": "#/components/parameters/sort_dates" @@ -7888,8 +7890,6 @@ paths: summary: Apply available credit to a pending or past due charge invoice description: Apply credit payment to the outstanding balance on an existing charge invoice from an account’s available balance from existing credit invoices. - Credit that was refunded from the invoice cannot be applied back to the invoice - as payment. parameters: - "$ref": "#/components/parameters/site_id" - "$ref": "#/components/parameters/invoice_id" @@ -13059,6 +13059,7 @@ paths: - "$ref": "#/components/parameters/site_id" - "$ref": "#/components/parameters/subscription_id" - "$ref": "#/components/parameters/ids" + - "$ref": "#/components/parameters/invoice_state" - "$ref": "#/components/parameters/limit" - "$ref": "#/components/parameters/order" - "$ref": "#/components/parameters/sort_dates" @@ -14724,6 +14725,18 @@ components: required: true schema: type: string + invoice_state: + name: state + in: query + description: Invoice state. + schema: + type: string + default: all + enum: + - pending + - past_due + - paid + - failed measured_unit_id: name: measured_unit_id in: path @@ -15662,6 +15675,11 @@ components: "$ref": "#/components/schemas/BillingInfoCreate" custom_fields: "$ref": "#/components/schemas/CustomFields" + entity_use_code: + type: string + description: The Avalara AvaTax value that can be passed to identify the + customer type for tax purposes. The range of values can be A - R (more + info at Avalara). Value is case-sensitive. AccountResponse: type: object properties: @@ -15781,6 +15799,11 @@ components: "$ref": "#/components/schemas/BillingInfo" custom_fields: "$ref": "#/components/schemas/CustomFields" + entity_use_code: + type: string + description: The Avalara AvaTax value that can be passed to identify the + customer type for tax purposes. The range of values can be A - R (more + info at Avalara). Value is case-sensitive. AccountNote: type: object required: @@ -15932,6 +15955,11 @@ components: type: string title: Country description: Country, 2-letter ISO 3166-1 alpha-2 code. + geo_code: + type: string + maxLength: 20 + description: Code that represents a geographic entity (location or object). + Only returned for Sling Vertex Integration AddOnMini: type: object title: Add-on mini details @@ -16652,16 +16680,30 @@ components: properties: account_reference: type: string - description: Used by Adyen gateways. The Shopper Reference value used - when the external token was created. Must be used in conjunction with - gateway_token and gateway_code. + description: Used by Adyen and Braintree gateways. For Adyen The Shopper + Reference value used when the external token was created. Must be + used in conjunction with gateway_token and gateway_code. For Braintree + the PayPal PayerID is populated in the response. maxLength: 264 + card_network_preference: + type: string + description: Represents the card network preference associated with the + billing info for dual badged cards. Must be a supported card network. + enum: + - Bancontact + - CartesBancaires + - Dankort + - MasterCard + - Visa amazon_billing_agreement_id: type: string title: Amazon billing agreement ID paypal_billing_agreement_id: type: string title: PayPal billing agreement ID + roku_billing_agreement_id: + type: string + title: Roku's CIB if billing through Roku fraud_session_id: type: string title: Fraud Session ID @@ -19734,6 +19776,11 @@ components: type: string maxLength: 50 description: Country, 2-letter ISO 3166-1 alpha-2 code. + geo_code: + type: string + maxLength: 20 + description: Code that represents a geographic entity (location or object). + Only returned for Sling Vertex Integration created_at: type: string title: Created at @@ -19789,6 +19836,11 @@ components: type: string maxLength: 50 description: Country, 2-letter ISO 3166-1 alpha-2 code. + geo_code: + type: string + maxLength: 20 + description: Code that represents a geographic entity (location or object). + Only returned for Sling Vertex Integration required: - first_name - last_name @@ -20039,6 +20091,11 @@ components: type: string maxLength: 50 description: Country, 2-letter ISO 3166-1 alpha-2 code. + geo_code: + type: string + maxLength: 20 + description: Code that represents a geographic entity (location or object). + Only returned for Sling Vertex Integration Site: type: object properties: @@ -21334,6 +21391,14 @@ components: remaining_billing_cycles: type: integer description: Represents how many billing cycles are left in a ramp interval. + starting_on: + type: string + format: date-time + title: Date the ramp interval starts + ending_on: + type: string + format: date-time + title: Date the ramp interval ends unit_amount: type: integer description: Represents the price for the ramp interval. @@ -22275,9 +22340,20 @@ components: properties: account_reference: type: string - description: Used by Adyen gateways. The Shopper Reference value used - when the external token was created. + description: Used by Adyen and Braintree gateways. For Adyen the Shopper + Reference value used when the external token was created. For Braintree + the PayPal PayerID is populated in the response. maxLength: 264 + card_network_preference: + type: string + description: Represents the card network preference associated with the + billing info for dual badged cards. Must be a supported card network. + enum: + - Bancontact + - CartesBancaires + - Dankort + - MasterCard + - Visa billing_agreement_id: type: string description: Billing Agreement identifier. Only present for Amazon or Paypal diff --git a/recurly/client.py b/recurly/client.py index 787ada00..123f1fb4 100644 --- a/recurly/client.py +++ b/recurly/client.py @@ -749,6 +749,8 @@ def list_account_invoices(self, account_id, **options): results correspond to your request. * Records are returned in an arbitrary order. Since results are all returned at once you can sort the records yourself. + state : str + Invoice state. limit : int Limit number of records 1-200. order : str @@ -1970,6 +1972,8 @@ def list_invoices(self, **options): results correspond to your request. * Records are returned in an arbitrary order. Since results are all returned at once you can sort the records yourself. + state : str + Invoice state. limit : int Limit number of records 1-200. order : str @@ -3370,6 +3374,8 @@ def list_subscription_invoices(self, subscription_id, **options): results correspond to your request. * Records are returned in an arbitrary order. Since results are all returned at once you can sort the records yourself. + state : str + Invoice state. limit : int Limit number of records 1-200. order : str diff --git a/recurly/resources.py b/recurly/resources.py index 3008bfe8..4bdb8bff 100644 --- a/recurly/resources.py +++ b/recurly/resources.py @@ -57,6 +57,8 @@ class Address(Resource): Country, 2-letter ISO 3166-1 alpha-2 code. first_name : str First name + geo_code : str + Code that represents a geographic entity (location or object). Only returned for Sling Vertex Integration last_name : str Last name phone : str @@ -75,6 +77,7 @@ class Address(Resource): "city": str, "country": str, "first_name": str, + "geo_code": str, "last_name": str, "phone": str, "postal_code": str, @@ -147,6 +150,8 @@ class Account(Resource): Unique ID to identify a dunning campaign. Used to specify if a non-default dunning campaign should be assigned to this account. For sites without multiple dunning campaigns enabled, the default dunning campaign will always be used. email : str The email address used for communicating with this customer. The customer will also use this email address to log into your hosted account management pages. This value does not need to be unique. + entity_use_code : str + The Avalara AvaTax value that can be passed to identify the customer type for tax purposes. The range of values can be A - R (more info at Avalara). Value is case-sensitive. exemption_certificate : str The tax exemption certificate number for the account. If the merchant has an integration for the Vertex tax provider, this optional value will be sent in any tax calculation requests for the account. first_name : str @@ -200,6 +205,7 @@ class Account(Resource): "deleted_at": datetime, "dunning_campaign_id": str, "email": str, + "entity_use_code": str, "exemption_certificate": str, "first_name": str, "has_active_subscription": bool, @@ -238,6 +244,8 @@ class ShippingAddress(Resource): Created at email : str first_name : str + geo_code : str + Code that represents a geographic entity (location or object). Only returned for Sling Vertex Integration id : str Shipping Address ID last_name : str @@ -264,6 +272,7 @@ class ShippingAddress(Resource): "created_at": datetime, "email": str, "first_name": str, + "geo_code": str, "id": str, "last_name": str, "nickname": str, @@ -335,6 +344,8 @@ class PaymentMethod(Resource): The bank account type. Only present for ACH payment methods. billing_agreement_id : str Billing Agreement identifier. Only present for Amazon or Paypal payment methods. + card_network_preference : str + Represents the card network preference associated with the billing info for dual badged cards. Must be a supported card network. card_type : str Visa, MasterCard, American Express, Discover, JCB, etc. cc_bin_country : str @@ -367,6 +378,7 @@ class PaymentMethod(Resource): schema = { "account_type": str, "billing_agreement_id": str, + "card_network_preference": str, "card_type": str, "cc_bin_country": str, "exp_month": int, @@ -389,7 +401,7 @@ class GatewayAttributes(Resource): Attributes ---------- account_reference : str - Used by Adyen gateways. The Shopper Reference value used when the external token was created. + Used by Adyen and Braintree gateways. For Adyen the Shopper Reference value used when the external token was created. For Braintree the PayPal PayerID is populated in the response. """ schema = { @@ -1238,6 +1250,8 @@ class InvoiceAddress(Resource): Country, 2-letter ISO 3166-1 alpha-2 code. first_name : str First name + geo_code : str + Code that represents a geographic entity (location or object). Only returned for Sling Vertex Integration last_name : str Last name name_on_account : str @@ -1259,6 +1273,7 @@ class InvoiceAddress(Resource): "company": str, "country": str, "first_name": str, + "geo_code": str, "last_name": str, "name_on_account": str, "phone": str, @@ -2031,17 +2046,23 @@ class SubscriptionRampIntervalResponse(Resource): """ Attributes ---------- + ending_on : datetime + Date the ramp interval ends remaining_billing_cycles : int Represents how many billing cycles are left in a ramp interval. starting_billing_cycle : int Represents the billing cycle where a ramp interval starts. + starting_on : datetime + Date the ramp interval starts unit_amount : int Represents the price for the ramp interval. """ schema = { + "ending_on": datetime, "remaining_billing_cycles": int, "starting_billing_cycle": int, + "starting_on": datetime, "unit_amount": int, }