Get agol Login user name using Esri js api 4x

723
2
07-09-2021 03:04 PM
divyabathina
New Contributor III

Hi ,

How can we the login user name when accessing secure agol maps using Esri JS api 4x application .

Thanks,

Divya

Tags (2)
0 Kudos
2 Replies
ReneRubalcava
Frequent Contributor

You can do this in the following steps:

  1. Register OAuthInfo with IdentityManager.
  2. Construct and load Portal.
  3. You can now access the Portal User.
0 Kudos
divyabathina
New Contributor III

Hi Rene,

Ill try this and update you back,

Thanks,

Divya 

0 Kudos