Loyalty
Endpoints related to Okendo Loyalty
Loyalty
The ID of the Loyalty Customer. Note: May not be used in combination with the email
parameter
The email address of the Loyalty Customer. Note: May not be used in combination with the loyaltyCustomerId
parameter
[email protected]
An object containing basic details about a Loyalty Customer.
Authentication credentials are missing or incorrect.
The requested resource is forbidden.
The requested resource could not be found.
GET /enterprise/loyalty/customers HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Accept: */*
{
"loyaltyCustomer": {
"loyaltyCustomerId": "123e4567-e89b-12d3-a456-426614174000",
"minimumVipTierName": "text",
"points": {
"balance": 1
},
"status": "pending",
"vipTierName": "text"
}
}
Lists the available ways to earn loyalty points. If a Loyalty Customer is specified, this returns ways of earning and amounts tailored to that customer.
The ID of the Loyalty Customer. Note: May not be used in combination with the email
parameter
The email address of the Loyalty Customer. Note: May not be used in combination with the loyaltyCustomerId
parameter
[email protected]
An object containing a list of earning rules.
Authentication credentials are missing or incorrect.
The requested resource is forbidden.
The requested resource could not be found.
GET /enterprise/loyalty/earning_rules HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Accept: */*
{
"rules": [
{
"type": "fixed-amount",
"amount": 1
}
]
}
Lists the available ways to redeem loyalty points for rewards. If a Loyalty Customer is specified, this returns ways of earning and amounts tailored to that customer.
The ID of the Loyalty Customer. Note: May not be used in combination with the email
parameter
The email address of the Loyalty Customer. Note: May not be used in combination with the loyaltyCustomerId
parameter
[email protected]
An object containing a list of redemption rules.
Authentication credentials are missing or incorrect.
The requested resource is forbidden.
The requested resource could not be found.
GET /enterprise/loyalty/redemption_rules HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Accept: */*
{
"rules": [
{
"redemptionRuleId": "123e4567-e89b-12d3-a456-426614174000",
"appliesToCollections": {
"collectionId": 388918313199,
"title": "Clothing",
"url": "https://example.myshopify.com/collections/clothing"
},
"expiresAfterDays": 1,
"minimumPurchase": 1,
"purchaseType": "single",
"recurringCycleLimit": 1,
"type": "fixed-value",
"reward": {
"awardVia": "coupon",
"points": 1,
"value": 1
}
}
]
}
Lists the active coupons for a customer. If a Loyalty Customer is specified, this returns the most recent coupons that have not been used for that customer.
A limit on the number of items returned. Between 1 and 100. Default 25.
25
The URL-encoded JSON object representing the cursor for the next page of results.
The ID of the Loyalty Customer. Note: May not be used in combination with the email
parameter
The email address of the Loyalty Customer. Note: May not be used in combination with the loyaltyCustomerId
parameter
[email protected]
An object containing a list of coupons.
Authentication credentials are missing or incorrect.
The requested resource is forbidden.
The requested resource could not be found.
GET /enterprise/loyalty/coupons HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Accept: */*
{
"coupons": [
{
"code": "OKRX-XXXXX-XXXX",
"description": "$10 off",
"appliesToCollectionIds": [
"shopify-123456789"
],
"appliesToProductIds": [
"shopify-123456789"
],
"displayType": "discount",
"expiryDate": "2025-09-12T16:30:25.334Z",
"maximumShipping": 1,
"minimumPurchase": 1,
"purchaseType": "single",
"recurringCycleLimit": 1,
"value": 10,
"valueType": "fixed_amount"
}
],
"nextUrl": "https://example.com"
}
An object identifying the Loyalty Customer by email
or loyaltyCustomerId
.
The number of points by which the customer's points balance is to be adjusted. Specify either a positive number to add points or a negative number to remove points.
10
Description of the transaction which is displayed to the store owner.
Gifted points due to bad shipping experience
Description of the transaction which is displayed to the Customer.
Gifted Points
The transaction was successfully created and the Loyalty Customer's points balance was updated.
Invalid request parameters.
Authentication credentials are missing or incorrect.
The requested resource is forbidden.
The requested resource could not be found.
The request was well-formed but was unable to be followed due to semantic errors.
POST /enterprise/loyalty/adjustment_transactions HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Content-Type: application/json
Accept: */*
Content-Length: 194
{
"customerIdentifier": {
"loyaltyCustomerId": "123e4567-e89b-12d3-a456-426614174000"
},
"amount": 10,
"internalReason": "Gifted points due to bad shipping experience",
"notificationText": "Gifted Points"
}
{
"loyaltyCustomer": {
"points": {
"balance": 1
}
}
}
The action ID of the custom earning rule.
k2d6ne
An object identifying the Loyalty Customer by email
or loyaltyCustomerId
.
The value to be multiplied with the 'points per' value. Required for Custom Points Per Value Rules.
10
The transaction was successfully created and the Customer was awarded points based on the configured earning rule.
Invalid request parameters.
Authentication credentials are missing or incorrect.
The requested resource is forbidden.
The requested resource could not be found.
The request was well-formed but was unable to be followed due to semantic errors.
POST /enterprise/loyalty/earning_transactions HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Content-Type: application/json
Accept: */*
Content-Length: 114
{
"actionId": "k2d6ne",
"customerIdentifier": {
"loyaltyCustomerId": "123e4567-e89b-12d3-a456-426614174000"
},
"value": 10
}
{
"pointsEarned": 1,
"loyaltyCustomer": {
"loyaltyCustomerId": "123e4567-e89b-12d3-a456-426614174000",
"points": {
"balance": 1
}
}
}
An object identifying the Loyalty Customer by email
or loyaltyCustomerId
.
The unique identifier for the redemption rule.
The redemption transaction was successfully created and the Loyalty Customer's points balance was updated.
Invalid request parameters.
The requested resource is forbidden.
The requested resource could not be found.
Failed to redeem points.
POST /enterprise/loyalty/redemption_transactions HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Content-Type: application/json
Accept: */*
Content-Length: 183
{
"customerIdentifier": {
"loyaltyCustomerId": "123e4567-e89b-12d3-a456-426614174000"
},
"redemptionRuleId": "123e4567-e89b-12d3-a456-426614174000",
"variableValue": {
"points": 100,
"value": 10
}
}
{
"loyaltyCustomer": {
"points": {
"balance": 1000
}
},
"transactionDetails": {
"amount": 100
},
"reward": {
"status": "completed",
"storeCredit": {
"balanceAmount": "100",
"transactionAmount": "10"
},
"type": "store-credit"
}
}
An object identifying the Loyalty Customer by email
or loyaltyCustomerId
.
The name of the VIP Tier, or null to remove a previously configured minimum VIP Tier.
Silver
The Loyalty Customer's minimum VIP Tier was updated, in addition to any resultant change to the current VIP Tier.
Invalid request parameters.
Authentication credentials are missing or incorrect.
The requested resource is forbidden.
The requested resource could not be found.
The request was well-formed but was unable to be followed due to semantic errors.
POST /enterprise/loyalty/customer_minimum_vip_tiers HTTP/1.1
Host: api.okendo.io
Authorization: Basic username:password
Content-Type: application/json
Accept: */*
Content-Length: 113
{
"customerIdentifier": {
"loyaltyCustomerId": "123e4567-e89b-12d3-a456-426614174000"
},
"minimumVipTierName": "Silver"
}
{
"minimumVipTierName": "text",
"vipTierName": "text"
}
Last updated