Good day,
I'm trying to implement MSAL.js in my application. Basically, I'm able to implement the msal.js and log in using my email from the AD. I also configured the msal to save my tokenid and accessToken in my localStorage
The accessToken is working in my backend because I tested it using Postman software. But in my app, I don't know how can acquire and put it in my Axios header because the key in the localStorage shows like this:
Where it has a Key in the localStorage of an object.
{"authority":"https://login.microsoftonline.com/TENANTID/","clientId":"CLIENT_ID","scopes":"CLIENT_ID","homeAccountIdentifier":"SOME_HASH"}
With an value of:
accessToken: 'TOKEN_HASH_HERE'
idToken: 'TOKEN_HASH_HERE'
expiresIn: 'TOKEN_HASH_HERE'
homeAccountIdentifier: 'TOKEN_HASH_HERE'
I need to get the access token to be able to put it in my axios header like this:
axios.defaults.headers.common['Authorization'] = `Bearer ${accessTokenFromMsal}`
Thank you in advance.

