Skip to main content
POST
/
extra
/
register
curl -X POST https://api.example.com/extra/register \
  -H "Content-Type: application/json" \
  -b "access_token=YOUR_JWT_TOKEN" \
  -d '{
    "v_name": "Silla Plástica",
    "v_value_add": 5000,
    "v_quantity": 50
  }'
{
  "message": "Registro Exitoso"
}
This endpoint allows you to register a new extra item (such as chairs, tables, tablecloths, etc.) available in the system. The user must be authenticated with a valid JWT token stored in the access_token cookie.

Request Body

v_name
string
required
Name of the extra itemExample: "Silla Plástica" (Plastic Chair)
v_value_add
number
required
Additional cost for the extra item. Must be a positive number.Example: 5000
v_quantity
number
required
Available quantity of the extra item. Must be a positive integer.Example: 50

Response

message
string
Success message confirming the extra was registeredExample: "Registro Exitoso"

Status Codes

200
Success
Extra registered successfully
400
Bad Request
Validation error in the submitted data
401
Unauthorized
Token not sent or invalid (cookie missing or expired)
500
Internal Server Error
Internal server error
curl -X POST https://api.example.com/extra/register \
  -H "Content-Type: application/json" \
  -b "access_token=YOUR_JWT_TOKEN" \
  -d '{
    "v_name": "Silla Plástica",
    "v_value_add": 5000,
    "v_quantity": 50
  }'
{
  "message": "Registro Exitoso"
}

Build docs developers (and LLMs) love