SDK Python
A model-driven approach to building AI agents in just a few lines of code.
What is SDK Python?
SDK Python is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to model-driven approach to building ai agents in just a few lines of code.
A model-driven approach to building AI agents in just a few lines of code.
This server falls under the Coding Agents category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- A model-driven approach to building AI agents in just a few
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx sdk-pythonConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use SDK Python
Strands Agents SDK is an open-source Python (and TypeScript) framework from AWS that takes a model-driven approach to building AI agents — you define tools and a model, and the SDK handles the agentic loop, tool calling, streaming, and multi-agent orchestration in just a few lines of code. It defaults to Amazon Bedrock as its model provider (supporting Claude Sonnet on Bedrock out of the box) and also integrates with Anthropic direct, OpenAI, Gemini, Ollama, and LiteLLM for local and third-party models. Developers use it to rapidly prototype and deploy production-grade AI agents with MCP support, structured output, guardrails, and event-driven observability.
Prerequisites
- Python 3.10 or later (for the Python SDK)
- Node.js 20 or later (for the TypeScript SDK)
- AWS credentials configured with Bedrock model access enabled (default provider), OR an Anthropic/OpenAI/Gemini API key if using those providers instead
- pip or uv for Python package installation
Install the Python SDK
Install the core strands-agents package and the optional built-in tools package. Python 3.10+ is required.
pip install strands-agents strands-agents-toolsConfigure your model provider
By default Strands uses Amazon Bedrock. Ensure your AWS credentials are configured, or switch to a different provider by importing an alternate model provider class.
# Default: Amazon Bedrock (requires AWS credentials)
aws configure
# Or use Anthropic direct:
pip install anthropic
# then in code:
from strands.models.anthropic import AnthropicModel
model = AnthropicModel(model_id='claude-sonnet-4-6', api_key='sk-ant-...')Create your first agent
Import Agent and pass a list of tools. The agent automatically handles the tool-calling loop until the task is complete.
from strands import Agent
from strands_tools import calculator
agent = Agent(tools=[calculator])
result = agent("What is the square root of 1764?")
print(result)Connect an MCP server as a tool source
Strands natively supports MCP servers. Use MCPClient to connect and automatically load all tools from any MCP-compatible server.
from strands import Agent
from strands.tools.mcp import MCPClient
mcp_client = MCPClient(
command='npx',
args=['-y', '@wonderwhy-er/desktop-commander@latest']
)
with mcp_client:
agent = Agent(tools=mcp_client.list_tools_sync())
agent("Read the file at ~/project/main.py and summarise it")Use the TypeScript SDK
For TypeScript projects, install the npm package and invoke the agent similarly.
npm install @strands-agents/sdk
// agent.ts
import { Agent } from '@strands-agents/sdk';
const agent = new Agent();
const result = await agent.invoke('What is the capital of France?');
console.log(result);SDK Python Examples
Client configuration
Strands Agents SDK is a library you embed in your own code, not an MCP server. A typical Python script using the Anthropic provider directly looks like this:
from strands import Agent
from strands.models.anthropic import AnthropicModel
from strands_tools import file_read, shell
model = AnthropicModel(
model_id='claude-sonnet-4-6',
api_key='sk-ant-your-key-here'
)
agent = Agent(model=model, tools=[file_read, shell])
agent("List all Python files in the current directory")Prompts to try
Example tasks well-suited to Strands agents with tool access.
- "Calculate the compound interest on $10,000 at 5% over 10 years"
- "Read the contents of config.yaml and validate all required keys are present"
- "Search the web for recent Python 3.13 release notes and summarise the new features"
- "Build a two-agent pipeline where one agent writes tests and another reviews them"Troubleshooting SDK Python
NoCredentialsError when using the default Bedrock provider
Run `aws configure` to set up your AWS access key and secret, or set the AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, and AWS_DEFAULT_REGION environment variables. Also ensure you have enabled model access for Claude Sonnet in the Bedrock console for your region.
ModuleNotFoundError: No module named 'strands_tools'
Install the tools package separately: `pip install strands-agents-tools`. It is a distinct package from the core SDK.
MCP tools not loading from MCPClient
Ensure the MCP server command runs successfully in your terminal before embedding it in MCPClient. The MCPClient context manager must remain open while the agent is running — do not call list_tools_sync outside the `with mcp_client:` block.
Frequently Asked Questions about SDK Python
What is SDK Python?
SDK Python is a Model Context Protocol (MCP) server that model-driven approach to building ai agents in just a few lines of code. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install SDK Python?
Follow the installation instructions on the SDK Python GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with SDK Python?
SDK Python works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is SDK Python free to use?
Yes, SDK Python is open source and available under the Apache-2.0 license. You can use it freely in both personal and commercial projects.
SDK Python Alternatives — Similar Coding Agents Servers
Looking for alternatives to SDK Python? Here are other popular coding agents servers you can use with Claude, Cursor, and VS Code.
Dify
★ 142.2kProduction-ready platform for agentic workflow development.
Ruflo
★ 54.0k🌊 The leading agent orchestration platform for Claude. Deploy intelligent multi-agent swarms, coordinate autonomous workflows, and build conversational AI systems. Features enterprise-grade architecture, self-learning swarm intelligence, RAG integrat
Goose
★ 45.7kan open source, extensible AI agent that goes beyond code suggestions - install, execute, edit, and test with any LLM
Antigravity Awesome Skills
★ 38.3kInstallable GitHub library of 1,400+ agentic skills for Claude Code, Cursor, Codex CLI, Gemini CLI, Antigravity, and more. Includes installer CLI, bundles, workflows, and official/community skill collections.
AgentScope
★ 25.5kBuild and run agents you can see, understand and trust.
Serena
★ 24.5kA coding agent toolkit that provides IDE-like semantic code retrieval and editing tools, enabling LLMs to efficiently navigate and modify codebases using symbol-level operations instead of basic file reading and string replacements.
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.
Set Up SDK Python in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use SDK Python?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.