コンテンツへスキップ

Shop Builder API (2.0.0)

Overview

  • 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.

OpenAPI記述をダウンロード
言語
サーバー
Mock server
https://xsolla.redocly.app/_mock/ja/api/shop-builder/
https://store.xsolla.com/api/
操作

個人用カタログ

ユーザー属性に応じたルールを指定することができるAPIです。 ユーザーが具体的なルールの条件をすべて満たした場合、パーソナライズされたアイテムが表示されます。

パーソナライズされたプロモーションについては、プロモーションセクションを参照してください。

購入前に属性を渡すには、Xsolla Login APIを使うか、Pay Station APIを使ってトークンを生成する際にそれをuser.attributesプロパティに渡します。

操作
操作
操作

カート(クライアント側)

操作

カート(サーバー側)

操作

決済(クライアント側)

操作

決済(サーバー側)

操作
操作

無料アイテム

操作

ウェブフック

操作
操作

マーチャント

操作

カタログ

このAPIは販売可能なアイテムや特定のアイテムを取得することができます。

操作
操作
操作
操作
操作
操作

すべてのプロモーションリストを取得Server-sideAdmin

リクエスト

プロジェクトのプロモーションリストを取得します。

セキュリティ
basicAuth
パス
project_idinteger必須

プロジェクトID。このパラメータは、パブリッシャーアカウントのプロジェクト名の横にあります。

例: 44056
クエリ
limitinteger>= 1

ページでの要素数の制限。

例: limit=50
offsetinteger>= 0

リストが生成される要素番号(カウントは0から始まります)。

例: offset=0
enabledinteger

is_enabledフラグで要素を絞り込みます。

curl -i -X GET \
  -u <username>:<password> \
  'https://xsolla.redocly.app/_mock/ja/api/shop-builder/v3/project/44056/admin/promotion?limit=50&offset=0&enabled=0'

レスポンス

プロモーションのリストが正常に受信されました。

ボディapplication/json
active_promotions_countinteger(active_promotions_count)

アクティブなプロモーションの数。

inactive_promotions_countinteger(inactive_promotions_count)

非アクティブ化されたプロモーションの数。

promotionsArray of objects(Promotions_200-get-promotion-model)
total_promotions_countinteger(total_promotions_count)

プロモーションの合計数。

レスポンス
application/json
{ "active_promotions_count": 3, "inactive_promotions_count": 2, "promotions": [ {}, {}, {}, {}, {} ], "total_promotions_count": 5 }

コードで引き換え可能なプロモーションを入手するServer-sideAdmin

リクエスト

プロモーションコードまたはクーポンコードを取得します。

セキュリティ
basicAuth
パス
project_idinteger必須

プロジェクトID。このパラメータは、パブリッシャーアカウントのプロジェクト名の横にあります。

例: 44056
codestring[ 1 .. 128 ] characters必須

大文字と小文字を区別する一意のコードです。文字と数字が含まれます。

例: WINTER2021
curl -i -X GET \
  -u <username>:<password> \
  https://xsolla.redocly.app/_mock/ja/api/shop-builder/v3/project/44056/admin/promotion/redeemable/code/WINTER2021

レスポンス

プロモーションは正常に受信されました。

ボディapplication/json
bonusArray of objects or null(Promotions_coupon_bonus)
discountobject or null

プロモーションコード限定。

例: {"discount":{"percent":"10.99"}}
discounted_itemsArray of objects or null

プロモーションコードによる割引が適用されるアイテムのリスト。 プロモーションコード限定。

external_idstring(Promotions_coupon-external_id)

一意のプロモーションID。external_idには、小文字と大文字のラテン英数字、ピリオド、ダッシュ、およびアンダースコアのみが含まれます。

デフォルト "coupon_external_id"
例: "coupon_external_id"
is_enabledboolean(Promotions_coupon-is_enabled)
デフォルト true
nameobject(Promotions_coupon_name)

プロモーションの名前。キーと値のペアを含む必要があります。 キーは"^[a-z]{2}-[A-Z]{2}$"形式のロケール、値は文字列です。

デフォルト {"de-DE":"Gutscheintitel","en-US":"Coupon title"}
例: {"de-DE":"Gutscheintitel","en-US":"Coupon title"}
promotion_periodsArray of objects(promotion_periods)

プロモーションの有効期間。複数の期間を指定する場合は、date_fromdate_untilの両方が必須となります。

redeem_code_limitinteger or null(Promotions_redeem_code_limit)

コードごとの引き換え回数。

デフォルト 10
例: 10
redeem_total_limitinteger or null(Promotions_coupon-redeem_total_limit)

クーポンの総数を制限します。

デフォルト 10
例: 10
redeem_user_limitinteger or null(Promotions_coupon-redeem_user_limit)

一人のユーザーが引き換えできるクーポンの総数を制限します。

デフォルト 10
例: 10
total_limit_stateobject or null(Promotions_coupon_total_limit_state)

各クーポンコードには制限があります。

レスポンス
application/json
{ "bonus": [ {} ], "external_id": "coupon_fall_hammer_2", "is_enabled": true, "name": { "en": "This is a Coupon code for Epic Fall Hammer", "ru": "Eto kod kupona на Epic Fall Hammer" }, "promotion_periods": [ {}, {} ], "redeem_code_limit": null, "redeem_total_limit": 99, "redeem_user_limit": 1 }

クーポン

このAPIを使用すると、クーポンを管理できます。

操作

プロモーションコード

このAPI を使用すると、プロモーションコードを管理できます。

操作

ユニークなカタログオファー

このAPIを使用すると、ユニークなカタログオファーを管理することができます。

操作

ディスカウント

このAPIを使用すると、割引キャンペーンを管理することができます。

操作

ボーナス

このAPIを使用すると、ボーナスプロモーションを管理できます。

操作
操作
操作
操作
操作
操作

クライアント

操作

クランクライアント

操作
操作

クライアント

操作
操作

クライアント

操作
操作

クライアント

操作
操作