Strands Agents MCP server

Server that enables execution of Strands agents through a plugin architecture, automatically discovering and registering plugins for seamless integration with existing workflows.
Back to servers
Setup instructions
Provider
Nacho Garay
Release date
May 18, 2025
Stats
6 stars

Strands Agent MCP serves as a bridge between the Strands agent framework and the Model Context Protocol (MCP), allowing you to register and execute Strands agents through MCP. This integration makes it possible to use Strands agents with Amazon Q and other MCP-compatible systems.

Installation

Since this package is currently in alpha stage and not yet available on PyPI, you'll need to install it from source:

# Clone the repository
git clone https://github.com/yourusername/strands-agent-mcp.git
cd strands-agent-mcp

# Install the package
pip install -e .

Running the MCP Server

Starting the server is straightforward:

strands-agent-mcp

This command launches the MCP server, making your Strands agents available through the MCP interface.

Configuration Options

You can customize the server behavior using these environment variables:

  • PLUGIN_PATH: Specify a custom path to look for plugins (default: ".")
  • PLUGIN_NAMESPACE: Define a custom namespace prefix for plugins (default: 'sap_mcp_plugin')

Creating Agent Plugins

The server uses a plugin architecture to make it easy to add new agents. To create a plugin:

  1. Create a Python package with a name starting with sap_mcp_plugin_
  2. Implement a build_agents function that returns a list of AgentEntry objects

Example Plugin

Here's a simple example of a Strands agent plugin:

from typing import List
from boto3 import Session
from strands import Agent
from strands.models import BedrockModel

from strands_agent_mcp.registry import AgentEntry

def build_agents() -> List[AgentEntry]:
    return [
        AgentEntry(
            name="my-agent",
            agent=Agent(
                model=BedrockModel(boto_session=Session(region_name="us-west-2"))
            ),
            skills=["general-knowledge", "coding"]
        )
    ]

This plugin creates an agent named "my-agent" with skills in general knowledge and coding.

Connecting to Amazon Q

After starting the MCP server, you can connect it to Amazon Q by following Amazon Q's documentation for setting up MCP connections.

Available MCP Tools

Once connected, the following MCP tools will be available:

  • execute_agent: Run an agent with parameters agent_name and prompt
  • list_agents: Get a list of all available agents

Sample Agent Usage

The repository includes a sample plugin that demonstrates how to create a simple agent:

from typing import List
from boto3 import Session
from strands import Agent
from strands.models import BedrockModel

from strands_agent_mcp.registry import AgentEntry

def build_agents() -> List[AgentEntry]:
    return [
        AgentEntry(
            name="simple-agent",
            agent=Agent(
                model=BedrockModel(boto_session=Session(region_name="us-west-2"))
            ),
            skills=["general-knowledge"]
        )
    ]

This sample creates a basic agent with general knowledge capabilities, using AWS Bedrock as the underlying model provider.

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "strands-agents-mcp" '{"command":"strands-agent-mcp","args":[]}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "strands-agents-mcp": {
            "command": "strands-agent-mcp",
            "args": []
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "strands-agents-mcp": {
            "command": "strands-agent-mcp",
            "args": []
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later