Get associated target groups of a user

This API allows you to retrieve the details of all the associated target groups, including the user's milestones and streaks information.

API endpoint example

https://eucrm.cc.capillarytech.com/v3/users/547528790/targetGroups

Prerequisites

  • Authentication; Basic or OAuth authentication details
  • Access group resource - NA

Resource information

URI/users/{userId}/targetGroups
HTTP methodGET
Pagination supported?NO
Rate limitNA
Batch supportNA

Request path parameters

Parameter
(Parameters marked with * are mandatory)
TypeDescription
UserID*LongThe userId represents the unique identifier of a user. It allows you to retrieve the target groups associated with a specific user.

Request query parameters

Parameter
(Parameters marked with * are mandatory)
TypeDescription
includeInactiveBooleanSet true for fetching user targets for all periods, both active and inactive.
targetRuleIdLongThe ID of the target rule set for the target group.
https://eucrm.cc.capillarytech.com/v3/users/547528790/targetGroups

Response parameters

ParameterData TypeDescription
userIdLongThe unique identifier of the customer.
customerObjectAn object containing information about customer.
-idIntegerThe unique identifier of the customer.
-.profilesArray of objectsAn array containing profiles details of the customer
- - firstNameStringThe first name of the customer.
- - lastNameStringThe last name of the customer.
- - commChannelsArray of objectsAn array containing communication information of the customer.
- - - typeStringThe type of communication channel from which we connect to customer. (e.g., mobile, email).
- - - accountIdEnumFor sources that support multiple accounts, For example, FACEBOOK, WEB_ENGAGE, WECHAT, MOBILE_APP.
- - - valueStringThe value of the communication channel (e.g., phone number, email address).
- - - primaryBooleanthis indicates that the above channel is primary or not
- - - verifiedBooleanIndicates if the communication channel has been verified.
- - - subscribedBooleanPass true if the identifier is subscribed for the org's newsletters (bulk messages).
- - - attributesObjectAdditional Details of the identifier.
- - sourceStringThe source from which the customer profile was created (e.g., instore).
- - accountIdStringThe account ID of the customer .
- - userIdIntegerThe unique identifier for the customer.
- - orgSourceIdIntegerThe organization source ID for the customer.
-loyaltyInfoObjectContaining loyalty information of the customer.
- - attributionObjectContaining attribution information for the loyalty information.
- - - createdOnStringThe date and time when the loyalty information was created.
- - - lastUpdatedOnStringThe date and time when the loyalty information was last updated.
- - - lastUpdatedByObjectThe information about the user who last updated the loyalty information.
- - - - idIntegerThe unique identifier for the user who last updated the loyalty information.
- - - - codeNullThe code associated with the last updated user.
- - - - descriptionStringThe description about the last update.
- - - - nameNullName of the user last updated.
- - - - typeEnumType of the customer identifier.
- - - createdByObjectContaining information about the user who created the loyalty information.
- - - - idIntegerThe unique identifier for the user who created the loyalty information.
- - - - codeNullThe code associated with the last updated user.
- - - - descriptionStringThe description about the last update.
- - - - nameNullName of the user last updated.
- - - - typeEnumType of the customer identifier.
- - loyaltyTypeStringThe type of loyalty program.
- - lifetimePurchasesFloatThe total amount of purchases made by the customer in his entire lifetime.
- customFieldsObjectContaining custom fields of the customer.
- - genderStringThe gender of the customer.
targetGroupsArray of objectsContaining information about target groups associated with customer.
- idIntegerThe unique identifier for the target group.
- attributionObjectContaining attribution information for the target group.
- - createdOnStringThe date and time when the target group was created.
- - lastUpdatedOnStringThe date and time when the target group was last updated.
- - lastUpdatedByObjectContaining information about the user who last updated the target group.
- - -idIntegerThe unique identifier for the user who last updated the target group.
- - - codeStringThe code associated with the user who last updated the target group.
- - - descriptionStringThe description associated with the user who last updated the target group.
- - - nameStringThe name of the user who last updated the target group.
- - - typeStringThe type of the user who last updated the target group like ADMIN_USER.
- -createdByObjectContaining information about the user who created the target group.
- - - idIntegerThe unique identifier for the user who created the target group.
- - - codeStringThe code associated with the user who created the target group.
- - - descriptionStringThe description of the user who created the target group.
- - - nameStringThe name of the user who created the target group.
- - - typeStringThe type of the user who created the target group like ADMIN_USER.
- targetsArray of objectsContaining information about targets within the target group.
- - targetIdIntegerThe unique identifier for the target.
- - periodIdIntegerThe unique identifier for the period.
- - periodRefCodeStingThe reference code for the period of the target.
- - periodStartDateStringThe start date of the period for the target.
- - periodEndDateStringThe end date of the period for the target.
- - targetValueFloatThe target value to be achieved.
- - targetAchievedValueFloatThe value achieved towards the target.
- - targetTypeEnumThe type of target:
SUM, COUNT,VISIT.
Refer to this API documentation for more information.
- - targetEntityEnum The KPI on which the target is tracked.
TRANSACTION, LINEITEM, EVENT, REWARDS.
Refer to this API documentation for more information.
- - targetRuleIdIntegerThe rule identifier for the target.
- - enrolledOnStringThe date and time when the target was enrolled.
- - eventNameStringThe name of the event associated with the target.
- -periodStartDateWithTimeStampStringThe start date and time of the period associated with the target rule.
- - periodEndDateWithTimeStampStringThe end date and time of the period associated with the target rule.
- - currentPeriodBooleanIndicates if the target is for the current period.
- - milestonesArray of objectsContaining information about milestones for the target.
- - - idIntegerThe unique identifier for the milestone.
- - -triggerNameStringThe name of the trigger of the milestone.
- - - triggerValueFloatThe value of the trigger of the milestone.
- - - isAchievedBooleanIndicates if the milestone has been achieved.
--- streaksArrayAn array of streaks for the target group.
---- userStreakIdIntegerThe user streak ID.
---- streakIdIntegerThe streak ID.
---- streakNameStringThe name of the streak.
---- statusStringThe status of the streak (For Example- ACHIEVED).
---- currentCountIntegerThe current count of the streak.
---- totalTargetCountOfSequenceIntegerThe total target count of the streak sequence.
---- streakAchievedUserTargetIdStringThe ID of the streak achieved by the user.
- targetEvaluationTypeEnumThe type of evaluation for the target group :
FIXED_CALENDAR_WINDOW
CYCLIC_WINDOW
PERIOD_AGNOSTIC_WINDOW Refer to this API documentation for more information.
- trackingTypeEnumThe type of target for tracking the created milestone:
- Default
- Unified
- Streak
- Capping
-Non continuous streak
Refer to this API documentation for more information.
errorsObjectError in the API call if any.
warningsObjectWarning in the API call if any.

{
    "data": {
        "userId": 64035151,
        "customer": {
            "id": 64035151,
            "profiles": [
                {
                    "firstName": "naresh",
                    "lastName": "silla",
                    "commChannels": [
                        {
                            "type": "email",
                            "accountId": null,
                            "value": "[email protected]",
                            "primary": false,
                            "verified": false,
                            "subscribed": null,
                            "attributes": null
                        },
                        {
                            "type": "mobile",
                            "accountId": null,
                            "value": "917093808678",
                            "primary": false,
                            "verified": false,
                            "subscribed": null,
                            "attributes": null
                        }
                    ],
                    "source": "instore",
                    "accountId": "",
                    "userId": 64035151,
                    "orgSourceId": -1
                }
            ],
            "loyaltyInfo": {
                "attribution": {
                    "createdOn": "2024-01-17T07:00:51.000+0000",
                    "lastUpdatedOn": "2024-04-19T07:39:11.000+0000",
                    "lastUpdatedBy": {
                        "id": 75122513,
                        "code": null,
                        "description": null,
                        "name": null,
                        "type": null
                    },
                    "createdBy": {
                        "id": 75109398,
                        "code": null,
                        "description": null,
                        "name": null,
                        "type": null
                    }
                },
                "loyaltyType": "loyalty",
                "lifetimePurchases": 23508.000
            },
            "customFields": {}
        },
        "targetGroups": [
            {
                "id": 851,
                "attribution": {
                    "createdOn": "2024-04-11T12:10:48.000+0000",
                    "lastUpdatedOn": "2024-04-11T12:10:48.000+0000",
                    "lastUpdatedBy": {
                        "id": 75122513,
                        "code": "till.marketsuper",
                        "description": "",
                        "name": "till.marketsuper",
                        "type": "TILL"
                    },
                    "createdBy": {
                        "id": 75122513,
                        "code": "till.marketsuper",
                        "description": "",
                        "name": "till.marketsuper",
                        "type": "TILL"
                    }
                },
                "name": "JP&A",
                "preferredTillId": 75077502,
                "targets": [
                    {
                        "targetId": 2160795,
                        "periodId": 1807,
                        "periodRefCode": "JP&A1",
                        "periodStartDate": "2024-04-11",
                        "periodEndDate": "2024-04-17",
                        "targetValue": 2.000,
                        "targetAchievedValue": 7.000,
                        "targetName": "JP&A",
                        "targetType": "COUNT",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 427,
                        "enrolledOn": "2024-04-11T12:25:09.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-11T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-04-17T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": 2179901,
                        "periodId": 1808,
                        "periodRefCode": "JP&A2",
                        "periodStartDate": "2024-04-18",
                        "periodEndDate": "2024-04-24",
                        "targetValue": 2.000,
                        "targetAchievedValue": 8.000,
                        "targetName": "JP&A",
                        "targetType": "COUNT",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 427,
                        "enrolledOn": "2024-04-18T10:59:36.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-18T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-04-24T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    }
                ],
                "streaks": [
                    {
                        "userStreakId": 1,
                        "streakId": 19,
                        "streakName": "JP&A11",
                        "status": "ACHIEVED",
                        "currentCount": 2,
                        "totalTargetCountOfSequence": 2,
                        "streakAchievedUserTargetId": 2179901
                    }
                ],
                "targetEvaluationType": "FIXED_CALENDAR_WINDOW",
                "trackingType": "STREAKS"
            },
            {
                "id": 643,
                "attribution": {
                    "createdOn": "2023-12-04T10:26:41.000+0000",
                    "lastUpdatedOn": "2023-12-04T10:26:41.000+0000",
                    "lastUpdatedBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    },
                    "createdBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    }
                },
                "name": "sdcs",
                "preferredTillId": -1,
                "targets": [
                    {
                        "targetId": null,
                        "periodId": 1093,
                        "periodRefCode": "Cycle_1",
                        "periodStartDate": "2023-12-04",
                        "periodEndDate": "2024-01-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2023-12-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-01-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1094,
                        "periodRefCode": "Cycle_2",
                        "periodStartDate": "2024-01-04",
                        "periodEndDate": "2024-02-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-01-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-02-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1095,
                        "periodRefCode": "Cycle_3",
                        "periodStartDate": "2024-02-04",
                        "periodEndDate": "2024-03-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-02-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-03-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1096,
                        "periodRefCode": "Cycle_4",
                        "periodStartDate": "2024-03-04",
                        "periodEndDate": "2024-04-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-03-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-04-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1097,
                        "periodRefCode": "Cycle_5",
                        "periodStartDate": "2024-04-04",
                        "periodEndDate": "2024-05-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-05-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1098,
                        "periodRefCode": "Cycle_6",
                        "periodStartDate": "2024-05-04",
                        "periodEndDate": "2024-06-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-05-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-06-03T23:59:59.000Z",
                        "currentPeriod": true,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1099,
                        "periodRefCode": "Cycle_7",
                        "periodStartDate": "2024-06-04",
                        "periodEndDate": "2024-07-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-06-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-07-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1100,
                        "periodRefCode": "Cycle_8",
                        "periodStartDate": "2024-07-04",
                        "periodEndDate": "2024-08-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-07-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-08-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1101,
                        "periodRefCode": "Cycle_9",
                        "periodStartDate": "2024-08-04",
                        "periodEndDate": "2024-09-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-08-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-09-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1102,
                        "periodRefCode": "Cycle_10",
                        "periodStartDate": "2024-09-04",
                        "periodEndDate": "2024-10-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-09-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-10-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1103,
                        "periodRefCode": "Cycle_11",
                        "periodStartDate": "2024-10-04",
                        "periodEndDate": "2024-11-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-10-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-11-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": null,
                        "periodId": 1104,
                        "periodRefCode": "Cycle_12",
                        "periodStartDate": "2024-11-04",
                        "periodEndDate": "2024-12-03",
                        "targetValue": 1200.000,
                        "targetAchievedValue": 0,
                        "targetName": "sdcs",
                        "targetType": "REGULAR_POINTS",
                        "targetEntity": "POINTS",
                        "targetRuleId": 335,
                        "enrolledOn": "2024-05-07T10:26:56.573+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-11-04T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-12-03T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    }
                ],
                "targetEvaluationType": "FIXED_CALENDAR_WINDOW",
                "trackingType": "CAPPING"
            },
            {
                "id": 854,
                "attribution": {
                    "createdOn": "2024-04-12T07:01:19.000+0000",
                    "lastUpdatedOn": "2024-04-12T07:01:19.000+0000",
                    "lastUpdatedBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    },
                    "createdBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    }
                },
                "name": "efef",
                "preferredTillId": 75050873,
                "targets": [
                    {
                        "targetId": 2162472,
                        "periodId": 1814,
                        "periodRefCode": "Cycle_1",
                        "periodStartDate": "2024-04-12",
                        "periodEndDate": "2024-05-11",
                        "targetValue": 11.000,
                        "targetAchievedValue": 2600.000,
                        "targetName": "efef",
                        "targetType": "GROSS_SALES",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 429,
                        "enrolledOn": "2024-04-12T07:02:39.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-12T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-05-11T23:59:59.000Z",
                        "currentPeriod": true,
                        "milestones": null
                    }
                ],
                "targetEvaluationType": "FIXED_CALENDAR_WINDOW",
                "trackingType": "DEFAULT"
            },
            {
                "id": 871,
                "attribution": {
                    "createdOn": "2024-04-18T11:37:38.000+0000",
                    "lastUpdatedOn": "2024-04-18T11:37:38.000+0000",
                    "lastUpdatedBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    },
                    "createdBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    }
                },
                "name": "Drink a coffee everyday",
                "preferredTillId": 75050875,
                "targets": [
                    {
                        "targetId": 2180118,
                        "periodId": 1896,
                        "periodRefCode": "Cycle_1",
                        "periodStartDate": "2024-04-18",
                        "periodEndDate": "2024-04-18",
                        "targetValue": 1.000,
                        "targetAchievedValue": 130.000,
                        "targetName": "Drink a coffee everyday",
                        "targetType": "QUANTITY",
                        "targetEntity": "LINEITEM",
                        "targetRuleId": 443,
                        "enrolledOn": "2024-04-18T11:53:08.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-18T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-04-18T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": 2181420,
                        "periodId": 1897,
                        "periodRefCode": "Cycle_2",
                        "periodStartDate": "2024-04-19",
                        "periodEndDate": "2024-04-19",
                        "targetValue": 1.000,
                        "targetAchievedValue": 390.000,
                        "targetName": "Drink a coffee everyday",
                        "targetType": "QUANTITY",
                        "targetEntity": "LINEITEM",
                        "targetRuleId": 443,
                        "enrolledOn": "2024-04-19T07:21:32.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-19T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-04-19T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    }
                ],
                "streaks": [
                    {
                        "userStreakId": 5,
                        "streakId": 48,
                        "streakName": "Drink a coffee everyday_1",
                        "status": "INPROGRESS",
                        "currentCount": 2,
                        "totalTargetCountOfSequence": 5
                    }
                ],
                "targetEvaluationType": "FIXED_CALENDAR_WINDOW",
                "trackingType": "STREAKS"
            },
            {
                "id": 872,
                "attribution": {
                    "createdOn": "2024-04-18T11:40:02.000+0000",
                    "lastUpdatedOn": "2024-04-18T11:40:02.000+0000",
                    "lastUpdatedBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    },
                    "createdBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    }
                },
                "name": "Post a picture everyday",
                "preferredTillId": 75050874,
                "targets": [
                    {
                        "targetId": 2180119,
                        "periodId": 1936,
                        "periodRefCode": "Cycle_1",
                        "periodStartDate": "2024-04-18",
                        "periodEndDate": "2024-04-18",
                        "targetValue": 1.000,
                        "targetAchievedValue": 1.000,
                        "targetName": "Post a picture everyday",
                        "targetType": "COUNT",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 444,
                        "enrolledOn": "2024-04-18T11:53:08.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-18T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-04-18T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    },
                    {
                        "targetId": 2181421,
                        "periodId": 1937,
                        "periodRefCode": "Cycle_2",
                        "periodStartDate": "2024-04-19",
                        "periodEndDate": "2024-04-19",
                        "targetValue": 1.000,
                        "targetAchievedValue": 3.000,
                        "targetName": "Post a picture everyday",
                        "targetType": "COUNT",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 444,
                        "enrolledOn": "2024-04-19T07:21:33.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-19T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-04-19T23:59:59.000Z",
                        "currentPeriod": false,
                        "milestones": null
                    }
                ],
                "streaks": [
                    {
                        "userStreakId": 6,
                        "streakId": 52,
                        "streakName": "Post a picture everyday_1",
                        "status": "INPROGRESS",
                        "currentCount": 2,
                        "totalTargetCountOfSequence": 10
                    }
                ],
                "targetEvaluationType": "FIXED_CALENDAR_WINDOW",
                "trackingType": "STREAKS"
            },
            {
                "id": 862,
                "attribution": {
                    "createdOn": "2024-04-16T14:50:21.000+0000",
                    "lastUpdatedOn": "2024-04-16T14:50:21.000+0000",
                    "lastUpdatedBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    },
                    "createdBy": {
                        "id": 75071236,
                        "code": "1675780342_",
                        "description": "",
                        "name": "naresh silla",
                        "type": "ADMIN_USER"
                    }
                },
                "name": "egeger",
                "preferredTillId": 75050874,
                "targets": [
                    {
                        "targetId": 2176896,
                        "periodId": 1841,
                        "periodRefCode": "Cycle_1",
                        "periodStartDate": "2024-04-16",
                        "periodEndDate": "2024-05-15",
                        "targetValue": 11.000,
                        "targetAchievedValue": 2200.000,
                        "targetName": "egeger",
                        "targetType": "GROSS_SALES",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 437,
                        "enrolledOn": "2024-04-17T08:01:05.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-04-16T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-05-15T23:59:59.000Z",
                        "currentPeriod": true,
                        "milestones": null
                    }
                ],
                "targetEvaluationType": "FIXED_CALENDAR_WINDOW",
                "trackingType": "DEFAULT"
            }
        ]
    },
    "errors": null,
    "warnings": null
}

{
    "data": {
        "userId": 547528790,
        "customer": {
            "id": 547528790,
            "profiles": [
                {
                    "firstName": "Anjaney",
                    "lastName": "Vatsal",
                    "commChannels": [
                        {
                            "type": "mobile",
                            "accountId": null,
                            "value": "917897897896",
                            "primary": false,
                            "verified": false,
                            "subscribed": null,
                            "attributes": null
                        }
                    ],
                    "source": "instore",
                    "accountId": "",
                    "userId": 547528790,
                    "orgSourceId": -1
                }
            ],
            "loyaltyInfo": {
                "attribution": {
                    "createdOn": "2023-06-21T15:18:56.000+0000",
                    "lastUpdatedOn": "2023-10-25T14:22:47.000+0000",
                    "lastUpdatedBy": {
                        "id": 75074637,
                        "code": null,
                        "description": null,
                        "name": null,
                        "type": null
                    },
                    "createdBy": {
                        "id": 75036445,
                        "code": null,
                        "description": null,
                        "name": null,
                        "type": null
                    }
                },
                "loyaltyType": "loyalty",
                "lifetimePurchases": 1111.000
            },
            "customFields": {
                "gender": ""
            }
        },
        "targetGroups": [
            {
                "id": 995,
                "attribution": {
                    "createdOn": "2024-02-20T05:45:04.000+0000",
                    "lastUpdatedOn": "2024-02-20T05:45:04.000+0000",
                    "lastUpdatedBy": {
                        "id": 75050734,
                        "code": "1630580928_",
                        "description": "",
                        "name": "Vinodhan Alagasamy",
                        "type": "ADMIN_USER"
                    },
                    "createdBy": {
                        "id": 75050734,
                        "code": "1630580928_",
                        "description": "",
                        "name": "Vinodhan Alagasamy",
                        "type": "ADMIN_USER"
                    }
                },
                "name": "Jotun Painter- buy 10X in 1 month to unlock a voucher",
                "preferredTillId": 75046500,
                "targets": [
                    {
                        "targetId": 9443405,
                        "periodId": 2622,
                        "periodRefCode": "Cycle_3",
                        "periodStartDate": "2024-05-01",
                        "periodEndDate": "2024-05-31",
                        "targetValue": 10.000,
                        "targetAchievedValue": 0,
                        "targetName": "Jotun Painter- buy 10X in 1 month to unlock a voucher",
                        "targetType": "COUNT",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 1059,
                        "enrolledOn": "2024-02-20T05:56:35.000+0000",
                        "eventName": "TransactionAdd",
                        "periodStartDateWithTimeStamp": "2024-05-01T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-05-31T23:59:59.000Z",
                        "currentPeriod": true,
                        "milestones": [
                            {
                                "id": 201,
                                "triggerName": "3",
                                "triggerValue": 3.000000,
                                "isAchieved": false
                            },
                            {
                                "id": 202,
                                "triggerName": "5",
                                "triggerValue": 5.000000,
                                "isAchieved": false
                            }
                        ]
                    },
                    {
                        "targetId": 14174302,
                        "periodId": 2622,
                        "periodRefCode": "Cycle_3",
                        "periodStartDate": "2024-05-01",
                        "periodEndDate": "2024-05-31",
                        "targetValue": 10.000,
                        "targetAchievedValue": 0,
                        "targetName": "Jotun Painter- buy 10X in 1 month to unlock a voucher_ReturnBill",
                        "targetType": "COUNT",
                        "targetEntity": "TRANSACTION",
                        "targetRuleId": 1060,
                        "enrolledOn": "2024-02-20T06:18:59.000+0000",
                        "eventName": "ReturnBill",
                        "periodStartDateWithTimeStamp": "2024-05-01T00:00:00.000Z",
                        "periodEndDateWithTimeStamp": "2024-05-31T23:59:59.000Z",
                        "currentPeriod": true,
                        "milestones": null
                    }
                ],
                "targetEvaluationType": "FIXED_CALENDAR_WINDOW",
                "trackingType": "DEFAULT"
            }
        ]
    },
    "errors": null,
    "warnings": null
}
Language
Authorization
Basic
base64
:
URL
Click Try It! to start a request and see the response here!