Skip to content

fix(mcp): emit spec-compliant outputSchema and object-wrapped list results - #67

Merged
birdmanmandbir merged 2 commits into
mainfrom
fix/mcp-output-schema
Aug 11, 2026
Merged

fix(mcp): emit spec-compliant outputSchema and object-wrapped list results#67
birdmanmandbir merged 2 commits into
mainfrom
fix/mcp-output-schema

Conversation

@orga-agent

@orga-agent orga-agent Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Problem

The flicknote MCP server (v0.5.0) returned two kinds of spec-noncompliant payloads that strict 2025-era MCP clients reject:

  1. tools/list outputSchema — note_list, note_find, and project_list declared {"type": "array", ...}, and note_source a oneOf union without a root type. The MCP spec requires outputSchema.type to be "object".
  2. tools/call structuredContent — the three list tools returned bare arrays; strict clients require a JSON record.

pi-mcp-adapter (Pi coding agent) enforces these strictly, so the server failed to connect there. Codex's client tolerated both, hiding the bug.

Fix

  • note_source: explicit minimal outputSchema ({"type": "object"}) via rmcp's output_schema tool attribute.
  • note_list / note_find / project_list: wrap the array in an object ({"notes": [...]} / {"projects": [...]}) so both the derived outputSchema and the structuredContent are valid objects. This matches the pattern used by MCP reference servers and keeps the structured data intact.
  • Updated the three MCP characterization tests for the wrapped shape.

All 46 flicknote-cli tests pass.

@birdmanmandbir
birdmanmandbir merged commit e2fd1b5 into main Aug 11, 2026
9 checks passed
@orga-agent
orga-agent Bot deleted the fix/mcp-output-schema branch August 11, 2026 07:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant