This API allows getting any kind of sellable items or specific item.
- Get virtual currency
Shop Builder API (2.0.0)
- Version: 2.0.0
- Servers:
https://store.xsolla.com/api - Contact Us by Email
- Contact URL: https://xsolla.com/
- Required TLS version: 1.2
Shop Builder API provides a third-party solution for implementing the server side for your store interface. Use the endpoints to manage in-game items, in-game currencies, cart, player inventory, promotions, game library, etc.
Personalized catalog
This API allows to specify rules for user attributes. If the user meets all conditions for a concrete rule, personalized items will be shown.
For personalized promotions see Promotions section.
To pass attributes before a purchase, you can use Xsolla Login API or pass them into user.attributes property while generating token using Pay Station API.
Project ID. You can find this parameter in your Publisher Account next to the name of the project.
Unique item ID. The SKU may contain only lowercase and uppercase Latin alphanumeric characters, periods, dashes, and underscores.
Object with localizations for item’s name. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character language codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s name. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character language codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s description. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s description. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for long description of item. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both variants for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for long description of item. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both variants for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Item's additional assets such as screenshots, gameplay video and so on.
Groups the item belongs to.
List of attributes.
A JSON object containing item attributes and values. Attributes allow you to add more info to items like the player's required level to use the item. Attributes enrich your game's internal logic and are accessible through dedicated GET methods and webhooks.
- Mock serverhttps://xsolla.redocly.app/_mock/api/shop-builder/v2/project/{project_id}/admin/items/virtual_currency
- https://store.xsolla.com/api/v2/project/{project_id}/admin/items/virtual_currency
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
-u <username>:<password> \
https://xsolla.redocly.app/_mock/api/shop-builder/v2/project/44056/admin/items/virtual_currency \
-H 'Content-Type: application/json' \
-d '{
"sku": "com.xsolla.coin_1",
"name": {
"en-US": "Gold coin",
"de-DE": "Goldmünze"
},
"is_enabled": true,
"is_free": false,
"groups": [
"gold"
],
"order": 1,
"description": {
"en-US": "The main currency of your kingdom",
"de-DE": "Die Hauptwährung deines Königreichs"
},
"prices": [
{
"amount": 100,
"currency": "USD",
"is_enabled": true,
"is_default": true
}
],
"attributes": [
{
"external_id": "material",
"name": {
"en-US": "Material"
},
"values": [
{
"external_id": "gold",
"value": {
"en-US": "Gold"
}
}
]
}
],
"limits": {
"per_user": 5,
"per_item": 10000
},
"periods": [
{
"date_from": "2020-08-11T10:00:00+03:00",
"date_until": "2020-08-11T20:00:00+03:00"
}
],
"custom_attributes": {
"purchased": 0,
"attr": "value"
}
}'{ "sku": "com.xsolla.item_1" }
Project ID. You can find this parameter in your Publisher Account next to the name of the project.
- Mock serverhttps://xsolla.redocly.app/_mock/api/shop-builder/v2/project/{project_id}/admin/items/virtual_currency/sku/{virtual_currency_sku}
- https://store.xsolla.com/api/v2/project/{project_id}/admin/items/virtual_currency/sku/{virtual_currency_sku}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
https://xsolla.redocly.app/_mock/api/shop-builder/v2/project/44056/admin/items/virtual_currency/sku/crystalThe specified virtual currency was successfully received.
Unique item ID. The SKU may contain only lowercase and uppercase Latin alphanumeric characters, periods, dashes, and underscores.
Object with localizations for item’s name. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character language codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s name. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character language codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s description. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s description. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for long description of item. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both variants for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for long description of item. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both variants for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Groups the item belongs to.
List of attributes.
Item's additional assets such as screenshots, gameplay video and so on.
Type of item: virtual_good/virtual_currency/bundle/physical_good/unit.
{ "sku": "com.xsolla.crystal_1", "name": { "en": "Crystals", "ru": "Crystals" }, "type": "virtual_currency", "description": { "en": "Main in-game currency" }, "image_url": "https://cdn3.xsolla.com/img/misc/images/da33ab6cc1d7e5899cfdc5b6b6180fad.png", "long_description": null, "attributes": [ { … } ], "is_free": false, "order": 1, "groups": [], "prices": [ { … } ], "media_list": [], "vc_prices": [], "is_enabled": true, "is_show_in_store": true, "regions": [], "is_hard": false, "limits": { "per_user": null, "per_item": null, "recurrent_schedule": null }, "periods": [], "custom_attributes": { "purchased": 0, "attr": "value" } }
Project ID. You can find this parameter in your Publisher Account next to the name of the project.
Unique item ID. The SKU may contain only lowercase and uppercase Latin alphanumeric characters, periods, dashes, and underscores.
Object with localizations for item’s name. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character language codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s name. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character language codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s description. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for item’s description. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both options for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for long description of item. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both variants for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Object with localizations for long description of item. Accepts value in one of two formats: two-letter lowercase language codes (e.g., en) or five-character locale codes (e.g., en-US). While both formats are accepted as input, responses return two-letter lowercase language codes. When both variants for the same language are provided (e.g., en and en-US), the last provided value is stored. You can find the full list of supported languages in the documentation.
Item's additional assets such as screenshots, gameplay video and so on.
Groups the item belongs to.
List of attributes.
A JSON object containing item attributes and values. Attributes allow you to add more info to items like the player's required level to use the item. Attributes enrich your game's internal logic and are accessible through dedicated GET methods and webhooks.
- Mock serverhttps://xsolla.redocly.app/_mock/api/shop-builder/v2/project/{project_id}/admin/items/virtual_currency/sku/{virtual_currency_sku}
- https://store.xsolla.com/api/v2/project/{project_id}/admin/items/virtual_currency/sku/{virtual_currency_sku}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
-u <username>:<password> \
https://xsolla.redocly.app/_mock/api/shop-builder/v2/project/44056/admin/items/virtual_currency/sku/crystal \
-H 'Content-Type: application/json' \
-d '{
"sku": "com.xsolla.coin_1",
"name": {
"en-US": "Gold coin",
"de-DE": "Goldmünze"
},
"is_enabled": true,
"is_free": false,
"groups": [
"gold"
],
"order": 1,
"description": {
"en-US": "The main currency of your kingdom",
"de-DE": "Die Hauptwährung deines Königreichs"
},
"prices": [
{
"amount": 100,
"currency": "USD",
"is_enabled": true,
"is_default": true
}
],
"attributes": [
{
"external_id": "material",
"name": {
"en-US": "Material"
},
"values": [
{
"external_id": "gold",
"value": {
"en-US": "Gold"
}
}
]
}
],
"limits": {
"per_user": 5,
"per_item": 10000
},
"periods": [
{
"date_from": "2020-08-11T10:00:00+03:00",
"date_until": "2020-08-11T20:00:00+03:00"
}
],
"custom_attributes": {
"purchased": 0,
"attr": "value"
}
}'