Delete Variation
Delete a variation from a product.
Endpointโ
DELETE /v1/products/{id}/variations/{variationId}
Authenticationโ
Requires an API key with the products:write scope.
Parametersโ
| Parameter | Type | Location | Description |
|---|---|---|---|
id | integer | path | The product ID |
variationId | integer | path | The variation ID |
Responseโ
Success (204 No Content)โ
Returns no content on successful deletion.
Example Requestโ
curl -X DELETE "https://app.equipdash.com/api/v1/products/1/variations/3" \
-H "Authorization: Bearer YOUR_API_KEY"
Errorsโ
| Status | Code | Description |
|---|---|---|
| 401 | authentication_required | No API key provided |
| 403 | insufficient_scope | API key lacks products:write scope |
| 404 | resource_not_found | Product or variation not found |
| 409 | conflict | Variation is used in existing bookings |
Error Response Exampleโ
If the variation is used in bookings:
{
"error": {
"code": "conflict",
"message": "This variation is used in existing bookings and cannot be deleted."
},
"meta": {
"request_id": "req_abc123"
}
}
Important Notesโ
- Variations with existing bookings cannot be deleted
- Deleting a variation also removes its inventory items
- Consider disabling the product instead if you need to preserve history