Skip to main content
Glama

Attach a stored secret to an app

bind_app_secret
Idempotent

Attach a secret that is already stored in the account vault to one app, under the environment variable name the app reads, and restart the app. Call this when the user says the key already exists in Dockhold (call list_secrets to see the names), or when a second app should use the same stored value: nothing passes through your context and no value is stored again. Sharing one entry between apps means they share the value; if the user wants separate credentials per app, store a new value with set_app_secret under a distinct vault_key_name instead. This token can attach any secret on the account to any app on the account.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameNoThe environment variable name the app code reads. Defaults to vault_key_name.
app_idYesThe app id returned by list_apps
vault_key_nameYesThe stored secret's name in the account vault, as list_secrets reports it

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (mutation, idempotent), the description discloses the restart side effect, the privacy-critical fact that 'nothing passes through your context and no value is stored again,' and the broad authorization scope ('any secret on the account to any app'). These are behavioral traits an agent cannot infer from the schema or annotations. The restart detail coexists with idempotentHint=true without a direct contradiction.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four sentences, front-loaded with the core action, followed by usage conditions, a caveat with the alternative, and a security note. Every sentence carries distinct, necessary information; nothing is repeated from the schema.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers action, side effect, when/when-not, alternative, sharing semantics, and token authorization — with annotations covering idempotency and safety. The only gap is that no output or success confirmation is described, which matters slightly more because there is no output schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% and each parameter already has a descriptive comment, so the baseline is 3. The description adds value by clarifying that reusing a vault_key_name across apps means they 'share the value,' and by tying the name parameter to 'the environment variable name the app reads.' This elevates it slightly above schema-only.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb-resource pair ('attach a secret already stored in the account vault to one app') plus the environment-variable context and the restart side effect. It explicitly separates itself from set_app_secret ('store a new value with set_app_secret... instead'), so an agent can distinguish it from its nearest sibling without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit trigger conditions ('when the user says the key already exists in Dockhold', 'when a second app should use the same stored value') and points to list_secrets for discovery. It also states the exclusion — 'if the user wants separate credentials per app' — and names the alternative tool (set_app_secret). This is exactly the when/when-not guidance the dimension rewards.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.