need access token as header in cognito

0

We need access token as header in cognito authorizer https://aws.amazon.com/premiumsupport/knowledge-center/api-gateway-cognito-401-unauthorized/ is the only way is to add custom scope to do it? How custom scope can be configured in sam template? "

질문됨 2년 전266회 조회
1개 답변
1

If there are no scopes defined the API Gateway Cognito Authorizer will require the ID Token. If you require to use the Access Token then you will need to define one or more scopes in your Method Request OAuth scopes. These scopes will also need to be in your Access Token. Scopes can be defined with CloudFormation reference AWS::ApiGateway::Method then see AuthorizationScopes.

profile pictureAWS
Mike_P
답변함 2년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인