[{"data":1,"prerenderedAt":78},["ShallowReactive",2],{"pattern-cloudfront-agentcore-runtime-cdk":3},{"id":4,"title":5,"architectureURL":6,"cleanup":7,"contributors":10,"deploy":13,"description":20,"extension":21,"framework":22,"gitHub":23,"highlight":6,"introBox":29,"language":36,"level":37,"meta":38,"patternArch":39,"resources":59,"s3URL":6,"services":6,"stem":73,"testing":74,"videoId":6,"__hash__":77},"patterns\u002Fpatterns\u002Fcloudfront-agentcore-runtime-cdk.json","Amazon CloudFront to Amazon Bedrock AgentCore Runtime",null,{"text":8},[9],"Delete the stacks: \u003Ccode>cdk destroy --all\u003C\u002Fcode>",[11,12],"content\u002Fcontributors\u002Frakshith-rao.json","content\u002Fcontributors\u002Fbiswanath-mukherjee.json",{"text":14},[15,16,17,18,19],"python3 -m venv .venv","source .venv\u002Fbin\u002Factivate","pip3 install -r requirements.txt","cdk bootstrap aws:\u002F\u002F\u003Caccount-id>\u002Fus-west-2 aws:\u002F\u002F\u003Caccount-id>\u002Fus-east-1","cdk deploy --all","Proxy requests to Amazon Bedrock AgentCore Runtime through CloudFront with OAuth 2.0 authentication, supporting A2A, HTTP, and MCP protocols.","json","AWS CDK",{"template":24},{"repoURL":25,"templateURL":26,"projectFolder":27,"templateFile":28},"https:\u002F\u002Fgithub.com\u002Faws-samples\u002Fserverless-patterns\u002Ftree\u002Fmain\u002Fcloudfront-agentcore-runtime-cdk","serverless-patterns\u002Fcloudfront-agentcore-runtime-cdk","cloudfront-agentcore-runtime-cdk","app.py",{"headline":30,"text":31},"How it works",[32,33,34,35],"This pattern creates a CloudFront distribution that proxies requests to three AgentCore Runtimes (A2A, HTTP, MCP protocols).","CloudFront Functions strip path prefixes (\u002Fa2a, \u002Frest, \u002Fmcp) before forwarding to the appropriate AgentCore Runtime.","AgentCore validates JWT tokens for OAuth 2.0 authentication.","Benefits include: Custom domain support, DDoS protection via AWS Shield, optional WAF integration for rate limiting and geo-blocking, custom authorizer logic via Lambda@Edge, and centralized logging.","Python","300",{},{"icon1":40,"icon2":45,"icon3":48,"line1":52,"line2":56},{"x":41,"y":42,"service":43,"label":44},20,50,"cognito","Amazon Cognito",{"x":42,"y":42,"service":46,"label":47},"cloudfront","Amazon CloudFront",{"x":49,"y":42,"service":50,"label":51},80,"bedrock-agentcore","Amazon Bedrock AgentCore",{"from":53,"to":54,"label":55},"icon1","icon2","JWT",{"from":54,"to":57,"label":58},"icon3","Proxy",{"bullets":60},[61,64,67,70],{"text":62,"link":63},"AgentCore Runtime Service Contracts","https:\u002F\u002Fdocs.aws.amazon.com\u002Fbedrock-agentcore\u002Flatest\u002Fdevguide\u002Fruntime-service-contract.html",{"text":65,"link":66},"Amazon Bedrock AgentCore Runtime Documentation","https:\u002F\u002Faws.github.io\u002Fbedrock-agentcore-starter-toolkit\u002F",{"text":68,"link":69},"CloudFront Functions Documentation","https:\u002F\u002Fdocs.aws.amazon.com\u002FAmazonCloudFront\u002Flatest\u002FDeveloperGuide\u002Fcloudfront-functions.html",{"text":71,"link":72},"Using AWS WAF with CloudFront","https:\u002F\u002Fdocs.aws.amazon.com\u002FAmazonCloudFront\u002Flatest\u002FDeveloperGuide\u002Fdistribution-web-awswaf.html","patterns\u002Fcloudfront-agentcore-runtime-cdk",{"text":75},[76],"See the GitHub repo for detailed testing instructions.","wYvus1llCezZsl-eE0Vfoc_ISmcKtO-k8_I1gwD9zFI",1782470139342]