Wise.Services.Balances (Wise v1.0.0)

Copy Markdown View Source

Wise Balance API — multi-currency balance management.

Summary

Functions

close(config, pid, bid)

@spec close(Wise.Config.t(), Wise.Types.profile_id(), Wise.Types.balance_id()) ::
  {:ok, :ok} | {:error, Wise.Error.t()}

create(config, pid, attrs)

@spec create(Wise.Config.t(), Wise.Types.profile_id(), map()) ::
  {:ok, map()} | {:error, Wise.Error.t()}

get(config, pid, bid)

@spec get(Wise.Config.t(), Wise.Types.profile_id(), Wise.Types.balance_id()) ::
  {:ok, map()} | {:error, Wise.Error.t()}

get_deposit_limits(config, pid)

@spec get_deposit_limits(Wise.Config.t(), Wise.Types.profile_id()) ::
  {:ok, list()} | {:error, Wise.Error.t()}

get_total_funds(config, pid, currency)

@spec get_total_funds(Wise.Config.t(), Wise.Types.profile_id(), String.t()) ::
  {:ok, map()} | {:error, Wise.Error.t()}

list(config, pid, types \\ [])

@spec list(Wise.Config.t(), Wise.Types.profile_id(), keyword()) ::
  {:ok, list()} | {:error, Wise.Error.t()}

move_money(config, pid, attrs)

@spec move_money(Wise.Config.t(), Wise.Types.profile_id(), map()) ::
  {:ok, map()} | {:error, Wise.Error.t()}

set_excess_money_account(config, pid, rid)

@spec set_excess_money_account(
  Wise.Config.t(),
  Wise.Types.profile_id(),
  Wise.Types.recipient_id()
) :: {:ok, :ok} | {:error, Wise.Error.t()}