Account Information

List accounts

get
https://api.snaptrade.com/api/v1/accounts

Returns all brokerage accounts across all connections known to SnapTrade for the authenticated user.

This endpoint returns Daily data regardless of the customer's plan. Daily data is cached and refreshed once a day, which makes this endpoint fast and well-suited to listing accounts across all of a user's connections in a single call. Exact refresh timing may vary by brokerage. To get real-time data on Pay as you Go / Real-time, use the list accounts for a connection endpoint. Customers on Pay as you Go / Daily can force a refresh with the manual refresh endpoint.

Execute an API Request

Query
userIdstringrequired

SnapTrade User ID. This is chosen by the API partner and can be any string that is a) unique to the user, and b) immutable for the user. It is recommended to NOT use email addresses for this property because they are usually not immutable.

userSecretstringrequired

SnapTrade User Secret. This is a randomly generated string and should be stored securely. If compromised, please rotate it via the rotate user secret endpoint.

Authorization
Request
Installation
$
npm install snaptrade-typescript-sdk
1
import { Snaptrade } from "snaptrade-typescript-sdk";
2
3
const snaptrade = new Snaptrade({
4
clientId: "PARTNER_CLIENT_ID",
5
consumerKey: "CONSUMER_KEY",
6
});
7
8
const response =
9
await snaptrade.accountInformation.listUserAccounts(
10
{
11
userId: "snaptrade-user-123",
12
userSecret:
13
"adf2aa34-8219-40f7-a6b3-60156985cc61",
14
},
15
);
16
console.log(response.data);

Response fields

array of objects

List of brokerage accounts across all connections.

object

A single account at a brokerage.

1
[
2
{
3
"id": "917c8734-8470-4a3e-a18f-57c3f2ee6631",
4
"brokerage_authorization": "87b24961-b51e-4db8-9226-f198f6518a89",
5
"name": "Robinhood Individual",
6
"number": "Q6542138443",
7
"institution_account_id": "54953432",
8
"institution_name": "Robinhood",
9
"created_date": "2024-07-23T22:50:22.761Z",
10
"funding_date": "2024-07-25T12:00:00.000Z",
11
"opening_date": "2024-07-20T09:30:00.000Z",
12
"sync_status": {
13
"transactions": {
14
"initial_sync_completed": true,
15
"last_successful_sync": "2022-01-24",
16
"first_transaction_date": "2022-01-24"
17
},
18
"holdings": {
19
"initial_sync_completed": true,
20
"last_successful_sync": "2024-06-28 18:42:46.561408+00:00"
21
}
22
},
23
"balance": {
24
"total": {
25
"amount": 15363.23,
26
"currency": "USD"
27
}
28
},
29
"status": "open",
30
"raw_type": "Margin",
31
"account_category": "INVESTMENT",
32
"meta": {
33
"type": "Margin",
34
"status": "ACTIVE",
35
"institution_name": "Robinhood"
36
},
37
"portfolio_group": "2bcd7cc3-e922-4976-bce1-9858296801c3",
38
"cash_restrictions": [],
39
"is_paper": false
40
}
41
]