diff --git a/.latest-tag-stripe-openapi-sdk b/.latest-tag-stripe-openapi-sdk index 8397cf82..b8a55cf1 100644 --- a/.latest-tag-stripe-openapi-sdk +++ b/.latest-tag-stripe-openapi-sdk @@ -1 +1 @@ -v551 +v553 diff --git a/lib/generated/account.ex b/lib/generated/account.ex index 9691f471..024c3c3a 100644 --- a/lib/generated/account.ex +++ b/lib/generated/account.ex @@ -66,7 +66,7 @@ defmodule Stripe.Account do ) ( - @typedoc "The company's primary address." + @typedoc "The individual's primary address." @type address :: %{ optional(:city) => binary, optional(:country) => binary, @@ -78,7 +78,7 @@ defmodule Stripe.Account do ) ( - @typedoc "The Kana variation of the the individual's primary address (Japan only)." + @typedoc "The Kana variation of the company's primary address (Japan only)." @type address_kana :: %{ optional(:city) => binary, optional(:country) => binary, @@ -221,13 +221,8 @@ defmodule Stripe.Account do ) ( - @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} ) ( @@ -337,7 +332,7 @@ defmodule Stripe.Account do ) ( - @typedoc "An identifying document, either a passport or local ID card." + @typedoc "A document verifying the business." @type document :: %{optional(:back) => binary, optional(:front) => binary} ) @@ -575,11 +570,12 @@ 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 Services Agreement](https://stripe.com/docs/connect/updating-accounts#tos-acceptance)." @type tos_acceptance :: %{ optional(:date) => integer, optional(:ip) => binary, - optional(:user_agent) => binary | binary + optional(:service_agreement) => binary, + optional(:user_agent) => binary } ) @@ -589,8 +585,8 @@ defmodule Stripe.Account do ) ( - @typedoc "Settings specific to the account's Treasury FinancialAccounts." - @type treasury :: %{optional(:tos_acceptance) => tos_acceptance} + @typedoc "The treasury capability." + @type treasury :: %{optional(:requested) => boolean} ) ( diff --git a/lib/generated/checkout__session.ex b/lib/generated/checkout__session.ex index d8ad8ab5..88b51164 100644 --- a/lib/generated/checkout__session.ex +++ b/lib/generated/checkout__session.ex @@ -230,15 +230,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} ) ( diff --git a/lib/generated/payment_intent.ex b/lib/generated/payment_intent.ex index fb01c76d..a32e0ac3 100644 --- a/lib/generated/payment_intent.ex +++ b/lib/generated/payment_intent.ex @@ -92,11 +92,11 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil + @typedoc "If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method." @type acss_debit :: %{ - optional(:mandate_options) => mandate_options, - optional(:setup_future_usage) => :none | :off_session | :on_session, - optional(:verification_method) => :automatic | :instant | :microdeposits + optional(:account_number) => binary, + optional(:institution_number) => binary, + optional(:transit_number) => binary } ) @@ -136,8 +136,8 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account." - @type au_becs_debit :: %{optional(:account_number) => binary, optional(:bsb_number) => binary} + @typedoc nil + @type au_becs_debit :: %{optional(:setup_future_usage) => :none | :off_session | :on_session} ) ( @@ -149,8 +149,8 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil - @type bacs_debit :: %{optional(:setup_future_usage) => :none | :off_session | :on_session} + @typedoc "If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account." + @type bacs_debit :: %{optional(:account_number) => binary, optional(:sort_code) => binary} ) ( @@ -192,11 +192,8 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil - @type boleto :: %{ - optional(:expires_after_days) => integer, - optional(:setup_future_usage) => :none | :off_session | :on_session - } + @typedoc "If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method." + @type boleto :: %{optional(:tax_id) => binary} ) ( @@ -281,8 +278,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 + } ) ( @@ -368,56 +395,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} ) ( @@ -479,34 +458,10 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc "If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method." + @typedoc nil @type p24 :: %{ - 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 + optional(:setup_future_usage) => :none, + optional(:tos_shown_and_accepted) => boolean } ) @@ -686,11 +641,8 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil - @type sepa_debit :: %{ - optional(:mandate_options) => map(), - optional(:setup_future_usage) => :none | :off_session | :on_session - } + @typedoc "If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account." + @type sepa_debit :: %{optional(:iban) => binary} ) ( @@ -705,8 +657,11 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc "If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method." - @type sofort :: %{optional(:country) => :AT | :BE | :DE | :ES | :IT | :NL} + @typedoc nil + @type sofort :: %{ + optional(:preferred_language) => :de | :en | :es | :fr | :it | :nl | :pl, + optional(:setup_future_usage) => :none | :off_session + } ) ( @@ -715,13 +670,13 @@ defmodule Stripe.PaymentIntent do ) ( - @typedoc nil + @typedoc "If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method." @type us_bank_account :: %{ - optional(:financial_connections) => financial_connections, - optional(:networks) => networks, - optional(:preferred_settlement_speed) => :fastest | :standard, - optional(:setup_future_usage) => :none | :off_session | :on_session, - optional(:verification_method) => :automatic | :instant | :microdeposits + optional(:account_holder_type) => :company | :individual, + optional(:account_number) => binary, + optional(:account_type) => :checking | :savings, + optional(:financial_connections_account) => binary, + optional(:routing_number) => binary } ) diff --git a/lib/generated/refund.ex b/lib/generated/refund.ex index 2b18b4d9..843ccc2b 100644 --- a/lib/generated/refund.ex +++ b/lib/generated/refund.ex @@ -155,7 +155,8 @@ defmodule Stripe.Refund do ( nil - @doc "
Create a refund.
\n\n#### Details\n\n * Method: `post`\n * Path: `/v1/refunds`\n" + + @doc "When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
\n\nCreating a new refund will refund a charge that has previously been created but not yet refunded.\nFunds will be refunded to the credit or debit card that was originally charged.
\n\nYou can optionally refund only part of a charge.\nYou can do so multiple times, until the entire charge has been refunded.
\n\nOnce entirely refunded, a charge can’t be refunded again.\nThis method will raise an error when called on an already-refunded charge,\nor when trying to refund more money than is left on a charge.
\n\n#### Details\n\n * Method: `post`\n * Path: `/v1/refunds`\n" ( @spec create( params :: %{ diff --git a/lib/generated/setup_intent.ex b/lib/generated/setup_intent.ex index 105cad17..dd690aa1 100644 --- a/lib/generated/setup_intent.ex +++ b/lib/generated/setup_intent.ex @@ -62,11 +62,11 @@ defmodule Stripe.SetupIntent do ) ( - @typedoc "If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options." + @typedoc "If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method." @type acss_debit :: %{ - optional(:currency) => :cad | :usd, - optional(:mandate_options) => mandate_options, - optional(:verification_method) => :automatic | :instant | :microdeposits + optional(:account_number) => binary, + optional(:institution_number) => binary, + optional(:transit_number) => binary } ) @@ -439,11 +439,13 @@ defmodule Stripe.SetupIntent do ) ( - @typedoc "If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options." + @typedoc "If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method." @type us_bank_account :: %{ - optional(:financial_connections) => financial_connections, - optional(:networks) => networks, - optional(:verification_method) => :automatic | :instant | :microdeposits + optional(:account_holder_type) => :company | :individual, + optional(:account_number) => binary, + optional(:account_type) => :checking | :savings, + optional(:financial_connections_account) => binary, + optional(:routing_number) => binary } ) diff --git a/priv/openapi/spec3.sdk.json b/priv/openapi/spec3.sdk.json index 7e305487..d8c29a83 100644 --- a/priv/openapi/spec3.sdk.json +++ b/priv/openapi/spec3.sdk.json @@ -114148,7 +114148,7 @@ } }, "post": { - "description": "Create a refund.
", + "description": "When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
\n\nCreating a new refund will refund a charge that has previously been created but not yet refunded.\nFunds will be refunded to the credit or debit card that was originally charged.
\n\nYou can optionally refund only part of a charge.\nYou can do so multiple times, until the entire charge has been refunded.
\n\nOnce entirely refunded, a charge can’t be refunded again.\nThis method will raise an error when called on an already-refunded charge,\nor when trying to refund more money than is left on a charge.
", "operationId": "PostRefunds", "requestBody": { "content": { @@ -114167,10 +114167,10 @@ "additionalProperties": false, "properties": { "amount": { - "description": "A positive integer representing how much to refund.", "type": "integer" }, "charge": { + "description": "The identifier of the charge to refund.", "maxLength": 5000, "type": "string" }, @@ -114220,10 +114220,12 @@ "type": "string" }, "payment_intent": { + "description": "The identifier of the PaymentIntent to refund.", "maxLength": 5000, "type": "string" }, "reason": { + "description": "String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.", "enum": [ "duplicate", "fraudulent", @@ -114233,9 +114235,11 @@ "type": "string" }, "refund_application_fee": { + "description": "Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.", "type": "boolean" }, "reverse_transfer": { + "description": "Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).