List promotions

GET /promotions

Get a list of active promotions with their codes for the current account

Query parameters

  • per_page integer

    Default value is 15.

  • page integer

    Default value is 1.

  • filter[is_active] boolean

    Filter by active status

  • filter[currency_code] string

    Filter promotions by currency code

  • filter[has_codes] boolean

    Filter promotions that have codes

  • filter[stores.id][] array[string(uuid)]

    Filter by store UUIDs

  • filter[tags][] object

    Filter by custom tags

    Hide filter[tags][] attribute Show filter[tags][] attribute object
    • * string Additional properties
  • filter[has_activation_schedule] boolean

    Filter promotions with scheduled activation

  • filter[has_deactivation_schedule] boolean

    Filter promotions with scheduled deactivation

  • sort string

    Sort promotions by one or more fields. Use '-' prefix for descending order. Available fields: name, last_used, created_at, updated_at Default: -updated_at

Responses

  • 200 application/json

    Successful response

    Hide response attributes Show response attributes object
    • data array[object]

      Promotion information for basket operations

      Hide data attributes Show data attributes object
      • id string(uuid)

        Promotion UUID for basket operations

      • eni string

        Entity Number Identifier for basket validation

      • name string

        Promotion display name

      • type string

        Promotion type

        Values are total_order or free_item.

      • currency_code string

        Currency code for the promotion

      • total_order_options object

        Options for total_order type promotions

        Hide total_order_options attributes Show total_order_options attributes object
        • discount_value integer

          Fixed discount amount in cents (mutually exclusive with discount_percentage)

          Minimum value is 1, maximum value is 99999999.

        • discount_percentage number

          Percentage discount as decimal (0.0001 to 1, mutually exclusive with discount_value)

          Minimum value is 0.0001, maximum value is 1.

      • minimum_order_value integer | null

        Minimum order value in cents to apply promotion

      • is_active boolean

        Whether the promotion is currently active

      • codes array[object]

        Available promotion codes (loaded when requested)

        Hide codes attributes Show codes attributes object
        • id string(uuid)
        • code string
        • remaining_uses integer | null

          Number of remaining uses (null for unlimited)

      • stores array[object]

        Stores where this promotion is valid

        Store information needed for API operations

        Hide stores attributes Show stores attributes object
        • id string(uuid)

          Store UUID

        • subdomain string

          Store subdomain used in Store-Subdomain header

        • name string

          Store display name

        • currency object

          Store currency configuration

          Hide currency attribute Show currency attribute object
          • code string

            Currency code (e.g., usd, gbp, eur)

    • meta object
      Hide meta attributes Show meta attributes object
      • current_page integer
      • per_page integer
      • total integer
GET /promotions
curl \
 --request GET 'https://api.gb.enjovia.app/promotions' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": [
    {
      "id": "bcd23456-e89b-12d3-a456-426614174006",
      "eni": "PROMO-2024-001",
      "name": "Summer Sale - 20% Off",
      "type": "total_order",
      "currency_code": "usd",
      "total_order_options": {
        "discount_value": 1000,
        "discount_percentage": 0.2
      },
      "minimum_order_value": 5000,
      "is_active": true,
      "codes": [
        {
          "id": "cde34567-e89b-12d3-a456-426614174007",
          "code": "SUMMER20",
          "remaining_uses": 100
        }
      ],
      "stores": [
        {
          "id": "550e8400-e29b-41d4-a716-446655440000",
          "subdomain": "acme-shop",
          "name": "ACME Store",
          "currency": {
            "code": "usd"
          }
        }
      ]
    }
  ],
  "meta": {
    "current_page": 1,
    "per_page": 20,
    "total": 10
  }
}