Skip to main content
Glama

Detach a resource from an app

detach_resource
DestructiveIdempotent

Detach a resource from an app: remove the environment variables it set and, if the app is running, ask for a restart so its next process starts without them. The state is detached when that is done, and detaching while Valet still owes the restart or the removal, which it keeps trying; the answer gives the reason. The running process keeps the variables until it is replaced. A variable whose value is not the one the resource set stays on the app, and the answer names it. The resource itself and its data are unchanged, and other apps that hold it keep it. Detaching a resource that is not attached changes nothing. Requires connecting a Valet account.

Input Schema

NameRequiredDescriptionDefault
nameYesRequired. The app's name.
org_nameNoThe Valet organization the app belongs to. Omit to use the organization the account joined first.
resourceYesRequired. The resource's name in the organization.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4/5.0
Behavior5/5

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

The description goes well beyond the annotations: it explains that env vars are removed, a restart is requested, the running process keeps the vars until replaced, non-matching variable values are left in place, resource data is preserved, other apps retain the resource, and a Valet account is required. It is consistent with idempotentHint=true ('changes nothing') and destructiveHint=true.

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

Conciseness3/5

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

The purpose is front-loaded, but the body is long and at least one sentence is garbled ('detaching while Valet still owes the restart or the removal, which it keeps trying; the answer gives the reason'), which costs clarity. Several clauses could be tightened.

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?

With no output schema, the description carries the return-value burden and does so partially ('the answer gives the reason', 'the answer names it'), plus it discloses auth requirements and edge cases. The awkward phrasing leaves some return behavior ambiguous, preventing a 5.

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

Parameters3/5

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

Schema description coverage is 100%, so name, org_name and resource are already documented in the schema. The description adds no syntax, format, or constraint detail beyond that, so the baseline 3 applies.

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 and resource ('Detach a resource from an app') and immediately distinguishes it from the destructive sibling by noting 'The resource itself and its data are unchanged.' An agent can tell this apart from destroy_resource without opening a schema.

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

Usage Guidelines3/5

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

Usage is implied through behavioral edge cases (detaching a non-attached resource is a no-op, other apps holding the resource keep it), but there is no explicit when-to-use framing and no alternative named (e.g. destroy_resource to delete the resource itself, attach_resource to re-attach). The agent must infer the routing.

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.

Resources