A valid schema ensures that the AI agent understands the structure of the data it needs to provide.
How the WebMCP schema validity audit fails
The audit fails if:
- A form has a
tooldescriptionbut is missing thetoolnameattribute. - A form has a
toolnamebut is missing thetooldescriptionattribute. - A required form field is missing a
nameattribute.
Lighthouse also issues a warning if an optional field has a name but is
missing a toolparamdescription or an associated <label>.
How to fix
- Ensure symmetry: Always provide both a name and a description for every tool.
- Add names to inputs: Verify that every input element within a tool form has
a unique
nameattribute. - Provide parameter context: Add
toolparamdescriptionto inputs to help the agent understand what value is expected.