Skip to main content
Glama

add_postman_collection_variable

Adds a variable to a Postman collection file. Specify the file path and variable details (key, value, type) to update the collection.

Instructions

Add a variable to the Postman collection

Args:
    file_path: The path to the Postman collection file (string)
    variable: The variable dictionary with keys like key, value, type, etc. (dict)
            Example: {
                "key": "base_url",
                "value": "https://api.example.com",
                "type": "string"
            }
Returns:
    The updated Postman collection data (dict)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_pathYes
variableYes
Behavior2/5

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

No annotations are provided, so the description must disclose behavioral traits. It states it 'adds' a variable, but does not specify behavior if the variable already exists (overwrite vs append), whether the file is modified in-place, or any required permissions. The return value is described vaguely as 'the updated Postman collection data'.

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 concise: a one-sentence purpose followed by well-structured Args and Returns sections. The example aids understanding. No unnecessary fluff, though it could be more terse.

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

Completeness3/5

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

Given the complexity (2 params, nested object, no output schema, no annotations), the description covers the basic purpose and parameter details. However, it lacks information on edge cases (duplicate keys), file path validation, whether the file is saved, and error handling. It is adequate but not complete.

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?

The input schema for 'variable' is minimal (just an object with no properties). The description adds significant value by explaining it is a dictionary with keys like key, value, type and providing an example. This compensates for the 0% schema description coverage.

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 verb 'Add' and resource 'variable to the Postman collection'. It distinguishes itself from sibling tools like add_postman_collection_auth or add_postman_collection_folder by specifying exactly what it does.

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

Usage Guidelines2/5

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

No explicit guidelines on when to use this tool versus alternatives. It does not mention prerequisites, when not to use it, or differentiate from update_postman_collection_variable. The usage is only implied by the basic purpose.

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/marioToribi0/code2postman-mcp'

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