Skip to content

Commit

Permalink
Update services based on v625 of Stripe OpenApi SDK
Browse files Browse the repository at this point in the history
  • Loading branch information
web-flow committed Oct 26, 2023
1 parent 840e129 commit e3de02a
Show file tree
Hide file tree
Showing 7 changed files with 78 additions and 143 deletions.
2 changes: 1 addition & 1 deletion .latest-tag-stripe-openapi-sdk
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v620
v625
33 changes: 18 additions & 15 deletions lib/generated/account.ex
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ defmodule Stripe.Account do
)

(
@typedoc "The Kana variation of the company's primary address (Japan only)."
@typedoc "The Kana variation of the the individual's primary address (Japan only)."
@type address_kana :: %{
optional(:city) => binary,
optional(:country) => binary,
Expand All @@ -91,7 +91,7 @@ defmodule Stripe.Account do
)

(
@typedoc "The Kanji variation of the company's primary address (Japan only)."
@typedoc "The Kanji variation of the the individual's primary address (Japan only)."
@type address_kanji :: %{
optional(:city) => binary,
optional(:country) => binary,
Expand Down Expand Up @@ -216,13 +216,18 @@ 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 "The card_payments capability."
@type card_payments :: %{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
}
)

(
Expand Down Expand Up @@ -571,11 +576,12 @@ defmodule Stripe.Account do
)

(
@typedoc "Details on the account's acceptance of the Stripe Treasury Services Agreement."
@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
}
)

Expand All @@ -585,8 +591,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}
)

(
Expand All @@ -595,11 +601,8 @@ defmodule Stripe.Account do
)

(
@typedoc "The individual's verification document information."
@type verification :: %{
optional(:additional_document) => additional_document,
optional(:document) => document
}
@typedoc "Information on the verification state of the company."
@type verification :: %{optional(:document) => document}
)

(
Expand Down
7 changes: 5 additions & 2 deletions lib/generated/checkout__session.ex
Original file line number Diff line number Diff line change
Expand Up @@ -950,8 +950,11 @@ defmodule Stripe.Checkout.Session do
)

(
@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}
@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
}
)

(
Expand Down
117 changes: 28 additions & 89 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 @@ -352,56 +355,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}
)

(
Expand Down Expand Up @@ -430,12 +385,17 @@ defmodule Stripe.PaymentIntent 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(:interval_description) => binary,
optional(:payment_schedule) => :combined | :interval | :sporadic,
optional(:transaction_type) => :business | :personal
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)
}
)

Expand All @@ -458,34 +418,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
}
)

Expand Down Expand Up @@ -665,8 +601,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
}
)

(
Expand All @@ -686,7 +625,7 @@ defmodule Stripe.PaymentIntent do
)

(
@typedoc "The parameters that you can use to automatically create a Transfer after the payment succeeds.\nLearn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts)."
@typedoc "The parameters that you can use to automatically create a Transfer.\nLearn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts)."
@type transfer_data :: %{optional(:amount) => integer, optional(:destination) => binary}
)

Expand Down
31 changes: 12 additions & 19 deletions lib/generated/setup_intent.ex
Original file line number Diff line number Diff line change
Expand Up @@ -278,18 +278,13 @@ defmodule Stripe.SetupIntent 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(: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)
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
}
)

Expand Down Expand Up @@ -429,8 +424,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()}
)

(
Expand All @@ -444,13 +439,11 @@ defmodule Stripe.SetupIntent do
)

(
@typedoc "If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method."
@typedoc "If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options."
@type us_bank_account :: %{
optional(:account_holder_type) => :company | :individual,
optional(:account_number) => binary,
optional(:account_type) => :checking | :savings,
optional(:financial_connections_account) => binary,
optional(:routing_number) => binary
optional(:financial_connections) => financial_connections,
optional(:networks) => networks,
optional(:verification_method) => :automatic | :instant | :microdeposits
}
)

Expand Down
22 changes: 9 additions & 13 deletions lib/generated/token.ex
Original file line number Diff line number Diff line change
Expand Up @@ -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
}
)

Expand All @@ -40,7 +39,7 @@ defmodule Stripe.Token do
)

(
@typedoc "The company's primary address."
@typedoc "The person's address."
@type address :: %{
optional(:city) => binary,
optional(:country) => binary,
Expand All @@ -52,7 +51,7 @@ defmodule Stripe.Token do
)

(
@typedoc "The Kana variation of the person's address (Japan only)."
@typedoc "The Kana variation of the the individual's primary address (Japan only)."
@type address_kana :: %{
optional(:city) => binary,
optional(:country) => binary,
Expand All @@ -65,7 +64,7 @@ defmodule Stripe.Token do
)

(
@typedoc "The Kanji variation of the company's primary address (Japan only)."
@typedoc "The Kanji variation of the the individual's primary address (Japan only)."
@type address_kanji :: %{
optional(:city) => binary,
optional(:country) => binary,
Expand Down Expand Up @@ -294,11 +293,8 @@ defmodule Stripe.Token do
)

(
@typedoc "The person's verification status."
@type verification :: %{
optional(:additional_document) => additional_document,
optional(:document) => document
}
@typedoc "Information on the verification state of the company."
@type verification :: %{optional(:document) => document}
)

(
Expand Down
Loading

0 comments on commit e3de02a

Please sign in to comment.