| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
This API is being phased out and will no longer be available for viewing milestones.To view milestones, use the Get Details of all Loyalty Promotions API
This API is used to fetch all target periods present in a target group. Meaning, this depends on the "target group id" and that is a mandatory parameter.
Example request
curl --location 'https://eu.api.capillarytech.com/v3/targetGroups/2163/targetPeriods' \
--header 'Authorization: Basic bWFkaMjU2YQ==' \
--header 'Cookie: _cfuvid=H_OUDqsSJh7q7aUlkRgBjVIMRBFDNp2ic0PI6VAnYzw-1762857476978-0.0.1.1-604800000'Example response
{
"data": [
{
"id": 19336,
"attribution": {
"createdOn": "2025-05-22T03:43:09.000+0000",
"createdOnISO": "2025-05-22T03:43:09Z",
"lastUpdatedOn": "2025-05-22T03:43:09.000+0000",
"lastUpdatedOnISO": "2025-05-22T03:43:09Z",
"lastUpdatedBy": {
"id": 75155297,
"code": "tj_capillary",
"description": "",
"name": "tj_capillary",
"type": "TILL"
},
"createdBy": {
"id": 75155297,
"code": "tj_capillary",
"description": "",
"name": "tj_capillary",
"type": "TILL"
}
},
"startDate": "2025-05-22",
"endDate": "2025-05-22",
"refCode": "Cycle_1",
"periodStatus": "ENDED",
"targetGroupId": 2163,
"description": "",
"active": true
},
{
"id": 19337,
"attribution": {
"createdOn": "2025-05-22T03:43:09.000+0000",
"createdOnISO": "2025-05-22T03:43:09Z",
"lastUpdatedOn": "2025-05-22T03:43:09.000+0000",
"lastUpdatedOnISO": "2025-05-22T03:43:09Z",
"lastUpdatedBy": {
"id": 75155297,
"code": "tj_capillary",
"description": "",
"name": "tj_capillary",
"type": "TILL"
},
"createdBy": {
"id": 75155297,
"code": "tj_capillary",
"description": "",
"name": "tj_capillary",
"type": "TILL"
}
},
"startDate": "2025-05-23",
"endDate": "2025-05-23",
"refCode": "Cycle_2",
"periodStatus": "ENDED",
"targetGroupId": 2163,
"description": "",
"active": true
}
],
"errors": null,
"warnings": null
}Response parameters
| Parameter | Type | Description |
|---|---|---|
| data | Array | List of objects containing the main data payload. |
| data[].id | Integer | Unique identifier for the record. |
| data[].attribution | Object | Metadata about the creation and updates of the record. |
| attribution.createdOn | String | Timestamp when the target period was created (ISO 8601 format). Note: This field will be deprecated in the future and is being replaced by |
| attribution.createdOnISO | String | Indicates the creation date and time of the target period in ISO 8601 format, returned in the server's time zone. EU server example India server example Note: The response time zone always matches the server time zone, regardless of the time zone offset in the request. |
| attribution.lastUpdatedOn | String | Timestamp when the record was last updated (ISO 8601 format). Note: This field will be deprecated in the future and is being replaced by lastUpdatedOnISO. |
| attribution.lastUpdatedOnISO | String | Indicates the last updated date and time of the target period in ISO 8601 format, returned in the server's time zone. EU server example India server example Note: The response time zone always matches the server time zone, regardless of the time zone offset in the request. |
| lastUpdatedBy.id | Integer | Unique identifier of the user. |
| lastUpdatedBy.code | String | Code associated with the user. |
| lastUpdatedBy.description | String | Description of the user |
| lastUpdatedBy.name | String | Name of the user. |
| lastUpdatedBy.type | String | Type of the user (e.g., "TILL"). |
| attribution.createdBy | Object | Details of the user who created the record (same structure as lastUpdatedBy). |
| data[].startDate | String | Start date of the period (YYYY-MM-DD format). |
| data[].endDate | String | End date of the period (YYYY-MM-DD format). |
| data[].refCode | String | Reference code for the period (e.g., "Cycle_1"). |
| data[].periodStatus | String | Status of the period (e.g., "ENDED"). |
| data[].targetGroupId | Integer | Identifier for the target group associated with the period. |
| data[].description | String | Description of the period (empty in this case). |
| data[].active | Boolean | Indicates whether the period is active. |
