Skip to main content
Glama

Specway API Library

Sync API from its spec

specway_sync_api
DestructiveIdempotent

Re-reads an API's OpenAPI spec from the URL it was imported from and applies every change at once: new endpoints are added, changed ones are replaced from the spec, and endpoints no longer in the spec are removed from the docs. The changes go live, and a changelog entry is written when anything changed. Endpoints hidden from the docs stay hidden. Returns how many endpoints were added, changed and removed, with up to 50 of each listed. Running it again when the spec has not changed changes nothing. Only works for an API imported from a URL (source_url in specway_list_apis); the spec is fetched from that URL on the internet.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "api_id": "<api_id>"
    },
    "name": "specway_sync_api"
  }
}

Input Schema

NameRequiredDescriptionDefault
api_idYesAn api_id from specway_list_apis. Opaque.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already flag destructiveHint=true and idempotentHint=true, and the description goes well beyond them: it spells out exactly what is destroyed ('endpoints no longer in the spec are removed from the docs'), that changes go live immediately, that a changelog entry is written, that hidden endpoints are preserved, and that the spec is fetched over the internet. This is precisely the extra context the annotations alone cannot convey.

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 destructive scope is front-loaded in the first sentence, followed by side effects, the idempotency note, the prerequisite, and finally the return shape. Every sentence carries distinct information with no restatement of the name or title.

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?

With no output schema, the description compensates by describing the return value (added/changed/removed counts, up to 50 of each listed). Combined with the disclosed side effects and the URL-import prerequisite, an agent has everything needed to decide and call correctly.

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 coverage is 100% and the single parameter is already documented as an opaque api_id. The description adds meaning the schema does not: the api_id must correspond to a URL-imported API with a source_url, which constrains which values are valid inputs.

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 opens with a specific verb and resource: 'Re-reads an API's OpenAPI spec from the URL it was imported from and applies every change at once.' It then enumerates the concrete effects (add, replace, remove) so an agent can distinguish this from siblings like specway_update_endpoint_description, which edits a single endpoint rather than reconciling the whole spec.

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?

It states a clear precondition ('Only works for an API imported from a URL (source_url in specway_list_apis)') and a when-not-to-bother signal ('Running it again when the spec has not changed changes nothing'). No alternative tool is named for the non-URL-imported case, so the agent gets context but not explicit redirection.

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