---
title: "Set Parent"
method: POST
path: "/v1/entities/{entity_id}/parent"
tags: ["entities"]
---

# Set Parent

`POST /v1/entities/{entity_id}/parent`

## Request

- Base URL: `https://api.bitpoort.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.bitpoort.com/v1/entities/{entity_id}/parent`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Set/clear an entity's parent ("Binance US" under "Binance"). Rejects a
cycle (a child may never become its own ancestor); audited as a reparent
op in the append-only merge log.

## Path parameters

- `entity_id` integer, required

## Request body

- SetParentRequest
  - `parent_entity_id` integer, nullable, required: Parent entity (e.g. Binance for 'Binance US'); null clears the parent

## Response `200`

Successful Response

- object

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/bitpoort/apis/bitpoort-api.md) · [All operations](https://skmtc.dev/bitpoort/apis/bitpoort-api/llms.txt) · [OpenAPI document](https://skmtc.dev/bitpoort/apis/bitpoort-api/revisions/1a51d8566777?raw)
