List accounts
curl --request GET \
--url https://api.example.com/api/v1/user/accountsconst options = {method: 'GET'};
fetch('https://api.example.com/api/v1/user/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.example.com/api/v1/user/accounts"
response = requests.get(url)
print(response.text)Account Management
List accounts
Return all Qash accounts for a user.
GET
/
api
/
v1
/
user
/
accounts
List accounts
curl --request GET \
--url https://api.example.com/api/v1/user/accountsconst options = {method: 'GET'};
fetch('https://api.example.com/api/v1/user/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.example.com/api/v1/user/accounts"
response = requests.get(url)
print(response.text)Requires
Authorization: Bearer <user-access-token> — the token from Verify login code. No X-Api-Key, X-Api-Secret, or userId — the token already identifies the user.id from each account to reference it in deposit, transfer, and transaction endpoints.
Request
GET /api/v1/user/accounts
Authorization: Bearer <user-access-token>
Response
200 OK{
"items": [
{ "id": 659, "asset": "USDC", "type": "LIABILITY", "credits": "0.00000000", "debits": "0.00000000" }
],
"meta": { "totalItems": 1, "currentPage": 1 }
}
Item fields
| Field | Type | Description |
|---|---|---|
id | number | Account ID — use in deposit, transfer, and transaction requests |
asset | string | Currency of the account — always "USDC" today |
type | string | Always "LIABILITY" for a user’s own account |
The account is created automatically the first time the user logs in — you do not need to call a separate account-creation endpoint. Every active user has exactly one USDC account.
Errors
| HTTP status | Error | Cause |
|---|---|---|
401 | Invalid or expired token | Missing, expired, or malformed access token |