Skip to content

Instantly share code, notes, and snippets.

@mxro

mxro/api-gateway.tf

Created Feb 20, 2021
Embed
What would you like to do?
resource "aws_api_gateway_integration" "lambda" {
rest_api_id = aws_api_gateway_rest_api.main.id
resource_id = aws_api_gateway_method.proxy.resource_id
http_method = aws_api_gateway_method.proxy.http_method
# Lambdas can only be invoked via Post - but the gateway will also forward GET requests etc.
integration_http_method = "POST"
type = "AWS_PROXY"
uri = aws_lambda_function.main.invoke_arn
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment