Keys for agents and apps
How signing keys, secrets and permissions work today for agents, apps and pages, where they differ, and a proposal to give apps keys of their own on the same code agents use.

The question

An agent can sign: it holds keys, its owner grants those keys write access, and it publishes Seed documents. An app cannot: its tools hold no key and cannot reach the Seed node at all. So any app job that touches the app's own data (a shopping list, a feedback record, a nightly summary) has had to be done by an agent session instead. That is backwards. This note compares how keys, secrets and permissions work in each part of the system today, and proposes one model for agents and apps.

Today

Agents

    Keys. An agent signs with signing identities: Ed25519 keys created or imported on the app environment (the agents server) with CreateSigningIdentity / ImportSigningIdentity. Each key is a row in the secrets table, encrypted with AES-256-GCM under the server's secret key, labelled kind: hm-account-key with its account id.

    Attachment. The agent's definition lists the keys it may use (signingKeys), and one of them is the primary (signingKey). Writes sign as the primary unless the agent picks another.

    Authority. A key is just an account. What it may write comes from capabilities: when an agent is created, its owner chooses its write access (its own document, the whole space, or none), and the desktop grants a WRITER capability on that path to the agent's key. Writers can be added later, as WRITER capabilities on the agent's document.

    Other secrets. Model provider keys and other secrets live in the same secrets table and are referenced by name (secretRefs).

    Audit. Every write is part of a session or run transcript, signed by the key it names.

Apps

    Keys. None. An app's tools run in a sandbox with network access but no Seed client and no key. They cannot read the app's records or publish anything; records must be passed in as input.

    Secrets. The app's private config (API keys such as a SerpAPI key) is one JSON blob per running app, encrypted with the same server key, in app_runs.private_config_ciphertext, and handed to every tool as ctx.privateConfig.

    Who runs it. Whoever starts the app on a server (app_runs.started_by) must be a writer of the app's space. Starting it is not a grant of anything else.

    Triggers. An app's trigger calls one of its tools. The call is recorded as made by the trigger's author, but nothing is signed, because nothing can be.

    Audit. Every tool call is recorded (app_tool_calls), readable by anyone who can read the tool.

Pages

    Keys. A page runs in the viewer's browser and signs as the viewer, through the page permission prompt (one "Save …" approval per save). It writes only what the viewer may write.

    Tools. A page calls its app's tools as the viewer (seed.app.call), after the viewer allows it.

Users

    Keys. Users hold their own keys (desktop vault, web sign-in). Every request to the agents server is an envelope signed by the user's key, or by a device key the account delegated to with a capability.

Side by side


Agent

App tool

Page

Holds a key

yes, hosted on the server

no

no (borrows the viewer's)

Where keys live

secrets, encrypted

none

viewer's device

How authority is given

WRITER capability to its key, chosen at creation

none possible

the viewer's own access

Other secrets

secrets by name (secretRefs)

private config blob

none

Can use a model

yes (its provider)

only by calling an API itself

no

Recorded as

its key, in its transcript

the caller, in tool calls

the viewer

What is wrong with it

    Apps cannot touch Seed. The most common app jobs are data jobs on the app's own records. Without keys they need an agent, which costs a model session per job, ties the app to an agent's existence and access, and makes the app's behaviour live somewhere else. (We just removed the "app trigger runs an agent" workaround for exactly this reason.)

    Two secret stores. Agents reference named secrets; apps carry an anonymous blob. Rotating a key, seeing which ones exist, or sharing one between an app and an agent works differently in each.

    Authority is set up differently. Agents get capabilities through a creation-time choice and the People tab; apps have no way to be given anything.

    "Who runs the app" stands in for "who the app acts as". Today it only gates who may start it, but it is the nearest thing to an app identity, and it is a person, not the app.

Proposal: hosted identities, one model for agents and apps

A hosted identity is what an agent's signing identity is today: an Ed25519 key held, encrypted, by the app environment, owned by an account, with a label. Nothing about it is agent-specific. The proposal is to make it a first-class thing that can be attached to either an agent or an app, with the same code for creating, importing, attaching, granting and signing.

    Create or import once, attach to anything. CreateSigningIdentity / ImportSigningIdentity stay as they are. An agent's definition lists its keys (signingKeys, primary) as now; an app's run gets the same list, set in the app's Settings ("Keys: Recipe Box key"). One key per app is the default; reusing an agent's key for an app is allowed but shown.

    Grant with capabilities, in the same UI. Authority stays where it belongs: capabilities from the space owner to the key, scoped to paths. The app's Settings shows "This app can write: Shopping Lists, Feedback", with Add access granting a WRITER capability on a collection, exactly like adding a writer on the People tab. An app made under an agent's document can be offered the obvious grants at creation, the way an agent's write access is chosen today.

    Tools get Seed access through the server. A tool gets ctx.seed (read, query, publish), a client whose writes the server signs with the app's key. The tool code never sees the key. The server checks that the key is attached to this app and that the target is within its capabilities before signing, and records each publish on the tool call. Reads of public content need no grant; private reads use a reader capability.

    One secret store. App private config moves into the secrets table and is referenced by name, like model provider keys (privateConfig: {serpApiKey: {secret: "serpapi"}}). Settings lists what an app uses; rotating a secret updates every app and agent that names it.

    Model access the same way. An app may name a model provider (secretRefs), giving tools ctx.model. Summaries and digests become the app's own work, with its own provider and cost.

    Run as the viewer, as an option. A tool called from a page could run with the viewer's authority instead of the app's (the page already asks the viewer). That suits per-person data. Default stays the app's key.

With that, an app's trigger calls a tool that reads the week's recipes, writes the shopping list and signs it as the Recipe Box, in seconds and with no agent. Agents keep doing what only they can: conversations, judgement, building and maintaining apps.

What becomes the same code

    Key custody: one secrets table, one encryption, one create/import path.

    Attachment: a list of key names on a principal (an agent's definition, an app's run).

    Authority: capabilities to the key, granted from the People/Access UI.

    Signing: one server-side signer used by the agent's write verb and the tools' ctx.seed.publish, checking attachment and capability, recording what it signed.

    Secrets and models: named secrets and providers, referenced the same way.

Steps

    Move app private config into the secrets table (named references), keeping the old blob readable.

    Let an app's run name signing keys; show and edit them in the app's Settings.

    Add ctx.seed to the tool runtime: reads first, then publish through the shared signer with capability checks and audit on the tool call.

    App Settings: "This app can write", granting capabilities with the People-tab component.

    ctx.model with a named provider.

    Update the agent guides: data work an app does is a tool on an app trigger; agents build and repair apps.

Open questions

    Whose key is it? A hosted identity belongs to an account on one server. If someone else runs the same app elsewhere, they get their own key and their own grants. Is that right, or should an app's identity be portable (exported with the app)?

    Per-app or per-tool scopes? Capabilities are per key. Per-tool limits would need a key per tool or a server-side policy on top.

    Private reads. What does it mean for an app to read private documents, and who may grant that?

    Rotation and revocation. Revoking a capability is not available yet for every case (removed editors). The app Settings should at least show what each key can do and let you detach it.

    Viewer mode. When a tool runs as the viewer, which device key signs, and how long does the permission last?

Do you like what you are reading? Subscribe to receive updates.

Unsubscribe anytime