Skip to main content
Glama

generateCollection

Convert API specifications into Postman collections for testing and documentation, with customizable options for request naming, folder organization, and parameter handling.

Instructions

Creates a collection from the given API specification. The specification must already exist or be created before it can be used to generate a collection. The response contains a polling link to the task status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
specIdYesThe spec's ID.
elementTypeYesThe `collection` element type.
nameYesThe generated collection's name.
optionsNoThe advanced creation options and their values. For more details, see Postman's [OpenAPI to Postman Collection Converter OPTIONS documentation](https://github.com/postmanlabs/openapi-to-postman/blob/develop/OPTIONS.md). These properties are case-sensitive.
Behavior3/5

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

Annotations already declare readOnlyHint=false, idempotentHint=false, and destructiveHint=false, covering the safety profile. The description adds useful behavioral context: it mentions the response contains 'a polling link to the task status,' indicating this is an asynchronous operation that requires polling (e.g., using 'getStatusOfAnAsyncApiTask'). However, it doesn't detail error conditions, rate limits, or authentication requirements beyond what annotations provide.

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?

The description is highly concise and well-structured in three sentences: purpose, prerequisite, and response behavior. Each sentence earns its place by providing essential information without redundancy. It's front-loaded with the core action and avoids unnecessary elaboration.

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?

Given the tool's moderate complexity (asynchronous generation with multiple options), the description is reasonably complete. It covers purpose, prerequisite, and response behavior. However, there's no output schema, and the description doesn't explain the polling process in detail (e.g., how to use the link). With annotations covering safety and schema covering parameters, the gaps are minor but noticeable for an async 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?

Schema description coverage is 100%, so the schema fully documents all 4 parameters (specId, elementType, name, options) with detailed descriptions. The description doesn't add any parameter-specific information beyond what's in the schema, such as explaining the relationship between specId and the collection or clarifying option defaults. Baseline 3 is appropriate since the schema carries the full burden.

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

Purpose4/5

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

The description clearly states the tool's purpose: 'Creates a collection from the given API specification.' It specifies the verb ('creates') and resource ('collection'), and distinguishes it from siblings like 'createCollection' by mentioning it generates from an existing specification. However, it doesn't explicitly contrast with 'generateSpecFromCollection' (reverse operation) or 'syncCollectionWithSpec' (synchronization).

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

Usage Guidelines4/5

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

The description provides clear context for when to use this tool: 'The specification must already exist or be created before it can be used to generate a collection.' This indicates a prerequisite (spec must exist) and implicitly suggests using 'createSpec' first if needed. It doesn't explicitly mention when NOT to use it or name alternatives like 'createCollection' (which might not require a spec), but the context is sufficient for basic guidance.

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/postmanlabs/postman-mcp-server'

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