Keystash

v0.4.2
io.github.thu-lawyer/keystash Checked 4 days ago Published 1 month ago

Keychain-backed secret broker: an AI agent can use your keys, but no tool ever returns one.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

secret_list

List stored secrets as metadata only: name, tags, rotation policy, last rotation, allowed URLs. Never returns a value.

ParameterTypeDescription
namestringReturn only this entry.
tagstringReturn only entries carrying this tag.

secret_store

Store a secret. The value is collected from the human through a native macOS dialog; it is never passed as an argument and never returned. Use this only when the human is present.

ParameterTypeDescription
name *stringReference name, SERVICE_ENV_PURPOSE, e.g. OPENAI_PROD_KEY.
allowed_urlsarrayURL prefixes this entry may be sent to, each ending with '/'. secret_use refuses every other destination.
auth_headerstringDefault 'Authorization'.
auth_prefixstringDefault 'Bearer '.
rotate_every_daysinteger
tagsarray

secret_rotate

Replace an existing secret's value with a new one collected from the human through a native macOS dialog. Metadata is preserved unless overridden.

ParameterTypeDescription
name *string
allowed_urlsarray
rotate_every_daysinteger
tagsarray

secret_generate

Generate a high-entropy value, store it, and return only a short fingerprint. The value is never returned; the human retrieves it with `keystash copy NAME` (clipboard, auto-cleared).

ParameterTypeDescription
name *string
allowed_urlsarray
lengthinteger
rotate_every_daysinteger
tagsarray

secret_use

Send one HTTP request to an allow-listed URL with the entry's value as its credential. Returns the status and the scrubbed response body. The AI does not choose the credential and cannot read it.

ParameterTypeDescription
name *string
url *stringMust be covered by the entry's allowed_urls.
bodyRequest body: object, string, or omitted.
methodstringDefault GET.
timeoutnumberSeconds, max 300.

secret_delete

Delete a secret and its metadata. Requires a native confirmation dialog from the human; without it nothing is deleted.

ParameterTypeDescription
name *string