Asynchronous patterns for calling Amazon Bedrock AgentCore agents in serverless pipelines
Amazon Web Services Daniel Abib
Amazon Bedrock AgentCore agent invocations in serverless pipelines were shown to be cheaper when the caller stops idling and instead resumes orchestration only after the agent finishes. The proposed task-token callback pattern uses a 120-second timeout/heartbeat safety net so the dispatcher Lambda can return quickly and Step Functions holds the wait without charging idle compute. As a result, costs shift away from blocking caller compute and the pipeline can be orchestrated either with task tokens, direct Step Functions integration, or durable functions instead of waiting synchronously.
Why it matters
In this post, you learn three serverless patterns (task-token callback, direct service integration, and durable functions) for invoking Amazon Bedrock AgentCore agents asynchronously from AWS Step Functions pipelines, eliminating idle compute costs while your AI agent processes requests.