Summary
This release introduces a new BedrockAgentFunctionResolver to Event Handler that simplifies connecting AWS Lambda functions to Amazon Bedrock Agents. This feature eliminates the need to write boilerplate code for parsing requests and formatting responses, allowing you to focus on your agent's business logic.
⭐ A big thank you to @VatsalGoel3 and @svozza for their contributions to this release and to Instil for becoming a public customer reference!
Creating Amazon Bedrock Agents
You can now use the new BedrockAgentFunctionResolver
to register tools and handle requests in your Lambda functions. The resolver will automatically parse the request, route it to the appropriate function, and return a well-formed response that includes the tool's output and any existing session attributes.
By default, errors are handled gracefully and returned to the agent with error type and message information, allowing the conversation to continue. This is useful when you want to let the LLM handle errors and reduce boilerplate error-handling code.
If you need more control over error scenarios, you can use BedrockFunctionResponse
to customize the response and determine if the conversation should continue:
You can also use the BedrockFunctionResponse
when you want to enrich the response with session attributes or knowledge base configurations, or when you want the agent to re-prompt the user to provide additional information.
Changes
- chore: fix esm scope for layers stack (#4007) by @dreamorosi
- chore(commons): consolidate boolean parsing (#3970) by @dreamorosi
🌟New features and non-breaking changes
- feat(event-handler): add Amazon Bedrock Agents Functions Resolver (#3957) by @svozza
- feat(commons): environment variable helpers (#3945) by @dreamorosi
📜 Documentation updates
- docs: add bedrock agents page to llmtxt (#4010) by @dreamorosi
- docs(event-handler): add docs page for Bedrock Agent Function (#3991) by @dreamorosi
- chore(deps): bump the aws-cdk group across 1 directory with 3 updates (#4004) by @dependabot[bot]
- chore(deps): bump @types/node from 22.15.23 to 22.15.29 (#4001) by @dependabot[bot]
- chore(deps): bump the aws-sdk-v3 group across 1 directory with 9 updates (#4002) by @dependabot[bot]
- chore(deps): bump aws-cdk-lib from 2.198.0 to 2.199.0 in the aws-cdk group across 1 directory (#3984) by @dependabot[bot]
- chore(deps): bump @types/node from 22.15.21 to 22.15.23 (#3985) by @dependabot[bot]
- chore(deps): bump esbuild from 0.25.4 to 0.25.5 (#3980) by @dependabot[bot]
- chore: add Instil as customer reference (#3978) by @dreamorosi
- chore(deps): bump the aws-sdk-v3 group across 1 directory with 9 updates (#3975) by @dependabot[bot]
- chore(deps): bump aws-cdk-lib from 2.197.0 to 2.198.0 in the aws-cdk group across 1 directory (#3968) by @dependabot[bot]
- chore: add latest to site_url (#3966) by @hjgraca
- chore(deps): bump the aws-sdk-v3 group across 1 directory with 9 updates (#3965) by @dependabot[bot]
- chore(deps): bump the aws-cdk group across 1 directory with 3 updates (#3954) by @dependabot[bot]
- chore(deps): bump @types/node from 22.15.19 to 22.15.21 (#3956) by @dependabot[bot]
- docs: clarify zod version support (#3961) by @dreamorosi
- chore: Add llms.txt to documentation (#3953) by @hjgraca
🐛 Bug and hot fixes
- fix(parameters): preserve original stack trace on transform failures … (#3982) by @VatsalGoel3
🔧 Maintenance
- docs(event-handler): add docs page for Bedrock Agent Function (#3991) by @dreamorosi
- chore(deps): bump the aws-cdk group across 1 directory with 3 updates (#4004) by @dependabot[bot]
- chore(deps-dev): bump lint-staged from 16.0.0 to 16.1.0 (#3994) by @dependabot[bot]
- chore(deps): bump @types/node from 22.15.23 to 22.15.29 (#4001) by @dependabot[bot]
- chore(deps): bump the aws-sdk-v3 group across 1 directory with 9 updates (#4002) by @dependabot[bot]
- chore(deps): bump ossf/scorecard-action from 2.4.1 to 2.4.2 (#4003) by @dependabot[bot]
- chore(deps-dev): bump zod from 3.25.32 to 3.25.48 (#4000) by @dependabot[bot]
- chore(deps): bump vscode/devcontainers/javascript-node from
1ab856e
to0d29e5f
in /.devcontainer (#3996) by @dependabot[bot] - chore(deps-dev): bump @redis/client from 5.1.0 to 5.1.1 (#3986) by @dependabot[bot]
- chore(deps): bump aws-cdk-lib from 2.198.0 to 2.199.0 in the aws-cdk group across 1 directory (#3984) by @dependabot[bot]
- chore(event-handler): align implementation with other runtimes (#3989) by @dreamorosi
- chore(deps-dev): bump typedoc from 0.28.4 to 0.28.5 in the typescript group across 1 directory (#3979) by @dependabot[bot]
- chore(deps): bump @types/node from 22.15.21 to 22.15.23 (#3985) by @dependabot[bot]
- chore(deps-dev): bump zod from 3.25.28 to 3.25.32 (#3987) by @dependabot[bot]
- chore(deps): bump esbuild from 0.25.4 to 0.25.5 (#3980) by @dependabot[bot]
- chore: add Instil as customer reference (#3978) by @dreamorosi
- chore(deps-dev): bump zod from 3.25.23 to 3.25.28 (#3976) by @dependabot[bot]
- chore(deps): bump the aws-sdk-v3 group across 1 directory with 9 updates (#3975) by @dependabot[bot]
- chore(deps): bump aws-cdk-lib from 2.197.0 to 2.198.0 in the aws-cdk group across 1 directory (#3968) by @dependabot[bot]
- feat(event-handler): add Amazon Bedrock Agents Functions Resolver (#3957) by @svozza
- chore(deps-dev): bump zod from 3.25.7 to 3.25.23 (#3969) by @dependabot[bot]
- chore: switch codebase to default esm (#3959) by @dreamorosi
- chore(deps): bump the aws-sdk-v3 group across 1 directory with 9 updates (#3965) by @dependabot[bot]
- chore(deps-dev): bump the vitest group across 1 directory with 2 updates (#3947) by @dependabot[bot]
- chore(deps): bump the aws-cdk group across 1 directory with 3 updates (#3954) by @dependabot[bot]
- chore(deps-dev): bump @redis/client from 5.0.1 to 5.1.0 (#3949) by @dependabot[bot]
- chore(deps): bump @types/node from 22.15.19 to 22.15.21 (#3956) by @dependabot[bot]
- feat(commons): environment variable helpers (#3945) by @dreamorosi
- chore(deps-dev): bump zod from 3.24.4 to 3.25.7 (#3948) by @dependabot[bot]
This release was made possible by the following contributors:
@VatsalGoel3, @dreamorosi, @hjgraca, and @svozza