Hey there! I've implement a magic-link auth flow (via this tutorial: https://theburningmonk.com/2023/03/implementing-magic-links-with-amazon-cognito-a-step-by-step-guide/) but I'm having a hard time actually getting the users tokens from the frontend to the backend.
The auth flow is kicked off from a custom CLI I am building. I send a user an email, they click the link in that email to verify their user, and on the front end I sign the user in and send the challenge response
const cognitoUser = await Auth.signIn(email);
const challengeResult = await Auth.sendCustomChallengeAnswer(cognitoUser, token);
This is all successful, but my challenge is I want the tokens (id_token, access_token) to be retrievable from my CLI and then saved to a local auth config file. My CLI is in a listening-for-verification state at this point. A bit stuck on how to proceed here. Any guidance on best practices to achieve this?