Crew AI MCP Server
An MCP server that provides AI agent and task management capabilities using the CrewAI framework.
Setup
- Clone or fork this repository
- Run the setup script:
./crew.sh
The setup script will:
- Install required Python dependencies
- Configure the MCP settings file for your system
- Set up the correct paths automatically
Configuration
Before using the server, set your OpenAI API key:
export OPENAI_API_KEY="your-api-key"
Usage
The server provides three main tools:
1. Create an Agent
{
"method": "call_tool",
"params": {
"name": "create_agent",
"arguments": {
"role": "researcher",
"goal": "Research and analyze information effectively",
"backstory": "An experienced research analyst"
}
}
}
2. Create a Task
{
"method": "call_tool",
"params": {
"name": "create_task",
"arguments": {
"description": "Analyze recent market trends",
"agent": "researcher",
"expected_output": "A detailed analysis report"
}
}
}
3. Create and Run a Crew
{
"method": "call_tool",
"params": {
"name": "create_crew",
"arguments": {
"agents": ["researcher"],
"tasks": ["Analyze recent market trends"],
"verbose": true
}
}
}
Example Usage
Create and run a complete workflow:
(echo '{"method": "call_tool", "params": {"name": "create_agent", "arguments": {"role": "researcher", "goal": "Research and analyze information effectively", "backstory": "An experienced research analyst"}}}'; echo '{"method": "call_tool", "params": {"name": "create_task", "arguments": {"description": "Analyze recent market trends", "agent": "researcher", "expected_output": "A detailed analysis report"}}}'; echo '{"method": "call_tool", "params": {"name": "create_crew", "arguments": {"agents": ["researcher"], "tasks": ["Analyze recent market trends"], "verbose": true}}}') | python3 src/crew_server.py
System Requirements
- Python 3.8 or higher
jq
command-line tool (for setup script)- VSCode with Roo Cline extension installed
Supported Platforms
- macOS
- Linux
- Windows (via Git Bash)
Troubleshooting
If you encounter any issues:
- Ensure your OpenAI API key is set correctly
- Check that all dependencies are installed (
pip install -r requirements.txt
) - Verify the MCP settings file exists and has the correct configuration
- Make sure the server path in the MCP settings matches your actual file location
Contributing
- Fork the repository
- Create your feature branch
- Make your changes
- Run the setup script to verify everything works
- Submit a pull request
Last updated on