AnsweredAssumed Answered

Angular Application requires access to secure ESRI web services. Issues generating token and passing to web service request

Question asked by cb6938@mt.gov_MTDEQ on Jul 14, 2020

I have an Angular Application that required access secure ESRI web services. Our GIS admin has provided me a username and password for accessing the services, but when I try to call the service, I get an error that I need an access token. If I manually use the username and password to generate the token and place the token in my code, I am able to retrieve the data from the service. Unfortunately, I need to generate the token in my code and pass it to my web service call. The ESRI documentation regarding token generation so far has not been helpful. I would love assistance on this. Would be happy to provide the code (C#) I have so far.

 

Below are some of the references I have reviewed:

http://resources.esri.com/help/9.3/arcgisserver/apis/javascript/ve/help/Working%20with%20ArcGIS%20Server%20services/SecureServices.htm

http://resources.esri.com/help/9.3/arcgisserver/adf/dotnet/developer/ArcGIS/SOAP/using_secure_services.htm

https://developers.arcgis.com/rest/users-groups-and-items/generate-token.htm

Outcomes