Skip to main content
POST
/
v1
/
loyalties
/
{campaignId}
/
tiers
Create loyalty tiers
curl --request POST \
  --url https://{cluster}.voucherify.io/v1/loyalties/{campaignId}/tiers \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'X-App-Id: <api-key>' \
  --header 'X-App-Token: <api-key>' \
  --data null
[
  {
    "name": "<string>",
    "earning_rules": {},
    "rewards": {},
    "points": {
      "from": 123,
      "to": 123
    },
    "id": "<string>",
    "campaign_id": "<string>",
    "metadata": {},
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z",
    "config": {
      "points": {
        "from": 123,
        "to": 123
      }
    },
    "expiration": {
      "customer_id": "cust_7iUa6ICKyU6gH40dBU25kQU1",
      "campaign_id": "camp_rRsfatlwN7unSeUIJDCYedal",
      "tier_id": "<string>",
      "start_date": "<string>",
      "expiration_date": "<string>",
      "created_at": "2021-12-22T10:13:06.487Z",
      "updated_at": "2021-12-22T10:13:06.487Z"
    },
    "object": "loyalty_tier"
  }
]

Authorizations

X-App-Id
string
header
required
X-App-Token
string
header
required
Authorization
string
header
required

Path Parameters

campaignId
string
required
Example:

Body

application/json · Loyalty Tier Base · object[]
name
string
required
points
object
required
earning_rules
object
rewards
object
metadata
object

Response

200 - application/json
name
string
required
points
object
required
id
string
required
campaign_id
string
required
metadata
object | null
required
created_at
string<date-time>
required
config
object
required
object
enum<string>
default:loyalty_tier
required
Available options:
loyalty_tier
earning_rules
object
rewards
object
updated_at
string<date-time> | null
expiration
object