3

I'm using .NET code to submit GET and POST requests to secured REST services served up by our internal ArcGIS Server 10.4.

How should I pass the security token?

Perhaps I can just add it as a querystring parameter but I do not know the parameter key.

I found documentation explaining the what and why of ArcGIS Server tokens but not how to actually pass them in a request. I have the url for obtaining a token. I just don't know how to use it.

1
  • The documentation explains how the token request is sent, in a POST to an HTTPS port. There are multiple possible encoding options. As with all the other capabilities of the REST API, the best way to find out how it works is to enable network logging in your JavaScript console of choice and hit the API from a web client.
    – Vince
    Mar 27, 2017 at 23:17

1 Answer 1

10

For Post Request You send it over inside a form in the body with the key token and the value is the token you received from this document explaining how to get token

For Get Request You can send them over via a query parameter attached to the url

https://services1.arcgis.com/dis-mine/arcgis/rest/services/my-name/FeatureServer/0/query?where=blahblah*outfields=*&token=YOURTOKEN&f=json
2
  • how to pass token with arcgis wmtsp tile map server? Jan 11, 2021 at 7:57
  • Thanks i am able to get the tiles with last token paraemeter. Jan 11, 2021 at 10:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.