Delete Variant (Admin)
Soft delete a product variant for admin.
Endpoint
Authentication
Required (Admin role)
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
id |
integer | Yes | Variant ID |
product_id |
integer | Yes | Product ID |
Response
Success (200 OK)
Error Responses
Product Not Found (404)
Variant Not Found (404)
Missing ID Parameter (400)
Example Request
curl -X DELETE "https://api.luxmart.site/v1/products/variant/admin/?id=1&product_id=5" \
-H "Authorization: Token your_access_token"
Notes
- Performs a soft delete (sets
is_deleted: true) - Variant must belong to the specified product
- Deleted variants cannot be retrieved or purchased
- Admin can delete variants from any store