View Source Stripe.Treasury.FinancialAccount (stripity_stripe v3.2.0)

Stripe Treasury provides users with a container for money called a FinancialAccount that is separate from their Payments balance. FinancialAccounts serve as the source and destination of Treasury’s money movement APIs.

Summary

Types

Adds an ABA FinancialAddress to the FinancialAccount.

Enables ACH Debits via the InboundTransfers API.

Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.

Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.

Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.

Contains Features that add FinancialAddresses to the FinancialAccount.

Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.

Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).

Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.

Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.

The set of functionalities that the platform can restrict on the FinancialAccount.

t()

The treasury.financial_account type.

Enables US domestic wire transfers via the OutboundPayments API.

Functions

Creates a new FinancialAccount. For now, each connected account can only have one FinancialAccount.

Returns a list of FinancialAccounts.

Retrieves the details of a FinancialAccount.

Retrieves Features information associated with the FinancialAccount.

Updates the details of a FinancialAccount.

Updates the Features associated with a FinancialAccount.

Types

@type aba() :: %{optional(:requested) => boolean()}

Adds an ABA FinancialAddress to the FinancialAccount.

@type ach() :: %{optional(:requested) => boolean()}

Enables ACH Debits via the InboundTransfers API.

@type card_issuing() :: %{optional(:requested) => boolean()}

Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.

@type created() :: %{
  optional(:gt) => integer(),
  optional(:gte) => integer(),
  optional(:lt) => integer(),
  optional(:lte) => integer()
}
@type deposit_insurance() :: %{optional(:requested) => boolean()}

Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.

@type features() :: %{
  optional(:card_issuing) => card_issuing(),
  optional(:deposit_insurance) => deposit_insurance(),
  optional(:financial_addresses) => financial_addresses(),
  optional(:inbound_transfers) => inbound_transfers(),
  optional(:intra_stripe_flows) => intra_stripe_flows(),
  optional(:outbound_payments) => outbound_payments(),
  optional(:outbound_transfers) => outbound_transfers()
}

Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.

@type financial_addresses() :: %{optional(:aba) => aba()}

Contains Features that add FinancialAddresses to the FinancialAccount.

@type inbound_transfers() :: %{optional(:ach) => ach()}

Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.

@type intra_stripe_flows() :: %{optional(:requested) => boolean()}

Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).

@type outbound_payments() :: %{
  optional(:ach) => ach(),
  optional(:us_domestic_wire) => us_domestic_wire()
}

Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.

@type outbound_transfers() :: %{
  optional(:ach) => ach(),
  optional(:us_domestic_wire) => us_domestic_wire()
}

Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.

Link to this type

platform_restrictions()

View Source
@type platform_restrictions() :: %{
  optional(:inbound_flows) => :restricted | :unrestricted,
  optional(:outbound_flows) => :restricted | :unrestricted
}

The set of functionalities that the platform can restrict on the FinancialAccount.

@type t() :: %Stripe.Treasury.FinancialAccount{
  active_features: term(),
  balance: term(),
  country: binary(),
  created: integer(),
  features: Stripe.Treasury.FinancialAccountFeatures.t(),
  financial_addresses: term(),
  id: binary(),
  livemode: boolean(),
  metadata: term() | nil,
  object: binary(),
  pending_features: term(),
  platform_restrictions: term() | nil,
  restricted_features: term(),
  status: binary(),
  status_details: term(),
  supported_currencies: term()
}

The treasury.financial_account type.

  • active_features The array of paths to active Features in the Features hash.
  • balance
  • country Two-letter country code (ISO 3166-1 alpha-2).
  • created Time at which the object was created. Measured in seconds since the Unix epoch.
  • features
  • financial_addresses The set of credentials that resolve to a FinancialAccount.
  • id Unique identifier for the object.
  • livemode Has the value true if the object exists in live mode or the value false if the object exists in test mode.
  • metadata Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
  • object String representing the object's type. Objects of the same type share the same value.
  • pending_features The array of paths to pending Features in the Features hash.
  • platform_restrictions The set of functionalities that the platform can restrict on the FinancialAccount.
  • restricted_features The array of paths to restricted Features in the Features hash.
  • status The enum specifying what state the account is in.
  • status_details
  • supported_currencies The currencies the FinancialAccount can hold a balance in. Three-letter ISO currency code, in lowercase.
@type us_domestic_wire() :: %{optional(:requested) => boolean()}

Enables US domestic wire transfers via the OutboundPayments API.

Functions

Link to this function

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

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

Creates a new FinancialAccount. For now, each connected account can only have one FinancialAccount.

Details

  • Method: post
  • Path: /v1/treasury/financial_accounts
Link to this function

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

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

Returns a list of FinancialAccounts.

Details

  • Method: get
  • Path: /v1/treasury/financial_accounts
Link to this function

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

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

Retrieves the details of a FinancialAccount.

Details

  • Method: get
  • Path: /v1/treasury/financial_accounts/{financial_account}
Link to this function

retrieve_features(financial_account, params \\ %{}, opts \\ [])

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

Retrieves Features information associated with the FinancialAccount.

Details

  • Method: get
  • Path: /v1/treasury/financial_accounts/{financial_account}/features
Link to this function

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

View Source
@spec update(
  financial_account :: binary(),
  params :: %{
    optional(:expand) => [binary()],
    optional(:features) => features(),
    optional(:metadata) => %{optional(binary()) => binary()},
    optional(:platform_restrictions) => platform_restrictions()
  },
  opts :: Keyword.t()
) :: {:ok, t()} | {:error, Stripe.ApiErrors.t()} | {:error, term()}

Updates the details of a FinancialAccount.

Details

  • Method: post
  • Path: /v1/treasury/financial_accounts/{financial_account}
Link to this function

update_features(financial_account, params \\ %{}, opts \\ [])

View Source
@spec update_features(
  financial_account :: binary(),
  params :: %{
    optional(:card_issuing) => card_issuing(),
    optional(:deposit_insurance) => deposit_insurance(),
    optional(:expand) => [binary()],
    optional(:financial_addresses) => financial_addresses(),
    optional(:inbound_transfers) => inbound_transfers(),
    optional(:intra_stripe_flows) => intra_stripe_flows(),
    optional(:outbound_payments) => outbound_payments(),
    optional(:outbound_transfers) => outbound_transfers()
  },
  opts :: Keyword.t()
) ::
  {:ok, Stripe.Treasury.FinancialAccountFeatures.t()}
  | {:error, Stripe.ApiErrors.t()}
  | {:error, term()}

Updates the Features associated with a FinancialAccount.

Details

  • Method: post
  • Path: /v1/treasury/financial_accounts/{financial_account}/features