Delete a model
DELETE/api/v1/models/{model_id}
Overview
Soft-delete a model owned by your account. Returns its ID and deleted: true; subsequent lookup and repeated deletion return 404, and lists exclude it. The linked file remains protected. A model referenced by any order, including a cancelled order, cannot be deleted.
Requires models:write.
Parameters
model_id path · required
Public model ID returned in id; pass unchanged.
Immutable model ID: MD- followed by eight uppercase Crockford Base32 characters. Use this same ID in the website, URLs and API; pass it unchanged.
string
Responses
Model deleted.
200 response
JSON
{
"id": "MD-739YQ549",
"deleted": true
}id string · required
Immutable model ID: MD- followed by eight uppercase Crockford Base32 characters. Use this same ID in the website, URLs and API; pass it unchanged.
Min length: 11 · Max length: 11
deleted boolean · required
Always true.
Always: true
Response headers
X-Request-IDRequest identifier for support. Send X-Request-ID with 8–64 ASCII letters, digits or hyphens to reuse that value; otherwise the server generates a UUID4 hex value. Include the returned X-Request-ID in support requests. Do not put secrets or account IDs in this value.
Errors
| HTTP | Code | What to do |
|---|---|---|
| 401 Unauthorized | unauthenticated | The API key is missing, invalid or revoked. Send a valid business API key in Authorization: Bearer. |
| 403 Forbidden | permission_denied | The key lacks the endpoint's scope, or payments lack spending consent. Check the scope listed on the endpoint. |
| 404 Not Found | model_not_found | No model with this ID exists in the account, or it was deleted. Check the ID. |
| 409 Conflict | model_in_use | An order uses this model, so it cannot be deleted. |
| 500 Internal Server Error | internal | The server failed unexpectedly. Retry with backoff; contact support with X-Request-ID if it persists. |
| 503 Service Unavailable | unavailable | A required service is briefly unavailable. Retry with backoff, reusing the same Idempotency-Key. |
API v1 preview