Skip to content

Retrieve Token History by cmsTokenID

Retrieves a paginated list of history entries for a specific token.

URL test:

    https://test.lightcms.io/cms/v2/cards/tokens/ABC123/history?size=20&page=0&sort=createdAt,desc

Method:

GET

Path items:

/cards/tokens/{cmsTokenId}/history ?size={size} &page={page} &sort={sort}

Parameters:

Parameter Location Type Example Description Required
cmsTokenId path string ABC123 CMS internal card token identifier Yes
size query integer 20 Number of records on the page (default is 20) No
page query integer 0 Requested page number; returns empty list if page does not exist No
sort query string createdAt,desc Requested sort order – list of “field,direction” pairs; possible fields: accountExternalId, accountCurrency, status. Default: createdAt,desc No

Example:

    curl -X GET "https://test.lightcms.io/cms/v2/cards/tokens/ABC123/history?size=20&page=0&sort=createdAt,desc" \
         -H 'accept: */*'

Responses:

200 - OK

Status Code: 200 OK

[
  {
    "id": 4,
    "tokenId": "ABC123",
    "deviceId": "XX",
    "deviceTypeDescription": "Mobile",
    "deviceType": "MOBILE",
    "status": "ACTIVE",
    "tokenRequestorDescription": "Customer",
    "tokenRequestor": "CUSTOMER",
    "tokenUniqueReferenceId": "REF123",
    "panSource": "ENCRYPTED",
    "createdAt": "2025-07-23T09:49:22.322Z",
    "updatedAt": "2025-07-23T09:49:22.322Z"
  }
]

Parameter Location Type Description
id root integer Internal identifier of the history record.
tokenId root string Token identifier this history entry belongs to.
deviceId device string Identifier of the device that performed the action.
deviceTypeDescription device string Human‑readable description of the device type.
deviceType device string Machine‑readable device type code.
status root string Status of the token at this point in time (e.g., ACTIVE, INACTIVE).
tokenRequestorDescription root string Description of who requested the token.
tokenRequestor root string Code of the requestor (e.g., CUSTOMER, MERCHANT).
tokenUniqueReferenceId root string Unique reference linking this history entry to the original request.
panSource root string Source of the PAN for the token (e.g., ENCRYPTED, MASKED).
createdAt root string Timestamp when this history entry was created (ISO‑8601).
updatedAt root string Timestamp of the last update to this history entry (ISO‑8601).
404 - Not Found

Status Code: 404 Not Found

{
  "errorMessage": "Entity with tokenId ABC123 not found in DB."
}

Parameter Location Type Description
errorMessage root string Human‑readable description of the error condition.
500 - Internal error

Status Code: 500 Internal error

{
  "timestamp": "2025-07-22T13:09:02.348+02:00",
  "status": 500,
  "error": "Internal Server Error",
  "path": "/cms/v2/cards/tokens/ABC123/history"
}

Parameter Location Type Description
timestamp root string ISO‑8601 timestamp when the error occurred.
status root integer HTTP status code (500).
error root string Short description of the error.
path root string The request path that caused the error.