Manual Tier Adjustment

This API allows for manual adjustment of a customer's loyalty tier (slab), including upgrading, downgrading, renewing the current tier, or extending its expiry date.

Prerequisites

  • Authentication: Basic/OAuth authentication
  • Access group: Default access group

Resource Information

URIv2/slab/manualSlabAdjustment
HTTP MethodPOST
PaginationNo
Batch supportNA
Rate limit informationNA

API Endpoint Example

https://eu.api.capillarytech.com/v2/slab/manualSlabAdjustment?identifierName=id&identifierValue=8124102&source=INSTORE

Query Parameters

Parameter Name
(Parameters marked as * are mandatory)
Data TypeDescription
source*StringSource of customer information. Supported values:
INSTORE,FACEBOOK,WEB_ENGAGE,WECHAT,MARTJACK,TMALL,TAOBAO,JD,ECOMMERCE,WEBSITE,LINE,MOBILE_APP
identifierName*StringIdentifier type to identify the customer. Supported values: mobile, id, externalId
identifierValue*StringValue corresponding to the identifierName provided.
typeStringType of entity to adjust the tier. Supported values: CUSTOMER, USERGROUP2.

Request Body Example

{
    "programId": 973,
    "toSlabName": "Emerald",
    "slabAction": "UPGRADE",
    "manualSlabActionValidity": "FIXED_DURATION",
    "manualSlabActionValidityUpto": "20",
    "reassessTierOnNextActivity": true,
    "slabChangeReason": "Won the tier giveaway"
}

Request Body Parameters

Parameter (Parameters marked as * are required)Data TypeDescription
programId*IntegerUnique ID of the loyalty program. To retrieve the programId , use the Get Loyalty Programs API.
slabAction*EnumType of slab change being performed. Supported values:
UPGRADE: Upgrade the customer's tier to a higher tier.
DOWNGRADE: Downgrade a customer's tier to a lower tier.
RENEWAL: Renew this customer's current tier.
EXTEND_CURRENT_TIER_EXPIRY_DATE: Extend the customer's current tier expiry date.
toSlabNameStringName of the slab to upgrade or downgrade the customer to. This parameter is required if slabAction = UPGRADE or DOWNGRADE. For example, to downgrade a customer from "Gold" to "Silver”, provide the value as "Silver".
manualSlabActionValidity*EnumValidity period for the tier change. Supported values:
FIXED_DURATION: Extends the slab expiry by a fixed number of days
SPECIFIC_DATE: Sets the slab expiry to a specific date
CURRENT_TIER_EXPIRY_DATE: Maintains the current slab's expiry date
AS_PER_TIER_STRATEGY: Calculates the expiry date based on the expiration strategy defined by the loyalty program.
manualSlabActionValidityUpto*LongDate or number of days the customer's tier upgrade or downgrade is valid till.
If manualSlabActionValidity = FIXED_DURATION: Provide a numerical value. For example to extend the expiry by 15 days, provide this value as 15.
If manualSlabActionValidity = SPECIFIC_DATE: Provide the date till when the tier is valid in YYYY-MM-DD format. For example to extend the expiry till 20th April, 2025, provide this value as 2025-04-20.
reassessTierOnNextActivityBooleanSpecify if the customer's tier during their next transaction or activity should be re-evaluated. The value is false by default.
true: The system will reassess the customer's tier during their next activity.
false: No automatic reassessment will occur during the next activity and the tier upgrade will expire based on the expiry strategy defined.
slabChangeReasonStringReason for changing, renewing or extending the customer's tier. Character limit: 255 characters.

Response Body

{
    "programId": 973,
    "entityId": 424134447,
    "sideEffects": [
        {
            "entityType": "USER",
            "previousSlabName": "Ruby",
            "previousSlabNumber": 2,
            "upgradedSlabName": "Emerald",
            "upgradedSlabNumber": 3,
            "slabExpiryDate": "30th Nov, 2025",
            "type": "slab"
        }
    ],
    "warnings": []
}
{
    "programId": 2834,
    "entityId": 424134447,
    "sideEffects": [
        {
            "entityType": "USER",
            "previousSlabName": "GOLD",
            "previousSlabNumber": 3,
            "upgradedSlabName": "Silver",
            "upgradedSlabNumber": 2,
            "slabExpiryDate": "30th Nov, 2025",
            "type": "slab"
        }
    ],
    "warnings": []
}
{
    "programId": 2834,
    "entityId": 424134447,
    "sideEffects": [
        {
            "entityType": "USER",
            "previousSlabName": "GOLD",
            "previousSlabNumber": 3,
            "upgradedSlabName": "GOLD",
            "upgradedSlabNumber": 3,
            "slabExpiryDate": "30th Nov, 2025",
            "type": "slab"
        }
    ],
    "warnings": []
}

Response Body Parameters

ParameterDescription
programIdUnique ID of the loyalty program.
entityIdUnique ID of the customer whose slab was adjusted.
sideEffectsObject containing details of the tier adjustment.
- entityTypeType of entity part of the tier adjustment. Possible values: USER, USERGROUP2
- previousSlabNameCustomer's slab name before the adjustment.
- previousSlabNumberNumerical representation of the previous slab. For example, if the slab was the third slab in the order, the value will be 3.
- upgradedSlabNameCustomer's slab name after the adjustment.
- upgradedSlabNumberNumerical representation of the upgraded or downgraded slab. For example, if the slab was the second slab in the order, the value will be 2.
- slabExpiryDateNew expiry date of the customer's slab.
- typeType of side effect. Possible value: slab
warningsObject containing warnings, if any.
Language
Credentials
Basic
base64
:
URL
Click Try It! to start a request and see the response here!