From 571648920c86a4735ae6e28c4a8c2787e94349df Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 17 Nov 2023 01:35:40 +0000 Subject: [PATCH] Update services based on v669 of Stripe OpenApi SDK Reference: https://github.com/stripe/openapi/releases/tag/v669 --- .latest-tag-stripe-openapi-sdk | 2 +- lib/generated/account.ex | 29 +++--- lib/generated/checkout__session.ex | 11 +-- lib/generated/payment_intent.ex | 146 ++++++++++++++--------------- lib/generated/setup_intent.ex | 21 +++-- lib/generated/token.ex | 15 ++- priv/openapi/spec3.sdk.json | 50 +++++++++- 7 files changed, 155 insertions(+), 119 deletions(-) diff --git a/.latest-tag-stripe-openapi-sdk b/.latest-tag-stripe-openapi-sdk index 7dd62bd6..1719ca37 100644 --- a/.latest-tag-stripe-openapi-sdk +++ b/.latest-tag-stripe-openapi-sdk @@ -1 +1 @@ -v665 +v669 diff --git a/lib/generated/account.ex b/lib/generated/account.ex index 378b38f3..912bbc3b 100644 --- a/lib/generated/account.ex +++ b/lib/generated/account.ex @@ -91,7 +91,7 @@ defmodule Stripe.Account do ) ( - @typedoc "The Kanji variation of the the individual's primary address (Japan only)." + @typedoc "The Kanji variation of the company's primary address (Japan only)." @type address_kanji :: %{ optional(:city) => binary, optional(:country) => binary, @@ -119,8 +119,8 @@ defmodule Stripe.Account do ) ( - @typedoc "The bacs_debit_payments capability." - @type bacs_debit_payments :: %{optional(:requested) => boolean} + @typedoc "Settings specific to Bacs Direct Debit payments." + @type bacs_debit_payments :: %{optional(:display_name) => binary} ) ( @@ -217,18 +217,13 @@ defmodule Stripe.Account do ) ( - @typedoc "Settings specific to the account's use of the Card Issuing product." - @type card_issuing :: %{optional(:tos_acceptance) => tos_acceptance} + @typedoc "The card_issuing capability." + @type card_issuing :: %{optional(:requested) => boolean} ) ( - @typedoc "Settings specific to card charging on the account." - @type card_payments :: %{ - optional(:decline_on) => decline_on, - optional(:statement_descriptor_prefix) => binary, - optional(:statement_descriptor_prefix_kana) => binary | binary, - optional(:statement_descriptor_prefix_kanji) => binary | binary - } + @typedoc "The card_payments capability." + @type card_payments :: %{optional(:requested) => boolean} ) ( @@ -545,6 +540,7 @@ defmodule Stripe.Account do ( @typedoc "Options for customizing how the account functions within Stripe." @type settings :: %{ + optional(:bacs_debit_payments) => bacs_debit_payments, optional(:branding) => branding, optional(:card_issuing) => card_issuing, optional(:card_payments) => card_payments, @@ -582,7 +578,7 @@ defmodule Stripe.Account do ) ( - @typedoc "Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](https://stripe.com/docs/issuing/connect/tos_acceptance)." + @typedoc "Details on the account's acceptance of the Stripe Treasury Services Agreement." @type tos_acceptance :: %{ optional(:date) => integer, optional(:ip) => binary, @@ -606,8 +602,11 @@ defmodule Stripe.Account do ) ( - @typedoc "Information on the verification state of the company." - @type verification :: %{optional(:document) => document} + @typedoc "The individual's verification document information." + @type verification :: %{ + optional(:additional_document) => additional_document, + optional(:document) => document + } ) ( diff --git a/lib/generated/checkout__session.ex b/lib/generated/checkout__session.ex index 031148fc..c364781c 100644 --- a/lib/generated/checkout__session.ex +++ b/lib/generated/checkout__session.ex @@ -238,15 +238,7 @@ defmodule Stripe.Checkout.Session do ( @typedoc nil - @type custom_fields :: %{ - optional(:dropdown) => dropdown, - optional(:key) => binary, - optional(:label) => label, - optional(:numeric) => numeric, - optional(:optional) => boolean, - optional(:text) => text, - optional(:type) => :dropdown | :numeric | :text - } + @type custom_fields :: %{optional(:name) => binary, optional(:value) => binary} ) ( @@ -998,6 +990,7 @@ defmodule Stripe.Checkout.Session do optional(:payment_intent) => binary, optional(:payment_link) => binary, optional(:starting_after) => binary, + optional(:status) => :complete | :expired | :open, optional(:subscription) => binary }, opts :: Keyword.t() diff --git a/lib/generated/payment_intent.ex b/lib/generated/payment_intent.ex index 6d478454..bbc4ef3d 100644 --- a/lib/generated/payment_intent.ex +++ b/lib/generated/payment_intent.ex @@ -285,8 +285,38 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil - @type eps :: %{optional(:setup_future_usage) => :none} + @typedoc "If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method." + @type eps :: %{ + optional(:bank) => + :arzte_und_apotheker_bank + | :austrian_anadi_bank_ag + | :bank_austria + | :bankhaus_carl_spangler + | :bankhaus_schelhammer_und_schattera_ag + | :bawag_psk_ag + | :bks_bank_ag + | :brull_kallmus_bank_ag + | :btv_vier_lander_bank + | :capital_bank_grawe_gruppe_ag + | :deutsche_bank_ag + | :dolomitenbank + | :easybank_ag + | :erste_bank_und_sparkassen + | :hypo_alpeadriabank_international_ag + | :hypo_bank_burgenland_aktiengesellschaft + | :hypo_noe_lb_fur_niederosterreich_u_wien + | :hypo_oberosterreich_salzburg_steiermark + | :hypo_tirol_bank_ag + | :hypo_vorarlberg_bank_ag + | :marchfelder_bank + | :oberbank_ag + | :raiffeisen_bankengruppe_osterreich + | :schoellerbank_ag + | :sparda_bank_wien + | :volksbank_gruppe + | :volkskreditbank_ag + | :vr_bank_braunau + } ) ( @@ -320,25 +350,8 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc "If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method." - @type ideal :: %{ - optional(:bank) => - :abn_amro - | :asn_bank - | :bunq - | :handelsbanken - | :ing - | :knab - | :moneyou - | :n26 - | :rabobank - | :regiobank - | :revolut - | :sns_bank - | :triodos_bank - | :van_lanschot - | :yoursafe - } + @typedoc nil + @type ideal :: %{optional(:setup_future_usage) => :none | :off_session} ) ( @@ -347,56 +360,8 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil - @type klarna :: %{ - optional(:capture_method) => :manual, - optional(:preferred_locale) => - :"cs-CZ" - | :"da-DK" - | :"de-AT" - | :"de-CH" - | :"de-DE" - | :"el-GR" - | :"en-AT" - | :"en-AU" - | :"en-BE" - | :"en-CA" - | :"en-CH" - | :"en-CZ" - | :"en-DE" - | :"en-DK" - | :"en-ES" - | :"en-FI" - | :"en-FR" - | :"en-GB" - | :"en-GR" - | :"en-IE" - | :"en-IT" - | :"en-NL" - | :"en-NO" - | :"en-NZ" - | :"en-PL" - | :"en-PT" - | :"en-SE" - | :"en-US" - | :"es-ES" - | :"es-US" - | :"fi-FI" - | :"fr-BE" - | :"fr-CA" - | :"fr-CH" - | :"fr-FR" - | :"it-CH" - | :"it-IT" - | :"nb-NO" - | :"nl-BE" - | :"nl-NL" - | :"pl-PL" - | :"pt-PT" - | :"sv-FI" - | :"sv-SE", - optional(:setup_future_usage) => :none - } + @typedoc "If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method." + @type klarna :: %{optional(:dob) => dob} ) ( @@ -458,10 +423,34 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil + @typedoc "If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method." @type p24 :: %{ - optional(:setup_future_usage) => :none, - optional(:tos_shown_and_accepted) => boolean + optional(:bank) => + :alior_bank + | :bank_millennium + | :bank_nowy_bfg_sa + | :bank_pekao_sa + | :banki_spbdzielcze + | :blik + | :bnp_paribas + | :boz + | :citi_handlowy + | :credit_agricole + | :envelobank + | :etransfer_pocztowy24 + | :getin_bank + | :ideabank + | :ing + | :inteligo + | :mbank_mtransfer + | :nest_przelew + | :noble_pay + | :pbac_z_ipko + | :plus_bank + | :santander_przelew24 + | :tmobile_usbugi_bankowe + | :toyota_bank + | :volkswagen_bank } ) @@ -639,7 +628,7 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc "Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session)." + @typedoc "Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information." @type radar_options :: %{optional(:session) => binary} ) @@ -649,8 +638,11 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc "If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account." - @type sepa_debit :: %{optional(:iban) => binary} + @typedoc nil + @type sepa_debit :: %{ + optional(:mandate_options) => map(), + optional(:setup_future_usage) => :none | :off_session | :on_session + } ) ( diff --git a/lib/generated/setup_intent.ex b/lib/generated/setup_intent.ex index e8a6fe24..0689d556 100644 --- a/lib/generated/setup_intent.ex +++ b/lib/generated/setup_intent.ex @@ -278,13 +278,18 @@ defmodule Stripe.SetupIntent do ) ( - @typedoc "Additional fields for Mandate creation" + @typedoc "Configuration options for setting up an eMandate for cards issued in India." @type mandate_options :: %{ - optional(:custom_mandate_url) => binary | binary, - optional(:default_for) => list(:invoice | :subscription), - optional(:interval_description) => binary, - optional(:payment_schedule) => :combined | :interval | :sporadic, - optional(:transaction_type) => :business | :personal + optional(:amount) => integer, + optional(:amount_type) => :fixed | :maximum, + optional(:currency) => binary, + optional(:description) => binary, + optional(:end_date) => integer, + optional(:interval) => :day | :month | :sporadic | :week | :year, + optional(:interval_count) => integer, + optional(:reference) => binary, + optional(:start_date) => integer, + optional(:supported_types) => list(:india) } ) @@ -426,8 +431,8 @@ defmodule Stripe.SetupIntent do ) ( - @typedoc "If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account." - @type sepa_debit :: %{optional(:iban) => binary} + @typedoc "If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options." + @type sepa_debit :: %{optional(:mandate_options) => map()} ) ( diff --git a/lib/generated/token.ex b/lib/generated/token.ex index 27f79a70..5d6c6d71 100644 --- a/lib/generated/token.ex +++ b/lib/generated/token.ex @@ -20,12 +20,11 @@ defmodule Stripe.Token do ) ( - @typedoc "Information for the account this token represents." + @typedoc "Details on the legal guardian's acceptance of the main Stripe service agreement." @type account :: %{ - optional(:business_type) => :company | :government_entity | :individual | :non_profit, - optional(:company) => company, - optional(:individual) => individual, - optional(:tos_shown_and_accepted) => boolean + optional(:date) => integer, + optional(:ip) => binary, + optional(:user_agent) => binary | binary } ) @@ -65,7 +64,7 @@ defmodule Stripe.Token do ) ( - @typedoc "The Kanji variation of the the individual's primary address (Japan only)." + @typedoc "The Kanji variation of the person's address (Japan only)." @type address_kanji :: %{ optional(:city) => binary, optional(:country) => binary, @@ -269,7 +268,7 @@ defmodule Stripe.Token do ) ( - @typedoc "The individual's registered address." + @typedoc "The person's registered address." @type registered_address :: %{ optional(:city) => binary, optional(:country) => binary, @@ -294,7 +293,7 @@ defmodule Stripe.Token do ) ( - @typedoc "The person's verification status." + @typedoc "The individual's verification document information." @type verification :: %{ optional(:additional_document) => additional_document, optional(:document) => document diff --git a/priv/openapi/spec3.sdk.json b/priv/openapi/spec3.sdk.json index 07c1a755..e65d79d2 100644 --- a/priv/openapi/spec3.sdk.json +++ b/priv/openapi/spec3.sdk.json @@ -381,11 +381,22 @@ "description": "", "properties": { "display_name": { - "description": "The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this will appear on the mandate, and as the statement descriptor.", + "description": "The Bacs Direct Debit display name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. The fee appears 5 business days after requesting Bacs. If you don't set the display name before requesting Bacs capability, it's automatically set as \"Stripe\" and the account is onboarded to Stripe branding, which is free.", "maxLength": 5000, + "nullable": true, + "type": "string" + }, + "service_user_number": { + "description": "The Bacs Direct Debit Service user number for this account. For payments made with Bacs Direct Debit, this number is a unique identifier of the account with our banking partners.", + "maxLength": 5000, + "nullable": true, "type": "string" } }, + "required": [ + "display_name", + "service_user_number" + ], "title": "AccountBacsDebitPaymentsSettings", "type": "object", "x-expandableFields": [], @@ -59323,6 +59334,17 @@ "settings": { "description": "Options for customizing how the account functions within Stripe.", "properties": { + "bacs_debit_payments": { + "description": "Settings specific to Bacs Direct Debit.", + "properties": { + "display_name": { + "description": "The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as \"Stripe\" and the account is onboarded to Stripe branding, which is free.", + "type": "string" + } + }, + "title": "bacs_debit_payments_specs", + "type": "object" + }, "branding": { "description": "Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.", "properties": { @@ -61119,6 +61141,17 @@ "settings": { "description": "Options for customizing how the account functions within Stripe.", "properties": { + "bacs_debit_payments": { + "description": "Settings specific to Bacs Direct Debit payments.", + "properties": { + "display_name": { + "description": "The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as \"Stripe\" and the account is onboarded to Stripe branding, which is free.", + "type": "string" + } + }, + "title": "bacs_debit_payments_specs", + "type": "object" + }, "branding": { "description": "Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.", "properties": { @@ -68306,6 +68339,21 @@ }, "style": "form" }, + { + "description": "Only return the Checkout Sessions matching the given status.", + "in": "query", + "name": "status", + "required": false, + "schema": { + "enum": [ + "complete", + "expired", + "open" + ], + "type": "string" + }, + "style": "form" + }, { "description": "Only return the Checkout Session for the subscription specified.", "in": "query",