Skip to content

[EDIT] Account_id Param Required when submitting an order as a Guest #93

Answered by logeshswell
m4tt133 asked this question in Help
Discussion options

You must be logged in to vote

@m4tt133 What you see is expected behavior and the order can't be submitted without account.email (or account_id).
Please look into the below section to update email and password (if applicable) to the cart before submitting the order.
https://developers.swell.is/frontend-api/carts#update-cart-account-info

If you want your users to submit the order without authentication, then pass only email_id as follows:

await swell.cart.update({
  account: {
    email: '[email protected]'
  }
})
await swell.cart.submitOrder()

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by logeshswell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
2 participants