A tool contract describes how an agent may call a capability and what the capability promises to return. Request and response schemas reduce ambiguous arguments, while explicit error states let the workflow decide whether to retry, recover or ask for help.
For tools that change external systems, the contract should also document authorization, idempotency and compensation behavior. A clear contract makes the boundary independently testable and prevents the model from inventing unsupported parameters or assumptions.
ELI5
A tool contract clearly defines how an AI agent may use a tool. It describes the accepted inputs, returned results, errors, permissions, and any changes the tool can make.
For example, a calendar tool can require a valid date, attendee list, and title, then return a confirmed event identifier or a specific error. Clear rules stop the agent from inventing unsupported fields or assuming that a failed request succeeded.
What should a tool contract define?
It should define request and response schemas, validation rules, errors, authorization requirements and possible side effects.
Why do agents need strict tool schemas?
Schemas turn model-generated arguments into bounded, testable inputs and reject malformed or unsupported calls before execution.




