[SHOP-5] Create a Cart endpoint Created: 27/Feb/20  Updated: 27/Mar/20  Resolved: 27/Mar/20

Status: Closed
Project: Shop
Component/s: None
Affects Version/s: None
Fix Version/s: 1.0

Type: Story Priority: Neutral
Reporter: Adrien Manzoni Assignee: Riste Drangovski
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Epic Link: REST API
Sprint: Scrum Sprint 1

 Description   
CART
POST /cart If the user is anonymous (unable to fetch the user from the underlying http session), then it creates an anonymous cart.
Otherwise, it create a cart linked to the user id.
 
Return a cookie storing the cart id
false
GET /cart Return the cart
The cart id is taken from the cookie
true
DELETE /cart Delete the cart
The cart id is taken from the cookie
false
POST /cart/item Update the cart by adding the cart item present in the body of the request
The cart id is taken from the cookie
false
PUT /cart/item Update the cart by updating the cart item quantity (only field which can be updated)
The cart id is taken from the cookie
false
DELETE /cart/item/{itemId} Update the cart by deleting the given cart item
The cart id is taken from the cookie
false

Generated at Mon Feb 12 10:48:10 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.