@superjackfruitlabs/treaty-ecosystem-identity 0.0.14 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/corpus/token_vectors.json +1012 -0
- package/dist/access-token.d.ts +58 -0
- package/dist/access-token.js +171 -0
- package/dist/index.d.ts +8 -1
- package/dist/index.js +6 -0
- package/dist/jwks-cache.d.ts +23 -0
- package/dist/jwks-cache.js +69 -0
- package/package.json +4 -1
package/README.md
CHANGED
|
@@ -36,6 +36,7 @@ repo boundary instead of a language boundary.
|
|
|
36
36
|
| `matrix_gate_events.json` | The two events a superpipeline approval gate crosses Matrix on: the gate the board asks, and the decision a human sends back. Pins the v1 option ids against superpipeline's `GateDecision`, and records the four fields superpipeline#34 proposed that do not exist. Since version 3 it also pins gate.v2 and decision.v2 (charter `decisions/2026-11-07-gate-v2-is-the-decision-envelope.md`): options as the gate offers them, a subject-bound gate's subject and preview, and the answer's subject binding. The hub validates them in `apps/hub/src/services/board-chat/gates.test.ts`. Since version 4 it also pins question.v2, question.answer.v2, delivery.v2 and delivery.answer.v2 (charter: the decision envelope covers questions and follow-ups): a question's options with their meaning and input, free text, the follow-up a manual delivery owes, and gate.outcome.v1, the receipt that closes a gate's or a follow-up's card. The hub validates them in `question.test.ts` and `delivery.test.ts` beside it. Since version 5 (charter: strict decisions and harness permissions bind their subject) it also pins a subject-bound question.v2 and its answer (entries with `variant: "subject-bound"`: the subject, option `scope` / `requires`, the answer's binding), and AgentPod's own `dev.agentpod.permission.v2`, `dev.agentpod.permission.answer.v2` and `dev.agentpod.permission.outcome.v1`. The hub validates them in `question-subject.test.ts` and `permission-v2.test.ts`. Since version 6 (charter: waiting cards and broker approvals reach chat) it also pins `dev.superpipeline.attention.v2` (a card waiting on a person: its wait id, reason and the resume / archive options), `dev.superpipeline.attention.answer.v2` and `dev.superpipeline.attention.outcome.v1`, and a SuperToolkit approval request as a board-less, `stk-capability/v1` subject-bound question.v2 and its answer (entries with `variant: "approval-request"`). The hub validates them in `attention.test.ts` and `approval-request.test.ts`. Since version 7 (charter: unanswered decisions remind, then escalate) it also pins `deadline { remind_at?, escalate_at? }` on gate.v2, question.v2, delivery.v2 and attention.v2 (entries with `variant: "deadline"`), a gate closed as `expired` (`gate.outcome.v1`, `variant: "expired"`), and the two notices posted in reply to a waiting card, `dev.superpipeline.decision.reminded.v1` and `dev.superpipeline.decision.escalated.v1`. The hub validates them in `decision-timeout-wire.test.ts`. Since version 8 (charter: a gate may offer a choice of variants) it also pins a variant gate (entries with `variant: "choice"`): its gate.v2 carrying `subject { variants: [{ id, label, subject }] }` with no identity of its own, each variant bounded and withheld on its own, its v1 fallback that offers no approval, the decision.v2 whose binding is the variant chosen, and the receipt naming it (`chosen_variant`). The hub validates them in `gate-variants.test.ts`. Since version 9 (charter: a gate may need more than one approver) it also pins a quorum gate (entries with `variant: "quorum"`): its gate.v2 carrying `quorum { required, from, approvals: [{ principal_id, at, variant_id? }] }` beside the options, the quorums that must not be carried, `dev.agentpod.gate.progress.v2` (the progress posted for an approval short of the quorum), and the decision.v2 with the two board refusals of a quorum approval (`QUORUM_ALREADY_APPROVED`, `APPROVAL_DECIDER_NOT_ALLOWED`) and what is said for each. The hub validates them in `gate-quorum.test.ts`. Since version 10 (charter: an approval may wait for its release time) it also pins a held gate (entries with `variant: "release"`): its gate.v2 carrying `release { hold_for_minutes?, not_before? }` and the releases that must not be carried, the held approval's `gate.outcome.v1` with `held_until`, `dev.agentpod.decision.released.v2` (released and blocked) and `dev.agentpod.decision.pulled_back.v2` posted in reply to the gate's card, `dev.superpipeline.gate.pull_back.v2` (the pull-back a person sends, and one refused without a comment) with the board's refusals of it, and the decision.v2 refusal `APPROVAL_RELEASE_AFTER_EXPIRY`, each with what is said. The hub validates them in `gate-release.test.ts`. Since version 11 (charter: a gate may be decided by checks) it also pins a gate decided by checks (entries with `variant: "checks"`): its gate.v2 carrying `checks [{ name, provider, status, url? }]` and the lists that must not be carried, `dev.agentpod.check.failed.v2` (returned, and parked replying to the open checks.waiting card) and `dev.agentpod.check.overridden.v2` with what is said for each, the reminder (standalone) and escalation of overdue checks (`decision_kind: "checks"`), `dev.agentpod.checks.waiting.v2` (the card an escalation posts, which an override references), and `dev.superpipeline.check.override.v2` (the override a person sends, and one refused without a comment) with the board's refusals of it and what is said. The hub validates them in `gate-checks.test.ts`. |
|
|
37
37
|
| `card_prompt.json` | The prompt contract: what a card becomes when it is handed to a harness, assembled from the card, the previous stage's handoff, the card's references and (since `card-prompt/4`) its comment thread. Pins the **rendered text**, not only the shape. |
|
|
38
38
|
| `token_claims.json` | The access-token claims every product verifies — **v9**, the organization plane's shape (`org`, `ent`, `jti`; `aud` a string or an array; no `tenant`). Since v9 it is also the organization plane's own copy: accounts kept a separate `fixtures/token_claims.json` that had drifted, and the two were merged here, adding `superlibrary` to `ent`, the OAuth-only claims a consumer ignores, more reject cases and one valid example token per kind of caller. treaty's `packages/ecosystem-identity/test/token-claims.test.ts` checks the examples against the claims. AgentPod pins v8 in its `packages/contract/src/token-claims.ts`. AgentPod's hub keeps minting the v7 shape until its issuer is removed; that copy is frozen at `apps/hub/src/auth/testdata/token_claims.v7.json`. |
|
|
39
|
+
| `token_vectors.json` | Signed access tokens and what every verifier must answer for each: the claims, or one refusal code from a closed set. It holds a **test-only** Ed25519 key (public, derived from a printed seed: never trust it), the JWKS a verifier is given, and one case per `token_claims.json` example and reject case, plus the edges of the rules every verifier shares: 30 s of leeway on `exp`, `nbf` and `iat`, a lifetime of at most 300 s, a required `kid`, Ed25519 keys only, `sub` and `org` in the id grammar, `jti`, `mayDispatch` and `mayGrantReach` required, and any `mayDispatch` value that is not a prn refusing the whole token. `scripts/token-vectors.ts` writes it (`--check` fails when it is stale). treaty's `verifyAccessToken()` passes every case; a verifier in any other language is conformant when it does too. |
|
|
39
40
|
|
|
40
41
|
All of them are plain JSON and depend on no type from any repo. That is deliberate — a corpus that
|
|
41
42
|
needed AgentPod's schemas to be readable could not be checked into superpipeline.
|