AutoGen MCP Integration

v1.0.0Coding Agentsstable

This repository demonstrates how to use AutoGen to integrate local and remote MCP (Model Context Protocol) servers. It showcases a local math tool (math_server.py) using Stdio and a remote Apify tool (RAG Web Browser Actor) via SSE for tasks like ari

aiautogenazuredata-sciencellm
Share:
29
Stars
0
Downloads
0
Weekly
0/5

What is AutoGen MCP Integration?

AutoGen MCP Integration is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to this repository demonstrates how to use autogen to integrate local and remote mcp (model context protocol) servers. it showcases a local math tool (math_server.py) using stdio and a remote apify tool ...

This repository demonstrates how to use AutoGen to integrate local and remote MCP (Model Context Protocol) servers. It showcases a local math tool (math_server.py) using Stdio and a remote Apify tool (RAG Web Browser Actor) via SSE for tasks like ari

This server falls under the Coding Agents category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • This repository demonstrates how to use AutoGen to integrate

Use Cases

Integrate local and remote servers
Web browsing automation
SaM-92

Maintainer

LicenseMIT
Languagepython
Versionv1.0.0
UpdatedFeb 26, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx mcp-autogen-sse-stdio

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use AutoGen MCP Integration

This repository is a reference implementation showing how to connect Microsoft AutoGen agents to both local MCP servers via stdio and remote MCP servers via Server-Sent Events (SSE), enabling agent workflows that transparently mix on-device tools with cloud-hosted capabilities. It ships a local math tool server (math_server.py) accessible through stdio and integrates the Apify RAG Web Browser Actor via SSE for live web search and news summarisation. Python developers learning AutoGen or building multi-tool agent pipelines use it as a starting point for wiring MCP transports into their own agents.

Prerequisites

  • Python 3.12 or higher
  • uv package manager installed
  • An OpenAI API key (OPENAI_API_KEY) for the AutoGen LLM backend
  • An Apify API key (APIFY_API_KEY) for the remote SSE web browsing tool
  • Git to clone the repository
1

Clone the repository

Clone the mcp_autogen_sse_stdio repository to your local machine.

git clone https://github.com/SaM-92/mcp_autogen_sse_stdio.git
cd mcp_autogen_sse_stdio
2

Create a Python 3.12 virtual environment with uv

The project requires Python 3.12 specifically. Use uv to create and activate the environment.

uv venv --python 3.12
source .venv/bin/activate  # Windows: .venv\Scripts\activate
3

Install project dependencies

Install all dependencies from pyproject.toml using uv pip.

uv pip install -e .
4

Create and populate the .env file

Create a .env file in the project root with your OpenAI and Apify API keys.

OPENAI_API_KEY=your_openai_api_key
APIPY_API_KEY=your_apify_api_key
5

Run the demonstration script

Execute the main script from the project's parent directory as specified in the README. It runs two tasks: a local arithmetic calculation and a remote web news search.

uv run mcp_autogen_sse_stdio/main.py
6

Adapt the example for your own tools

To add your own local stdio MCP server, point math_server.py to your server script. To use a different SSE endpoint, replace the Apify SSE URL with your remote MCP server's SSE endpoint in main.py.

AutoGen MCP Integration Examples

Client configuration

Environment variable configuration needed in the .env file to run the AutoGen MCP integration examples.

{
  "env": {
    "OPENAI_API_KEY": "your_openai_api_key",
    "APIFY_API_KEY": "your_apify_api_key"
  },
  "note": "This project runs AutoGen agents directly via Python, not through a standard MCP client config. Run: uv run mcp_autogen_sse_stdio/main.py"
}

Prompts to try

Tasks you can instruct the AutoGen agent to perform using the local math tools and remote Apify web browser.

- "Calculate (3 + 5) x 12 using the local math tools."
- "Search the web for the latest news about Iran-US negotiations and summarise in 3 bullet points."
- "Add 847 and 253 locally, then search for current mortgage rates online and report both results."
- "What is 15 multiplied by 33? Also find today's top technology headlines."

Troubleshooting AutoGen MCP Integration

uv run fails with 'Python 3.12 not found'

Install Python 3.12 explicitly with uv: uv python install 3.12. Then recreate the venv with uv venv --python 3.12.

Apify SSE connection times out or returns 401

Confirm APIFY_API_KEY is spelled correctly in .env (note: some setups use APIPIFY_API_KEY — check the exact variable name used in main.py). Verify your Apify account has the RAG Web Browser Actor enabled.

Script must be run from the parent directory, not from inside mcp_autogen_sse_stdio/

The README explicitly states the script must be executed from the parent directory using uv run mcp_autogen_sse_stdio/main.py. Running python main.py from inside the directory will cause import errors.

Frequently Asked Questions about AutoGen MCP Integration

What is AutoGen MCP Integration?

AutoGen MCP Integration is a Model Context Protocol (MCP) server that this repository demonstrates how to use autogen to integrate local and remote mcp (model context protocol) servers. it showcases a local math tool (math_server.py) using stdio and a remote apify tool (rag web browser actor) via sse for tasks like ari It connects AI assistants to external tools and data sources through a standardized interface.

How do I install AutoGen MCP Integration?

Follow the installation instructions on the AutoGen MCP Integration GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with AutoGen MCP Integration?

AutoGen MCP Integration works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is AutoGen MCP Integration free to use?

Yes, AutoGen MCP Integration is open source and available under the MIT license. You can use it freely in both personal and commercial projects.

Browse More Coding Agents MCP Servers

Explore all coding agents servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "mcp-autogen-sse-stdio": { "command": "npx", "args": ["-y", "mcp-autogen-sse-stdio"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use AutoGen MCP Integration?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides