# Legal entity (single) A legal entity is owned by exactly one client. Each legal entity owns its own accounts and depositories. The `client`, `accounts`, and `depositories` relationships are NOT mutable via PATCH — accounts / depositories are added through their dedicated POST endpoints, and a legal entity cannot move between clients. ## Endpoints GET /v2/legal-entities/:id Fetch one legal entity. PATCH /v2/legal-entities/:id Update mutable attributes (only `name`). DELETE /v2/legal-entities/:id Delete the legal entity. Rejected if it owns any account, depository, or transaction history. GET /v2/legal-entities/:id/accounts POST /v2/legal-entities/:id/accounts Manage accounts under the legal entity. GET /v2/legal-entities/:id/depositories POST /v2/legal-entities/:id/depositories Manage depositories under the legal entity. GET /v2/legal-entities/:id/custodian-authorities POST /v2/legal-entities/:id/custodian-authorities Manage custodian authorities under the legal entity — see `aleta api --spec /v2/custodian-authorities/:id` for the data model. ## Path params id (required) — Legal-entity identifier (Mongo ObjectID). ## Attributes (`type: legal-entity`) name (string) — Display name. ## Relationships client — The client that owns the legal entity (read-only). accounts — Accounts owned by the legal entity (read-only here). depositories — Depositories owned by the legal entity (read-only here).