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

# Grave acts

> The named acts that change the host's own facts: grants, disclosures, erasures, legal holds, branches, pins and task answers.

The six writes change an app's tables. The host's own facts, its `sys`
tables, change only through the **grave acts**: one named verb on a
mutation's `ctx` for each. `bijection check` lists the grave acts of every
function, and `bijection.lock` records them on each path, so a review of the
lock shows every function that can grant a role, erase a unit or land a
branch.

| Act | What it does | Answers |
| - | - | - |
| `ctx.grant(role, { to, under, until?, from?, only? })` | Issue a grant to a principal, agent or invitation bearer at the mutation’s exact commit label | the `Grant` |
| `ctx.revoke(grant, { release })`, `ctx.revoke(selection, { release })` | End exactly that grant, or every live grant a `sys.grants.where({ label, role, holder })` or `where({ label, role, parent })` selection names, with every grant below them. Use `issuer` for trust grants. | the ended `Grant` points |
| `ctx.open(sealed, { release })` | Commit the disclosure audit, then open a sealed value through a declared release. Trials refuse this open. | the clear value |
| `ctx.erase(unit)` | Close a unit (a family member, or an erasable fact) in every version and world. Has no inverse; physical destruction is asynchronous. | the `Erasure` point |
| `ctx.hold(unit, { message })` | Place a legal hold on a unit at the caller's label: destruction waits while the hold stands | the `Hold` |
| `ctx.lift(hold)` | Lift exactly that hold at the caller's label | the hold point |
| `ctx.branch({ from, until, upTo })` | Begin a writable world over a version, ending at `until` (by default, at the end of retention) | the `Branch` |
| `ctx.land(branch, { seen, then, within })` | Apply a branch to its parent, at the version the lander reviewed | a `Task<Version, "Conflict">` |
| `ctx.discard(branch)` | End a branch without landing it | the branch point |
| `ctx.pin(version, { until })` | Keep a version readable within retention (by default, to its end) | the `Pin` |
| `ctx.unpin(pin)` | Stop keeping it | the pin point |
| `ctx.answer(task, result)` | Settle a pending task with a result | the task point |
| `ctx.withdraw(task, { message })` | Settle a pending task as `Withdrawn` | the task point |
| `ctx.retry(obligation, { program })` | Schedule a stuck obligation again | the obligation point |
| `ctx.adopt(taskOrObligation)` | Adopt a blocked task or an obligation stuck on a lapsed grant | the task or obligation point |
| `ctx.withdraw(obligation, { message })` | Close a stuck obligation and keep the task’s result | the obligation point |

Grave acts run in mutations. An act that requires an existing fact refuses `Absent` when the fact is missing or outside the frame’s clearance.

## Read the facts

An ordinary grant is issued at the mutation's exact commit label. Registering
a fresh member issues its declared founder grant as part of registration.
An optional `release` on `revoke` names a declared release when revoking below
the commit label. Direct `ctx.grant(pending, { token })` redemption runs at
the bearer grant's label. The [Members library](https://docs.bijection.com/access/grants.md#membership-directory)
accepts new-member requests at public and queues redemption at the exact member.

`sys` holds the facts the grave acts write: `sys.grants`, `sys.tasks`, `sys.obligations`,
`sys.branches`, `sys.pins`, `sys.holds`, `sys.disclosures`, `sys.erasures` and
`sys.destructions` (written by the host custody collector at `erasable.custody`).
It also holds a platform fact that no act writes: `sys.organizationRegistry`.
Sign-in trust, identity bindings and sessions are rows of `sys.grants`. Read
them with the five reads like any table:

```ts theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
const grant = await ctx.get(sys.grants(id));
const held = await ctx.page(sys.grants.where({ label: ctx.frame.under, role: clerk, holder: sys.grants.holder(principal) }), { size: 50, cursor: null });
const branch = await ctx.get(sys.branches(b)); // { id, from, until }
const registry = await ctx.get(sys.organizationRegistry); // the installation's one fact, or null
```

The system tables expose their write acts through `ctx`. Member and file retirement use `ctx.retire`.
Data verbs that target a system fact refuse `Disallowed` with reason `SysReadOnly`.

## Grants

`ctx.grant` and `ctx.revoke` are how roles reach principals.
[Grants](https://docs.bijection.com/access/grants.md) covers roles, `clear`, `include`, `issue` and the
`members` library that most apps use for them.

## Disclosures

`ctx.open(sealed)` sees a sealed value within the frame's clearance. A
mutation can use `ctx.open(sealed, { release })` to open through a declared
[release](https://docs.bijection.com/access/disclosure.md) and record who did so and when in
`sys.disclosures`. The release must lower from the value's label to an audience
the function's `under` clears. `bijection check` reports incompatible labels.

## Erasure

```ts theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
const erasure = await ctx.erase(tenant.of(org));
const closure = await ctx.get(erasure);
```

`ctx.erase` takes one family member, `family.of(key)`, or the point of an
erasable fact (`table(fields, { erasable: true })`, addressed by its minted key).
It closes the unit in the same commit, writes a `sys.erasures` closure fact,
and returns the `Erasure` point directly (there is no erase task and no
continuation). Once a unit is closed, every read of it refuses `Erased` in
every version and world. See [Data lifetime](https://docs.bijection.com/database/history-and-lifetime.md).
While a [legal hold](https://docs.bijection.com/database/legal-holds.md) of the unit stands at any label,
its reads still close at once, and the host custody collector delays physical
destruction until the public hold cutoff passes and no standing hold remains,
recording destruction in `sys.destructions` at `erasable.custody`.

## Legal holds

```ts theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
const hold = await ctx.hold(tenant.of(org), { message: "Litigation 2026-114: keep until the court releases it" });
// later, in another mutation
await ctx.lift(hold);
```

`ctx.hold` keeps a unit from destruction and records why in `sys.holds`. See
[Legal holds](https://docs.bijection.com/database/legal-holds.md).

## Branches and pins

`ctx.branch`, `ctx.land` and `ctx.discard` are the [branch](https://docs.bijection.com/branches) acts.
A landing's continuation receives `t.result(sys.land)`: the version the
landing committed, or `Conflict` if the branch moved past `seen`.

`ctx.pin(version, { until })` keeps one version readable, and
`ctx.unpin(pin)` lets it go. A pin never keeps a version past history: it is
admitted within the installation's retention (its shortest table `history`,
at most 30 days), measured from the version's commit. Without `until` it
keeps the version to the end of retention, and an `until` past that end
refuses `BeyondHistory`, naming the latest end. `ctx.branch` is admitted the
same way from its version. A table's `pin` option keeps the version or branch a
fact names readable instead; see
[Time and retention](https://docs.bijection.com/database/history-and-lifetime.md).

A version pin also keeps the Program installed at that version. Use
`{ in: version, program: version }` to replay a query at that version.
See [Replay the exact code](https://docs.bijection.com/branches/comparison.md#replay-the-exact-code).

## Task answers

`ctx.answer(task, result)` and `ctx.withdraw(task, { message })` settle tasks of targets
performed by roles, or tasks a performer mutation left open. See
[Effects](https://docs.bijection.com/functions/effects.md).

## Guards on grave acts

Every grave act has a guard scope of the same name: `act.grant(role)`,
`act.revoke(role)`, `act.disclose(release)`, `act.erase()`, `act.hold()`,
`act.lift()`, `act.branch()`,
`act.land()`, `act.discard()`, `act.pin()`, `act.unpin()`, `act.answer(target)`
and `act.withdraw(target)`. A guard refuses the act when its predicate matches;
see [Guards](https://docs.bijection.com/access/guards.md).

## Decided again

The kernel decides a deferred act such as a branch landing again at claim
through the submitter's grants recorded at submit that are still live. The
`then` delivery uses
the authority of the obligation that submit admitted.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.