-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue with shared authorizers #107
Comments
Could you please show your serverless-auto-swagger custom config in your Serverless file? |
Could you try making custom:
...
customAuthorizer:
type: COGNITO_USER_POOLS
authorizerId: !ImportValue authorizer
autoswagger:
...
lambdaAuthorizer: ${self:custom.customAuthorizer}
functions:
...
test:
...
events:
- http:
...
authorizer: ${self:custom.customAuthorizer} This was my use-case when I added this feature. If this doesn't work, I honestly don't know a ton about authorizers, so I don't know if more complex scenarios are possible. (also, careful with the indentation in my example – treat that as pseudo-code, as I simply typed it up in GitHub markdown code) |
I have tried the same. But after running |
Hello! We are having some troubles trying to implement the lambdaAuthorizer in the swagger endpoints. We have a microservices architechture, our authorizer is in a separated microservice and we can use this authorizer ( via output variable) in our lambdas. Here is a code snipet of how we use this authorizer in our lambdas:
The idea that we had is to reuse this authorizer for the lambdaAuthorizer section but we can't figure it out why it ain't working (maybe we are missunderstanding or doing something wrong).
Thank you for your time in advance.
The text was updated successfully, but these errors were encountered: