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.

Path Parameters
  • creditLineId
    Type: string Format: uuid
    required

    Credit line UUID

Body
required
application/json
  • amount
    Type: integer
    greater than:  
    0
    min:  
    -9007199254740991
    max:  
    9007199254740991
    required

    Transaction amount in cents

  • externalId
    Type: string
    min length:  
    1
    max length:  
    255
    required

    Partner-side transaction id — idempotency key per credit line; re-sending the same id is a no-op

  • transactionDate
    Type: string Format: date
    required

    Transaction 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

  • description
    Type: string
    max length:  
    500
    nullable

    Transaction description

  • type
    enum

    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
Responses
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
  • application/json
Request Example for post/credit-lines/{creditLineId}/transactions
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
}