# プロモーションコードの特典を入手 このコードによりプロモーションコードの特典を入手します。 ユーザーが多くのアイテムの中から1つをボーナスとして選択できるようにするために使用することができます。 通常のケースでは、プロモーションコードにボーナスとしてゲームが含まれている場合、DRMを選択します(type=unit)。 Endpoint: GET /v2/project/{project_id}/promocode/code/{promocode_code}/rewards Version: 2.0.0 Security: XsollaLoginUserJWT ## Path parameters: - `project_id` (integer, required) プロジェクトID。このパラメータは、パブリッシャーアカウントのプロジェクト名の横にあります。 Example: 44056 - `promocode_code` (string, required) 大文字と小文字を区別する一意のコードです。文字と数字が含まれます。 Example: "SO6rew99j9" ## Response 200 fields (application/json): - `bonus` (array) - `bonus.item` (object) - `bonus.item.description` (string) アイテムの説明。 Example: "Game description" - `bonus.item.image_url` (string) 画像URL。 Example: "https://cdn.xsolla.net/img/misc/images/b79342cdf24f0f8557b63c87e8326e62.png" - `bonus.item.name` (string) アイテム名。 Example: "Game name" - `bonus.item.sku` (string) 一意のアイテムID。SKUには、小文字と大文字のラテン英数字、ピリオド、ダッシュ、およびアンダースコアのみが含まれます。 Example: "game_01" - `bonus.item.type` (string) アイテムタイプ:virtual_good/virtual_currency/bundle/physical_good/unit。 Example: "unit" - `bonus.item.unit_items` (array) アイテムにユニットタイプがある場合は、ユニット内のすべてのアイテムが含まれます。ほとんどの場合、ユーザーはそのうちの1つをプロモーションコードボーナスとして選択する必要があります。 - `bonus.item.unit_items.drm_name` (string) DRM名。 Example: "Steam" - `bonus.item.unit_items.drm_sku` (string) 一意のDRM ID。SKUには、小文字と大文字のラテン英数字、ピリオド、ダッシュ、およびアンダースコアのみが含まれます。 Example: "steam" - `bonus.item.unit_items.is_free` (boolean) trueの場合で、アイテムは無料です。 - `bonus.item.unit_items.type` (string) アイテムタイプ:game_key。 Example: "game_key" - `bonus.quantity` (number) アイテム数量。 - `discount` (object,null) 割引率。 カートの価格は、この割引率で計算された値で減少し、小数点以下2桁に四捨五入されます。 - `discount.percent` (string) Example: "10.00" - `discounted_items` (array,null) プロモーションコードによる割引が適用されるアイテムリスト。 - `discounted_items.discount` (object, required) - `discounted_items.discount.percent` (string, required) 割引率。 カートアイテムの価格は、この割引率で 計算された値で減少し、 小数点以下2桁に四捨五入されます。 Example: "10.00" - `discounted_items.sku` (string, required) アイテムSKU。 - `is_selectable` (boolean) trueの場合、ユーザーはプロモーションコードを引き換える前にボーナスを選択する必要があります。 ## Response 401 fields (application/json): - `errorCode` (integer) Example: 1501 - `errorMessage` (string) Example: "[0401-1501]: Authorization failed: Provide authorization" - `statusCode` (integer) Example: 401 ## Response 403 fields (application/json): - `errorCode` (integer) - `errorMessage` (string) Example: "Authorization header not sent." - `statusCode` (integer) Example: 403 - `transactionId` (string) Example: "x-x-x-x-transactionId-mock-x-x-x" ## Response 404 fields (application/json): - `errorCode` (integer) Example: 4001 - `errorMessage` (string) Example: "[0401-9807]: Enter valid promo code." - `statusCode` (integer) Example: 404