On this page
Introduction
The Riafront API lets your own systems read your firm's data (clients, accounts, positions, transactions, daily values, money in and out, and notes) and add or change clients, accounts, households, goals, follow-ups, documents, and more. Use it to feed a data warehouse, keep a CRM in step, or log calls from a phone system.
Every request goes to one address, over HTTPS, and sends and receives JSON:
https://www.riafront.com/api/v1
If you'd rather receive files on a schedule, the same data can be sent as CSV files to your SFTP server. A firm admin sets that up under Settings → Data exports.
Quick start
- A firm admin signs in to Riafront, goes to Settings → API and makes a key. Tick only what it needs. The key is shown once, so copy it into your password manager or your system's secret store.
- Check the key works. This says which firm it belongs to and what it can do:
curl https://www.riafront.com/api/v1/me -H "Authorization: Bearer $RIAFRONT_API_KEY"
- Read something:
curl "https://www.riafront.com/api/v1/clients?limit=50" -H "Authorization: Bearer $RIAFRONT_API_KEY"
Keys and scopes
Send the key on every request as Authorization: Bearer riafront_live_…. A key belongs to the firm, not a person, and reads the whole firm unless it's limited. We keep only a hash of it, so a lost key can't be shown again: turn it off and make a new one. Making, rotating, and turning off keys goes on the firm's activity log.
Each key can do only what was ticked when it was made:
| Scope | Lets the key |
|---|
clients:read | Read clients: GET /clients and /clients/{id} |
accounts:read | Read accounts: GET /accounts and /accounts/{id} |
positions:read | Read positions: GET /positions |
transactions:read | Read transactions: GET /transactions |
daily_values:read | Read daily values: GET /daily-values |
flows:read | Read money in and out: GET /flows |
notes:read | Read notes: GET /notes and /notes/{id} |
households:read | Read households: GET /households and /households/{id}. Read household members: GET /household-members and /household-members/{id} |
documents:read | Read documents: GET /documents and /documents/{id} |
held_away:read | Read held-away assets: GET /held-away and /held-away/{id} |
liabilities:read | Read liabilities: GET /liabilities and /liabilities/{id}. Read liability balances: GET /liability-balances and /liability-balances/{id} |
orders:read | Read orders: GET /orders and /orders/{id} |
invoices:read | Read invoices: GET /invoices and /invoices/{id} |
payments:read | Read invoice payments: GET /invoice-payments and /invoice-payments/{id} |
signatures:read | Read signature requests: GET /signature-requests and /signature-requests/{id} |
goals:read | Read goals: GET /goals and /goals/{id} |
risk_scores:read | Read risk scores: GET /risk-scores and /risk-scores/{id} |
securities:read | Read securities: GET /securities and /securities/{id} |
follow_ups:read | Read follow-ups: GET /follow-ups and /follow-ups/{id} |
documents:files | Download a document's file: GET /documents/{id}/file |
clients:write | Add a client: POST /clients, /clients/bulk, change one: PATCH /clients/{id}, add or change by your own id: PUT /clients/external/{external_id} |
accounts:write | Add an account: POST /accounts, /accounts/bulk, change one: PATCH /accounts/{id}, add or change by your own id: PUT /accounts/external/{external_id} |
notes:write | Log a note: POST /notes, /notes/bulk |
households:write | Add a household: POST /households, /households/bulk, change one: PATCH /households/{id}, add or change by your own id: PUT /households/external/{external_id} |
held_away:write | Add a held-away asset: POST /held-away, /held-away/bulk, change one: PATCH /held-away/{id} |
liabilities:write | Add a liability: POST /liabilities, /liabilities/bulk, change one: PATCH /liabilities/{id}. Add a liability balance: POST /liability-balances, /liability-balances/bulk |
goals:write | Add a goal: POST /goals, /goals/bulk, change one: PATCH /goals/{id} |
follow_ups:write | Add a follow-up: POST /follow-ups, /follow-ups/bulk, mark a follow-up done: POST /follow-ups/{id}/done |
transactions:write | Send a transaction for review: POST /transactions, /transactions/bulk |
positions:write | Set a starting holding or cash: POST /positions, /positions/bulk |
daily_values:write | Set an account value for a day: POST /daily-values, /daily-values/bulk |
prices:write | Set a security price: POST /prices, /prices/bulk |
period_returns:write | Set a return for a period: POST /period-returns, /period-returns/bulk |
invoices:write | Add or change an invoice: POST /invoices, /invoices/bulk |
documents:write | Add a document: POST /documents, get a link to upload a file: POST /documents/upload-link, confirm an upload: POST /documents/{id}/confirm |
A key can also be limited when it's made:
- Whose clients. Only some advisors' clients. The key can't see anyone else, even by id, and clients it adds go to its advisor.
- Where from. Only some IP addresses or ranges, like
203.0.113.0/24. Anything else gets a 403. - How fast. From 30 to 1,200 requests a minute. 120 is standard.
- How long. An expiry date.
Rotating a key gives you a new one with the same settings, and keeps the old one working for a grace period (none, an hour, a day, or a week) while you swap it in. Rotate keys when someone who knew one leaves, and on whatever schedule your security policy sets.
Requests and responses
- A list comes back as
{ "data": [ … ], "next_cursor": "…" }, and one record as { "data": { … } }. - Money is in US dollars unless the column ends in
_local, which is in the account's or security's own currency. - Returns are decimals:
0.01 is 1%. - Dates are
YYYY-MM-DD. Times are ISO 8601 in UTC, like 2026-09-28T14:05:00Z. - Ids are UUIDs and never change. Use them to match records between runs.
- A value we don't have is
null. Every column in the reference is always present.
Paging
Lists come 200 rows at a time, or up to 1000 with limit. When there are more, the response has a next_cursor. Send it back as cursor for the next page, and stop when it comes back null. A cursor stays valid, so a long sync can stop and carry on later.
let cursor = null;
do {
const url = new URL('https://www.riafront.com/api/v1/transactions');
url.searchParams.set('limit', '1000');
if (cursor) url.searchParams.set('cursor', cursor);
const res = await fetch(url, { headers: { Authorization: `Bearer ${key}` } });
const page = await res.json();
save(page.data);
cursor = page.next_cursor;
} while (cursor);
Filters and syncing
| Filter | Works on | Meaning |
|---|
client_id | accounts, positions, transactions, daily-values, flows, notes, household-members, documents, held-away, liabilities, liability-balances, orders, invoices, invoice-payments, signature-requests, goals, risk-scores, follow-ups | Only this client's. |
account_id | positions, transactions, daily-values, flows, documents, orders | Only this account's. |
household_id | household-members | Only this household's. |
invoice_id | invoice-payments | Only this invoice's. |
from | transactions, daily-values, flows, notes, orders, invoices, invoice-payments, signature-requests, risk-scores, follow-ups | On or after this day, as YYYY-MM-DD. |
to | transactions, daily-values, flows, notes, orders, invoices, invoice-payments, signature-requests, risk-scores, follow-ups | On or before this day, as YYYY-MM-DD. |
external_id | clients, accounts, households | Only the record with this id from your own system. It has to match all of it, including capitals. |
email | clients | Only the client with this email address. It has to match all of it, and capitals don't matter. |
symbol | securities | Only the security with this ticker symbol. Capitals don't matter. |
status | clients, accounts, documents, held-away, liabilities, invoices, signature-requests, goals, follow-ups | Only rows with this status. The description of each list says which values it takes. |
state | orders | Only orders in this state. The description of the list says which values it takes. |
updated_since | clients, accounts, transactions, notes, households, household-members, documents, held-away, liabilities, liability-balances, orders, invoices, invoice-payments, signature-requests, goals, risk-scores, securities, follow-ups | Changed at or after this time, as an ISO 8601 timestamp. Use it to pick up only what changed since you last asked. |
To keep a copy in step, ask for everything once, then on each run ask only for what changed with updated_since set to when the last run started, less a few minutes so nothing falls between runs. Match rows on id. Positions have no change time, so read them in full. Daily values and money in and out change by day, so ask for the last few days with from.
When new data is ready
Each market day comes in over two steps. Times are New York time.
| When | What happens |
|---|
| 9:30pm on each market day (8:30pm in winter) | Every holding is valued at the day's official closing price, and each account's value and return for the day are recorded. |
| 2am the next morning (1am in winter) | Your custodian's positions and prices for the day come in. Where the custodian's price is different from the market's, the custodian's is used and the day is worked out again. Its transactions wait on the Reconciliation page until someone at your firm posts them. |
Nothing runs on weekends or market holidays, so those days have no daily value. For a day's final numbers, pull after 6am.
Or check first. GET /me returns data_ready: values_through is the last market day that's been valued, and custodian_prices_through is the latest day your custodian's positions came in for (null if your firm doesn't load them). When the two dates match and accounts_updating is 0, that day is done, apart from transactions someone posts later.
"data_ready": {
"values_through": "2026-09-25",
"custodian_prices_through": "2026-09-25",
"accounts_updating": 0
}
Adding and changing records
POST JSON to /clients, /accounts, /households, /held-away, /liabilities, /liability-balances, /goals, /notes, /follow-ups, /transactions, /positions, /daily-values or /documents. A new record comes back with status 201. Fields we don't know are refused, so a typo can't pass unnoticed. If anything's wrong, a 422 lists each field and what's wrong with it.
Send an Idempotency-Key header with every POST: any unique string, like a UUID. If the connection drops and you send the same request again with the same key, you get the first answer back, with Idempotent-Replayed: true, and nothing is added twice. Using the same key for a different request is a 422. We keep keys for 24 hours.
Change a record with PATCH /clients/{id} (also accounts, households, held-away, liabilities, and goals). Send only the fields to change. Names, contact details, advisor, status, and your own id can be changed. Balances, ids and anything that would rewrite history can't, and asking for one is a 422.
Match on your own ids. Clients, accounts, and households take an external_id, the id the record has in your CRM or spreadsheet. PUT /clients/external/{external_id} adds the client the first time and changes the same client every time after, so a sync can run again and again without making copies.
Send many at once with POST /clients/bulk (or any other path that can be added to): up to 500 rows as a JSON list or a CSV file. Each row is saved on its own, and the answer says what happened to each one.
Transactions are reviewed first. A transaction sent to /transactions does not go into the books. It waits on the Reconciliation page with the rows from custodian files, and someone there posts it. A firm that uses Riafront for the client app only has no custodian file to check it against, so its transactions post at once.
A firm with no custodian sends everything the client app shows: clients and accounts, then /positions for what each account holds (the symbol CASH is its cash), then /transactions for what happened after that, and /daily-values for what each account was worth on each past day, which is what charts and returns use.
Files. POST /documents takes a file as base64, up to 10 MB. For anything bigger, ask for a link with POST /documents/upload-link, PUT the file to it, then call POST /documents/{id}/confirm. We take PDFs, images, Office files, CSV, and text, and check the start of the file as well as its name.
Everything added or changed through the API goes on the firm's activity log, naming the key.
Webhooks
Instead of asking the API over and over, your system can be told when something happens. A firm admin adds your address on the API page in Settings and picks the events. We POST each one there as JSON, usually within 5 minutes.
| Event | When |
|---|
flow.created | A deposit, withdrawal, or transfer is added, counted the way the flows dataset counts it. amount is in US dollars, and money in is positive. |
client.created | A client is added, in the app or through the API. |
account.created | An account is added. |
note.created | A note, call, or meeting is logged on a client. |
reconciliation.break_opened | The custodian's records and ours disagree about an account. |
document.created | A document is added to a client's documents. The file itself and where it's stored aren't sent. |
task.created | A follow-up date is set on a client note, so it shows on the Tasks page. |
task.completed | A follow-up on a client note is marked done. |
order.created | An order is entered, including drafts. |
order.status_changed | An order moves to a new status, like approved, sent to the custodian, filled, or rejected. The payload has the old and the new status. |
signature.completed | A client signed a document you asked them to sign. The signed copy is added to their documents too, which sends a New document event. |
data.ready | The last market day's numbers are final: valued, the custodian's prices in, nothing being reworked. Sent once a day. |
Every event has the same shape. data changes with the event:
A flow.created event
{
"id": "6d5c4b3a-2918-4776-8554-433221100fed",
"type": "flow.created",
"created_at": "2026-09-29T06:10:00Z",
"data": {
"transaction_id": "2b3c4d5e-6f70-4812-9a3b-4c5d6e7f8091",
"account_id": "5a6b7c8d-9e0f-4a1b-8c2d-3e4f5a6b7c8d",
"client_id": "8c1d2e3f-4a5b-4c6d-8e7f-9a0b1c2d3e4f",
"advisor_id": "1e2d3c4b-5a69-4788-9a6b-5c4d3e2f1a0b",
"date": "2026-09-28",
"kind": "deposit",
"shares": false,
"amount": 25000
}
}
Answer with any 2xx status within 10 seconds. Do the real work after you've answered. If you answer anything else, or don't answer, we try again after 1, 5 and 30 minutes, then 2, 6, 12 and 24 hours. After 8 tries we stop and tell the firm's admins. We don't follow redirects.
An event can arrive more than once, and not always in order. Each has an id, also sent as the Riafront-Event-Id header, so keep the ones you've handled and skip repeats.
Check the signature on every request, so you know it came from us and wasn't changed. The Riafront-Signature header looks like t=1790662200,v1=5f2c…, where v1 is an HMAC-SHA256 of the time, a full stop and the raw body, made with the webhook's secret. Refuse a request more than 5 minutes old.
# Work it out by hand, to compare with the v1 in the header:
printf '%s.%s' "$T" "$BODY" | openssl dgst -sha256 -hmac "$RIAFRONT_WEBHOOK_SECRET"
"Send a test" on the API page sends a test event straight away and shows what your address answered. Recent events and their results are listed there too, with a button to send one again.
Limits and headers
Every response has these headers:
| Header | Meaning |
|---|
X-RateLimit-Limit | The key's requests a minute. |
X-RateLimit-Remaining | How many are left this minute. |
X-RateLimit-Reset | When the minute resets, as a Unix time. |
X-Request-Id | This request in our log. Quote it if you ask us about a request. |
Over the limit, you get a 429 with Retry-After in seconds. Wait that long and try again. For big reads, use a larger limit rather than more requests.
Errors
Errors have the same shape, with a code you can act on and a message you can show a person:
{
"error": {
"code": "invalid",
"message": "Some fields aren't right.",
"details": [{ "field": "email", "message": "Required." }]
}
}
| Status | Code | When |
|---|
| 400 | bad_request | A filter, limit, or cursor is wrong, or the body isn't JSON. |
| 401 | unauthorized | No key, or it's turned off, expired, or rotated past its grace period. |
| 403 | forbidden | The key doesn't have the scope, or the request came from an address it doesn't allow. |
| 404 | not_found | No such path, or no record with that id that the key can see. |
| 409 | conflict | It already exists (a taken email or account number), or the first request with this Idempotency-Key is still running. |
| 422 | invalid | A field is wrong. details lists them. |
| 429 | rate_limited | Over the key's requests a minute. Wait for Retry-After. |
| 500 | server_error | Something failed on our side. Try again, and quote the request id if it keeps happening. |
Changes to the API
This is version 1, at /api/v1. We may add endpoints, fields, and filters to it, so write your code to ignore fields it doesn't know. The OpenAPI file always matches what the API does today, and tools like Postman, Swagger UI, or a code generator can read it.
GET/api/v1/me
The key you're using
Which firm the key belongs to, what it can do, and how far the data has got (see When new data is ready). Any live key can call it.
curl https://www.riafront.com/api/v1/me -H "Authorization: Bearer $RIAFRONT_API_KEY"
Response · 200
{
"data": {
"firm": {
"id": "0f1e2d3c-4b5a-4968-8776-655443322110",
"name": "Example Wealth"
},
"key": {
"id": "a1b2c3d4-e5f6-4789-9abc-def012345678",
"name": "Data warehouse",
"prefix": "riafront_live_4e1802",
"scopes": [
"clients:read",
"accounts:read"
],
"expires_at": null
},
"data_ready": {
"values_through": "2026-09-25",
"custodian_prices_through": "2026-09-25",
"accounts_updating": 0
}
}
}