Deprecated.
This function will continue to work until September 4, 2024, but a newer version is available at
wix-ecom-backend.Orders.createOrder()
.
We recommend you migrate to the new Wix eCommerce APIs as soon as possible.
If this function is already in your code, it will continue to work.
To stay compatible with future changes, migrate to
wix-ecom-backend.Orders.createOrder()
.
To migrate to the new function:
Add the new import statement:
Look for any code that uses wixStoresBackend.createOrder()
,
and replace it with orders.createOrder()
.
Update your code to work with the new createOrder()
response properties.
Test your changes to make sure your code behaves as expected.
Creates a new order.
The createOrder()
function returns a Promise that resolves to an Order
object when the order has been created.
Note: Do not pass important information from client-side code. Doing so opens a vulnerability that a malicious user can exploit to change information, such as a buyer’s personal details (address, email, etc.) or product price information. To learn more about how to keep your code secure, see Security Considerations When Working with Wix Code.
The information for the order being created.