Skip to content

Commit

Permalink
docs: add more clarification on updating a cart's customer
Browse files Browse the repository at this point in the history
  • Loading branch information
shahednasser committed Nov 19, 2024
1 parent 661ea78 commit 403ce75
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,11 @@ The Update Cart API route accepts a `region_id` request body parameter, whose va

If a guest customer logs in, you must update the cart to be associated with the logged-in customer.

The request to update the cart's associated customer must be authenticated:

- If the customer is authenticated by a session, include `credentials: include` in the fetch requests.
- If the customer is authenticated by a JWT token, include it in the Bearer Authorization header.

<Note>

You can't change the `customer_id` if the cart was associated with a customer previously.
Expand Down

0 comments on commit 403ce75

Please sign in to comment.