Service URL: DELETE /baskets/{basketReference}/items/{lineNumber}
Tokens:
basketReference – The basket reference of the basket to remove the item from. The basket reference can be a basketId or PRIMARY for a primary basket
lineNumber – The line number to remove from the basket
Remarks:
Deletes an existing line number from a basket.
Scenarios
Scenario | Outcome | Expected behaviour | Status Code | Response | |
---|---|---|---|---|---|
1 | Service is given a valid lineNumber and basketReference so the item is removed from the basket | success | The basket item is removed. | 200 | 200 Success ok |
2 | Service is given a invalid lineNumber and a valid basketReference | NotFound | Service returns a bad request | 400 | Error Message: Item could not be removed from the basket with reference: <BasketReference> |
Example Request:
1DELETE: http://localhost:8080/WebRestApi/rest/baskets/PRIMARY/items/2 |
Example Response:
1Status: 200 OK