Get target periods

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
❗️

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

ParameterTypeDescription
dataArrayList of objects containing the main data payload.
data[].idIntegerUnique identifier for the record.
data[].attributionObjectMetadata about the creation and updates of the record.
attribution.createdOnString

Timestamp when the target period was created (ISO 8601 format).

Note: This field will be deprecated in the future and is being replaced by createdOnISO.

attribution.createdOnISOString

Indicates the creation date and time of the target period in ISO 8601 format, returned in the server's time zone.

EU server example
2025-12-16T14:30:45Z → 16 December 2025, 14:30:45 (UTC)

India server example
2025-12-16T14:30:45+05:30 → 16 December 2025, 14:30:45 (IST)

Note: The response time zone always matches the server time zone, regardless of the time zone offset in the request.

attribution.lastUpdatedOnStringTimestamp 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.lastUpdatedOnISOString

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
2025-12-16T14:30:45Z → 16 December 2025, 14:30:45 (UTC)

India server example
2025-12-16T14:30:45+05:30 → 16 December 2025, 14:30:45 (IST)

Note: The response time zone always matches the server time zone, regardless of the time zone offset in the request.

lastUpdatedBy.idIntegerUnique identifier of the user.
lastUpdatedBy.codeStringCode associated with the user.
lastUpdatedBy.descriptionStringDescription of the user
lastUpdatedBy.nameStringName of the user.
lastUpdatedBy.typeStringType of the user (e.g., "TILL").
attribution.createdByObjectDetails of the user who created the record (same structure as lastUpdatedBy).
data[].startDateStringStart date of the period (YYYY-MM-DD format).
data[].endDateStringEnd date of the period (YYYY-MM-DD format).
data[].refCodeStringReference code for the period (e.g., "Cycle_1").
data[].periodStatusStringStatus of the period (e.g., "ENDED").
data[].targetGroupIdIntegerIdentifier for the target group associated with the period.
data[].descriptionStringDescription of the period (empty in this case).
data[].activeBooleanIndicates whether the period is active.
Path Params
int64
required
Headers
string
string
string
string
Responses

Language
Credentials
Basic
base64
:
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json