API / Reference / Card Transactions
Batch update card transactions
PATCH
https://api.light.inc/v1/card-transactions/batch-update
Updates multiple card transactions in a single operation
Asynchronous. The call authorises every id up front (one id you may not update makes the whole request 403), queues the work and returns an empty body immediately; nothing in the response tells you whether any update succeeded. Items are processed independently: one failing item does not stop the others, and a failure that is a validation error is written to that transaction's failureContext, where a later GET shows it. Poll updatedAt or failureContext on the transactions to confirm. There is no cap on the list length.
This is the only endpoint that accepts postingDate, and it is write-only from the card side: no card-transaction response returns it. Read it back on the ledger line (GET /v1/ledger-transaction-lines, postingDate) once the transaction is posted. Line updates here take description, accountId, taxCodeId and customProperties only; edits to a posted transaction fail into failureContext rather than being rejected up front.
Authorization
Send one of these on every request. See Authentication for how to get credentials.
- API key
Basic authentication header of the form Basic <api_key>, where <api_key> is your api key.
- Bearer token
Request body
application/json;charset=UTF-8
-
cardTransactionIdstring · uuid -
customPropertiesarray of object-
groupIdstring · uuid -
valueIdsarray of string · uuidCatalogue value ids for this group. Required; send
[](with an emptyinlineValues) to clear the group.SINGLE_SELECTandMULTI_SELECTgroups accept nothing else. See Custom properties on writes. -
inlineValuesarray of stringLiteral values for
TEXT,NUMERIC,BOOLEANandDATEgroups, as strings (yyyy-MM-ddfor dates). Rejected on select groups withCUSTOM_PROPERTY_VALUE_TYPE_MISMATCH. See Custom properties on writes.
-
-
linesarray of object-
lineIdstring · uuid -
customPropertiesarray of object-
groupIdstring · uuid -
valueIdsarray of string · uuidCatalogue value ids for this group. Required; send
[](with an emptyinlineValues) to clear the group.SINGLE_SELECTandMULTI_SELECTgroups accept nothing else. See Custom properties on writes. -
inlineValuesarray of stringLiteral values for
TEXT,NUMERIC,BOOLEANandDATEgroups, as strings (yyyy-MM-ddfor dates). Rejected on select groups withCUSTOM_PROPERTY_VALUE_TYPE_MISMATCH. See Custom properties on writes.
-
-
descriptionstring -
accountIdstring · uuid -
taxCodeIdstring · uuid
-
-
postingDatestring · dateWritable here and nowhere else on the card side, and returned by no card-transaction response. Read it back on the ledger line (
GET /v1/ledger-transaction-lines,postingDate) once the transaction is posted. -
descriptionstring
Response
This endpoint returns no content.