# ToolSchema Forge - LLM Tool Schema Converter

> ToolSchema Forge - LLM Tool Schema Converter is a paid API for AI agents from toolschema-forge.toolschemaforge.workers.dev, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-21).

Converts, lints, and cross-compiles LLM tool definitions between OpenAI, Anthropic, Gemini, and MCP formats, with auto-fixing and issue reporting, paid per call via x402.

## Facts

- Endpoint: POST https://toolschema-forge.toolschemaforge.workers.dev/v1/tool-schema/convert?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-21
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/toolschema-forge-llm-tool-schema-converter-d436fbdc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_VWxtt966bdWfK_JTaf7P5

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability toolschema-forge-llm-tool-schema-converter-d436fbdc -d '<json body>'
```

Example prompt: Convert this OpenAI function schema to Anthropic and Gemini formats and lint it for any compatibility issues: {name: 'get_weather', description: 'Get weather for a city', parameters: {type: 'object', required: ['city'], properties: {city: {type: 'string'}, unit: {enum: ['c','f']}}}}

## When to prefer this

Choose this endpoint when you need deterministic, rule-based conversion of LLM tool schemas across providers (OpenAI, Anthropic, Gemini, MCP) with linting and auto-fixing, rather than asking an LLM to manually rewrite schemas. Ideal for CI pipelines, agent builder tooling, or any workflow where you need to maintain a single source-of-truth tool definition and emit provider-specific variants automatically. Particularly useful when OpenAI strict mode compliance is needed, since the service auto-fixes common issues like missing additionalProperties:false and optional property nullability.

## Known failure modes

- Unrecognizable tool format — returns error if input doesn't match any supported provider schema
- Missing required 'tool' field in body — validation error
- Invalid target format enum value — rejected at schema level
- Payment failure via x402 — HTTP 402 if USDC payment not provided or insufficient
- Malformed JSON body — HTTP 400 parse error
- Tool schema too complex or deeply nested for deterministic linting

## How this service works

Deterministic LLM tool-schema conversion, linting and MCP manifest generation for OpenAI (incl. strict mode), Anthropic, Gemini and MCP, paid per call in USDC on Base via x402.

## Output

Returns a JSON object with a 'detected' field indicating the auto-detected source format, and a 'results' map keyed by target format (e.g. openai, openai_strict, anthropic, gemini, mcp, jsonschema). Each target entry contains the converted 'tool' schema and an 'issues' array listing any lint findings with path, code, message, severity (error/warning), and whether the issue was auto-fixed.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "type": "object",
     "required": [
      "tool"
     ],
     "properties": {
      "tool": {
       "type": "object",
       "description": "Tool definition in any supported format (OpenAI chat/responses, Anthropic, Gemini, MCP, or {name, description, parameters})."
      },
      "targets": {
       "type": "array",
       "items": {
        "enum": [
         "openai",
         "openai_strict",
         "anthropic",
         "gemini",
         "mcp",
         "jsonschema"
        ],
        "type": "string"
       },
       "minItems": 1,
       "description": "Target formats. Default: all."
      }
     }
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "detected",
      "results"
     ],
     "properties": {
      "results": {
       "type": "object",
       "additionalProperties": {
        "type": "object",
        "properties": {
         "tool": {
          "type": "object"
         },
         "issues": {
          "type": "array",
          "items": {
           "type": "object",
           "required": [
            "provider",
            "path",
            "code",
            "message",
            "severity",
            "fixed"
           ],
           "properties": {
            "code": {
             "type": "string"
            },
            "path": {
             "type": "string"
            },
            "fixed": {
             "type": "boolean"
            },
            "message": {
             "type": "string"
            },
            "provider": {
             "enum": [
              "openai",
              "openai_strict",
              "anthropic",
              "gemini",
              "mcp",
              "jsonschema"
             ],
             "type": "string"
            },
            "severity": {
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "results": {
   "gemini": {
    "tool": {
     "name": "get_weather",
     "parameters": {
      "type": "object",
      "required": [
       "city"
      ],
      "properties": {
       "city": {
        "type": "string",
        "description": "City name"
       },
       "unit": {
        "enum": [
         "c",
         "f"
        ],
        "type": "string"
       }
      }
     },
     "description": "Get the current weather for a city."
    },
    "issues": []
   },
   "openai_strict": {
    "tool": {
     "type": "function",
     "function": {
      "name": "get_weather",
      "strict": true,
      "parameters": {
       "type": "object",
       "required": [
        "city",
        "unit"
       ],
       "properties": {
        "city": {
         "type": "string",
         "description": "City name"
        },
        "unit": {
         "enum": [
          "c",
          "f",
          null
         ],
         "type": [
          "string",
          "null"
         ]
        }
       },
       "additionalProperties": false
      },
      "description": "Get the current weather for a city."
     }
    },
    "issues": [
     {
      "code": "optional_made_nullable",
      "path": "/properties/unit",
      "fixed": true,
      "message": "Optional property \"unit\" was made nullable and required",
      "provider": "openai_strict",
      "severity": "warning"
     },
     {
      "code": "additional_properties_forced",
      "path": "/additionalProperties",
      "fixed": true,
      "message": "additionalProperties must be false for OpenAI Structured Outputs",
      "provider": "openai_strict",
      "severity": "warning"
     }
    ]
   }
  },
  "detected": "openai"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/toolschema-forge-llm-tool-schema-converter-d436fbdc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from toolschema-forge.toolschemaforge.workers.dev](https://www.zero.xyz/host/toolschema-forge.toolschemaforge.workers.dev/llms.txt)
