Install
pip install strands-agents bedrock-agentcore boto3npm install -g @aws/agentcore # CLIBuild agents on AWS in Python: Strands Agents for the agent loop, Amazon Bedrock AgentCore Runtime and Harness for hosting, plus Memory, Gateway, Identity, A2A and Agents Classic.
Write the agent with Strands Agents (or LangGraph, CrewAI, the OpenAI Agents SDK and others). Run it on AgentCore Runtime by wrapping it in BedrockAgentCoreApp and deploying it with the AgentCore CLI. If you don’t need your own code, declare a managed harness instead: model, system prompt and tools as configuration, run by AgentCore.
Install
pip install strands-agents bedrock-agentcore boto3npm install -g @aws/agentcore # CLIVersion
strands-agents 1.64.0 · bedrock-agentcore 1.26.0 · boto3 1.44.2 · AgentCore CLI 1.0.2 · Python 3.10+ (checked 2026-11-19)
A Strands agent served with the AgentCore Runtime contract (POST /invocations and GET /ping on port 8080):
from bedrock_agentcore import BedrockAgentCoreAppfrom strands import Agent
app = BedrockAgentCoreApp()agent = Agent(model="us.anthropic.claude-sonnet-5-5")
@app.entrypointdef invoke(payload, context): prompt = payload.get("prompt") if not isinstance(prompt, str): raise ValueError("prompt must be a string") return {"result": str(agent(prompt))}
if __name__ == "__main__": app.run()Run it with python main.py and curl -X POST localhost:8080/invocations -d '{"prompt": "Hello"}'. Getting started shows how to deploy it.