Xsolla-logoXsolla Developers
или
Личный кабинет

Получение списка виртуальных предметовClient-side

get/v2/project/{project_id}/items/virtual_items

Gets a virtual items list for building a catalog.

Attention

All projects have the limitation to the number of items that you can get in the response. The default and maximum value is 50 items per response. To get more data page by page, use limit and offset fields.

Note

In general, the use of catalog of items is available without authorization.
Only authorized users can get a personalized catalog.
SecurityXsollaLoginUserJWT
Request
path Parameters
project_id
required
integer

ID проекта. Вы можете найти этот параметр в Личном кабинете рядом с названием проекта.

Example: 44056
query Parameters
limit
integer

Лимит количества элементов на странице.

Example: limit=50
offset
integer

Номер элемента, с которого выполняется вывод на странице (нумерация ведется с 0).

Example: offset=0
locale
string
Default: "en"

Язык ответа. Двухбуквенный код языка в нижнем регистре в соответствии с ISO 639-1.

additional_fields[]
Array of strings

Список дополнительных полей. Эти поля будут указаны в ответе, если вы отправите их в своем запросе.

Items Enum: "media_list" "order" "long_description" "custom_attributes"
country
string

Two-letter uppercase country code per ISO 3166-1 alpha-2. Check the documentation for detailed information about countries supported by Xsolla and the process of determining the country.

Example: country=US
promo_code
string [ 1 .. 128 ] characters

Уникальный код, чувствительный к регистру. Содержит буквы и цифры.

Example: promo_code=WINTER2021
show_inactive_time_limited_items
integer
Default: 0

Отображает предметы с ограниченным сроком действия, которые недоступны пользователю. Срок действия таких предметов еще не начался или уже истек.

Example: show_inactive_time_limited_items=1
Responses
200

Список виртуальных предметов успешно получен.

Request samples
curl -i -X GET \
  'https://store.xsolla.com/api/v2/project/{project_id}/items/virtual_items?limit=50&offset=0&locale=en&additional_fields%5B%5D=media_list&country=US&promo_code=WINTER2021&show_inactive_time_limited_items=1' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'
Response samples
application/json
{
  • "has_more": true,
  • "items": [
    ]
}