Delete a work item relation definition
Remove a custom relation definition from the workspace. A successful delete returns 204 with an empty body.
Plane then removes every relation that uses the definition, in the background, across all projects. To retire a relation type and keep its relations, update it with is_active: false instead.
The definition's name and labels become free, so a new definition can reuse them.
The three default definitions can't be deleted. Deleting one returns 400.
You need to be a workspace owner or admin, and the workspace's plan must include custom relations, or the response is 402.
Path parameters
slug:requiredstringThe workspace slug. It appears in your Plane URLs. In https://app.plane.so/my-team/projects/, the slug is my-team.
pk:requiredstring (uuid)The id of the relation definition to delete.
Response shaping
fields:optionalstringComma-separated list of fields to return. Fields you don't request are left out of the response instead of coming back as null, so a missing key means you didn't ask for it and null means the value is null. id is always included, whether or not you name it.
Pass all to get every requestable field. An unknown field name returns 400 with the list of valid names and the closest match, so a typo is caught instead of being silently ignored.
Requestable here: color, created_at, created_by_id, description, external_id, external_source, id, inward, is_active, is_default, logo_props, name, outward, sort_order, updated_at, updated_by_id.
See Sparse fields.
Scopes
workspaces.work_item_relation_definitions:write
Errors
| Status | Code | Cause |
|---|---|---|
400 | invalid_request | The definition is a default one, so it can't be deleted. |
401 | unauthorized | Missing or invalid credentials. |
402 | payment_required | Custom relations aren't included in the workspace's plan. |
403 | forbidden | You aren't a workspace owner or admin, or your token scope doesn't allow this. |
404 | not_found | No such definition or workspace, or it's outside your tenant. |
406 | not_acceptable | The Accept header asks for a representation the API can't produce. |
409 | governance_migration_in_progress | A governance migration is running in this workspace, so writes are paused. Retry after it finishes. |
413 | payload_too_large | The request body is over the size limit. |
415 | unsupported_media_type | The Content-Type isn't one this endpoint accepts. |
429 | rate_limited | Throttled. Honor the Retry-After header before retrying. |
A repeat delete returns 404
The second call for the same id returns 404 not_found, because the definition is already gone. Treat 404 on retry as success.
curl -X DELETE \
"https://api.plane.so/api/v2/workspaces/my-team/work-item-relation-definitions/7a4c9e12-5f3b-4d68-8e01-2b6d9f4a3c85/" \
-H "X-Api-Key: $PLANE_API_KEY"import requests
response = requests.delete(
"https://api.plane.so/api/v2/workspaces/my-team/work-item-relation-definitions/7a4c9e12-5f3b-4d68-8e01-2b6d9f4a3c85/",
headers={"X-Api-Key": "your-api-key"},
)
print(response.status_code)const response = await fetch(
"https://api.plane.so/api/v2/workspaces/my-team/work-item-relation-definitions/7a4c9e12-5f3b-4d68-8e01-2b6d9f4a3c85/",
{
method: "DELETE",
headers: {
"X-Api-Key": "your-api-key",
},
},
);
console.log(response.status);No response body.
{
"type": "invalid_request",
"code": "invalid_request",
"detail": "A default relation definition cannot be deleted."
}
