Move To Cloud – ADAL.JS and Token Services

At this point I have pretty much stripped out the ADAL.JS library to include minimal code needed to acquire tokens based on user’s identity. The stripped file is only about 180 lines of code and 7 kb in size and its not even compressed.

Token Services is an azure website, I have hosted it at, the page adaltoken.html takes a query string parameter redirect_url=‘the page to receive the acquired token’, and and upon successful authentication puts the acquired token in another query string parameter called adal_token=‘token‘, it also puts the issue time for the token in a query string parameter called adal_token_issued=‘issue time’. This page can be called from any where needing an access token. As needed it prompts the user to enter the WAAD credentials, adal.js provided token has a lifetime of about an hour.