Problem
With a scalar or list response_type, ctx.elicit() wraps the value in an object schema whose top-level title is FastMCP's internal wrapper name, "ScalarElicitationType", with no supported way to suppress it. (#3911 added control over the property-level title/description, but the object-level title remains.)
Example (fastmcp 3.4.2, mcp 1.28.0)
from fastmcp.server.elicitation import parse_elicit_response_type
parse_elicit_response_type(["yes", "no"]).schema
# {
# "type": "object",
# "properties": {"value": {"enum": ["yes","no"], "title": "Value", "type": "string"}},
# "required": ["value"],
# "title": "ScalarElicitationType", # internal model name, on the wire
# }
Expected vs. actual
- Expected: the wrapper schema doesn't put FastMCP's internal model name on the wire (or lets it be suppressed).
- Actual: every scalar/list elicitation emits
"title": "ScalarElicitationType".
Non-obvious insight (from research)
This breaks clients that parse requestedSchema strictly: Codex (CLI + Desktop) declares its schema with serde deny_unknown_fields and rejects every FastMCP elicitation with unknown field 'title', so the form never renders (openai/codex#31163). I confirmed empirically that an otherwise-identical title-less schema renders and is accepted on the same client. The MCP requestedSchema (2025-11-25) sets no additionalProperties: false and title is valid JSON Schema, so this is arguably also a client bug — but since the emitted title is a valueless internal name, dropping it fixes the interop failure with no downside.
Problem
With a scalar or list
response_type,ctx.elicit()wraps the value in an object schema whose top-leveltitleis FastMCP's internal wrapper name,"ScalarElicitationType", with no supported way to suppress it. (#3911 added control over the property-level title/description, but the object-leveltitleremains.)Example (fastmcp 3.4.2, mcp 1.28.0)
Expected vs. actual
"title": "ScalarElicitationType".Non-obvious insight (from research)
This breaks clients that parse
requestedSchemastrictly: Codex (CLI + Desktop) declares its schema with serdedeny_unknown_fieldsand rejects every FastMCP elicitation withunknown field 'title', so the form never renders (openai/codex#31163). I confirmed empirically that an otherwise-identical title-less schema renders and is accepted on the same client. The MCPrequestedSchema(2025-11-25) sets noadditionalProperties: falseandtitleis valid JSON Schema, so this is arguably also a client bug — but since the emitted title is a valueless internal name, dropping it fixes the interop failure with no downside.