Open maxm450 opened 2 years ago
I'm having a similar issue. Everything works well but no API keys are generated.
...
provider:
name: aws
stage: ${opt:stage, 'dev'}
runtime: nodejs12.x
apiGateway:
apiKeys:
- ${self:provider.stage}-myKey
shouldStartNameWithService: true
custom:
apiGatewayServiceProxies:
- sqs:
path: /test
method: post
queueName: { 'Fn::GetAtt': ['TestQueue', 'QueueName'] }
private: true
...
I was able to find something which may work here: https://github.com/serverless/serverless/issues/4928
Is this how others are doing it now?
I got mine to work by removing apiGateway
and have apiKeys
directly underneath provider
. Also I have a usage plan although not sure that is required.
I got mine to work by removing
apiGateway
and haveapiKeys
directly underneathprovider
. Also I have a usage plan although not sure that is required.
That worked for me as well. I don't have a usage plan, so just moving apiKeys
directly under provider
seems to solve it.
API keys are not generated even if those are passed inside the provider section:
I would expect that the API gateway would use the api key name defined inside the provider section. Same as https://www.serverless.com/framework/docs/providers/aws/events/apigateway/#setting-api-keys-for-your-rest-api
serverless: 3.16.0 serverless-apigateway-service-proxy: 2.1.0
yml: `service: test-integration
plugins:
custom: apiGatewayServiceProxies:
AWS provider configuration
provider: name: aws region: us-east-1 stage: dummy apiGateway: apiKeys: