Skip to content

Commit

Permalink
Update services based on v638 of Stripe OpenApi SDK
Browse files Browse the repository at this point in the history
  • Loading branch information
web-flow committed Nov 2, 2023
1 parent 66d8611 commit b670d7b
Show file tree
Hide file tree
Showing 10 changed files with 401 additions and 67 deletions.
2 changes: 1 addition & 1 deletion .latest-tag-stripe-openapi-sdk
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v634
v638
12 changes: 9 additions & 3 deletions lib/generated/account.ex
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down Expand Up @@ -207,6 +207,7 @@ defmodule Stripe.Account do
optional(:giropay_payments) => giropay_payments,
optional(:legacy_payments) => legacy_payments,
optional(:sepa_debit_payments) => sepa_debit_payments,
optional(:revolut_pay_payments) => revolut_pay_payments,
optional(:transfers) => transfers,
optional(:eps_payments) => eps_payments,
optional(:grabpay_payments) => grabpay_payments,
Expand All @@ -216,8 +217,8 @@ defmodule Stripe.Account do
)

(
@typedoc "The card_issuing capability."
@type card_issuing :: %{optional(:requested) => boolean}
@typedoc "Settings specific to the account's use of the Card Issuing product."
@type card_issuing :: %{optional(:tos_acceptance) => tos_acceptance}
)

(
Expand Down Expand Up @@ -515,6 +516,11 @@ defmodule Stripe.Account do
}
)

(
@typedoc "The revolut_pay_payments capability."
@type revolut_pay_payments :: %{optional(:requested) => boolean}
)

(
@typedoc "Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](https://stripe.com/docs/connect/bank-transfers#payout-information) documentation."
@type schedule :: %{
Expand Down
24 changes: 10 additions & 14 deletions lib/generated/checkout__session.ex
Original file line number Diff line number Diff line change
Expand Up @@ -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}
)

(
Expand Down Expand Up @@ -509,6 +501,7 @@ defmodule Stripe.Checkout.Session do
optional(:paynow) => paynow,
optional(:paypal) => paypal,
optional(:pix) => pix,
optional(:revolut_pay) => revolut_pay,
optional(:sepa_debit) => sepa_debit,
optional(:sofort) => sofort,
optional(:us_bank_account) => us_bank_account,
Expand Down Expand Up @@ -610,6 +603,11 @@ defmodule Stripe.Checkout.Session do
}
)

(
@typedoc "contains details about the RevolutPay payment method options."
@type revolut_pay :: %{optional(:setup_future_usage) => :none | :off_session}
)

(
@typedoc "contains details about the Sepa Debit payment method options."
@type sepa_debit :: %{optional(:setup_future_usage) => :none | :off_session | :on_session}
Expand Down Expand Up @@ -950,11 +948,8 @@ defmodule Stripe.Checkout.Session do
)

(
@typedoc "If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges."
@type transfer_data :: %{
optional(:amount_percent) => number,
optional(:destination) => binary
}
@typedoc "The parameters used to automatically create a Transfer when the payment succeeds.\nFor more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts)."
@type transfer_data :: %{optional(:amount) => integer, optional(:destination) => binary}
)

(
Expand Down Expand Up @@ -1101,6 +1096,7 @@ defmodule Stripe.Checkout.Session do
| :paypal
| :pix
| :promptpay
| :revolut_pay
| :sepa_debit
| :sofort
| :us_bank_account
Expand Down
1 change: 1 addition & 0 deletions lib/generated/customer.ex
Original file line number Diff line number Diff line change
Expand Up @@ -521,6 +521,7 @@ defmodule Stripe.Customer do
| :paypal
| :pix
| :promptpay
| :revolut_pay
| :sepa_debit
| :sofort
| :us_bank_account
Expand Down
112 changes: 86 additions & 26 deletions lib/generated/payment_intent.ex
Original file line number Diff line number Diff line change
Expand Up @@ -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}
)

(
Expand Down Expand Up @@ -192,8 +192,11 @@ defmodule Stripe.PaymentIntent do
)

(
@typedoc "If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method."
@type boleto :: %{optional(:tax_id) => binary}
@typedoc nil
@type boleto :: %{
optional(:expires_after_days) => integer,
optional(:setup_future_usage) => :none | :off_session | :on_session
}
)

(
Expand Down Expand Up @@ -282,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
}
)

(
Expand Down Expand Up @@ -374,17 +407,12 @@ defmodule Stripe.PaymentIntent do
)

(
@typedoc "Configuration options for setting up an eMandate for cards issued in India."
@typedoc "Additional fields for Mandate creation"
@type mandate_options :: %{
optional(:amount) => integer,
optional(:amount_type) => :fixed | :maximum,
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)
optional(:custom_mandate_url) => binary | binary,
optional(:interval_description) => binary,
optional(:payment_schedule) => :combined | :interval | :sporadic,
optional(:transaction_type) => :business | :personal
}
)

Expand All @@ -407,10 +435,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
}
)

Expand All @@ -425,6 +477,7 @@ defmodule Stripe.PaymentIntent do
optional(:alipay) => map(),
optional(:giropay) => map(),
optional(:ideal) => ideal,
optional(:revolut_pay) => map(),
optional(:radar_options) => radar_options,
optional(:metadata) => %{optional(binary) => binary},
optional(:link) => map(),
Expand Down Expand Up @@ -469,6 +522,7 @@ defmodule Stripe.PaymentIntent do
| :paypal
| :pix
| :promptpay
| :revolut_pay
| :sepa_debit
| :sofort
| :us_bank_account
Expand Down Expand Up @@ -496,6 +550,7 @@ defmodule Stripe.PaymentIntent do
optional(:alipay) => alipay | binary,
optional(:giropay) => giropay | binary,
optional(:ideal) => ideal | binary,
optional(:revolut_pay) => revolut_pay | binary,
optional(:card) => card | binary,
optional(:link) => link | binary,
optional(:promptpay) => promptpay | binary,
Expand Down Expand Up @@ -590,8 +645,16 @@ 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 revolut_pay :: %{optional(:setup_future_usage) => :none | :off_session}
)

(
@typedoc nil
@type sepa_debit :: %{
optional(:mandate_options) => map(),
optional(:setup_future_usage) => :none | :off_session | :on_session
}
)

(
Expand All @@ -606,11 +669,8 @@ defmodule Stripe.PaymentIntent do
)

(
@typedoc nil
@type sofort :: %{
optional(:preferred_language) => :de | :en | :es | :fr | :it | :nl | :pl,
optional(:setup_future_usage) => :none | :off_session
}
@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}
)

(
Expand Down
1 change: 1 addition & 0 deletions lib/generated/payment_link.ex
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ defmodule Stripe.PaymentLink do
@typedoc "A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode."
@type payment_intent_data :: %{
optional(:capture_method) => :automatic | :automatic_async | :manual,
optional(:description) => binary,
optional(:metadata) => %{optional(binary) => binary},
optional(:setup_future_usage) => :off_session | :on_session,
optional(:statement_descriptor) => binary,
Expand Down
7 changes: 6 additions & 1 deletion lib/generated/payment_method.ex
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ defmodule Stripe.PaymentMethod do
:metadata,
:radar_options,
:card,
:revolut_pay,
:ideal,
:giropay,
:alipay,
Expand All @@ -48,7 +49,7 @@ defmodule Stripe.PaymentMethod do
:pix
]

@typedoc "The `payment_method` type.\n\n * `acss_debit` \n * `affirm` \n * `afterpay_clearpay` \n * `alipay` \n * `au_becs_debit` \n * `bacs_debit` \n * `bancontact` \n * `billing_details` \n * `blik` \n * `boleto` \n * `card` \n * `card_present` \n * `cashapp` \n * `created` Time at which the object was created. Measured in seconds since the Unix epoch.\n * `customer` The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.\n * `customer_balance` \n * `eps` \n * `fpx` \n * `giropay` \n * `grabpay` \n * `id` Unique identifier for the object.\n * `ideal` \n * `interac_present` \n * `klarna` \n * `konbini` \n * `link` \n * `livemode` Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.\n * `metadata` Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.\n * `object` String representing the object's type. Objects of the same type share the same value.\n * `oxxo` \n * `p24` \n * `paynow` \n * `paypal` \n * `pix` \n * `promptpay` \n * `radar_options` \n * `sepa_debit` \n * `sofort` \n * `type` The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.\n * `us_bank_account` \n * `wechat_pay` \n * `zip` \n"
@typedoc "The `payment_method` type.\n\n * `acss_debit` \n * `affirm` \n * `afterpay_clearpay` \n * `alipay` \n * `au_becs_debit` \n * `bacs_debit` \n * `bancontact` \n * `billing_details` \n * `blik` \n * `boleto` \n * `card` \n * `card_present` \n * `cashapp` \n * `created` Time at which the object was created. Measured in seconds since the Unix epoch.\n * `customer` The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.\n * `customer_balance` \n * `eps` \n * `fpx` \n * `giropay` \n * `grabpay` \n * `id` Unique identifier for the object.\n * `ideal` \n * `interac_present` \n * `klarna` \n * `konbini` \n * `link` \n * `livemode` Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.\n * `metadata` Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.\n * `object` String representing the object's type. Objects of the same type share the same value.\n * `oxxo` \n * `p24` \n * `paynow` \n * `paypal` \n * `pix` \n * `promptpay` \n * `radar_options` \n * `revolut_pay` \n * `sepa_debit` \n * `sofort` \n * `type` The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.\n * `us_bank_account` \n * `wechat_pay` \n * `zip` \n"
@type t :: %__MODULE__{
acss_debit: term,
affirm: term,
Expand Down Expand Up @@ -86,6 +87,7 @@ defmodule Stripe.PaymentMethod do
pix: term,
promptpay: term,
radar_options: term,
revolut_pay: term,
sepa_debit: term,
sofort: term,
type: binary,
Expand Down Expand Up @@ -326,6 +328,7 @@ defmodule Stripe.PaymentMethod do
optional(:alipay) => map(),
optional(:giropay) => map(),
optional(:ideal) => ideal,
optional(:revolut_pay) => map(),
optional(:expand) => list(binary),
optional(:card) => card | card,
optional(:radar_options) => radar_options,
Expand Down Expand Up @@ -374,6 +377,7 @@ defmodule Stripe.PaymentMethod do
| :paypal
| :pix
| :promptpay
| :revolut_pay
| :sepa_debit
| :sofort
| :us_bank_account
Expand Down Expand Up @@ -533,6 +537,7 @@ defmodule Stripe.PaymentMethod do
| :paypal
| :pix
| :promptpay
| :revolut_pay
| :sepa_debit
| :sofort
| :us_bank_account
Expand Down
Loading

0 comments on commit b670d7b

Please sign in to comment.