Skip to content

fix(core): normalize content-only MCP tool results - #94

Merged
Ray-56 merged 1 commit into
mainfrom
fix/mcp-tool-result-envelope
Aug 21, 2026
Merged

fix(core): normalize content-only MCP tool results#94
Ray-56 merged 1 commit into
mainfrom
fix/mcp-tool-result-envelope

Conversation

@JJasonSun

@JJasonSun JJasonSun commented Aug 20, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • preserve the raw MCP tool-result envelope while exposing an existing structuredContent or structured_content object through the canonical structuredContent field
  • parse a JSON object from a text content block when a content-only result omits structured content
  • leave prose, invalid JSON, arrays, scalar JSON, Markdown fences, and combined fragments unchanged
  • apply the normalized result to direct MCP calls and the plan_call / run_call / get_call_run CLI workflow
  • document the raw MCP envelope, SDK field names, workflow handoff fields, and stable CLI result paths

Testing

  • pnpm test
  • pnpm check
  • pnpm pack:dry-run
  • git diff --check

Release

Adds patch changesets for @call-e/core and @call-e/cli.

Relates to CALLE-AI/awesome-phone-call-agents#158

@JJasonSun
JJasonSun marked this pull request as ready for review August 20, 2026 05:55
@Ray-56
Ray-56 merged commit a7e5439 into main Aug 21, 2026
1 check passed
@JJasonSun
JJasonSun deleted the fix/mcp-tool-result-envelope branch August 25, 2026 09:27
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.

2 participants