Skip to main content
Glama
hampsterx

claude-mcp-bridge

by hampsterx

Structured Output

structured

Generate JSON output that conforms to a provided JSON Schema, enabling validated data extraction, classification, and entity parsing from text or files with machine-parseable results.

Instructions

Generate JSON conforming to a provided JSON Schema. Uses Claude CLI's native --json-schema flag for validated output (not client-side validation).

Use for: data extraction from text/files, classification, entity parsing, or any task needing machine-parseable output.

Cost: Similar to query (~$0.01-0.10/call). Schema complexity doesn't significantly affect cost.

Tips:

  • Pass the JSON Schema as a JSON string in the schema parameter.

  • Schema max size: 20KB. Keep schemas focused for reliable output.

  • For extraction tasks, include source text via the files parameter or inline in the prompt.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filesNoText file paths to include as context
modelNoModel alias or full Claude model name
promptYesWhat to generate or extract
schemaYesJSON Schema as a JSON string
timeoutNoTimeout in milliseconds (default: 60000)
sessionIdNoClaude session ID to resume with --resume
maxBudgetUsdNoMaximum cost budget in USD for this call (passed to --max-budget-usd)
workingDirectoryNoWorking directory for file resolution and CLI execution
noSessionPersistenceNoDisable session persistence for ephemeral print calls
Behavior4/5

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

The annotations (readOnlyHint=false, destructiveHint=false, idempotentHint=false, openWorldHint=true) provide basic safety signals. The description adds valuable behavioral context: it uses native CLI validation (not client-side), cost is ~$0.01-0.10/call and unaffected by schema complexity, and it is designed for machine-parseable output. These details go beyond what annotations 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 description is concise: a lead sentence stating the core function, then a brief use case bullet, a cost note, and a tips section. Every sentence serves a purpose with no redundancy. The structure is front-loaded with the most important information.

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 has 9 parameters, no output schema, and moderate complexity, the description covers the essential aspects: purpose, use cases, cost, and parameter tips. It could mention default behavior (e.g., timeout default of 60000) or error handling, but the parameter schema covers most details. Overall, it is sufficiently complete for an agent to use 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?

All 9 parameters have descriptions in the schema (100% coverage), so baseline is 3. The description adds extra meaning: for the 'schema' parameter it notes 'Pass the JSON Schema as a JSON string' and 'Schema max size: 20KB'; for 'files' it explains 'include source text via the files parameter or inline in the prompt.' These tips improve parameter understanding beyond the schema alone.

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 'Generate JSON conforming to a provided JSON Schema' using a specific implementation (Claude CLI's --json-schema flag). It lists concrete use cases like data extraction, classification, and entity parsing, which distinguish it from sibling tools such as 'query' (likely free-form) and 'search' (retrieval).

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 explicitly says 'Use for: data extraction from text/files, classification, entity parsing, or any task needing machine-parseable output.' It also provides practical tips (schema max size, including source text via files parameter) but does not explicitly state when not to use this tool or mention alternatives beyond implying it's better than client-side validation.

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/hampsterx/claude-mcp-bridge'

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