---
title: "getRelatedEntitiesCount"
method: GET
path: "/v2/entity/{slug}/{id}/relations/count"
tags: ["Relations"]
---

# getRelatedEntitiesCount

`GET /v2/entity/{slug}/{id}/relations/count`

Returns the amount of unique related entities for an entity - includes direct and reverse relations.

## Path parameters

- `slug` string, required — URL-friendly identifier for the entity schema
- `id` string, uuid, required

## Query parameters

- `exclude_schemas` EntitySlug[]

## Response `200`

Success

- GetRelatedEntitiesCount
  - `hits` integer

## Other responses

- `404` — The requested resource was not found

---

[API](https://skmtc.net/epilot/apis/entity-api.md) · [All operations](https://skmtc.net/epilot/apis/entity-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/epilot/entity-api/versions/8dd3d44e1c4f/schema)
