Skip to main content
GET
/
v1
/
promotions
/
{campaignId}
/
tiers
List Promotion Tiers from Campaign
curl --request GET \
  --url https://{cluster}.voucherify.io/v1/promotions/{campaignId}/tiers \
  --header 'Authorization: Bearer <token>' \
  --header 'X-App-Id: <api-key>' \
  --header 'X-App-Token: <api-key>'
{
  "object": "list",
  "data_ref": "tiers",
  "tiers": [
    {
      "id": "promo_xyOKjAmysZrwt3aqq1dMUwMU",
      "created_at": "2022-04-07T08:43:53.730Z",
      "updated_at": "2022-08-26T05:22:43.220Z",
      "name": "Amount",
      "banner": "Get $10 off entire order",
      "action": {
        "discount": {
          "type": "AMOUNT",
          "amount_off": 1000,
          "effect": "APPLY_TO_ORDER"
        }
      },
      "metadata": {},
      "hierarchy": 2,
      "promotion_id": "camp_SGq39XXJ47vm7Xys3D0NLgQ0",
      "campaign": {
        "id": "camp_SGq39XXJ47vm7Xys3D0NLgQ0",
        "start_date": null,
        "expiration_date": null,
        "active": true,
        "category_id": "cat_0b5f67863083bf7c05",
        "object": "campaign"
      },
      "campaign_id": "camp_SGq39XXJ47vm7Xys3D0NLgQ0",
      "active": true,
      "summary": {
        "redemptions": {
          "total_redeemed": 1
        },
        "orders": {
          "total_amount": 2187,
          "total_discount_amount": 1000
        }
      },
      "object": "promotion_tier",
      "validation_rule_assignments": null
    },
    {
      "id": "promo_CQonGnrsFAdEJfJQ3oKB3a8G",
      "created_at": "2022-04-07T08:43:53.581Z",
      "updated_at": "2022-08-26T05:22:43.008Z",
      "name": "Percentage",
      "banner": "Get 10% OFF on entire order",
      "action": {
        "discount": {
          "type": "PERCENT",
          "percent_off": 10,
          "effect": "APPLY_TO_ORDER"
        }
      },
      "metadata": {},
      "hierarchy": 1,
      "promotion_id": "camp_SGq39XXJ47vm7Xys3D0NLgQ0",
      "campaign": {
        "id": "camp_SGq39XXJ47vm7Xys3D0NLgQ0",
        "start_date": null,
        "expiration_date": null,
        "active": true,
        "category_id": "cat_0b5f67863083bf7c05",
        "object": "campaign"
      },
      "campaign_id": "camp_SGq39XXJ47vm7Xys3D0NLgQ0",
      "active": true,
      "summary": {
        "redemptions": {
          "total_redeemed": 1
        },
        "orders": {
          "total_amount": 71600,
          "total_discount_amount": 7160
        }
      },
      "object": "promotion_tier",
      "validation_rule_assignments": null
    }
  ],
  "total": 2,
  "has_more": false
}

Authorizations

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

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

campaignId
string
required

Unique campaign ID assigned by Voucherify.

Example:

"camp_rRsfatlwN7unSeUIJDCYedal"

Response

200 - application/json

Returns a dictionary with a tiers property that contains an array of promotion tiers.

Response body schema for GET v1/promotions/{campaignId}/tiers and GET v1/promotions/tiers. Promotion Tiers

object
string
default:list

The type of the object represented by JSON. This object stores information about promotion tiers in a dictionary.

data_ref
string
default:tiers

Identifies the name of the attribute that contains the array of promotion tier objects.

tiers
Promotion Tier · object[]

Contains array of promotion tier objects.

total
integer

Total number of promotion tiers.

has_more
boolean

As query results are always limited (by the limit parameter), the has_more flag indicates if there are more records for given filter parameters. This lets you know if you can run another request to get more records returned in the results.

I