Motivation
Users increasingly ask how to consume MCP servers from code-execution-enabled agent hosts. See Anthropic's Code execution with MCP and Cloudflare Code Mode.
Content outline
- What is Code Mode + when to use it (vs. direct tool calling)
- Cosmos-specific example: "read schema, filter/aggregate in code, upsert selected rows" — parallels the Anthropic GDrive → Salesforce example
- Using the new TypeScript SDK sample (see separate issue)
- How progressive disclosure via
search_tools reduces context (see separate issue)
- Non-goals: MCPToolkit does not run agent code — sandboxing / resource limits are the client's responsibility. This is called out explicitly in the Anthropic post.
Acceptance criteria
Related
Part of the "Code Mode" support umbrella.
Motivation
Users increasingly ask how to consume MCP servers from code-execution-enabled agent hosts. See Anthropic's Code execution with MCP and Cloudflare Code Mode.
Content outline
search_toolsreduces context (see separate issue)Acceptance criteria
docs/CODE-MODE.mdREADME.mdanddocs/USE-CASES.mdRelated
Part of the "Code Mode" support umbrella.