Endpoints Specifications

Type Name Description Function Auth Parameters Return Type
GET /cart/get/:id Retrieves the cart item from the database with the given ID. GetCartItem API Key Cart Item ID
Type: Integer Cart Item
GET /cart/all/:user_id Retrieves all cart items for a user from the database. GetCartItems API Key User ID
Type: Integer Cart Items
POST /cart/add Inserts a cart item into the database. AddCartItem API Key Cart Object Cart Item
POST /cart/add/all Insert multiple cart items for a user. AddCartItems API Key Cart Items
{ data } Cart Items
{ data }
PUT /cart/update Updates a cart item in the database. UpdateCartItem API Key Cart Object Cart ID
Type: Integer
DELETE /cart/delete/:id/user/:user_id Deletes a cart item from the database. DeleteCartItem API Key Cart Item ID
Type: Integer
User ID
Type: String Cart ID
Type: Integer

Endpoints Return Data Specifications

GET /cart/get/:id

GET /cart/all/:user_id

POST /cart/add

PUT /cart/update

Endpoints Request Parameters Specifications

POST /cart/add

PUT /cart/update

Client Code Helpers

This section providers some helpers for designing the client-side code to consume the Cart service from the Plamatio backend REST API.

Endpoints Text Summary

Can use this as a prompt for a code-completion AI model.

GET
/cart/get/:id
Retrieves the cart item from the database with the given ID.

GET
/cart/all/:user_id
Retrieves all cart items for a user from the database.

POST
/cart/add
Inserts a cart item into the database.

PUT
/cart/update
Updates a cart item in the database.

DELETE
/cart/delete/:id
Deletes a cart item from the database.

Endpoint Definitions

Endpoint definitions to store Cart service endpoints in a central location.