View Source Stripe.Treasury.FinancialAccount (Striped v0.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.

Link to this section Summary

Types

Contains Features that add FinancialAddresses to the FinancialAccount.

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

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

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

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

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

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

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

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

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

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

t()

The treasury.financial_account type.

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

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.

Link to this section Types

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

Contains Features that add FinancialAddresses to the FinancialAccount.

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

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

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

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

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

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

@type features() :: %{
  card_issuing: card_issuing(),
  deposit_insurance: deposit_insurance(),
  financial_addresses: financial_addresses(),
  inbound_transfers: inbound_transfers(),
  intra_stripe_flows: intra_stripe_flows(),
  outbound_payments: outbound_payments(),
  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() :: %{aba: aba()}

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

@type inbound_transfers() :: %{ach: ach()}

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

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

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

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

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

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

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

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}

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

Link to this section Functions

Link to this function

create(client, params \\ %{})

View Source
@spec create(
  client :: term(),
  params :: %{
    optional(:expand) => [:string],
    optional(:features) => features(),
    :metadata => :object,
    optional(:platform_restrictions) => platform_restrictions(),
    supported_currencies: [:string]
  }
) :: {: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(client, params \\ %{})

View Source
@spec list(
  client :: term(),
  params :: %{
    optional(:created) => :object | :integer,
    optional(:ending_before) => :string,
    optional(:expand) => [:string],
    optional(:limit) => :integer,
    optional(:starting_after) => :string
  }
) ::
  {: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(client, financial_account, params \\ %{})

View Source
@spec retrieve(
  client :: term(),
  financial_account :: binary(),
  params :: %{optional(:expand) => [:string]}
) :: {: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(client, financial_account, params \\ %{})

View Source
@spec retrieve_features(
  client :: term(),
  financial_account :: binary(),
  params :: %{optional(:expand) => [:string]}
) ::
  {: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(client, financial_account, params \\ %{})

View Source
@spec update(
  client :: term(),
  financial_account :: binary(),
  params :: %{
    optional(:expand) => [:string],
    optional(:features) => features(),
    :metadata => :object,
    optional(:platform_restrictions) => platform_restrictions()
  }
) :: {: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(client, financial_account, params \\ %{})

View Source
@spec update_features(
  client :: term(),
  financial_account :: binary(),
  params :: %{
    optional(:card_issuing) => card_issuing(),
    optional(:deposit_insurance) => deposit_insurance(),
    optional(:expand) => [:string],
    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()
  }
) ::
  {: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