At 02:14 the cost agent found a runaway NAT gateway bill, drafted a fix, and asked to apply it. Nobody could say which IAM role it would use, what it was allowed to change, or what the session had cost so far. That gap is the whole subject of amazon bedrock agentcore in production. This guide builds agentcore production guardrails step by step: one IAM role per tool, deterministic policy checks at the Gateway, human approval before consequential actions, scoped memory, full audit trails, and cost caps that hold even when the agent loops.
What Amazon Bedrock AgentCore Is, and What It Is Not
Amazon Bedrock AgentCore is AWS infrastructure for running agents in production: a managed Runtime, a Gateway for tools, Identity, Memory, Observability, Policy, and Evaluations. It does not write your agent logic. Frameworks such as LangGraph or CrewAI can still build the reasoning; AgentCore hosts, connects, and governs it.
Start with the boundary, because most confusion about amazon bedrock agentcore comes from treating it as a chatbot product. AgentCore is a set of managed services for operating agents you build. Your code, or a framework you choose, decides how the agent reasons. AgentCore provides the production plumbing around that reasoning: where the agent runs, how it reaches tools, whose identity it carries, what it remembers, what it may do, and what record it leaves behind.
The timeline matters for production planning. Amazon Bedrock AgentCore reached general availability on 13 October 2025 with Runtime, Memory, Gateway, Identity, and Observability, plus managed Browser and Code Interpreter tools. Two governance pieces arrived later: AgentCore Policy reached general availability on 3 March 2026, and AgentCore Evaluations followed on 31 March 2026. A managed agent loop called Harness reached general availability in June 2026, and a next-generation Runtime, referred to as V2, became available as an opt-in on 18 September 2026 with snapshot restore and memory reclaim during sessions. Optimization, Agent Registry, and Payments were still preview items in late 2026 coverage, so this guide treats them as preview and builds nothing load-bearing on them.
That GA history gives you a simple rule. The core services have more than a year of production mileage, so you can standardise on them. Policy and Evaluations are younger, so you should adopt them with the same care you would give any new control plane: run policy in log-only mode first, measure what it would have denied, then enforce.
For a DevOps team, the practical question is not whether an agent can call a tool. Any prototype can do that. The question is whether you can prove, after the fact, what the agent did, which identity it used, what it cost, and where its limits were. AgentCore exists to make those answers structural instead of forensic. The rest of this guide uses one running example: a cost-anomaly agent that reads AWS cost data, checks internal policy, drafts a remediation plan, and opens a ticket for human approval before anything changes. Every guardrail below maps to that agent, and the same pattern transfers to incident triage, change review, and runbook agents.
One more framing point before the build. AgentCore does not replace your existing AWS governance. IAM, CloudTrail, CloudWatch, VPC controls, KMS encryption, and AWS Organizations policies still apply, and the strongest setups compose AgentCore controls with them rather than choosing between layers. If your platform team already runs guardrails for humans and CI pipelines, the agent should inherit the same account structure, tagging rules, and audit pipeline. Treat the agent as a new workload class inside your platform, not as an exception to it.
The 970+ Incident Handbook & K8s Runbooks are exclusive to subscribers — unlock for FREE
Get battle-tested production runbooks, AWS architecture blueprints, and zero-downtime CI/CD post-mortems sent directly to your inbox. 100% free, no spam.
Amazon Bedrock AgentCore Architecture: Runtime, Gateway, Identity
The production shape of amazon bedrock agentcore has three load-bearing parts. Runtime hosts the agent in an isolated microVM per session. Gateway is the single entry point for tool calls and the place policy checks run. Identity decides whose credentials each call carries. Route every tool call through the Gateway or the controls do not apply.
AgentCore Runtime is a serverless execution environment built for agents. Each session runs in an isolated microVM, sessions can run long enough for multi-step work, and compute billing is per second of active processing, with CPU usage dropping during model wait time. Runtime V2 restores new instances from a snapshot, which shortens cold starts, and reclaims unused memory during a session so you pay closer to actual use. For guardrails, the key Runtime property is isolation: one session cannot read another session's files, environment, or in-flight state.
AgentCore Gateway turns your existing systems into tools an agent can call. Lambda functions, OpenAPI and Smithy APIs, and MCP servers become tools behind one managed endpoint, with semantic tool search so the agent can find the right tool without loading every definition into context. The Gateway is also where governance becomes concrete. Policy evaluation, rate limiting, and inbound and outbound authorisation all sit on the Gateway path. That placement has a hard consequence: a tool call that bypasses the Gateway bypasses the checks. If your agent code can reach a database, an internal API, or an AWS service directly with ambient credentials, your policy layer is decorative. Production designs therefore make the Gateway the only road to tools, and they remove direct credentials from the agent process wherever possible.
AgentCore Identity handles who the agent acts as. It supports inbound authentication with IAM SigV4 or OAuth through providers such as Cognito, Okta, and Entra ID, and it holds outbound tokens and API keys in a vault so the agent can call third-party systems on a user's behalf without seeing raw secrets. The design decision is whether the agent acts as itself, with a workload identity you scope, or on behalf of a signed-in user, inheriting that user's permissions. For DevOps agents that read cost data or open tickets, a workload identity with narrow permissions is usually cleaner to audit. For agents that read a user's own documents or tickets, user-scoped identity keeps the permission boundary aligned with the data owner.
Memory and Observability complete the core. Memory stores short-term session context and long-term records that persist across sessions, with strategies for semantic recall, summarisation, user preferences, and episodic records. Observability emits OpenTelemetry traces covering model calls, tool calls, token counts, and latency into CloudWatch, where you can query them alongside the rest of your platform telemetry. Evaluations score agent behaviour with built-in and custom evaluators, and Policy enforces deterministic rules at the Gateway. The next sections take each control in turn, starting with the one that prevents the most damage per hour of setup: IAM scoping.
If you want the framework-neutral version of this control set first, our AI agent guardrails framework guide covers the same risk map without AWS specifics. The sections below translate that map into AgentCore mechanics.
IAM Least Privilege: One Role per Agent Tool
The first of the agentcore production guardrails is identity scoping. Give each tool its own IAM role, scoped by task, account, and data domain, with no wildcards on actions or resources. The agent runtime role should be able to invoke tools through the Gateway and little else. Broad roles turn a prompt mistake into an account incident.
Agents fail differently from normal software. They reason, choose tools, and retry, so a confused agent can repeat a harmful call many times with full confidence. IAM scoping is the control that bounds that blast radius. The pattern AWS guidance repeats is simple: least privilege for every tool, each tool with its own IAM role, scoped by task, account, and data domain, and no wildcard actions or resources in production policies.
Split the identities into three layers. First, the Runtime execution role: it starts sessions, writes logs, reads its own configuration, and calls the Gateway. It should not hold direct permissions to change infrastructure. Second, one role per tool: the cost-reading tool gets read-only Cost Explorer and CUR access in the billing account; the ticket tool gets permission to create and comment on tickets in one project; the remediation tool, if you ever grant one, gets a narrow set of change actions with resource-level conditions. Third, the human approver identity: approvals happen under a person's credentials or a workflow role, never under the agent's role, so the audit trail separates proposal from authorisation.
Here is the shape of a read-only tool role for the cost agent. Note the explicit resource scoping, the condition keys, and the absence of any write action:
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "ReadCostDataOnly",
"Effect": "Allow",
"Action": [
"ce:GetCostAndUsage",
"ce:GetCostForecast",
"ce:GetAnomalies"
],
"Resource": "*",
"Condition": {
"StringEquals": { "aws:PrincipalTag/agent": "cost-anomaly" }
}
},
{
"Sid": "DenyAllChanges",
"Effect": "Deny",
"Action": ["ec2:*", "rds:*", "s3:Delete*", "iam:*"],
"Resource": "*"
}
]
}
Cost Explorer APIs do not support resource-level ARNs for every call, which is why the condition and the explicit deny carry weight here. Where resource-level permissions exist, use them. Where they do not, compensate with account separation: run the agent in a tooling account, give it cross-account read roles into workload accounts, and keep write paths in a different account that only the approval workflow can reach.
Two habits make this sustainable. Tag every agent, tool, and session with the owning team and cost centre, because tags feed both IAM conditions and the cost attribution in a later section. And review tool roles on the same cadence as human roles, with Access Analyzer findings treated as defects. An agent tool role that quietly accumulated permissions during prototyping is the most common production surprise, and it is entirely preventable with a pre-launch policy diff. If your team also builds MCP servers for these tools, the MCP server tutorial for DevOps shows how to expose Kubernetes tools with the same scoping discipline.
AgentCore Policy vs Bedrock Guardrails: Actions vs Content
Bedrock Guardrails control what an agent says, using classifiers for harmful content, PII, prompt injection, and grounding. AgentCore Policy controls what an agent does, checking each Gateway tool call against Cedar rules with a deterministic allow or deny. Production setups need both layers, because neither covers the other.
The most common design error in agentcore production guardrails is treating content filters as action controls. Amazon Bedrock Guardrails screen language: harmful content categories, denied topics, word filters, sensitive information filters, contextual grounding checks, and automated reasoning checks. They rely on classifiers, so their decisions are probabilistic. A well-crafted prompt can sometimes talk its way past a content filter, and that is acceptable for a filter whose job is reducing harmful output. It is not acceptable for a control whose job is preventing a delete call in production.
AgentCore Policy fills that second role. It evaluates tool calls that pass through AgentCore Gateway against Cedar policies, written directly in Cedar or drafted from natural language and then reviewed. The check is deterministic: the same request always receives the same allow or deny, so a manipulated prompt cannot override a deny. Policy runs in LOG_ONLY mode while you tune it, then ENFORCE mode when the rules match your intent. Default posture is deny, and a forbid rule wins over a permit rule.
A Cedar rule for the cost agent might permit reading cost data while forbidding any tool that changes infrastructure, and forbidding ticket creation outside the owning team's project:
permit(
principal,
action == AgentCore::Action::"get_cost_and_usage",
resource
);
forbid(
principal,
action in [AgentCore::Action::"apply_change",
AgentCore::Action::"delete_resource"],
resource
);
permit(
principal,
action == AgentCore::Action::"create_ticket",
resource
) when {
context.project == "platform-cost"
};
Temporal policies extend this from single calls to sequences. A policy can tally what an agent has spent in a session and block the next purchase once a budget is reached, even when that purchase sits under the per-call limit. It can require that steps happen in a set order, that a value passed into one call matches what an earlier call returned, or that a significant action needs a recorded human approval first. These sequence rules close the gap where an agent places a series of individually acceptable calls that are unacceptable in total, which is exactly how runaway loops and threshold-gaming behaviour present in production.
Use the two layers together and assign each risk to the layer that can hold it. Prompt injection that tries to extract PII belongs to Guardrails plus output filtering. A tool call that would modify a production resource belongs to Policy plus IAM. A refund cap, a delete ban, a per-session budget, and a required approval step are all action rules, so they belong in Policy where the decision is deterministic and auditable. Write the rule, run it in LOG_ONLY against real traffic, read the would-deny log, and only then enforce. Skipping the log-only phase is how teams discover their policy forbids the agent's main job during an incident.
AgentCore Production Guardrails: Human Approval Gates
A bedrock agentcore human approval workflow separates proposal from execution. The agent drafts the change, a deterministic workflow routes it to a named approver with the evidence attached, and only an approval recorded under human credentials lets the change run. Classify actions by risk first, then automate only the tiers that earn it.
Approval gates are where agentcore production guardrails meet your existing change process. The design rule is separation: the agent proposes, a workflow routes, a human decides, and a separate execution path acts. The agent never holds the credentials that execute its own proposal, so a compromised or confused agent cannot approve itself.
Start by classifying every tool action into risk tiers. Read-only actions such as cost queries, log searches, and status checks can run autonomously under IAM and Policy controls. Reversible writes with small blast radius, such as opening a ticket, posting a summary to a channel, or tagging a resource for review, can run autonomously with audit logging. Consequential actions, meaning anything that changes production state, spends money, alters permissions, or deletes data, require recorded human approval. Irreversible actions should not be agent tools at all in the first release; keep them in human-run runbooks until the agent has a measured track record.
Implement the gate as a deterministic workflow, not as agent behaviour. A practical AWS pattern is Step Functions: the agent emits a structured proposal event, the state machine validates the proposal against schema and policy, sends an approval request with the evidence bundle attached, waits for the decision with a timeout, and on approval invokes the execution Lambda under its own scoped role. EventBridge carries the proposal event, and your ticketing system or chat tool carries the human decision. The agent's job ends at producing a good proposal: what it found, what it recommends, the exact change, the expected effect, the rollback step, and the cost estimate. Approvers reject vague proposals, so make the evidence bundle a required schema, not a writing suggestion.
Here is the proposal contract the cost agent must fill before the workflow accepts it:
{
"agent": "cost-anomaly",
"session_id": "sess_2026_12_06_0214",
"finding": "NAT gateway data processing up 38 percent week over week in eu-west-1",
"evidence": ["ce:GetCostAndUsage 2026-11-29 to 2026-12-05", "flow logs vpc-0a1b2c"],
"proposed_change": "Add VPC endpoints for S3 and DynamoDB in vpc-0a1b2c",
"expected_saving_usd_month": 412,
"rollback": "Delete the two gateway endpoints",
"risk_tier": "consequential",
"expires_at": "2026-12-07T02:14:00Z"
}
Expiry matters. An approval granted for a finding from yesterday should not execute against today's changed environment, so proposals carry a validity window and the workflow re-checks current state before acting. Record every decision, including rejections and timeouts, because rejection patterns are evaluation data: they tell you where the agent's judgement diverges from your engineers'. Our AI SRE agent evaluation guide covers how to score that divergence before widening autonomy. Widen tiers only on evidence: an action class moves from approval-gated to autonomous after a measured run of correct proposals, never because the demo looked smooth.
AgentCore Memory Scoping and Data Protection
AgentCore Memory stores short-term session context and long-term records across sessions. Scope every memory namespace to one agent, one user or team, and one data domain, set retention deliberately, and keep secrets and regulated data out of memory entirely. Memory is a data store, so it inherits your encryption, access, and deletion duties.
Memory is where agents quietly become data-protection problems. AgentCore Memory keeps short-term context inside a session and long-term records across sessions, with built-in strategies for semantic recall, summarisation, user preferences, and episodic records, plus override options for self-managed extraction. That convenience tempts teams to store everything the agent sees. Resist it. Every record in memory is data you must encrypt, scope, retain correctly, and delete on request.
Scope namespaces narrowly. A memory namespace should bind one agent, one principal scope, and one data domain: the cost agent's memory for the platform team holds cost findings and prior proposals, and it must never be readable by a support agent or by another team's cost agent. Cross-agent memory sharing feels efficient and creates the worst audit questions, because a record written under one agent's permissions gets read under another's. If two agents genuinely need shared facts, publish those facts to a system of record both can read under their own permissions, and keep memory private per agent.
Set retention per record type, not globally. Session context can expire in days. Proposal history may need to live as long as your change records do. User preferences live until the user revokes them. Long-term memory extraction should run with a reviewed prompt that extracts operational facts, such as which accounts a team owns and which endpoints already exist, and never extracts credentials, tokens, personal data, or customer content. Apply Bedrock Guardrails sensitive information filters on the write path as a second line, and test them with seeded records containing fake secrets to prove the filter fires.
Access control for memory follows the same per-tool IAM pattern as everything else. The agent's memory tool role can read and write its own namespace and nothing else. Human access to memory records goes through a reviewed admin path with its own logging, because debugging an agent by reading its memory is legitimate and must still leave a trail. Deletion needs a tested path too: when a user or team offboards, you should be able to enumerate and delete their records and prove the deletion in the audit log. Teams that cannot delete memory records cleanly should not enable long-term memory yet.
A final operational point: memory quality decays. Summaries drift, preferences go stale, and an agent with confident stale memory makes worse proposals than an agent with no memory. Review extraction quality in evaluations, expire records that stop being useful, and treat memory as a cache of operational facts with a source of truth elsewhere, never as the source of truth itself.
Observability and Audit Trails for Amazon Bedrock AgentCore
AgentCore Observability emits OpenTelemetry traces for model calls, tool calls, tokens, and latency into CloudWatch. Pair those traces with CloudTrail API records and model invocation logging, enable CloudWatch Transaction Search, and log every decision with its session id. If a step is not in the trace, you cannot defend it later.
Auditability is the guardrail that makes every other guardrail provable. For amazon bedrock agentcore, the record has three layers. AgentCore Observability produces OpenTelemetry traces of each session: model calls, tool calls, token counts, latency, and the reasoning steps between them, shipped to CloudWatch with per-agent metrics and log groups. CloudTrail records the AWS API calls made under each role, which ties tool execution to the IAM identity that performed it. Bedrock model invocation logging captures prompts and completions where your data policy permits storing them, with the redaction rules your compliance team sets.
Two setup details decide whether this works in practice. First, CloudWatch Transaction Search must be enabled for full trace search across spans; teams that skip it discover during their first incident that traces exist but cannot be queried end to end. Second, every log line and trace span needs the same correlation keys: session id, agent id, tool name, proposal id where one exists, and the approver identity where a human decided. Without shared keys, reconstructing one session means joining three systems by timestamp and hope.
Log the decision points, not just the calls. For each session you want the request, the model selected, each tool call with its input summary and output summary, each policy evaluation result, each approval decision, token usage, and cost. Policy denials deserve their own alarm, because a rising denial rate means the agent is probing boundaries or your rules drifted from the agent's job. Approval timeouts and rejections belong in the same dashboard, since they measure the human side of the system.
A Logs Insights query like this gives on-call a one-screen session reconstruction during an incident:
fields @timestamp, session_id, tool_name, policy_result, tokens_in, tokens_out, cost_usd
| filter session_id = "sess_2026_12_06_0214"
| sort @timestamp asc
Set alarms on the failure shapes agents produce: session cost above a threshold, tool error rate climbing, retry loops against one failing tool, policy denial spikes, and sessions that run far longer than the p95. A looping agent retrying a failing tool overnight is the canonical agent incident, and it is visible in traces hours before it is visible in the bill if the alarms exist. Route these alarms to the same on-call rotation that owns the agent's tools, because an agent alarm with no owner is a log line, not a control. Retention should match your audit requirements, and trace storage costs belong in the cost model in the next section, since observability is part of the true price of running agents.
AgentCore Production Guardrails for Cost: Caps and Attribution
AgentCore bills per component: Runtime per vCPU and GB hour, Gateway per tool call, Memory per GB and per record, with model tokens billed separately by Bedrock. Cap cost at three levels: per-session budgets enforced by policy, gateway rate limits, and account budgets with alarms. Attribute every session to a team through tags and trace fields.
Cost control fails for agents in a specific way: nothing breaks, the agent just keeps working. A loop that retries a failing tool, a session that pulls ever-larger context, or a fan-out of sub-agents can compound token and compute spend quietly. The agentcore production guardrails answer is layered caps, because no single budget control sees the whole picture.
First, know the meters. Prices checked on 6 December 2026 against the AWS AgentCore pricing page, US East, and you should verify your region before budgeting: Runtime v1 charges $0.0895 per vCPU-hour and $0.00945 per GB-hour, billed per second of active processing, while Runtime v2 consumption lists $0.1276 per vCPU-hour and $0.0169 per GB-hour with a committed baseline option. Gateway charges $0.005 per 1,000 invocations and $0.025 per 1,000 semantic search calls. Identity is free when used through Runtime or Gateway, and $0.010 per 1,000 token or API key requests otherwise. Short-term Memory moved on 6 October 2026 to $1.00 per GB ingested, $0.20 per GB retrieved, and $0.10 per GB-month stored; long-term Memory charges $0.75 per 1,000 records per month for built-in strategies and $0.50 per 1,000 retrievals. Web Search costs $7 per 1,000 queries. Policy authorization costs $0.000025 per request. Model inference tokens bill separately through Bedrock, and for most agents tokens are the largest line.
A worked example keeps this honest. Take 5,000 sessions in a month, each with 90 seconds of active processing on 1 vCPU and 2 GB of memory. Runtime v1 CPU is 125 vCPU-hours at $0.0895, which is $11.19. Memory is 250 GB-hours at $0.00945, which is $2.36. Gateway calls at, say, 20 tool calls per session add 100,000 invocations at $0.005 per 1,000, which is $0.50. The AgentCore platform cost is roughly $14 for the month, while model tokens for 5,000 multi-step sessions will typically run orders of magnitude higher. The lesson is not that agents are cheap; it is that token discipline, context size, and loop control decide the bill, so caps must watch tokens and session behaviour, not only compute.
Apply caps at three levels. Per-session budgets in Policy tally spend across the session and deny the call that would cross the budget, which stops loops at the source. Gateway rate limiting bounds tool call volume per agent and per tool, which protects downstream systems as well as the bill. Account-level AWS Budgets with alarms at 50, 80, and 100 percent of the monthly agent budget catch everything the first two layers miss, with a named owner who can disable the agent. Attribution ties it together: tag agents and tools by team and cost centre, carry session cost in trace fields, and report cost per completed task, not cost per session, because a cheap session that produced a rejected proposal is waste, not efficiency. Our guide to estimating AWS workload costs with an AI agent shows the estimation side of this discipline.
AgentCore Evaluations as Release Gates
AgentCore Evaluations score agent behaviour with 13 built-in evaluators plus custom ones, on live trace samples or on demand in CI. Gate releases on evaluation scores for correctness, tool selection, and safety, canary prompt and model changes, and treat a score regression like a failing test suite: it blocks the deploy.
Guardrails bound what an agent may do; evaluations measure whether it does its job well. AgentCore Evaluations reached general availability on 31 March 2026 with 13 built-in evaluators covering areas such as correctness, helpfulness, safety, task completion, and tool-selection accuracy, plus custom evaluators you define for your own criteria. Evaluations run on demand against test sessions or continuously against samples of live traces, which gives you both a pre-release gate and a production quality signal.
Build the release gate in three steps. First, assemble a golden set: real tasks with known-good outcomes, drawn from your ticket history and incident reviews, including the awkward cases where the correct behaviour is to refuse, escalate, or ask for approval. For the cost agent, the golden set includes anomalies with known causes, benign spend spikes that must not trigger proposals, and traps such as a proposal that would save money by breaking a compliance requirement. Second, score every candidate change, meaning prompt edits, model swaps, tool description changes, and policy updates, against the golden set in CI. Tool descriptions deserve special attention: a small wording change can shift tool selection across the whole agent, and evaluations catch that shift before users do. Third, set thresholds that block release: a drop in tool-selection accuracy or any safety evaluator failure stops the deploy, the same way a failing unit test does.
Production sampling closes the loop. Online evaluations score a sample of live traces, and score drift after a model provider update or a data change shows up there first. Feed rejected proposals and policy denials back into the golden set, because every human rejection is a labelled example of agent judgement diverging from yours. Over a quarter, that feedback loop is what earns wider autonomy: the evidence for moving an action class from approval-gated to autonomous is a sustained evaluation record, not a successful demo.
Keep the evaluation data honest. Golden sets rot when the underlying systems change, so review them on the same cadence as runbooks. Evaluator models can be gamed by verbose, confident output, so pair automated scores with sampled human review of traces, especially for safety criteria. And keep evaluation cost in the budget: scoring live traces consumes model calls, so sample rates are a cost decision as well as a quality decision. The agentic DevOps reference architecture places these gates inside a wider autonomy ladder, which is the right frame: autonomy expands one measured tier at a time.
Troubleshooting Amazon Bedrock AgentCore in Production
Most amazon bedrock agentcore production incidents fall into five shapes: policy denials from rules that drifted, tools reachable outside the Gateway, missing trace search, memory records leaking across scopes, and cost loops from retry behaviour. The table below maps each symptom to the check that finds it and the fix that holds.
When an agent misbehaves in production, resist debugging the prompt first. In amazon bedrock agentcore setups, the failure usually sits in the control layers around the model: a policy rule, an identity scope, a missing log, or a cost cap that was never wired. Work from the trace outward. Confirm the session id, read the span sequence, check the policy evaluation results, then read the tool outputs. The prompt is the last suspect, not the first.
| Symptom | Likely cause | Check | Fix |
|---|---|---|---|
| Tool calls suddenly denied | Policy rule drifted from the agent job, or a forbid rule matches broadly | Policy evaluation log for the session, LOG_ONLY history | Narrow the forbid rule, re-run LOG_ONLY, then enforce |
| Agent reaches a system Policy should block | Tool path bypasses the Gateway with ambient credentials | Runtime role permissions and direct network paths | Remove direct credentials, route the tool through Gateway |
| Traces exist but cannot be searched end to end | CloudWatch Transaction Search not enabled | Observability settings for the account | Enable Transaction Search and re-test with a fresh session |
| Agent recalls another team's facts | Memory namespace shared across agents or teams | Memory namespace bindings and tool role scope | Split namespaces per agent and team, delete leaked records |
| Session cost spikes overnight | Retry loop against a failing tool, context growing each step | Trace span count, token fields, tool error rate | Per-session budget in Policy, retry cap, gateway rate limit |
| Approvals time out during incidents | Approver routing has no fallback or expiry handling | Workflow state history and timeout records | Add fallback approvers, shorter expiry, re-check state on approval |
| Evaluation scores drop after a model change | Tool selection shifted with the new model behaviour | Evaluations diff on the golden set | Hold the release, fix tool descriptions, re-score |
Two habits prevent most rows in that table. Run every control change through the same review path as a code change, because a Cedar policy edit and an IAM policy edit are production changes with production blast radius. And rehearse the kill switch: disabling an agent, revoking a tool role, and switching Policy to a deny-all posture should be documented, tested actions that an on-call engineer can execute in minutes. An agent you cannot stop quickly is an agent you do not control, whatever the architecture diagram says.
Finish with the production checklist this guide builds toward. One IAM role per tool with no wildcard writes. Every tool call routed through the Gateway. Policy in ENFORCE after a LOG_ONLY tuning period, with temporal rules for session budgets and approval requirements. Guardrails screening content and sensitive information on input and output. Approval gates for every consequential action, with expiring proposals and recorded decisions. Memory namespaces scoped per agent and team, with retention and deletion tested. Traces searchable end to end, with alarms on cost, denials, and retry loops. Evaluations gating every release, with live sampling feeding the golden set. With those agentcore production guardrails in place, amazon bedrock agentcore becomes what it should be: boring infrastructure for agents you can defend in a change review, an audit, and an incident postmortem alike.
Frequently Asked Questions
Direct answers to common technical, architectural, and production troubleshooting questions.
What is Amazon Bedrock AgentCore?
Amazon Bedrock AgentCore is AWS infrastructure for running agents in production. It provides a managed Runtime, a Gateway for tool access, Identity, Memory, Observability, Policy, and Evaluations, plus managed Browser and Code Interpreter tools. It reached general availability on 13 October 2025. Your framework still builds the agent logic; AgentCore hosts and governs it.
Does AgentCore replace LangGraph or CrewAI?
No. LangGraph and CrewAI build agent reasoning and workflow logic. Amazon Bedrock AgentCore runs that logic in production and supplies the surrounding controls: session isolation, tool routing through the Gateway, identity, memory, policy checks, traces, and evaluations. Many production setups build with a framework and deploy onto AgentCore Runtime.
What is the difference between Bedrock Guardrails and AgentCore Policy?
Bedrock Guardrails control what an agent says, screening content, PII, and prompt injection with classifiers, so decisions are probabilistic. AgentCore Policy controls what an agent does, checking each Gateway tool call against Cedar rules with a deterministic allow or deny. Agentcore production guardrails need both: Guardrails for language risk, Policy for action risk.
How do approvals work before consequential actions?
The agent emits a structured proposal with evidence, expected effect, rollback, and an expiry time. A deterministic workflow such as Step Functions routes it to a named approver, and only a recorded human approval lets a separate execution role act. The agent never holds the credentials that execute its own proposal, and expired proposals are re-checked before running.
How do I attribute Bedrock cost per agent?
Tag each agent and tool with team and cost centre, carry session id and cost fields in OpenTelemetry traces, and tally spend per session in Policy so budgets can deny the call that crosses the cap. Report cost per completed task rather than per session. AgentCore meters Runtime, Gateway, Memory, and Policy separately, while model tokens bill through Bedrock.