Hi All,
Also would love to find out if this can be done through terraform, as the only way we can this at the moment is to import the swagger files.
Looking at the output from cognito authoriser i've set up, we get something along the lines of:
"authType": "cognito_user_pools",
"identitySource": "method.request.header.Authorization",
"name": "Test",
"providerARNs": [
"arn:aws:cognito-idp:<region>:<account>:userpool/<region>_<pool_id>"
],
"type": "COGNITO_USER_POOLS",
"id": "<id>"
which makes you think you should be able to set something up like the below but there is still something missing here as it looking for the providerARN and i cant' see how you able to specify it through this module:
* aws_api_gateway_authorizer:<pool_name. Error creating API Gateway Authorizer: BadRequestException: The list of providerARNs cannot be empty.
resource "aws_api_gateway_authorizer" "<pool_name>" {
name = "<pool_name>"
authorizer_uri = "arn:aws:cognito-idp:<region>:<account>:userpool/<region>_<pool_id>"
identity_source = "method.request.header.Authorization"
type = "COGNITO_USER_POOLS"
identity_validation_expression = "<id>"
}
has anyone been able to get this to work?
Best
H