I've created an API Gateway and added AWS_IAM for Authorization. I've launched an EC2 instance with the below role attached,
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"execute-api:Invoke"
],
"Resource": [
"arn:aws:execute-api:ap-south-1:123456789123:abcd12345/*/*/myresource"
]
}
]
}
When I tried to do CURL to my API gateway endpoint, the request failed with 403 and message "Missing Authentication Token".
Is it not possible to use role with IAM authorization in API Gateway?