AgentCore MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@AgentCore MCP Serverlist your tools"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
AgentCore MCP Server
A basic MCP (Model Context Protocol) server for deployment to Amazon Bedrock AgentCore Runtime.
Project Structure
.devcontainer/
├── devcontainer.json
└── Dockerfile
mcp_server.py
requirements.txtRelated MCP server: FastMCP Example Server
Prerequisites
VS Code with the Dev Containers extension
Docker running locally
AWS account with credentials configured
A Cognito user pool for authentication (see setup guide)
Local Development
Open this folder in VS Code
When prompted, click "Reopen in Container" (or run
Dev Containers: Reopen in Containerfrom the command palette)Start the MCP server:
python mcp_server.pyThe server runs at
http://localhost:8000/mcp
Test locally with MCP Inspector
npx @modelcontextprotocol/inspectorThen connect to http://localhost:8000/mcp in the inspector UI.
Deploy to AWS AgentCore
1. Scaffold the project
agentcore create --protocol MCPFollow the prompts. When asked, provide your Cognito discovery URL and client ID.
2. Copy your server code
Copy mcp_server.py into the generated project directory and ensure the entrypoint in agentcore/agentcore.json points to it.
3. Deploy
agentcore deployThis packages your code, uploads to S3, and creates the AgentCore runtime. You'll receive an agent runtime ARN on success.
4. Invoke the deployed server
export AGENT_ARN="arn:aws:bedrock-agentcore:us-west-2:ACCOUNT_ID:runtime/YOUR_RUNTIME"
export BEARER_TOKEN="your-cognito-access-token"import asyncio
from mcp import ClientSession
from mcp.client.streamable_http import streamablehttp_client
async def main():
encoded_arn = AGENT_ARN.replace(':', '%3A').replace('/', '%2F')
url = f"https://bedrock-agentcore.us-west-2.amazonaws.com/runtimes/{encoded_arn}/invocations?qualifier=DEFAULT"
headers = {"authorization": f"Bearer {BEARER_TOKEN}"}
async with streamablehttp_client(url, headers, timeout=120, terminate_on_close=False) as (read, write, _):
async with ClientSession(read, write) as session:
await session.initialize()
print(await session.list_tools())
asyncio.run(main())Agent Instructions
Use the following when providing this project as context to an AI coding agent.
## AgentCore MCP Server - Agent Context
This project is an MCP server targeting Amazon Bedrock AgentCore Runtime.
### Key facts
- Base image: `public.ecr.aws/docker/library/python:3.14`
- Runtime: Python with `mcp` package (FastMCP)
- Server binds to `0.0.0.0:8000/mcp` (required by AgentCore)
- Transport: `streamable-http` with `stateless_http=True`
- Node.js 24 LTS and `@aws/agentcore` CLI are available in the container
- Deploy with: `agentcore create --protocol MCP` then `agentcore deploy`
### Adding tools
Add new tools by decorating functions with `@mcp.tool()` in `mcp_server.py`:
@mcp.tool()
def my_tool(param: str) -> str:
"""Description of what this tool does"""
return result
### Deployment workflow
1. `agentcore create --protocol MCP` — scaffolds project config
2. Ensure `agentcore/agentcore.json` entrypoint points to `mcp_server.py`
3. `agentcore deploy` — builds, uploads, and deploys
4. Invoke via the AgentCore endpoint with a Bearer token from Cognito
### Constraints
- Server MUST listen on `0.0.0.0:8000` (AgentCore requirement)
- The `/mcp` path is the default and expected by the platform
- Use `stateless_http=True` unless multi-turn/elicitation is neededThis server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-quality-maintenanceA proof-of-concept implementation that enables Amazon Bedrock AgentCore to interact with AWS Lambda functions and REST APIs through the Model Context Protocol. It provides a gateway for protocol translation and supports direct server implementation using the FastMCP framework.Last updated
- Flicense-qualityDmaintenanceEducational example of an MCP server built with FastMCP, demonstrating how to expose tools, resources, and prompts for AI clients.Last updated
- Flicense-qualityDmaintenanceMCP server with example tools for arithmetic and greeting, designed for deployment on Amazon Bedrock AgentCore Runtime with OAuth authentication.Last updated4
- Alicense-qualityBmaintenanceA dead simple MCP server for exposing your app functions to AI agents like Claude Desktop.Last updated5385MIT
Related MCP Connectors
MCP server for AI dialogue using various LLM models via AceDataCloud
A basic MCP server to operate on the Postman API.
MCP server exposing the Backtest360 engine API as tools for AI agents.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/SteveRadich/template-aws-agentcore-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server