Get Loyalty Account Events (GET /v1/loyalty-accounts/{id}/events)
Retrieves all Loyalty Events associated with a specific Loyalty Account.
URL test:
Method:
GET
Path Items
/v1/loyalty-accounts/{id}/events
| Name | Location | Type | Required | Description |
|---|---|---|---|---|
| id | path | integer (int64) |
Yes | Identifier of the Loyalty Account (must be > 0). |
| page | query | integer (int32) |
No | Zero‑based page index (default 0). |
| size | query | integer (int32) |
No | Number of items per page (default 20). |
| sort | query | string | No | Sorting order, e.g., timestamp,desc. |
Example cURL
curl -X 'GET' \
'https://test.lightcms.io/loyalty/v1/loyalty-accounts/1/events?page=1&size=20&sort=timestamp,desc' \
-H 'accept: */*'
Responses:
200 - OK
Status Code: 200 OK
[
{
"id": 101,
"loyaltyAccountId": 987,
"loyaltyProgramId": 12,
"reward": {
"id": 55,
"rewardType": "LOYALTY_POINTS",
"rewardAmount": 100,
"rewardCurrency": "USD",
"previousRewardAmount": 0,
"customerMessage": "Points awarded",
"ruleId": 3,
"trancoreId": 2001,
"loyaltyEventId": 101,
"createdAt": "2024-06-01T10:00:00Z",
"updatedAt": "2024-06-01T10:00:00Z"
},
"eventType": "POINTS_EARNED",
"eventDetails": {},
"timestamp": "2024-06-01T10:00:00Z",
"createdAt": "2024-06-01T10:00:00Z",
"updatedAt": "2024-06-01T10:00:00Z"
}
]
| Parameter | Location | Type | Description |
|---|---|---|---|
| id | body | integer (int64) |
Unique identifier of the Loyalty Event. |
| loyaltyAccountId | body | integer (int64) |
Identifier of the Loyalty Account to which the event belongs. |
| loyaltyProgramId | body | integer (int64) |
Identifier of the Loyalty Program related to the event. |
| reward.id | body | integer (int64) |
Identifier of the associated Reward. |
| reward.rewardType | body | string | Type of reward (PERCENTAGE, FLAT_AMOUNT, LOYALTY_POINTS). |
| reward.rewardAmount | body | number | Amount/value of the reward. |
| reward.rewardCurrency | body | string | Currency code for the reward (e.g., USD). |
| reward.previousRewardAmount | body | number | Previous reward amount before this event. |
| reward.customerMessage | body | string | Message shown to the customer. |
| reward.ruleId | body | integer (int64) |
Identifier of the rule that triggered the reward. |
| reward.trancoreId | body | integer (int64) |
Transaction core ID linked to the reward. |
| reward.loyaltyEventId | body | integer (int64) |
Identifier of the Loyalty Event that created the reward. |
| reward.createdAt | body | string (date‑time) | Timestamp when the Reward was created. |
| reward.updatedAt | body | string (date‑time) | Timestamp of the last update to the Reward. |
| eventType | body | string | Type of the event (CUSTOMER_CARD_DISPLAYED, TRANSACTION_ASSESSMENT, CARD_ASSIGNMENT). |
| eventDetails | body | object (JsonNode) | Additional details specific to the event type. |
| timestamp | body | string (date‑time) | Exact time the event occurred. |
| createdAt | body | string (date‑time) | Timestamp when the Loyalty Event record was created. |
| updatedAt | body | string (date‑time) | Timestamp of the last modification to the Loyalty Event record. |
404 - Not Found
Status Code: 404 Not Found
{
"timestamp": "2026-02-03T17:09:02.825396155",
"status": 404,
"error": "Resource Not Found",
"message": "Loyalty account not found with id: 2"
}
| Parameter | Location | Type | Description |
|---|---|---|---|
| timestamp | body | string (date‑time) | Time when the error response was generated. |
| status | body | integer | HTTP status code (404). |
| error | body | string | Short error label (“Resource Not Found”). |
| message | body | string | Detailed error message indicating the missing ID. |