# Live surface capture — 2026-09-12

Evidence for `182.C.40.10` (documentation matches deployed behaviour) and
`182.C.39.03` (the API guide's captured responses). Four responses from a BFF
this session started, not from a schema.

## Method

`apps/oshun/bff/src/server.ts` under `tsx`, on :4010, against the local Postgres
and the staged CPU tools. Secrets were sourced through a throwaway `/tmp` script
that was deleted at the end; none is in this directory, and the captures were
grepped for key material before committing. The server was torn down and `:4010`
confirmed free.

Tokens were minted with `createDevAuthToken`, which is the dev-only
`dev.<base64url>` form the BFF accepts outside production.

## What it corrects

`api-guide.md` opened with **"Nothing here is mounted"** and
`creator-workflow.md` with **"None of this is reachable today"**. Both were true
when written and stopped being true on 2026-09-11, when the surface was mounted
— and more so today, with five adapters bound. A reader of either document would
have concluded the feature does not run. Both now say what runs and point here.

## The boot line

`boot-line.txt`, verbatim:

```
human-video api: 32 endpoints live; bound: preset catalogue; answering 503 until
bound: project drafts, idempotency records, upload sessions (no session table),
identity packs (no pack table), audio takes (no take table), jobs, candidates,
reviews (queue and decisions), releases, erasure, project listing
```

**The three "(no … table)" notes are the finding worth keeping.** The tables
exist — `human_video_upload_session`, `human_video_identity_pack` and
`human_video_audio_take` were applied to `oshun_dev` this session — and the
ports were still unbound, because **the committed generated Prisma client did
not carry the models**. That is `createHumanVideoRuntime` treating a stale
client as no database, deliberately: binding a missing delegate would give
`undefined.findUnique` on the first request, which is a 500 that tells nobody
anything.

> **Correction, later the same day.** This section said the environment's prisma
> CLI "is 6.19 and cannot regenerate the v7 schema". That was wrong. The root
> `pnpm exec prisma` resolves to nothing; `libs/oshun/persistence`'s own
> `node_modules/.bin/prisma` is 7.8.0 and regenerates in about 1.5 seconds. With
> the client regenerated all three ports bind, along with drafts, idempotency
> records and jobs — seven in total. The capture below is what the surface did
> BEFORE that, and it is kept because the scope measurements in it are still
> exact. See `../2026-09-12-jobs-adapter-live/` for the boot line as it stands.

## The four captures

| file                      | request                       | status                                                               |
| ------------------------- | ----------------------------- | -------------------------------------------------------------------- |
| `presets-200.json`        | `GET /presets`, `hv:*`        | **200** — the catalogue, served with no database                     |
| `identity-packs-503.json` | `GET /identity-packs`, `hv:*` | **503** `hv.internal.store_unavailable`, detail naming the operation |
| `presets-403-domain.json` | `GET /presets`, `domain:*`    | **403**                                                              |
| `boot-line.txt`           | —                             | what a 503 means on this deployment                                  |

## The scope boundary, measured

`182.C.40`-relevant, because it is the one thing an entitlement change will
touch. Four more requests to the same endpoint, varying only the token:

| scopes          | status  |
| --------------- | ------- |
| _(none)_        | 401     |
| `hv:*`          | **200** |
| `hv:projects:*` | **200** |
| `domain:*`      | 403     |
| `hv:jobs:*`     | 403     |
| `*`             | 403     |

The wildcard covers the namespace and stops there. `domain:*` is issued to every
signed-in customer, and letting it reach `hv:assets:read` would hand all of them
the tenant's identity packs — which is listing the faces a project was built
from. A bare `*` would be every scope on the platform.

This had only been unit-tested before today; these four requests are the first
time it was exercised against a running server.
