# 注文キャンセル（支払いおよび取引の詳細なし）

ユーザー、パートナー、またはシステムによって支払いがキャンセルされた場合、エクソーラは指定されたURLにorder_canceledウ
ェーブフックを送信します。このウェーブフックには、キャンセルされたアイテムに関する情報と、キャンセルされた注文の詳細が含まれています。

支払いが成功しなかった場合、ウェブフックは送信されません。例：
* 決済UIは開かれましたが、ユーザーが注文の支払いを行われません
* 決済UIが開かれましたが、支払いの実行中にエラーが発生しました

推奨されるウェーブフックの処理時間は3秒以内です。

Endpoint: POST order-cancellation-separate
Version: 1.0

## Request fields (application/json):

  - `custom_parameters` (object)
    追加情報。

  - `items` (array, required)
    ユーザーが購入したアイテムのリスト。

The set of parameters included in the array depends on the webhook version. 
Version 2 includes additional parameters: is_free, is_bonus, and 
is_bundle_content. To switch the version, pass its number in the version 
parameter in the [Update webhook version](/ja/api/catalog/common-webhooks/update-webhook-version/) API call.

  - `notification_type` (string, required)
    通知タイプ。

  - `order` (object, required)
    注文に関する情報。

  - `order.amount` (string, required)
    選択された通貨に基づくカートの合計金額です。

  - `order.comment` (string,null, required)
    注文に対するユーザーのコメント。

  - `order.coupons` (array)
    適用されたクーポン。クーポンが適用されていない場合は、配列は返されません。

  - `order.coupons.code` (string)
    適用されたクーポンのコードです。

  - `order.coupons.external_id` (string)
    External ID。

  - `order.currency` (string, required)
    注文の通貨。仮想通貨はSKUを使用し、実際通貨は3文字の[ISO4217](https://en.wikipedia.org/wiki/ISO_4217)コードを使用します。

  - `order.currency_type` (string, required)
    決済通貨タイプ。無料注文の場合はunknownの値が指定されています。
    Enum: "real", "virtual", "unknown", "loyalty_point"

  - `order.id` (integer, required)
    エクソーラ側でのユーザーの注文の一意の識別子。

  - `order.invoice_id` (string,null, required)
    実際通貨による支払い請求書ID。仮想通貨の決済また無料アイテムは、nullの値を使用します。

  - `order.mode` (string, required)
    決済モード。defaultは実際の支払いに、sandboxはテスト支払いに使用されます。
    Enum: "default", "sandbox"

  - `order.platform` (string,null, required)
    決済プラットフォーム。xsollaの値は、Xsollaを介した支払いに使用されます。その他の支払いについては、ゲームパブリッシングプラットフォームの名前に対応する値が使用されます：playstation_network、xbox_live、pc_standalone、nintendo_shop、google_play、app_store_ios、android_standalone、ios_standalone、android_other、ios_other、pc_other。
    Enum: "xsolla", "playstation_network", "xbox_live", "pc_standalone", "nintendo_shop", "google_play", "app_store_ios", "android_standalone", "ios_standalone", "android_other", "ios_other", "pc_other"

  - `order.promocodes` (array)
    適用されたプロモーションコード。プロモーションコードが適用されていない場合、配列は返されません。

  - `order.promocodes.code` (string)
    適用されたプロモーションコードのコードです。

  - `order.promocodes.external_id` (string)
    External ID。

  - `order.promotions` (array, required)
    注文全体に適用されたプロモーションです。
この配列は、次のいずれかのケースで返されます。：
  - 購入割引 設定のプロモーションコードなど、購入合計金額に影響するプロモーションが設定されている場合。
  - 購入に割引は適用されませんが、ボーナスアイテムが注文に追加される場合。この場合、割引ありのコスト（[amount_with_discount](/ja/webhooks/#operation/order-cancellation!path=order/promotions/amount_with_discount&t=request)）と割引なしのコスト（[amount_without_discount](/ja/webhooks/#operation/order-cancellation!path=order/promotions/amount_without_discount&t=request)）の値が返され、割引が適用されていないため両者は同じ値になります。

注文レベルのプロモーションが適用されていない場合は、空の配列が返されます。

  - `order.promotions.amount_with_discount` (string)
    割引なしのアイテムの総コスト。

  - `order.promotions.amount_without_discount` (string)
    割引なしのアイテムの総コスト。

  - `order.promotions.sequence` (integer)
    プロモーションアプリケーションの注文。

  - `order.status` (string, required)
    注文状況。

  - `user` (object, required)
    ユーザー情報。

  - `user.country` (string)
    ユーザーの国。2文字の国コード（大文字）は、[ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)に従って使用されます。

  - `user.email` (string, required)
    ユーザーのメールアドレス。

  - `user.external_id` (string, required)
    ユーザーID。


## Response 200 fields

## Response 400 fields
