AnsweredAssumed Answered

Generate token with proxy

Question asked by cai_gis163 on Jun 16, 2016
Latest reply on Jun 17, 2016 by blake.terhune



Could anyone tell me what should be the best way to generate token in ArcGIS for JavaScript. If I hard-code the credential information, it would be risky because other people could get my clientId and clientSecret easily. One possible way could be using the proxy, but as I add the serverUrl with app id and secret, I would still get a response that says client_id is not specified. So I am wondering if I didn't get this right or if there is a better solution.


The config settting is like:

<serverUrl url=""





And the local request url is like:



ps: If I put the clientId and secret within the url, it works all good.