Skip to main content
Glama

Tinplate AI Agent Security & Guardrails MCP

tinplate_tool_call_validator

Read-onlyIdempotent

Validate and coerce LLM function/tool-call JSON arguments against JSON Schema Draft 2020-12 definitions offline, catching type mismatches and schema constraint errors. (Endpoint: POST /v1/tool-call-validator)

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": {
      "tool_call": "<tool_call>",
      "tools": "<tools>"
    },
    "name": "tinplate_tool_call_validator"
  }
}

Input Schema

NameRequiredDescriptionDefault
toolsYesList of allowed tool definitions with their JSON Schemas.
tool_callYesRaw LLM tool call (OpenAI function/tool_call, Anthropic tool_use, Gemini functionCall, MCP tools/call, or raw string).
coerce_typesNoCoerce safe LLM type mismatches ('10' -> 10, 'true' -> true, stringified JSON arrays/objects, enum casing).
apply_defaultsNoPopulate missing properties that declare a `default` value in the JSON Schema.
fuzzy_match_tool_nameNoMatch tool names across snake_case, camelCase, and kebab-case differences.
strip_unknown_propertiesNoRemove hallucinated keys not declared in `properties` when `additionalProperties: false`.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changed
    • removedInput schema / properties / apply_defaults / example
      Removed value: -true
    • removedInput schema / properties / coerce_types / example
      Removed value: -true
    • removedInput schema / properties / fuzzy_match_tool_name / example
      Removed value: -true
    • removedInput schema / properties / strip_unknown_properties / example
      Removed value: -true
    • removedInput schema / properties / tool_call / example
      Removed value: -{
      -  "function": {
      -    "arguments": "```json\n{customer_id: 'cust_99', limit: '10', status: 'PAID', extra_hallucinated: true,}\n```",
      -    "name": "Search-Invoices"
      -  },
      -  "type": "function"
      -}
    • removedInput schema / properties / tools / example
      Removed value: -[
      -  {
      -    "description": "Search customer invoices",
      -    "name": "search_invoices",
      -    "parameters": {
      -      "additionalProperties": false,
      -      "properties": {
      -        "customer_id": {
      -          "minLength": 3,
      -          "type": "string"
      -        },
      -        "include_line_items": {
      -          "default": false,
      -          "type": "boolean"
      -        },
      -        "limit": {
      -          "maximum": 100,
      -          "minimum": 1,
      -          "type": "integer"
      -        },
      -        "status": {
      -          "enum": [
      -            "draft",
      -            "open",
      -            "paid",
      -            "void"
      -          ],
      -          "type": "string"
      -        }
      -      },
      -      "required": [
      -        "customer_id",
      -        "limit"
      -      ],
      -      "type": "object"
      -    }
      -  }
      -]
    • removedInput schema / properties / tools / items / properties / name / example
      Removed value: -"search_invoices"
  2. Added
  3. Removed
  4. Changed2 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • changedInput schema / properties / tool_call / anyOf
      Previous value: -[
      -  {
      -    "maxLength": 262144,
      -    "minLength": 1,
      -    "type": "string"
      -  },
      -  {
      -    "additionalProperties": {
      -      "nullable": true
      -    },
      -    "type": "object"
      -  }
      -]New value: +[
      +  {
      +    "maxLength": 262144,
      +    "minLength": 1,
      +    "type": "string"
      +  },
      +  {
      +    "additionalProperties": {},
      +    "type": "object"
      +  }
      +]
  5. Changed16 schema fields changed
    • addedInput schema / properties / apply_defaults
      Added value: +{
      +  "default": true,
      +  "description": "Populate missing properties that declare a `default` value in the JSON Schema.",
      +  "example": true,
      +  "type": "boolean"
      +}
    • addedInput schema / properties / coerce_types / default
      Added value: +true
    • changedInput schema / properties / coerce_types / description
      Previous value: -"Boolean flag 'coerce_types' (default: true)"New value: +"Coerce safe LLM type mismatches ('10' -> 10, 'true' -> true, stringified JSON arrays/objects, enum casing)."
    • addedInput schema / properties / coerce_types / example
      Added value: +true
    • addedInput schema / properties / fuzzy_match_tool_name
      Added value: +{
      +  "default": true,
      +  "description": "Match tool names across snake_case, camelCase, and kebab-case differences.",
      +  "example": true,
      +  "type": "boolean"
      +}
    • addedInput schema / properties / strip_unknown_properties
      Added value: +{
      +  "default": true,
      +  "description": "Remove hallucinated keys not declared in `properties` when `additionalProperties: false`.",
      +  "example": true,
      +  "type": "boolean"
      +}
    • addedInput schema / properties / tool_call / anyOf
      Added value: +[
      +  {
      +    "maxLength": 262144,
      +    "minLength": 1,
      +    "type": "string"
      +  },
      +  {
      +    "additionalProperties": {
      +      "nullable": true
      +    },
      +    "type": "object"
      +  }
      +]
    • changedInput schema / properties / tool_call / description
      Previous value: -"Structured object parameter 'tool_call'"New value: +"Raw LLM tool call (OpenAI function/tool_call, Anthropic tool_use, Gemini functionCall, MCP tools/call, or raw string)."
    • addedInput schema / properties / tool_call / example
      Added value: +{
      +  "function": {
      +    "arguments": "```json\n{customer_id: 'cust_99', limit: '10', status: 'PAID', extra_hallucinated: true,}\n```",
      +    "name": "Search-Invoices"
      +  },
      +  "type": "function"
      +}
    • removedInput schema / properties / tool_call / type
      Removed value: -"object"
    • changedInput schema / properties / tools / description
      Previous value: -"Array parameter 'tools'"New value: +"List of allowed tool definitions with their JSON Schemas."
    • addedInput schema / properties / tools / example
      Added value: +[
      +  {
      +    "description": "Search customer invoices",
      +    "name": "search_invoices",
      +    "parameters": {
      +      "additionalProperties": false,
      +      "properties": {
      +        "customer_id": {
      +          "minLength": 3,
      +          "type": "string"
      +        },
      +        "include_line_items": {
      +          "default": false,
      +          "type": "boolean"
      +        },
      +        "limit": {
      +          "maximum": 100,
      +          "minimum": 1,
      +          "type": "integer"
      +        },
      +        "status": {
      +          "enum": [
      +            "draft",
      +            "open",
      +            "paid",
      +            "void"
      +          ],
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "customer_id",
      +        "limit"
      +      ],
      +      "type": "object"
      +    }
      +  }
      +]
    • addedInput schema / properties / tools / items / $ref
      Added value: +"#/components/schemas/ToolDefinition"
    • removedInput schema / properties / tools / items / type
      Removed value: -"object"
    • addedInput schema / properties / tools / maxItems
      Added value: +128
    • addedInput schema / properties / tools / minItems
      Added value: +1
  6. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false and openWorldHint=false, so the safety profile is covered. The description contributes only the word 'offline', which usefully confirms no network dependency. It does not disclose what the tool returns on failure (error list vs exception), so it adds limited behavior beyond annotations.

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?

A single dense sentence that front-loads the action and scope. The trailing '(Endpoint: POST /v1/tool-call-validator)' largely restates the tool name and is the one clearly non-earning element.

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?

Six parameters with full schema coverage and rich annotations mean the calling contract is well specified. But there is no output schema and the description never says what a validation result looks like (pass/fail shape, error list, coerced arguments), which is the main missing piece for an agent deciding what to do with the response.

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 every parameter including the four coercion/repair flags is documented structurally. The description's mention of coercion and error catching maps onto those flags but adds no syntax or edge-case meaning beyond the schema. Baseline 3 applies where the schema does the heavy lifting.

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?

Specific verb and resource: 'validate and coerce LLM function/tool-call JSON arguments against JSON Schema Draft 2020-12', plus the failure mode it catches ('type mismatches and schema constraint errors'). An agent can tell what the tool does. However, it never distinguishes itself from adjacent siblings such as tinplate_json_heal or tinplate_llm_output_guard, so it stops short of a 5.

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?

Usage is implied by the domain: call it on LLM tool-call payloads before executing them. There is no explicit when-to-use statement, no exclusion of alternatives (e.g. when to prefer tinplate_json_heal for malformed JSON repair instead), and no note on prerequisites such as needing the full tool schema list.

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.