@Serverless Framework com AWS cognito gera erro CORS

Recebo esta mensagem de erro do front-end Angular e não estou autorizado a tocar no meu código lambda:

`Access to fetch at 'https://testapicd.***.***.com/localization/v1/role' from origin 'https://localization.test.***.***.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.`

Procurei em todos os lugares e parece não haver nenhum erro no meu código. Meu código sem servidor é

  getrole:
    handler: v1/handler_get_role.get_role
    name: get_role
    events:
      - http:
          path: v1/role
          method: get
          cors: true
          authorizer:
            name: CognitoCSAuthorizer
            type: COGNITO_USER_POOLS
            arn: ${file(config.${self:provider.stage}.json):userpoolarn}

Verifiquei três vezes todas as configurações e tudo parece correto. Algum conselho o que fazer? A funcionalidade funciona no ambiente de desenvolvimento, mas não quando eu a implanto no ambiente de test

Se eu tentar o token diretamente na API, ele também não funcionará (mas funcionou bem no dev). Eu nem acredito mais que é um problema do CORS. Eu acho que o token jwt está errad

def get_role(event, context):
    return {
        'statusCode': 200,
        'headers': {
         'Content-Type': 'application/json',
         'Access-Control-Allow-Origin' : '*', # Required for CORS support to work
         'Access-Control-Allow-Credentials': 'true',
        },
        'body': json.dumps("TEST")
     }

questionAnswers(3)

yourAnswerToTheQuestion