Synctera.ExternalAccounts (Synctera v1.0.0)

Copy Markdown View Source

Synctera 'External Accounts' endpoints.

Code generated by scripts/generate.py from the Synctera OpenAPI spec. Do not edit by hand — re-run mix generate (or python3 scripts/generate.py) to regenerate.

Summary

Functions

Add an external account — Add an external account for a customer. The account will be created in an unverified state.

Like add_external_accounts/2 but returns the value directly and raises on error.

Add external accounts through a vendor, such as Plaid. — Add external accounts for a customer through an existing access token. The token must be valid, and the information on the accounts returned by the vendor must correspond to the customer. A success response for this route may include failures if an account could not be added, so it's important that the caller checks the response body.

Like add_vendor_external_accounts/2 but returns the value directly and raises on error.

Create a permanent access token for an external account

Like create_access_token/2 but returns the value directly and raises on error.

Create a link token to verify an external account

Like create_verification_link_token/2 but returns the value directly and raises on error.

Delete an external account — Deletes an external account, given an external account ID. If no accounts left, the access token to the financial institution will be removed

Like delete_external_account/3 but returns the value directly and raises on error.

Get an external account — Returns an external account, given an external account ID.

Like get_external_account/3 but returns the value directly and raises on error.

Get an external account balance — Returns an external account balance, given an external account ID.

List transactions of a given external account — Returns a list of transactions on from the external account, given an external account ID. Maximum 500 transctions will be returned.

List external accounts — Returns a list of all external accounts assigned to customers.

Like list_external_accounts/2 but returns the value directly and raises on error.

Sync external accounts through a vendor, such as Plaid. — Sync external accounts for a customer through an existing access token. The token must be valid, and the information on the accounts returned by the vendor must correspond to the customer. A success response for this route may include failures if an account could not be added and deletions if the account is removed by the end user, so it's important that the caller checks the response body.

Like sync_vendor_external_accounts/2 but returns the value directly and raises on error.

Patch an external account — Edits an unverified external account, given an external account ID.

Like update_external_account/3 but returns the value directly and raises on error.

Functions

add_external_accounts(client, opts \\ [])

@spec add_external_accounts(
  Synctera.Client.t(),
  keyword()
) :: {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Add an external account — Add an external account for a customer. The account will be created in an unverified state.

Options

  • :body — request body (map), required.
  • :idempotency_key — see Synctera.Idempotency.
  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

add_external_accounts!(client, opts)

@spec add_external_accounts!(
  Synctera.Client.t(),
  keyword()
) :: Synctera.JSON.json()

Like add_external_accounts/2 but returns the value directly and raises on error.

add_vendor_external_accounts(client, opts \\ [])

@spec add_vendor_external_accounts(
  Synctera.Client.t(),
  keyword()
) :: {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Add external accounts through a vendor, such as Plaid. — Add external accounts for a customer through an existing access token. The token must be valid, and the information on the accounts returned by the vendor must correspond to the customer. A success response for this route may include failures if an account could not be added, so it's important that the caller checks the response body.

Options

  • :body — request body (map), required.
  • :idempotency_key — see Synctera.Idempotency.
  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

add_vendor_external_accounts!(client, opts)

@spec add_vendor_external_accounts!(
  Synctera.Client.t(),
  keyword()
) :: Synctera.JSON.json()

Like add_vendor_external_accounts/2 but returns the value directly and raises on error.

create_access_token(client, opts \\ [])

@spec create_access_token(
  Synctera.Client.t(),
  keyword()
) :: {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Create a permanent access token for an external account

Options

  • :body — request body (map), required.
  • :idempotency_key — see Synctera.Idempotency.
  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

create_access_token!(client, opts)

@spec create_access_token!(
  Synctera.Client.t(),
  keyword()
) :: Synctera.JSON.json()

Like create_access_token/2 but returns the value directly and raises on error.

delete_external_account(client, external_account_id, opts \\ [])

@spec delete_external_account(Synctera.Client.t(), String.t(), keyword()) ::
  {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Delete an external account — Deletes an external account, given an external account ID. If no accounts left, the access token to the financial institution will be removed

Options

  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

delete_external_account!(client, external_account_id, opts)

@spec delete_external_account!(Synctera.Client.t(), String.t(), keyword()) ::
  Synctera.JSON.json()

Like delete_external_account/3 but returns the value directly and raises on error.

get_external_account(client, external_account_id, opts \\ [])

@spec get_external_account(Synctera.Client.t(), String.t(), keyword()) ::
  {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Get an external account — Returns an external account, given an external account ID.

Options

  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

get_external_account!(client, external_account_id, opts)

@spec get_external_account!(Synctera.Client.t(), String.t(), keyword()) ::
  Synctera.JSON.json()

Like get_external_account/3 but returns the value directly and raises on error.

get_external_account_balance(client, external_account_id, opts \\ [])

@spec get_external_account_balance(Synctera.Client.t(), String.t(), keyword()) ::
  {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Get an external account balance — Returns an external account balance, given an external account ID.

Options

Query options: :max_age

  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

get_external_account_balance!(client, external_account_id, opts)

@spec get_external_account_balance!(Synctera.Client.t(), String.t(), keyword()) ::
  Synctera.JSON.json()

Like get_external_account_balance/3 but returns the value directly and raises on error.

get_external_account_transactions(client, external_account_id, opts \\ [])

@spec get_external_account_transactions(Synctera.Client.t(), String.t(), keyword()) ::
  {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

List transactions of a given external account — Returns a list of transactions on from the external account, given an external account ID. Maximum 500 transctions will be returned.

Options

Query options: :start_date, :end_date

  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

get_external_account_transactions!(client, external_account_id, opts)

@spec get_external_account_transactions!(Synctera.Client.t(), String.t(), keyword()) ::
  Synctera.JSON.json()

Like get_external_account_transactions/3 but returns the value directly and raises on error.

list_external_accounts(client, opts \\ [])

@spec list_external_accounts(
  Synctera.Client.t(),
  keyword()
) :: {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

List external accounts — Returns a list of all external accounts assigned to customers.

Options

Query options: :customer_id, :business_id, :limit, :page_token

  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

list_external_accounts!(client, opts)

@spec list_external_accounts!(
  Synctera.Client.t(),
  keyword()
) :: Synctera.JSON.json()

Like list_external_accounts/2 but returns the value directly and raises on error.

sync_vendor_external_accounts(client, opts \\ [])

@spec sync_vendor_external_accounts(
  Synctera.Client.t(),
  keyword()
) :: {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Sync external accounts through a vendor, such as Plaid. — Sync external accounts for a customer through an existing access token. The token must be valid, and the information on the accounts returned by the vendor must correspond to the customer. A success response for this route may include failures if an account could not be added and deletions if the account is removed by the end user, so it's important that the caller checks the response body.

Options

  • :body — request body (map), required.
  • :idempotency_key — see Synctera.Idempotency.
  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

sync_vendor_external_accounts!(client, opts)

@spec sync_vendor_external_accounts!(
  Synctera.Client.t(),
  keyword()
) :: Synctera.JSON.json()

Like sync_vendor_external_accounts/2 but returns the value directly and raises on error.

update_external_account(client, external_account_id, opts \\ [])

@spec update_external_account(Synctera.Client.t(), String.t(), keyword()) ::
  {:ok, Synctera.JSON.json()} | {:error, Synctera.Error.t()}

Patch an external account — Edits an unverified external account, given an external account ID.

Options

  • :body — request body (map), required.
  • :idempotency_key — see Synctera.Idempotency.
  • :device_info — a %Synctera.DeviceInfo{} overriding the client default.

update_external_account!(client, external_account_id, opts)

@spec update_external_account!(Synctera.Client.t(), String.t(), keyword()) ::
  Synctera.JSON.json()

Like update_external_account/3 but returns the value directly and raises on error.