Skip to content

Delete Entity

Deletes an Entity model from the project’s schema, together with every content entry of that type.

Reference protection

If the model is referenced by a relation field on another model, the deletion is rejected with 409 CONFLICT and nothing is deleted. There is no force override — remove or repoint the referencing field first, then retry.

Endpoint

shell
curl -X DELETE https://api.contentisland.net/api/1.0/model/entity/:id \
--header 'Authorization: Bearer YOUR_WRITE_TOKEN'

Path Parameters

NameTypeRequiredDescription
idstringyesThe 24-character id of the entity to delete.

Example

shell
curl -X DELETE https://api.contentisland.net/api/1.0/model/entity/660f5b8a3a1c2d4e7f8b9012 \
--header 'Authorization: Bearer YOUR_WRITE_TOKEN'

Response

On success the endpoint returns 204 No Content with an empty body.

Status Codes

CodeDescription
204The model and its content were deleted.
401Unauthorized. The token is missing, malformed or expired.
403Forbidden. The token does not have write permissions — use a Write Token.
404No entity with the given :id exists in the project.
409The model is referenced by a field on another model and cannot be deleted. Remove the reference first.
500Internal server error.