Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
EventBridge API Destination × AgentCore Runtime...
Search
Har1101
January 24, 2026
Technology
2
140
EventBridge API Destination × AgentCore Runtimeで実現するLambdaレスなイベント駆動エージェント
JAWS-UG 群馬 #36 presents - JAWS-UG 北陸新幹線 #5 in 群馬 での登壇資料です
Har1101
January 24, 2026
Tweet
Share
More Decks by Har1101
See All by Har1101
AgentCoreとHuman in the Loop
har1101
5
190
スケジュール駆動なエージェントを作ろう!
har1101
4
680
AIエージェントの設計で注意するべきポイント6選
har1101
6
3.2k
Now, go out
har1101
4
230
AWS re:Inventから考える、2026年のAIエージェント開発
har1101
2
600
CBとして行く初re:Invent 挑戦と失敗
har1101
2
330
Jr.Championsもいいけど、Community Buildersもね!
har1101
2
260
AgentCoreで始めるAmbient Agent
har1101
3
160
AgentCore×非同期実行で広がる、Ambient Agentの可能性
har1101
2
140
Other Decks in Technology
See All in Technology
新規事業 toitta におけるAI 機能評価の話 / AI Feature Evaluation in toitta
pokutuna
0
170
形式手法特論:コンパイラの「正しさ」は証明できるか? #burikaigi / BuriKaigi 2026
ytaka23
17
6.4k
これまでのネットワーク運用を変えるかもしれないアプデをおさらい
hatahata021
4
250
Bill One 開発エンジニア 紹介資料
sansan33
PRO
4
17k
Claude in Chromeで始める自律的フロントエンド開発
diggymo
1
230
Master Dataグループ紹介資料
sansan33
PRO
1
4.2k
20260120 Amazon VPC のパブリックサブネットを無くしたい!
masaruogura
2
150
AWS Amplify Conference 2026 - 仕様からリリースまで一気通貫生成 AI 時代のフルスタック開発
inariku
2
330
Introduction to Sansan for Engineers / エンジニア向け会社紹介
sansan33
PRO
6
64k
Agentic Coding 実践ワークショップ
watany
26
21k
クラウドセキュリティの進化 — AWSの20年を振り返る
kei4eva4
0
150
AI アクセラレータチップ AWS Trainium/Inferentia に 今こそ入門
yoshimi0227
1
300
Featured
See All Featured
Java REST API Framework Comparison - PWX 2021
mraible
34
9.1k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.7k
Getting science done with accelerated Python computing platforms
jacobtomlinson
1
100
Paper Plane
katiecoart
PRO
0
45k
So, you think you're a good person
axbom
PRO
2
1.9k
Six Lessons from altMBA
skipperchong
29
4.1k
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
1
280
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
0
49
Prompt Engineering for Job Search
mfonobong
0
150
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
49
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
Transcript
EventBridge API Destination × AgentCore Runtimeで実現する Lambdaレスなイベント駆動エージェント 2026/01/24 (土) JAWS-UG
群馬 #36 presents - JAWS-UG 北陸新幹線 #5 in 群馬 福地開
Who am I ? 福地 開 (ふくち はるき) @har1101mony 所属:JAWS-UG東京
年次:3年目 業務:Agent Builder 選出:AWS Community Builders (AI Engineering) 2025 Japan AWS Jr.Champions 2025 Japan All AWS Certifications Engineers
今日話すこと ◆Lambda無しでAgentCore Runtimeを動かす方法について • AgentCoreおさらい • これまでのEventBridge×AgentCore Runtime構成 • EventBridge
API Destination • イベント駆動エージェントを作る • まとめ ※資料中で「AI」と記載しているものは「生成AI」とりわけ「LLM」のことを指します ※所属組織とは一切関係ない、私個人の意見・考えとなります
AgentCore おさらい
Amazon Bedrock AgentCoreとは ◆AWS上でAIエージェントを展開・運用するためのプラットフォーム ◆全機能がサーバーレスで提供されている! https://github.com/awslabs/amazon-bedrock-agentcore-samples/tree/main/01-tutorials
Amazon Bedrock AgentCoreとは ◆AWS上でAIエージェントを展開・運用するためのプラットフォーム ◆全機能がサーバーレスで提供されている! https://github.com/awslabs/amazon-bedrock-agentcore-samples/tree/main/01-tutorials
Amazon Bedrock AgentCore Runtime とは ◆AIエージェント(およびツール)のコードをホストする基盤 • サーバーレスにスケール可能なコンテナ基盤 • 裏側では、ユーザーのセッションごとにマイクロVMを立ち上げてくれる
• LLMの出力待機時間など、I/O 待ちの時間はCPUリソースに課金されない • 実行時間を最長8時間に伸ばせるのでAIエージェントとの相性がGood https://speakerdeck.com/yuu551/2025nian-amazon-bedrock-agentcorematome (クラメソ神野さんの神資料読んでください!)
これまでの EventBridge×AgentCore Runtime 構成
◆EventBridge Rules + AgentCore Runtime • ポイント:RulesからRuntimeは直接呼べないため、呼び出し係としての Lambdaを挟む • このLambdaをできるだけ無くせるように頑張りたい
イベント駆動エージェントにはLambdaが必要
◆EventBridge Scheduler + AgentCore Runtime • ポイント:Lambda不要、直接AgentCore Runtimeを呼び出せるのがGood • ただ、やっぱりスケジュールだけではなくイベントでも動かしたい…
スケジュール駆動エージェントならシンプル
EventBridge API Destination
◆EventBridgeのターゲットにHTTPSエンドポイントを指定できる • ALB/API Gatewayに加えて、サードパーティのSaaS製品などと連携可能 • Connection経由で認証して外部のHTTPエンドポイントへリクエストを送る EventBridge API Destinationとは? 参考:https://docs.aws.amazon.com/ja_jp/eventbridge/latest/userguide/eb-api-destinations.html
◆AgentCore Runtimeのエンドポイント • OAuth認証の時はSDKではなくHTTPSリクエストが必要 ◆AgentCore Runtimeのインバウンド認証 • IAMかJWT(Cognitoなど)を選択する AgentCore Runtimeの制約
◆EventBridge API Destination • HTTPSエンドポイントをターゲットにできる • エンドポイントとの接続にOAuth認証を用いることができる ◆AgentCore Runtime •
HTTPSエンドポイントが存在する • インバウンド認証において、OAuthのAPIリクエストを受けJWTを検証する ◆良い感じに組み合わせられるのでは…? 2つを整理する
Lambda無しで イベント駆動エージェントを作る
◆Lambda無しでイベント駆動エージェント基盤を作る • EventBridge API DestinationのターゲットをAgentCore Runtimeの HTTPSエンドポイントに指定 • CognitoはM2M認証とし、Connectionに設定しておく •
RuntimeはCognitoを用いたJWT認証としておく アーキテクチャ
◆AgentCore Runtime • 非同期実行を用いる • HTTPSエンドポイントの記法に注意が必要 ◆EventBridge API Destination •
ターゲットの設定におけるエンドポイントのデコード処理 • 上記処理を回避してRuntimeのHTTPSエンドポイントを呼び出す方法 実装のポイント
AgentCore Runtimeの非同期実行 ◆普通に(=同期処理で)エージェントを動かすと、実行時間は15分まで ◆非同期処理にしておくと、最長8時間 ◆実装方法 • 非同期化したい処理を[app.add_async_task]と[app.complete_async_task] で挟む • この中でエージェントを動かすことも可能
https://docs.aws.amazon.com/bedrock-agentcore/latest/devguide/runtime-long-run.html
AgentCore RuntimeのHTTPSエンドポイント ◆コンソールからは確認できない値となっていることに注意 ◆以下ドキュメントを参考に、自分で少し組み替えてあげる ◆ARNをエンコードして(/や:を書き換えて)おく必要がある • https://bedrock-agentcore.ap-northeast-1.amazonaws.com/runtimes/ arn%3Aaws%3Abedrock-agentcore%3Aap-northeast-1%3A123456789012 %3Aruntime%2Fmy_agent-ABC123/invocations https://speakerdeck.com/yuu551/2025nian-amazon-bedrock-agentcorematome?slide=50
https://docs.aws.amazon.com/bedrock-agentcore/latest/devguide/runtime-oauth.html#invoke-agent https://docs.aws.amazon.com/bedrock-agentcore/latest/APIReference/API_InvokeAgentRuntime.html
EventBridge API Destinationのデコード処理 ◆設定されたURL の %XX エンコーディングを自動的にデコードして からリクエストを送信する仕組みになっている • arn%3Aaws%3A...
→ arn:aws:... と変換する (arn部分が問題になっている) ◆しかし、AgentCore RuntimeのHTTPSエンドポイントは エンコードされた状態のものを期待している(前ページ参照) • デコードされた状態で送信すると404 UnknownOperationExceptionとなる
リクエスト時の謎のエラーと手がかり https://docs.aws.amazon.com/bedrock-agentcore/latest/APIReference/API_InvokeAgentRuntime.html ◆accountID is required when agentRuntimeArn is provided as
agentId instead of agentRuntimeArn ◆日本語:agentRuntimeARN の代わりに agentId を渡した場合は accountId が必要です • ARNを使わなくてもできる方法を示してくれている? • ドキュメント的には確かにaccountIdも指定できそう…
エラー解決策 ◆agentId を渡した場合は accountId が必要 ◆逆説的にagentId+accountIdでagentRuntimeARNを代替できる? ◆従来の指定方法 • /runtimes/<エンコード済みARN>/my_agent/invocations •
ARNでエンコード・デコード問題が発生 ◆今回の指定方法 • /runtimes/<agentId>/invocations?accountId=123456789012 • パスに / を含む ARN を入れる必要がない • やってみたら動いたので動きます (公式ドキュメントに記載がないので動きが変わる可能性もあります)
コンソールで見るとこんな感じ
◆CDKで書いたので近い内にちゃんとした解説ブログ出します 最終的な実装
◆Lambdaレスイベント駆動エージェント基盤のお話をしました! • ちょっと面倒くさいですがEventBridgeから直接AgentCore Runtimeを 呼ぶことができました ◆目指せ「初手AI」な世界 • イベント駆動なエージェントの作り方は何となく出来上がってきた • あとは具体的にどんなユースケースで実装するか・実際に作って精度はどう
かを見て、エージェントを育てていきたい ◆2026年 AIエージェント「構築」元年、やっていきましょう〜! まとめ