Tool Definition Generator
Writing an input_schema by hand is tedious and easy to get subtly wrong. Paste an example of the arguments your tool takes and get the definition, with nested shapes inlined rather than hoisted into $defs.
Output appears here as you type.
Runs entirely in your browser. Nothing you paste here is uploaded or stored.
Questions
Is what I paste sent anywhere?
No — and it is worth being concrete about why that matters here. A prompt, a captured response and a tool definition all contain the things people are most careful with: system instructions, customer data, internal endpoints. Every tool on this page is a pure function running in your tab, on a page whose Content-Security-Policy sets connect-src to ‘none’, so the browser will not let it open a network connection at all.
Which API do these target?
The Anthropic Messages API. Other providers use different shapes for the same concepts, and emitting a format from memory is exactly how a tool ends up confidently wrong — so rather than guess, this section covers the one it can be precise about.
What does strict mode change?
It guarantees the arguments the model sends validate exactly against your schema. The API only accepts it on a closed schema, so turning it on also sets additionalProperties to false and ensures a required array exists. Note that strict is a sibling of name, description and input_schema — not something you put on tool_choice, which is the most common way it gets misplaced.
Why are nested objects inlined instead of using $defs?
Because support for $ref varies. An inlined schema is longer but unambiguous, and a tool definition is written once and read by a model many times — clarity beats brevity.
Why does it keep telling me to write a longer description?
Because the description is the highest-leverage text in the entire definition. The model decides whether to call a tool almost entirely from it — not from the name, and not from the schema. A schema that is perfect and a description that is one word gives you a tool that is never called, or called at the wrong moment.