Skip to main content

Assets

The assets API, given an end user's accountId, will give you a holistic view of the assets the account holds (crypto and cash)

Note, only accountId's that are created under your organization will be accessible.

API details#

URL : /v1/assets/<accountId>

Method : GET

Auth required : Yes (API key and secret are required)

Success Response#

Code : 200 OK

Sample response return:

{  "accountId": "12345",  "email": "testuser@gmail.com",  "account_cash_funds": 2532.12,  "account_portfolio_value": 6534.12,  "account_crypto_holdings":     [       {         "ticker":"ETH",         "value": 0.152,         "cost_basis": 500.10,         "current_market_value": 700.98:        },        {         "ticker":"BTC",         "value": 0.025,         "cost_basis": 870.10,         "current_market_value": 1559.75:        },        {         "ticker":"DOGE",         "value": 6990,         "cost_basis": 1208.50,         "current_market_value": 1741.27:        }     ]}

- accountId - String. The accountId of the returned account

- account_cash_funds - Double. The amount of cash funds of the account

- account_portfolio_value - Double. The value of the total portfolio, including crypto and cash positions, returned in USD.

- account_crypto_holdings - Array. An array of all the crypto holdings an account has along with the amount of each crypto. Each element is a JSON element with crypto ticker, amount of crypto, cost basis in USD, and current USD market value

Error Response#

Code : 400 BAD REQUEST

Condition : If accountId is invalid or if organization does not have access to this account.