unrelate
End a relationship as of a date by closing its edge with valid_until, removing it from current reads while preserving its history; optionally note a newer relation that supersedes it.
Instructions
End a relation as of a date — the temporal counterpart to relate. Records that a relationship STOPPED being true (someone left a job, a project ended) by closing the edge with a valid_until: it drops out of current reads but its history is PRESERVED (unlike forget, which deletes the edge). Identify the edge by its relations/{uid} or by the (subject, predicate, object) triple (which closes the single open match). Pass endedAt for when it ended (defaults to now); pass supersededBy when a newer relation replaces it.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| object | No | Object of the relation to close: entities/{uid}, a bare ULID, "self", or a display name. | |
| scopes | No | Scopes to search when identifying the edge by triple: project, personal, team. Defaults to project+personal. | |
| endedAt | No | When the relationship ended (RFC 3339 UTC); becomes the edge's valid_until. Defaults to now. | |
| subject | No | Subject of the relation to close: entities/{uid}, a bare ULID, "self", or a display name. Provide with predicate+object as an alternative to relation. | |
| relation | No | The relation to close: relations/{uid} or a bare ULID (as returned by relations() or recall). Use THIS or a (subject, predicate, object) triple, not both. | |
| predicate | No | Predicate of the relation to close, e.g. works_at. | |
| supersededBy | No | Optional relations/{uid} of a newer relation that replaces this one (a correction). Omit for a pure close — the relationship simply ended. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Resource name of the closed relation. | |
| status | Yes | Always "retracted" on success: the edge is closed (valid_until set) but its history is preserved. | |
| validUntil | Yes | The valid_until the relation was closed at (RFC 3339 UTC). |