Skip to main content
Glama

Add or update environment variable

render_update_env_var
Idempotent

Add or update a specific environment variable on a Render service, targeting only directly assigned variables, not linked environment groups.

Instructions

Add or update environment variable. Add or update a particular environment variable for a particular service. This only applies to environment variables set directly on the service, not to environment variables in a linked environment group. Calls PUT /services/{serviceId}/env-vars/{envVarKey} on the Render Public API.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyYesRequest body.
envVarKeyYesThe name of the environment variable
serviceIdYesThe ID of the service
Behavior4/5

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

Annotations already indicate a non-read-only, idempotent, non-destructive operation. The description adds the key scoping detail that linked environment group variables are not affected, and it discloses the underlying API call (PUT /services/{serviceId}/env-vars/{envVarKey}). This goes beyond the annotations without contradicting them, though it doesn't detail side effects or return behavior.

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?

The description is composed of three sentences, with the first repeating the title and the second adding clarity. The third sentence is highly informative, providing scope and the API endpoint. There is slight redundancy between the first two sentences, but overall it remains concise and front-loaded.

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?

For a mutation tool with three parameters and no output schema, the description covers the core purpose, scope, and API endpoint. It doesn't describe the return value or the generateValue option, but these are partially addressed by the schema. The description is adequate for an agent to understand when and how to invoke the tool.

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?

The schema description coverage is 100%, with each parameter having a description ('The name of the environment variable', 'The ID of the service', and 'Request body.'). The tool description adds no additional parameter-level meaning, so the baseline of 3 applies since the schema already handles semantics.

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?

The description clearly states the action: 'Add or update environment variable' for 'a particular service'. It distinguishes from related tools by explicitly excluding 'environment variables in a linked environment group' and naming the exact API call. This makes the tool's purpose unambiguous and differentiates it from siblings like render_update_env_group_env_var.

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?

The description provides an explicit when-not-to-use condition: 'This only applies to environment variables set directly on the service, not to environment variables in a linked environment group.' This guides the agent to alternative tools for env group variables, satisfying the 'when-not' criterion. It also implies single-variable scope, contrasting with batch tools like render_update_env_vars_for_service.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/LuSrodri/render-useful-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server