Skip to main content
Glama

Generate model types

generate_types
Read-only

Generate ready-to-paste TypeScript, Swift, Kotlin, or Dart models from the OpenAPI spec for v2 responses using a single request.

Instructions

Ready-to-paste TypeScript, Swift (Codable), Kotlin (kotlinx.serialization) or Dart models for v2 responses, generated from the OpenAPI spec. Uses one request.

Input Schema

NameRequiredDescriptionDefault
modelsNoDefault: ExerciseV2, ExercisePageV2, WorkoutV2, ProgramV2. Others: MediaLinksV2, MuscleV2, RankedPageV2, CaloriesV2, SupplementV2, AccountUsageV2, TrendingV2…
languageYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.1.0

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false, so safety is covered; the description adds that output is derived from the OpenAPI spec and costs one request. It does not say how the generated code is returned (single blob vs per-model strings), which matters since there is no output schema.

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?

Two tight sentences with the deliverable front-loaded and the cost note second. Nothing is padded, though 'Uses one request' is slightly clipped for an agent unfamiliar with quota semantics.

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 two-parameter generator with no output schema, the description conveys the languages, the source (OpenAPI spec), and the 'ready-to-paste' output nature. The main gap is the shape of the returned code payload, but the essentials for a correct call are present.

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 coverage is 50%: the `models` parameter is well documented in-schema (defaults and alternatives), while `language` relies on its enum. The description merely restates the four enum values and adds no new semantics such as default model set behavior or the 20-item cap.

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?

States a specific verb and resource: generates TypeScript/Swift/Kotlin/Dart model types from the OpenAPI spec, scoped to v2 responses. The closest sibling, get_code_example, is not named or contrasted, so differentiation is left to inference.

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?

'For v2 responses' implies a context of use, and 'Uses one request' hints at cost. But there is no explicit when-to-use/when-not or mention of get_code_example as the alternative for example snippets rather than model types.

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