Record a transaction on a feed line
Record a single transaction (purchase or payment) against the feed in real time. Fails with CONFLICT when the externalId already exists, and with BAD_REQUEST when a purchase exceeds the available credit. Applies to feed credit lines only.
- Type: string Format: uuidcredit
Line Id requiredCredit line UUID
- Type: integeramountgreater than:0min:-9007199254740991max:9007199254740991required
Transaction amount in cents
- Type: stringexternal
Id min length:1max length:255requiredPartner-side transaction id — idempotency key per credit line; re-sending the same id is a no-op
- Type: string Format: datetransaction
Date requiredTransaction date (YYYY-MM-DD). Rejected when in the future (one day of tolerance) or before the line's start — the feed is a daily report, not a backfill channel
- Type: stringdescriptionmax length:500nullable
Transaction description
- enumtype
purchase = customer card spend (consumes availability, subject to the facility limit); payment = customer deposit made to the partner (restores availability, nets against purchases at period close — never pays extensions)
values- purchase
- payment
- application/json
- application/json
- application/json
- application/json
- application/json
- application/json
- application/json
- application/json
curl https://api-sandbox.tryslatehq.com/credit-lines/123e4567-e89b-12d3-a456-426614174000/transactions \
--request POST \
--header 'Content-Type: application/json' \
--header 'x-api-key: YOUR_SECRET_TOKEN' \
--data '{
"externalId": "txn_01J8ZQ",
"type": "purchase",
"amount": 12500,
"transactionDate": "2026-07-30",
"description": "Fuel — pump 4"
}'
{
"transaction": {
"id": "123e4567-e89b-12d3-a456-426614174000",
"creditLineId": "123e4567-e89b-12d3-a456-426614174000",
"externalId": "txn_01J8ZQ",
"type": "purchase",
"amount": 12500,
"transactionDate": "2026-07-30",
"description": null,
"financingAgreementId": null,
"status": "active",
"reversedAt": null,
"createdAt": "2026-07-30T00:00:00Z"
},
"availableCredit": 650000
}