Created
October 16, 2018 09:15
-
-
Save tarasowski/c17ee38c2b7a1ee685b898f4033955bd to your computer and use it in GitHub Desktop.
Cognito swagger example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ShopTokenApi: | |
Type: AWS::Serverless::Api | |
Properties: | |
StageName: prod | |
DefinitionBody: | |
swagger: 2.0 | |
info: | |
title: !Sub ${AWS::StackName} | |
securityDefinitions: | |
custom-authorizer: | |
type: apiKey | |
name: Authorization | |
in: header | |
x-amazon-apigateway-authtype: awsSigv4 | |
paths: | |
/shop/{id}: | |
get: | |
parameters: | |
- name: id | |
in: path | |
required: true | |
type: string | |
responses: {} | |
security: | |
- custom-authorizer: [] | |
x-amazon-apigateway-integration: | |
httpMethod: POST # for Lambda integrations the value must be POST | |
type: aws_proxy | |
uri: !Sub arn:aws:apigateway:${AWS::Region}:lambda:path/2015-03-31/functions/${GetShopToken.Arn}/invocations | |
/auth: | |
get: | |
responses: {} | |
x-amazon-apigateway-integration: | |
httpMethod: POST | |
type: aws_proxy | |
uri: !Sub arn:aws:apigateway:${AWS::Region}:lambda:path/2015-03-31/functions/${ShopifyServiceAuthBegin.Arn}/invocations | |
/callback: | |
post: | |
responses: {} | |
x-amazon-apigateway-integration: | |
httpMethod: POST | |
type: aws_proxy | |
uri: !Sub arn:aws:apigateway:${AWS::Region}:lambda:path/2015-03-31/functions/${ShopifyServiceAuthComplete.Arn}/invocations |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment