- Platform Overview
- Resources and Guides
-
POS Integration
-
Getting Started
-
Core Concepts
-
Integration SDK
-
Certification
-
- Order Ahead
-
Provider Enablement
-
Provider Enablement
-
Endpoints
-
Developer Endpoints
-
-
API Reference
-
Getting Started
-
v15
-
- Access Tokens
- Campaigns
- Credit Cards
- Users
- Credit
- Locations
- Payment Methods
- QR Codes
- Progress Adjustments
- Orders
- Rewards
- Gift Cards
-
-
v14
-
- Credit
- Access Tokens
-
Campaigns
- Get Details
- Claim
- Get by Cohort
- Claim Legacy
- Get Merchant ID
- Get Image
- Categories
- Credit Cards
- Interstitials
- Locations
- Loyalty
- Orders
- Payment Tokens
- Support Tickets
- Users
-
-
Campaigns .: Claim Legacy
API Reference / v14
Claim a Legacy Loyalty Campaign
This endpoint claims a legacy loyalty campaign via legacy_id
in the body. The :campaign_id
in the URL does not actually indicate which campaign will be targeted as might be expected. Instead, this endpoint will search for a legacy loyalty campaign associated with the app that is associated with the request.
Request Endpoint
POST /v14/loyalties/legacy/:campaign_id/claims
Authorization Required – User Token in Header
Authorization: token 123456-75489120749...
Request Body
{
"legacy_loyalty": {
"legacy_id": "12323"
}
}
Request Parameters
Param | Type | Required | Description |
---|---|---|---|
legacy_id |
String | Yes | The unique identifier of the legacy loyalty card |
cURL Example
curl -X POST -H Accept:application/json -H Content-Type:application/json -H 'Authorization:token 123456-75489120749...' -d '{ "legacy_loyalty": { "legacy_id": "12323", } }' https://api.thelevelup.com/v14/loyalties/legacy/1234567/claims
Example Responses
HTTP/1.1 200 OK
{
"claim": {
"campaign_id" : 6,
"code": "legacy_loyalty_cohort",
"id": 12323,
"value_amount": 1000,
"value_remaining_amount": 1000,
"progress_adjustments": [
{
"adjustment_amount": 3
},
{
"adjustment_amount": 11
},
]
}
}
Response Parameters
Param | Type | Description |
---|---|---|
campaign_id |
Integer | The ID of the legacy loyalty campaign. |
id |
Integer | The ID of the legacy loyalty’s claim. |
code |
String | The legacy loyalty’s cohort code. |
value_amount |
Integer | The original value of the claim. |
value_remaining_amount |
Integer | The remaining value of the claim. |
progress_adjustments[] |
Array | Object representing legacy loyalty’s progress adjustments. |
progress_adjustments [adjustment_amount]
|
Integer | The amount adjusted for each progress adjustment. |
Errors
HTTP/1.1 404 Not found