Repository navigation
Record API-key write provenance and expose console history queries - #87
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Console resource lists could not distinguish API keys that inherit the same principal, and keys had no write history. Preserve the authenticated key identity, commit write records and creation ownership with the business transaction, and add deployment-authenticated batch ownership and cursor history queries under
/core/v1. The public/v1schema and behavior stay unchanged.Coverage includes Agents, Sessions/events/Artifacts, Environment uploads, Templates, Skills/versions, Files, Vaults and Credentials. Runtime uploads retain safe provenance during preparation and record success with the confirmed PostgreSQL receipt. Creation ownership is permanent; other operations have configurable retention. No payloads, tokens or file contents are logged; no historical ownership is backfilled. Web/console whitelist work is outside this PR.
Validation: per-family real PostgreSQL success/rollback tests; actual Core HTTP acceptance (242 assertions / 24 writes); pinned SDK 3.13.0 CRUD and historical null attribution; real Codex/Kimi Docker execution, upload consumption, events, Artifact deletion, Core restart and cleanup; unchanged public schema; fresh GPT-6 Astra high full-diff blind review passed.
make -k checkran all gates: two old internal test fixtures needed updating for transactional auditing; both corrected tests and the entire Core gate then passed. Every other gate passed in the full run (147 browser cases, 781 Web tests, 409 client tests, 137 Claude tests, installer and Rust checks). Public response assertions are unchanged. The full official Python/Go client consistency script also passed; public/v1schema is byte-identical to main. Small post-review fixture-only corrections were self-reviewed.Console integration and retention contract:
contracts/agents-api/write-audit.md.