View Source Stripe.ExternalAccount (stripity_stripe v3.3.1)

Summary

Types

One or more documents that support the Bank account ownership verification requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.

Documents that may be submitted to satisfy various informational requests.

t()

The external_account type.

Functions

Create an external account for a given account.

Delete a specified external account for a given account.

List external accounts for an account.

Retrieve a specified external account for a given account.

Updates the metadata, account holder name, account holder type of a bank account belonging toa connected account and optionally sets it as the default for its currency. Other bank account details are not editable by design.

Types

Link to this type

bank_account_ownership_verification()

View Source
@type bank_account_ownership_verification() :: %{optional(:files) => [binary()]}

One or more documents that support the Bank account ownership verification requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.

@type documents() :: %{
  optional(:bank_account_ownership_verification) =>
    bank_account_ownership_verification()
}

Documents that may be submitted to satisfy various informational requests.

@type t() :: %Stripe.ExternalAccount{}

The external_account type.

Functions

Link to this function

create(account, params \\ %{}, opts \\ [])

View Source
@spec create(
  account :: binary(),
  params :: %{
    optional(:default_for_currency) => boolean(),
    optional(:expand) => [binary()],
    optional(:external_account) => binary(),
    optional(:metadata) => %{optional(binary()) => binary()}
  },
  opts :: Keyword.t()
) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}

Create an external account for a given account.

Details

  • Method: post
  • Path: /v1/accounts/{account}/external_accounts
Link to this function

delete(account, id, opts \\ [])

View Source
@spec delete(account :: binary(), id :: binary(), opts :: Keyword.t()) ::
  {:ok, Stripe.DeletedExternalAccount.t()}
  | {:error, Stripe.ApiErrors.t()}
  | {:error, term()}

Delete a specified external account for a given account.

Details

  • Method: delete
  • Path: /v1/accounts/{account}/external_accounts/{id}
Link to this function

list(account, params \\ %{}, opts \\ [])

View Source
@spec list(
  account :: binary(),
  params :: %{
    optional(:ending_before) => binary(),
    optional(:expand) => [binary()],
    optional(:limit) => integer(),
    optional(:object) => :bank_account | :card,
    optional(:starting_after) => binary()
  },
  opts :: Keyword.t()
) ::
  {:ok, Stripe.List.t(t())} | {:error, Stripe.ApiErrors.t()} | {:error, term()}

List external accounts for an account.

Details

  • Method: get
  • Path: /v1/accounts/{account}/external_accounts
Link to this function

retrieve(account, id, params \\ %{}, opts \\ [])

View Source
@spec retrieve(
  account :: binary(),
  id :: binary(),
  params :: %{optional(:expand) => [binary()]},
  opts :: Keyword.t()
) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}

Retrieve a specified external account for a given account.

Details

  • Method: get
  • Path: /v1/accounts/{account}/external_accounts/{id}
Link to this function

update(account, id, params \\ %{}, opts \\ [])

View Source
@spec update(
  account :: binary(),
  id :: binary(),
  params :: %{
    optional(:account_holder_name) => binary(),
    optional(:account_holder_type) => :company | :individual,
    optional(:account_type) => :checking | :futsu | :savings | :toza,
    optional(:address_city) => binary(),
    optional(:address_country) => binary(),
    optional(:address_line1) => binary(),
    optional(:address_line2) => binary(),
    optional(:address_state) => binary(),
    optional(:address_zip) => binary(),
    optional(:default_for_currency) => boolean(),
    optional(:documents) => documents(),
    optional(:exp_month) => binary(),
    optional(:exp_year) => binary(),
    optional(:expand) => [binary()],
    optional(:metadata) => %{optional(binary()) => binary()} | binary(),
    optional(:name) => binary()
  },
  opts :: Keyword.t()
) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}

Updates the metadata, account holder name, account holder type of a bank account belonging toa connected account and optionally sets it as the default for its currency. Other bank account details are not editable by design.

You can only update bank accounts when account.controller.requirement_collection is application, which includes Custom accounts.

You can re-enable a disabled bank account by performing an update call without providing anyarguments or changes.

#### Details * Method: `post` * Path: `/v1/accounts/{account}/external_accounts/{id}`