[{"data":1,"prerenderedAt":61},["ShallowReactive",2],{"pattern-apigw-lambda-bedrock-java":3},{"id":4,"title":5,"architectureURL":6,"cleanup":7,"contributors":10,"deploy":12,"description":15,"extension":16,"framework":17,"gitHub":18,"highlight":6,"introBox":23,"language":30,"level":31,"meta":32,"patternArch":33,"resources":51,"s3URL":6,"services":6,"stem":56,"testing":57,"videoId":6,"__hash__":60},"patterns\u002Fpatterns\u002Fapigw-lambda-bedrock-java.json","Amazon API Gateway to AWS Lambda to Amazon Bedrock",null,{"text":8},[9],"Delete the stack: \u003Ccode>cdk delete\u003C\u002Fcode>.",[11],"content\u002Fcontributors\u002Fgrzegorz-kozub.json",{"text":13},[14],"cdk deploy","Make a request to Bedrock via API Gateway using Java and CDK","json","AWS CDK",{"template":19},{"repoURL":20,"templateURL":21,"projectFolder":21,"templateFile":22},"https:\u002F\u002Fgithub.com\u002Faws-samples\u002Fserverless-patterns\u002Ftree\u002Fmain\u002Fapigw-lambda-bedrock-cdk-java","apigw-lambda-bedrock-cdk-java","infrastructure\u002Fsrc\u002Fmain\u002Fjava\u002Fcom\u002Fexample\u002FInfrastructureApp.java",{"headline":24,"text":25},"How it works",[26,27,28,29],"Amazon API Gateway receives the HTTP POST request containing the prompt.","AWS Lambda is triggered by API Gateway, this function forwards the prompt to Amazon Bedrock API using AWS SDK for Java. It uses Anthropic Claude-v2 model and sets other required parameters to fixed values for simplicity.","Based on the given prompt, using Anthropic Claude-v2 model, Amazon Bedrock generates the content and returns the response to Lambda.","Lambda processes the Bedrock output and sends it back to the user via the API Gateway.","Java","200",{},{"icon1":34,"icon2":39,"icon3":42,"line1":46,"line2":49},{"x":35,"y":36,"service":37,"label":38},20,50,"apigw","API Gateway REST API",{"x":36,"y":36,"service":40,"label":41},"lambda","AWS Lambda",{"x":43,"y":36,"service":44,"label":45},80,"bedrock","Amazon Bedrock",{"from":47,"to":48},"icon1","icon2",{"from":48,"to":50},"icon3",{"bullets":52},[53],{"text":54,"link":55},"Amazon Bedrock Model Access","https:\u002F\u002Fdocs.aws.amazon.com\u002Fbedrock\u002Flatest\u002Fuserguide\u002Fmodel-access.html","patterns\u002Fapigw-lambda-bedrock-java",{"text":58},[59],"See the GitHub repo for detailed testing instructions.","bkxGn1yejlx7LGeZANXw-dnc7Q54Q4xpwe8VXKQV1L0",1778927705027]