Project
cortex
Description
A valid tool inputSchema whose property definition uses $ref fails to deserialize into Tool.
Error Message
TOOL_REF_PROPERTY_PARSE=Err(Error("missing field `type`", line: 0, column: 0))
Debug Logs
System Information
Cortex crate: cortex-mcp-types 0.0.7
Commit: 7954d02
Date: 2026-04-10
OS: macOS
Screenshots
https://github.com/marvinayisi/issue-images/blob/main/mcp-tool-ref-property-20260410-074112.png
Steps to Reproduce
- Create a tiny Rust crate depending on
cortex-mcp-types from this workspace.
- Deserialize a tool definition whose
inputSchema.properties.query is { "$ref": "#/defs/query" }.
- Print the parse result.
Expected Behavior
The valid JSON Schema property object should deserialize successfully.
Actual Behavior
Deserialization fails because PropertySchema requires a local type field.
Additional Context
- Authoritative spec:
https://raw.githubusercontent.com/modelcontextprotocol/modelcontextprotocol/refs/heads/main/schema/2024-11-05/schema.ts
- Code path:
/Users/odeili/Projects/platform/cortex/src/cortex-mcp-types/src/tools.rs
- Duplicate check on 2026-04-10:
cortex-mcp-types Tool inputSchema $ref property missing field type
tool inputSchema $ref missing field type cortex-mcp-types
Project
cortex
Description
A valid tool
inputSchemawhose property definition uses$reffails to deserialize intoTool.Error Message
Debug Logs
System Information
Screenshots
https://github.com/marvinayisi/issue-images/blob/main/mcp-tool-ref-property-20260410-074112.png
Steps to Reproduce
cortex-mcp-typesfrom this workspace.inputSchema.properties.queryis{ "$ref": "#/defs/query" }.Expected Behavior
The valid JSON Schema property object should deserialize successfully.
Actual Behavior
Deserialization fails because
PropertySchemarequires a localtypefield.Additional Context
https://raw.githubusercontent.com/modelcontextprotocol/modelcontextprotocol/refs/heads/main/schema/2024-11-05/schema.ts/Users/odeili/Projects/platform/cortex/src/cortex-mcp-types/src/tools.rscortex-mcp-types Tool inputSchema $ref property missing field typetool inputSchema $ref missing field type cortex-mcp-types