Cash Transactions
Cash movements on a TradeZero account - locate fees and credits, margin interest, platform fees, dividends, and other ledger entries - are available as a paginated history read:
GET /v1/api/accounts/{accountId}/cash-transactions/start-date/{startDate}- cash ledger rows under thecashHistorykey, plus apaginationobject (currentLimit,currentOffset,totalRecords).
This endpoint pairs with Account Information: account detail and P&L give you balances and day totals; cash transactions give you the individual ledger lines behind those cash changes. Authentication uses the same API key headers as the rest of the Trading API - see Authentication.
What this endpoint is for
Use GET /cash-transactions/start-date/{startDate} when you need:
- Cash ledger history - fee, credit, interest, dividend, and adjustment rows for an account.
- A bounded date window - start from a
YYYY-MM-DDpath date and look forward up to 365 days (numberOfDays, default 30). - Paginated downloads - page through large histories with
offset/limitusingpagination.totalRecords.
What this endpoint does not do
The route is a read-only cash history. It does not move money, place trades, or stream updates.
| You need | Use instead |
|---|---|
| Current cash, buying power, equity | GET /v1/api/account/{accountId} |
| Day and total P&L | GET /v1/api/accounts/{accountId}/pnl or the P&L Stream |
| Fills and order history | GET /orders or paginated historical orders |
| Closed position lifecycles | Closed Positions |
| Locate quote / accept / inventory | Short Locates |
| Real-time balance push | P&L Stream - re-read cash transactions when you need ledger detail |
Filling an order or accepting a locate does not push a cash row over WebSocket. Re-query this endpoint (or read account aggregates such as totalLocateCosts) when you need ledger confirmation.
At a glance
| Method | Path | What it does |
|---|---|---|
| GET | /v1/api/accounts/{accountId}/cash-transactions/start-date/{startDate} | Retrieve cash transaction history - paginated ledger rows with deposit, withdraw, cash type, and note. |
Full OpenAPI reference: Retrieve Cash Transaction History Paginated.
Quick start
curl 'https://webapi.trade0.click/v1/api/accounts/TTE12345678/cash-transactions/start-date/2026-04-01?numberOfDays=90&limit=100&offset=0' \
-H 'Accept: application/json' \
-H 'TZ-API-KEY-ID: {YOUR_PUBLIC_KEY}' \
-H 'TZ-API-SECRET-KEY: {YOUR_SECRET}'
The base URL is https://webapi.trade0.click. Path parameters are {accountId} and {startDate} (YYYY-MM-DD). Query parameters control the lookback window and page size.
Use a live account id when you expect populated history. Paper accounts return the same envelope with an empty cashHistory array - see Paper vs live.
Request parameters
| Parameter | In | Required | Default | Notes |
|---|---|---|---|---|
accountId | path | Yes | — | Account identifier. Each row’s accountId echoes the canonical form. |
startDate | path | Yes | — | Window start in YYYY-MM-DD. Invalid values (for example not-a-date or 2026-13-40) return 404 Not Found. |
numberOfDays | query | No | 30 | Days to include from startDate, up to 365. Omitting the query matches an explicit numberOfDays=30. Values above 365 are accepted but do not expand the documented one-year window. |
offset | query | No | 0 | Number of cash rows to skip before returning results. |
limit | query | No | 100 | Maximum rows in this page. Maximum 10000. Values above 10000 are clamped (pagination.currentLimit returns 10000). |
The result window is [startDate, startDate + numberOfDays) in calendar days. Narrow numberOfDays when you only need a short slice - for example numberOfDays=7 on a recent startDate returns only that week’s rows and a matching totalRecords.
Response envelope
Successful responses are JSON objects with two top-level keys:
cashHistory- array of cash transaction rows for the current page, ordered oldest → newest byentryDatewithin the requested window.pagination-{ currentLimit, currentOffset, totalRecords }describing this page and the full result set size for the requested window.
{
"cashHistory": [
{
"accountId": "TTE60626",
"cashType": "Locate Fees",
"currency": "USD",
"deposit": 0.0,
"entryDate": "2026-04-14T00:00:00",
"note": "Locate 100 BB @ 0.0045 per share",
"withdraw": 0.45
}
],
"pagination": {
"currentLimit": 100,
"currentOffset": 0,
"totalRecords": 140
}
}
An empty window still returns the envelope: cashHistory is [] and pagination.totalRecords is 0.
Field reference
Cash row (cashHistory[])
| Field | Type | Description |
|---|---|---|
accountId | string | Account identifier for the row. |
cashType | string | Category of the movement. See Cash types. |
currency | string | Currency name. Live USD accounts return "USD". |
deposit | number | Amount added to the account in this transaction. |
withdraw | number | Amount removed from the account in this transaction. |
entryDate | string (date-time) | Ledger date. Values are calendar dates at midnight (…T00:00:00) - there is no intraday timestamp on the row. |
note | string | Human-readable description (fee formula, interest day, dividend detail, etc.). |
deposit and withdraw are mutually exclusive on a given row. One side carries the amount; the other is 0. There are no rows where both are non-zero, and no rows where both are zero.
| Direction | Pattern | Examples |
|---|---|---|
| Money out | withdraw > 0, deposit = 0 | Locate fee, margin interest, platform fee, overnight borrow charge |
| Money in | deposit > 0, withdraw = 0 | Locate credit (sold inventory), dividend, cash credit / adjustment |
Pagination (pagination)
| Field | Type | Description |
|---|---|---|
currentLimit | integer | Limit applied to this response (echo of the effective limit, after clamping). |
currentOffset | integer | Offset applied to this response. |
totalRecords | integer | Total cash rows available for the requested startDate / numberOfDays window (not just this page). |
Cash types
cashType is a free-form category string from the ledger. Live accounts commonly include the types below. Treat the list as observed categories, not a closed enum - new labels can appear as the back office posts additional activity.
cashType | Typical direction | What the note looks like |
|---|---|---|
Locate Fees | withdraw (charge) or deposit (credit) | Charge: Locate 100 BB @ 0.0045 per share. Credit after selling locate inventory: Locate credit 100 OPEN @ 0.0012 per share. |
Locate & Borrow Charge | withdraw | Overnight borrow / locate carry, for example ONB 1 BB ($-0.00288) for 05/26. |
Margin | withdraw | Daily margin interest, for example Daily Margin interest - 11/01/2025. |
Software & Data | withdraw | Platform / data fees, for example Professional Platform Fees 2025-08. |
Dividend | deposit | Dividend credit, for example Div (1) shares KO - Rate (0.510000000000) - Div ExDate 20250915. |
General | either | Manual or back-office cash adjustments (credits and debits). |
Filter or group in your client by cashType and/or by parsing note - the API does not accept a cashType query parameter.
When rows appear (locate fees)
Accepting a locate updates locate inventory and account aggregates before the matching cash ledger row is always visible on this endpoint.
| Surface | Timing after a filled locate accept |
|---|---|
GET /locates/history | Row reaches locateStatus: 50 (Filled) promptly. |
GET /locates/inventory | available shares appear promptly. |
GET /account/{accountId} | Aggregates such as totalLocateCosts can update promptly. |
GET /cash-transactions/... | The Locate Fees row may not appear immediately. Re-query later (including on a subsequent calendar day) with a window that covers the activity date. |
Do not treat an empty cash page in the seconds after accept as proof that no fee was charged. Confirm the fill on locates history / inventory (and account aggregates), then poll cash history with an appropriate startDate / numberOfDays.
Equity orders do not create cash-history rows by themselves. Commissions and trade economics live on order / fill history; this endpoint is the cash ledger, not a per-fill blotter.
Pagination
- Call with
offset=0and your chosenlimit(default100, max10000). - Read
pagination.totalRecords. - While
offset + cashHistory.length < totalRecords, request the next page withoffsetincreased bylimit.
curl 'https://webapi.trade0.click/v1/api/accounts/TTE12345678/cash-transactions/start-date/2026-04-01?numberOfDays=90&limit=100&offset=100' \
-H 'Accept: application/json' \
-H 'TZ-API-KEY-ID: {YOUR_PUBLIC_KEY}' \
-H 'TZ-API-SECRET-KEY: {YOUR_SECRET}'
totalRecords stays constant across pages for the same window; only currentOffset and the slice of cashHistory change. The pagination model matches paginated historical orders: rows in an array, page metadata under pagination. Cash uses cashHistory instead of tradingHistory, and cash limit may be set as high as 10000 (orders pagination caps at 100).
Under burst traffic the route can return 429 Too Many Requests. Space page requests; see API Rate Limits for platform-wide guidance.
Paper vs live
| Account | Behavior |
|---|---|
| Live | Returns cash ledger rows for the requested window (Locate Fees, margin interest, platform fees, dividends, and other types present on the account). |
| Paper | Returns the same envelope shape. Paper accounts have no cash ledger history: cashHistory is [] and totalRecords is 0, even after paper orders. Locates are live-only for a full quote → accept → fee lifecycle. |
Validate request wiring and pagination on paper, then use a live account when you need populated cash history.
Error handling
| Situation | Behavior |
|---|---|
| Missing or invalid API key / secret | 404 Not Found (same pattern as most Trading API reads - not a JSON 401) |
| Account id your key does not own, or a non-existent account id | 200 OK with an empty envelope (cashHistory: [], totalRecords: 0) - not a 404 |
Invalid startDate path value | 404 Not Found |
| Trailing slash on the path | Supported - same 200 envelope as without the slash |
| Account id casing | Case-insensitive in the path |
| Unknown query parameters | Ignored - the request still returns 200 with the normal envelope |
HEAD / PUT / PATCH | 405 Method Not Allowed |
POST / DELETE | 404 Not Found |
OPTIONS | 200 OK |
| Burst / rate limit | 429 Too Many Requests |
Stick to GET. Use account ids from GET /v1/api/accounts so you do not mistake an empty ledger for “no access.”
Worked examples
Locate fee charge
{
"accountId": "TTE60626",
"cashType": "Locate Fees",
"currency": "USD",
"deposit": 0.0,
"entryDate": "2026-04-14T00:00:00",
"note": "Locate 100 BB @ 0.0045 per share",
"withdraw": 0.45
}
withdraw equals shares × per-share price (100 × 0.0045 = 0.45). Pair with Short Locates when reconciling accepts to fees.
Locate credit (sold inventory)
{
"accountId": "TTE60626",
"cashType": "Locate Fees",
"currency": "USD",
"deposit": 0.12,
"entryDate": "2025-07-30T00:00:00",
"note": "Locate credit 100 OPEN @ 0.0012 per share",
"withdraw": 0.0
}
Same cashType as a locate charge; direction is on deposit vs withdraw, and the note prefix is Locate credit.
Dividend
{
"accountId": "TTE60626",
"cashType": "Dividend",
"currency": "USD",
"deposit": 0.51,
"entryDate": "2025-10-02T00:00:00",
"note": "Div (1) shares KO - Rate (0.510000000000) - Div ExDate 20250915",
"withdraw": 0.0
}
Related guides
- Account Information - balances, buying power, P&L snapshots, and aggregates such as
totalLocateCosts - Short Locates - quote, accept, inventory (fees post here as activity; cash rows follow on this endpoint)
- Closed Positions - realized P&L on flat lifecycles
- Equity Trading - order and fill history
- Retrieve Cash Transaction History Paginated - OpenAPI reference