The Delete Product endpoint permanently removes a product document from the database. The server first confirms the product exists — returning aDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/fredy-rizo/tukit/llms.txt
Use this file to discover all available pages before exploring further.
404 if it does not — then verifies that the requesting user holds the admin level 2 role before executing the deletion. Because the operation calls MongoDB’s deleteOne, it is irreversible; there is no soft-delete or recycle-bin mechanism. No request body is required — the product is identified entirely by the productId path parameter.
POST /api/product/remove/:productId
Authentication
| Header | Value | Required |
|---|---|---|
token-access | <your JWT token> | ✅ Yes |
Path Parameters
The MongoDB ObjectId of the product to delete. Returned as
_id when the
product was created or retrieved.Request Body
No request body is required or expected for this endpoint.Response
200 — Product Deleted
"Producto eliminado correctamente"false — note that the server intentionally returns false here to
signal that the product no longer exists.The raw result object returned by MongoDB’s
deleteOne operation.Error Responses
| Status | Condition | status |
|---|---|---|
404 | No product found with the given ID | false |
203 | Authenticated user is not admin level 2 | false |
500 | Unexpected server error | — |
404 — Product Not Found
203 — Not Authorized
Example
Replace
<YOUR_TOKEN> with a valid JWT for an admin level 2 user and
<PRODUCT_ID> with the _id of the product you want to remove.cURL
Success Response