How to get the ID token in trigger functions of AWS Cognito?

0

In the trigger functions of AWS Cognito, say Post confirmation trigger or Post authentication trigger, I would like to get the ID token, such that I could query some other services on behalf of the user.

Is that possible and if so, how?

It would be terrific if you could also provide a small example in Javascript and/or Python.

preguntada hace 4 meses146 visualizaciones
1 Respuesta
0

Hi,

Unfortunately the Post confirmation and Post authentication Lambda triggers don't include the ID Token, just the userAttributes, clientMetadata and the common parameters that Cognito adds to all requests.

profile picture
EXPERTO
respondido hace 4 meses

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas