---
title: "Delete Relation (deleteRelation)"
method: DELETE
path: "/api/relation"
tags: ["entity-relation-controller"]
---

# Delete Relation (deleteRelation)

`DELETE /api/relation`

Deletes a relation between two entities in the platform. 

If the user has the authority of 'System Administrator', the server checks that 'from' and 'to' entities are owned by the sysadmin. If the user has the authority of 'Tenant Administrator', the server checks that 'from' and 'to' entities are owned by the same tenant. If the user has the authority of 'Customer User', the server checks that the 'from' and 'to' entities are assigned to the same customer.

## Query parameters

- `fromId` string, required
- `fromType` string, required
- `relationType` string, required
- `relationTypeGroup` string
- `toId` string, required
- `toType` string, required

## Response `200`

OK

---

[API](https://skmtc.net/thingsboard/apis/thingsboard-rest-api.md) · [All operations](https://skmtc.net/thingsboard/apis/thingsboard-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/thingsboard/thingsboard-rest-api/revisions/40169ccdec5c/schema)
