Skip to main content
Glama

Set app variables

set_app_variables
DestructiveIdempotent

Add, change or remove environment variables of a hosted app or bot. Pass set as a map of NAME to value for the ones to write, and unset as a list of names to remove. Everything not named is left exactly as it is, values included. The response never contains a value, only the names that were written and removed: pass a value in, never expect one back. Saving environment recreates the container, so the app restarts and is offline for about a minute. Removing DISCORD_TOKEN from a Discord bot is refused, because it would take the bot down for good. A changed DISCORD_TOKEN is checked with Discord first and refused if Discord rejects it. The credentials of a bundled one-click database are written by FadeHost and are put back on every save, so they cannot be changed or removed here. Refuses a paused app and a suspended owner. Needs full access to the app, the same as the panel Environment tab.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
appYesThe app id (bot_...) from list_bots.
setNoThe variables to write, as a map of NAME to value, for example {"LOG_LEVEL": "debug"}. A name that already exists is overwritten. Names are variable names: letters, digits and underscores, not starting with a digit.
unsetNoThe variable names to remove, for example ["OLD_API_KEY"].

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
keptYesNames asked to be removed that are still set, because FadeHost manages them.
countYesHow many variables the app holds now.
statusYesThe app status after the save, usually deploying.
removedYesThe names that were removed.
writtenYesThe names that were written. Values are never returned.

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?

Annotations declare mutation/destructive/idempotent, and the description adds substantial context that annotations cannot convey: the response never returns values, saving recreates the container causing ~1 minute of downtime, DISCORD_TOKEN is validated with Discord and refused on rejection, and the DISCORD_TOKEN removal refusal. This is exactly the extra behavioral detail the definition should provide.

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

Conciseness4/5

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

Dense but front-loaded: the core operation and the set/unset contract come first, followed by response behavior, then refusals. It is longer than typical, but nearly every sentence carries a distinct operational fact, so little is wasted.

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

Completeness5/5

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

Given an output schema exists, the description still usefully notes the response returns only names, not values. Combined with the mutation, restart, and refusal details, an agent has everything needed to call this correctly and set expectations.

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 description coverage is 100%, so the baseline is 3, but the description reinforces semantics by explaining that set entries overwrite existing names and that anything unnamed is preserved untouched. It adds the crucial behavioral note that a value is never returned, which the schema does not convey.

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 ('Add, change or remove environment variables of a hosted app or bot') and immediately clarifies the mechanism (set map vs unset list). It is clearly distinguishable from the read sibling list_app_variables without opening either 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?

Explicitly covers when it applies and when it is refused: paused app, suspended owner, DISCORD_TOKEN removal from a Discord bot, invalid DISCORD_TOKEN, and bundled one-click database credentials. It also states the access requirement ('full access to the app'). This is well beyond generic when-to-use guidance.

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