Akshay
Akshay

Reputation: 85

How to generate access token and embed token from web app

I want to generate an access token and embed token of the azure active directory from my web app using javascript. I tried to generate token by calling REST-API using ajax but I faced CORS issue. Then I tried using ADAL and MSAL but nothing work. How can I generate a token in my web app programmatically?

Upvotes: 1

Views: 584

Answers (1)

unknown
unknown

Reputation: 7483

You could use ADAL/MSAL to integrate AAD in javascript. If using the client credentials flow that is not supported in javascript, you will get the CORS error.

There are samples to acquire access token:

Upvotes: 3

Related Questions