# Get all promotion list

Gets the list of promotions of a project.

Endpoint: GET /v3/project/{project_id}/admin/promotion
Version: 2.0.0
Security: basicAuth

## Path parameters:

  - `project_id` (integer, required)
    Project ID. You can find this parameter in your Publisher Account next to the project name and in the browser address bar when working with a project. The URL has the following format: https://publisher.xsolla.com//projects/.
    Example: 44056

## Query parameters:

  - `limit` (integer)
    Limit for the number of elements on the page.
    Example: 50

  - `offset` (integer)
    Number of the element from which the list is generated (the count starts from 0).

  - `enabled` (integer)
    Filter elements by is_enabled flag.

## Response 200 fields (application/json):

  - `promotions` (array)

  - `promotions.id` (integer)
    Promotion ID. Unique promotion identifier within the project.

  - `promotions.promotion_periods` (array)
    Promotion validity periods. If multiple periods are specified, both date_from and date_until are required.

  - `promotions.promotion_periods.date_from` (string, required)
    Start date for the specified promotion.
    Example: "2020-08-11T10:00:00+03:00"

  - `promotions.promotion_periods.date_until` (string,null)
    End date for the specified promotion. If set to null, the promotion is indefinite. Can be null only if a single validity period is specified.
    Example: "2020-08-11T20:00:00+03:00"

  - `promotions.name` (object)
    Name of promotion. Should contain key/value pairs
where key is a locale with "^[a-z]{2}-[A-Z]{2}$" format, value is string.

  - `promotions.bonus` (array)

  - `promotions.bonus.item` (object)

  - `promotions.bonus.item.sku` (string)
    Unique item ID. The SKU may contain only lowercase and uppercase Latin alphanumeric characters, periods, dashes, and underscores.
    Example: "game_01"

  - `promotions.bonus.item.name` (object)
    Item name.
    Example: {"en":"Game name"}

  - `promotions.bonus.item.type` (string)
    Type of item. Possible values:virtual_good — virtual itemsvirtual_currency — virtual currencybundle — bundleunit — game key package
    Example: "unit"

  - `promotions.bonus.item.bundle_type` (string)
    Bundle type. Returned if item type is a bundle.
    Enum: "standard", "virtual_currency_package"

  - `promotions.bonus.item.description` (string,null)
    Item description.
    Example: "Game description"

  - `promotions.bonus.item.image_url` (string,null)
    Image URL.
    Example: "https://cdn.xsolla.net/img/misc/images/b79342cdf24f0f8557b63c87e8326e62.png"

  - `promotions.bonus.item.content` (array)

  - `promotions.bonus.item.unit_items` (array)
    Array of platform-specific game keys. Used only when the item type is unit (bonus.item.type = 'unit'). If the game key package includes platform-specific keys, the user can choose one of them as a bonus.

  - `promotions.bonus.item.unit_items.sku` (string)
    Unique platform-specific game key package ID. Allowed characters: a–z, A–Z, 0–9, period (.), hyphen (-), underscore (_). It combines bonus.item.​sku and bonus.item.unit_items.drm_sku values. E.g., if bonus.item.​sku = 'cool_game' and bonus.item.unit_items.drm_sku = 'steam', the value will be cool_game_steam.
    Example: "cool_game_steam"

  - `promotions.bonus.item.unit_items.is_free` (boolean)

  - `promotions.bonus.item.unit_items.type` (string)
    Indicates that the item is a game key.
    Enum: "game_key"

  - `promotions.bonus.item.unit_items.name` (string)
    Game title.
    Example: "Awesome Game"

  - `promotions.bonus.item.unit_items.drm_name` (string)
    DRM name.
    Example: "Steam"

  - `promotions.bonus.item.unit_items.drm_sku` (string)
    Unique DRM ID used as a suffix to indicate a platform-specific game key. Allowed characters: a–z, A–Z, 0–9, period (.), hyphen (-), underscore (_).
    Example: "steam"

  - `promotions.bonus.quantity` (number)
    Item quantity.

  - `promotions.condition` (array,null)

  - `promotions.condition.item` (object)

  - `promotions.condition.item.sku` (string)
    Unique item ID. The SKU may contain only lowercase and uppercase Latin alphanumeric characters, periods, dashes, and underscores.

  - `promotions.condition.item.name` (object)
    Name of item. Should contain key/value pairs
where key is a locale with "^[a-z]{2}-[A-Z]{2}$" format, value is string.

  - `promotions.condition.item.type` (string)
    Type of item: virtual_good/virtual_currency/bundle/physical_good/unit.

  - `promotions.condition.item.description` (string,null)
    Item description.
    Example: "Game description"

  - `promotions.condition.item.image_url` (string,null)
    Image URL.
    Example: "https://cdn.xsolla.net/img/misc/images/b79342cdf24f0f8557b63c87e8326e62.png"

  - `promotions.condition.item.external_id` (string)
    Promotion external ID. Unique promotion identifier within the project.

  - `promotions.condition.item.is_enabled` (boolean)

  - `promotions.condition.item.redeem_total_limit` (integer,null)

  - `promotions.condition.item.redeem_user_limit` (integer,null)

  - `promotions.condition.item.redeem_code_limit` (integer,null)
    Number of redemptions per code.

  - `promotions.is_enabled` (boolean)

  - `promotions.type` (string)
    Promotion type.

  - `promotions.discount` (object,null)
    Example: {"discount":{"percent":"10.99"}}

  - `promotions.discount.percent` (string,null)
    Percent discount.
The price of cart will be decreased using a value calculated by using this percent and then rounded to 2 decimal places.

  - `promotions.limits` (object)
    Promotion limits.

  - `promotions.limits.per_user` (object,null)
    Promotion limitation for a separate user.

  - `promotions.limits.per_user.total` (integer)
    Total number of items a user can purchase. You can set this number in Publisher Account or use admin endpoints for Store entities (limits object).
    Example: 5

  - `promotions.limits.per_item` (integer,null)
    Global item limitation.
    Example: 10

  - `promotions.limits.recurrent_schedule` (object,null)
    Limit refresh period.

  - `promotions.limits.recurrent_schedule.per_user` (any)
    User limit refresh period.

  - `total_promotions_count` (integer)
    Total number of promotions.

  - `active_promotions_count` (integer)
    Number of active promotions.

  - `inactive_promotions_count` (integer)
    Number of deactivated promotions.

## Response 401 fields (application/json):

  - `statusCode` (integer)
    Example: 401

  - `errorCode` (integer)
    Example: 1020

  - `errorMessage` (string)
    Example: "[0401-1020]: Error in Authentication method occurred"


