Skip to content

Conversation

@VENUCODE
Copy link

Description

This PR adds a new agentic provider for Claude Agent SDK, enabling Composio tools to be used with Claude Agent SDK applications. The implementation follows the established provider pattern used by other agentic providers in the codebase, using the @tool decorator pattern to create Claude Agent SDK-compatible tool definitions. The provider includes proper error handling with pydantic validation error parsing, comprehensive documentation with usage examples, and a complete demo showcasing integration with Gmail Get Profile tool. The implementation uses a factory function pattern to ensure proper closure capture when creating multiple tools dynamically, preventing variable capture issues.
The provider is structured with a helper method _create_tool_function() that encapsulates the tool creation logic, following best practices for code organization and maintainability. A fully functional demo (claude_agent_demo.py) demonstrates the complete integration flow, including MCP server setup, Claude Agent Options configuration, and tool execution. All code has been formatted and linted according to project standards, and the implementation includes comprehensive docstrings with parameter descriptions, return types, and usage examples to aid developer understanding.
Status: Work in Progress - Ready for review and testing

…r and improved the py docs for better dev understanding
@macroscopeapp
Copy link

macroscopeapp bot commented Nov 14, 2025

Add composio_claude_agent.ClaudeAgentSDKProvider and a runnable demo to integrate Composio tools with Claude Agent SDK in provider.py

Introduce a new provider that wraps Composio tools as Claude Agent SDK MCP tools, add a demo script that runs an async query for GMAIL_GET_PROFILE, and include package metadata and docs for distribution.

📍Where to Start

Start with the provider implementation in provider.py, then run the demo in claude_agent_demo.py.


Macroscope summarized d8ca975.

…and improve environment variable checks

- Changed tool references from slug to name in `claude_agent_demo.py` and `provider.py`.
- Enhanced error handling for missing environment variables, specifically for `COMPOSIO_API_KEY` and `ANTHROPIC_API_KEY`.
@VENUCODE VENUCODE marked this pull request as ready for review December 3, 2025 17:02
@VENUCODE VENUCODE requested a review from haxzie as a code owner December 3, 2025 17:02
@VENUCODE VENUCODE changed the title [WIP]: Add Claude Agent SDK Provider for Composio Add Claude Agent SDK Provider for Composio Dec 3, 2025
@VENUCODE
Copy link
Author

VENUCODE commented Dec 3, 2025

bugbot run

@VENUCODE VENUCODE changed the title Add Claude Agent SDK Provider for Composio feat: support for claude agent sdk provider Dec 3, 2025
@cursor
Copy link

cursor bot commented Dec 3, 2025

PR Summary

Introduces a Claude Agent SDK provider that wraps Composio tools for MCP usage, plus a working demo, docs, and packaging.

  • Providers:
    • Add ClaudeAgentSDKProvider in python/providers/claude_agent/composio_claude_agent/provider.py to adapt Composio Tools to Claude Agent SDK SdkMcpTools via @tool.
    • Implements wrap_tool/wrap_tools and a factory _create_tool_function with pydantic validation error handling and Claude-compatible responses.
  • Demo:
    • Add python/providers/claude_agent/claude_agent_demo.py showing fetching GMAIL_GET_PROFILE, creating an MCP server, configuring ClaudeAgentOptions, and running ClaudeSDKClient.
  • Docs:
    • Add python/providers/claude_agent/README.md with installation, quick start, and API reference for ClaudeAgentSDKProvider.
  • Packaging:
    • Add pyproject.toml, setup.py, and composio_claude_agent/py.typed for distribution and type hints.

Written by Cursor Bugbot for commit 1582eb1. This will update automatically on new commits. Configure here.

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