stripity_stripe v2.2.1 Stripe.Account View Source
Work with Stripe Connect account objects.
You can:
- Retrieve your own account
- Retrieve an account with a specified
id
This module does not yet support managed accounts.
Stripe API reference: https://stripe.com/docs/api#account
Link to this section Summary
Functions
Create an account
Create a login link
Delete an account
List all connected accounts
Reject an account
Retrieve your own account without options
Retrieve your own account with options
Retrieve an account with a specified id
Update an account
Link to this section Types
Link to this type
create_params()
View Source
create_params() :: %{ :type => String.t(), optional(:account_token) => String.t(), optional(:business_logo) => String.t(), optional(:business_name) => String.t(), optional(:business_primary_color) => String.t(), optional(:business_url) => String.t(), optional(:country) => String.t(), optional(:debit_negative_balances) => boolean(), optional(:decline_charge_on) => decline_charge_on(), optional(:default_currency) => String.t(), optional(:email) => String.t(), optional(:external_account) => String.t(), optional(:legal_entity) => legal_entity(), optional(:metadata) => Stripe.Types.metadata(), optional(:payout_schedule) => Stripe.Types.transfer_schedule(), optional(:payout_statement_descriptor) => String.t(), optional(:product_description) => String.t(), optional(:statement_descriptor) => String.t(), optional(:support_email) => String.t(), optional(:support_phone) => String.t(), optional(:support_url) => String.t(), optional(:tos_acceptance) => tos_acceptance() }
Link to this type
legal_entity()
View Source
legal_entity() :: %{ additional_owners: [legal_entity_additional_owner()] | nil, address: legal_entity_address(), address_kana: legal_entity_japan_address() | nil, address_kanji: legal_entity_japan_address() | nil, business_name: String.t() | nil, business_name_kana: String.t() | nil, business_name_kanji: String.t() | nil, business_tax_id_provided: boolean(), business_vat_id_provided: boolean(), deleted: boolean() | nil, dob: legal_entity_dob(), first_name: String.t() | nil, first_name_kana: String.t() | nil, first_name_kanji: String.t() | nil, gender: String.t() | nil, last_name: String.t() | nil, last_name_kana: String.t() | nil, last_name_kanji: String.t() | nil, maiden_name: String.t() | nil, personal_address: legal_entity_address(), personal_address_kana: legal_entity_japan_address() | nil, personal_address_kanji: legal_entity_japan_address() | nil, personal_id_number_provided: boolean(), phone_number: String.t() | nil, ssn_last_4_provided: String.t(), tax_id_registar: String.t(), type: String.t() | nil, verification: legal_entity_verification() }
Link to this type
legal_entity_additional_owner()
View Source
legal_entity_additional_owner() :: %{ address: legal_entity_address(), dob: legal_entity_dob(), first_name: String.t() | nil, last_name: String.t() | nil, maiden_name: String.t() | nil, verification: legal_entity_verification() }
Link to this type
legal_entity_dob()
View Source
legal_entity_dob() :: %{ day: 1..31 | nil, month: 1..12 | nil, year: pos_integer() | nil }
Link to this type
legal_entity_verification()
View Source
legal_entity_verification() :: %{ details: String.t() | nil, details_code: String.t() | nil, document: Stripe.id() | Stripe.FileUpload.t() | nil, status: String.t() }
Link to this type
t()
View Source
t() :: %Stripe.Account{ business_logo: String.t() | nil, business_name: String.t() | nil, business_url: String.t() | nil, charges_enabled: boolean(), country: String.t(), created: Stripe.timestamp() | nil, debit_negative_balances: boolean(), decline_charge_on: decline_charge_on(), default_currency: String.t(), deleted: term(), details_submitted: boolean(), display_name: String.t() | nil, email: String.t() | nil, external_accounts: Stripe.List.t(Stripe.BankAccount.t() | Stripe.Card.t()), id: Stripe.id(), legal_entity: legal_entity(), metadata: Stripe.Types.metadata(), object: String.t(), payout_schedule: Stripe.Types.transfer_schedule(), payout_statement_descriptor: String.t() | nil, payouts_enabled: boolean(), product_description: String.t() | nil, statement_descriptor: String.t() | nil, support_email: String.t() | nil, support_phone: String.t() | nil, timezone: String.t() | nil, tos_acceptance: tos_acceptance(), transfers_enabled: term(), type: String.t(), verification: verification() }
Link to this type
tos_acceptance()
View Source
tos_acceptance() :: %{ date: Stripe.timestamp() | nil, ip: String.t() | nil, user_agent: String.t() | nil }
Link to this type
update_params()
View Source
update_params() :: %{ optional(:account_token) => String.t(), optional(:business_logo) => String.t(), optional(:business_name) => String.t(), optional(:business_primary_color) => String.t(), optional(:business_url) => String.t(), optional(:country) => String.t(), optional(:debit_negative_balances) => boolean(), optional(:decline_charge_on) => decline_charge_on(), optional(:default_currency) => String.t(), optional(:email) => String.t(), optional(:external_account) => String.t(), optional(:legal_entity) => legal_entity(), optional(:metadata) => Stripe.Types.metadata(), optional(:payout_schedule) => Stripe.Types.transfer_schedule(), optional(:payout_statement_descriptor) => String.t(), optional(:product_description) => String.t(), optional(:statement_descriptor) => String.t(), optional(:support_email) => String.t(), optional(:support_phone) => String.t(), optional(:support_url) => String.t(), optional(:tos_acceptance) => tos_acceptance() }
Link to this type
verification()
View Source
verification() :: %{ disabled_reason: String.t() | nil, due_by: Stripe.timestamp() | nil, fields_needed: [String.t()] }
Link to this section Functions
Link to this function
create(params, opts \\ [])
View Source
create(params, Stripe.options()) :: {:ok, t()} | {:error, Stripe.Error.t()} when params: %{ optional(:country) => String.t(), optional(:email) => String.t(), optional(:type) => String.t() }
Create an account.
Link to this function
create_login_link(id, params, opts \\ [])
View Source
create_login_link(Stripe.id() | t(), params, Stripe.options()) :: {:ok, t()} | {:error, Stripe.Error.t()} when params: %{optional(:redirect_url) => String.t()}
Create a login link.
Link to this function
delete(id, opts \\ [])
View Source
delete(Stripe.id() | t(), Stripe.options()) :: {:ok, t()} | {:error, Stripe.Error.t()}
Delete an account.
Link to this function
list(params \\ %{}, opts \\ [])
View Source
list(params, Stripe.options()) :: {:ok, Stripe.List.t(t())} | {:error, Stripe.Error.t()} when params: %{ optional(:ending_before) => t() | Stripe.id(), optional(:limit) => 1..100, optional(:starting_after) => t() | Stripe.id() }
List all connected accounts.
Link to this function
reject(id, reason, opts \\ [])
View Source
reject(Stripe.id() | t(), String.t(), Stripe.options()) :: {:ok, t()} | {:error, Stripe.Error.t()}
Reject an account.
Takes the id
and reason
.
Retrieve your own account without options.
Link to this function
retrieve(opts)
View Source
retrieve(list()) :: {:ok, t()} | {:error, Stripe.Error.t()}
Retrieve your own account with options.
Link to this function
retrieve(id, opts \\ [])
View Source
retrieve(binary(), list()) :: {:ok, t()} | {:error, Stripe.Error.t()}
Retrieve an account with a specified id
.
Link to this function
update(id, params, opts \\ [])
View Source
update(Stripe.id() | t(), params, Stripe.options()) :: {:ok, t()} | {:error, Stripe.Error.t()} when params: %{ optional(:business_logo) => String.t(), optional(:business_name) => String.t(), optional(:business_primary_color) => String.t(), optional(:business_url) => String.t(), optional(:double_negative_balances) => boolean(), optional(:decline_charge_on) => decline_charge_on(), optional(:default_currency) => String.t(), optional(:email) => String.t(), optional(:external_accounts) => String.t(), optional(:legal_entity) => legal_entity(), optional(:metadata) => String.Types.metadata(), optional(:payout_schedule) => String.Types.transfer_schedule(), optional(:payout_statement_descriptor) => String.t(), optional(:product_description) => String.t(), optional(:statement_descriptor) => String.t(), optional(:support_phone) => String.t(), optional(:support_email) => String.t(), optional(:support_url) => String.t(), optional(:tos_acceptance) => tos_acceptance() }
Update an account.
Takes the id
and a map of changes.