> ## Documentation Index
> Fetch the complete documentation index at: https://docs.withheadlight.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Schema reference

# Embed schema reference (v1)

The chart payload is validated with Zod in `lib/embed/chart-input.schema.ts`.

## Top-level shape

| Field                         | Type   | Required                             |
| ----------------------------- | ------ | ------------------------------------ |
| `v`                           | `1`    | yes                                  |
| `people`                      | array  | yes                                  |
| `relationships`               | array  | yes                                  |
| `trusts`                      | array  | yes                                  |
| `entities`                    | array  | yes                                  |
| `options`                     | object | no                                   |
| `options.perspectivePersonId` | string | no; opens the chart from that person |

## Caps

* Up to 500 total nodes across people, trusts, and entities
* Up to 1000 relationships

## URL fields

The schema rejects URL-shaped leaf fields (`href`, `src`, `avatarUrl`, etc.). The CSP `img-src 'self' data:` is the real control; the schema guard is defense in depth.

## Referential integrity

Relationship endpoints, trustee links, beneficiary links, and ownership owner IDs must resolve to IDs present in the payload.
