# Successful payment for order (without payment and transaction details) Xsolla sends the order_paid webhook to the specified URL when the following conditions are fulfilled: 1. The user successfully paid for the order. 2. Xsolla received a response about the successful processing of payment webhook. The order_paid webhook contains information about the purchased items and transaction details. The order_paid webhook is not sent if: * The payment was not successful, for example: * the payment form was opened, but the user did not pay for the order * the payment form was opened, but there were errors during the payment * The response about the successful processing of the payment webhook has not been received. It is recommended that the processing time of the order_paid webhook is less than 3 seconds. The expected answers are described in the Responses section. You can use other response codes. Depending on the response code and the connection of the automatic payment refund functionality, the webhook processing logic on Xsolla’s side is as follows: Response code Automatic payment refund is disabled (by default) Automatic payment refund is enabled 400, 401, 402, 403, 404, 409, 422, 415 No actions Automatic refund to the user 200, 201, 204 No actions No actions Different code or no response to webhook Multiple webhooks are sent within a specified time interval: 2 attempts with a 5-minute interval, 7 attempts with a 15-minute interval, 10 attempts with a 60-minute interval. Multiple webhooks are sent within a specified time interval: 2 attempts with a 5-minute interval, 7 attempts with a 15-minute interval, 10 attempts with a 60-minute interval. If all webhooks are sent but a successful response is not received, an automatic refund is issued to the user. To connect the automatic refund functionality, contact your Customer Success Managers or email to csm@xsolla.com. Endpoint: POST successful-order-payment-separate Version: 1.0 ## Request fields (application/json): - `notification_type` (string, required) Notification type. - `items` (array, required) List of items purchased by the user. 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 information about webhook settings](/api/igs/operation/update-webhook/) API call. - `order` (object, required) Information about the order. - `order.id` (integer, required) Unique identifier of the user's order on the Xsolla’s side. - `order.mode` (string, required) Payment mode. default is used for real payments; sandbox for test payments. Enum: "default", "sandbox" - `order.currency_type` (string, required) Payment currency type. For a free order, unknown value is specified. Enum: "real", "virtual", "unknown", "loyalty_point" - `order.currency` (string, required) Currency of order. Virtual currency uses the SKU and real currency uses a three-letter [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code. - `order.amount` (string, required) The total cost of a cart based on the chosen currency. - `order.status` (string, required) Order status. - `order.platform` (string,null, required) Payment platform. The xsolla value is used for payments via Xsolla. For other payments, the value corresponding to the name of the game publishing platform is used. 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.comment` (string,null, required) User’s commentary to the order. - `order.invoice_id` (string,null, required) Real currency payments invoice ID. Virtual currency payments or free items have a null value. - `order.promotions` (array, required) Applied promotions for the entire order. The array is returned in the following cases: - A promotion affects the total purchase amount, such as a promo code with the Discount on purchase setting. - No discount is applied to the purchase, but bonus items are added to the order. In this case, the values for the cost with discount ([amount_with_discount](/webhooks/#operation/order-cancellation!path=order/promotions/amount_with_discount&t=request)) and without discount ([amount_without_discount](/webhooks/#operation/order-cancellation!path=order/promotions/amount_without_discount&t=request)) are returned and identical, since no discount is applied. If no order-level promotions are applied, an empty array is returned. - `order.promotions.amount_without_discount` (string) Total cost of items without a discount. - `order.promotions.amount_with_discount` (string) Total cost of items with a discount. - `order.promotions.sequence` (integer) Order of promotions application. - `order.coupons` (array) Applied coupons. If the coupon isn’t applied, the array doesn’t return. - `order.coupons.code` (string) The code of an applied coupon. - `order.coupons.external_id` (string) External ID. - `order.promocodes` (array) Applied promocodes. If the promocode isn’t applied, the array doesn’t return. - `order.promocodes.code` (string) The code of an applied promocode. - `user` (object, required) User information. - `user.external_id` (string, required) User ID. - `user.email` (string, required) User email address. - `user.country` (string) User’s country. Two-letter uppercase [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code. - `custom_parameters` (object) Additional information. ## Response 200 fields ## Response 400 fields