Creates an order from a specified checkout.
Note: The following requirements must be met for an order to be created from a checkout.
checkout._id
to Get Checkout and take a look at the calculationErrors
field.availability.status
of "AVAILABLE"
or "PARTIALLY_AVAILABLE"
.priceSummary.total
is greater than 0, the billingInfo.address
field must be provided.shippingInfo.shippingDestination.address
and shippingInfo.selectedCarrierServiceOption
fields must be provided.shippingInfo.selectedCarrierServiceOption.logistics.pickupDetails
field must be provided.Checkout ID.
Indicates the payment method should be saved on the order
Indicates whether to authorize the payment and delay the capture
Payment gateway order ID.
For online orders, pass this value as the paymentId
parameter to the Wix Pay startPayment()
function so your customer can pay for the order.
paymentGatewayOrderId
will be returned if money needs to be charged.
In some cases, money cannot be charged:
priceSummary.total.amount
field in the checkout/order objects) is 0. For example, in the case of a free item or an item with a 100% discount.ID of newly created order.
ID of newly created subscription. Learn more about your site's Subscriptions.
curl -X POST 'https://www.wixapis.com/ecom/v1/checkouts/98efbd87-8097-44e9-9005-72093d7a21d5/create-order' \
-H 'Content-Type: application/json' \
-H 'Authorization: <AUTH>' \
{
"orderId": "f2eaeee3-8ade-460c-b622-5b63eec6f75f",
"paymentGatewayOrderId": "42c7ae00-b96c-4e36-9eb9-026667193f13"
}
There is 1 error with this status code.
There are 2 errors with this status code.
There are 13 errors with this status code.
There is 1 error with this status code.
This method may also return standard errors. Learn more about standard Wix errors.