Record an entry
post
https://api.flactrum.com/v1/transactions
| Required scope | transactions.write |
| Success status | 201 |
| Returns | One Transaction object |
Request body
| Field | Type | Description |
|---|---|---|
| branch_id * | string | — |
| type * | string | — |
| category * | string | Free text: rent, utilities, tips… |
| amount * | number | — |
| affects_cash | boolean | — |
| payment_method_id | string|null | — |
| description | string|null | — |
| transaction_date * | string | — |
| receipt | string | Receipt photo or PDF (jpg, png, webp, pdf; max 5 MB). Send as multipart/form-data; on update use POST with _method=PATCH. |
| remove_receipt | boolean | Removes the attached receipt. |
Response fields
| Field | Type | Description |
|---|---|---|
| id | string | — |
| branch_id | string | — |
| type | string | — |
| category | string | — |
| amount | number | Always positive; the direction comes from type. |
| affects_cash | boolean | Whether it passes through the till. A bill paid by bank transfer is an expense but does not change the day-end cash count. |
| payment_method_id | string|null | — |
| order_id | string|null | Set when the entry came from a sale rather than being typed in. |
| transaction_date | string | — |
| receipt_url | string|null | Photo or PDF of the receipt, when one was attached. |
Examples
Recorded from the test suite — these are real requests and their real responses.
curl -X POST 'https://api.flactrum.com/v1/transactions' \
-H 'Authorization: Bearer flk_your_key:your_secret' \
-H 'Content-Type: application/json' \
-d '{
"branch_id": "01m43my9r4ebzg9xfb8e72q21z",
"type": "expense",
"category": "utilities",
"amount": 3200,
"description": "Elektrik faturası",
"transaction_date": "2026-10-04",
"affects_cash": false
}'
HTTP 201 · application/json
{
"data": {
"id": "01m43my9rpmdhdyjfqd973zjvf",
"branch_id": "01m43my9r4ebzg9xfb8e72q21z",
"type": "expense",
"category": "utilities",
"amount": 3200,
"affects_cash": false,
"payment_method_id": null,
"order_id": null,
"description": "Elektrik faturası",
"transaction_date": "2026-10-04",
"receipt_url": null,
"created_at": "2026-10-04T14:26:30+00:00",
"updated_at": "2026-10-04T14:26:30+00:00"
}
}