ArcGIS Map Service enable Textual Query but disable Geometry return in Service Side

04-15-2019 06:38 PM
New Contributor

Dear Sir/Madam,

I would like to know is it possible to have a setting in ArcGIS Map Service that when using JavaScript API to 
identify (i.e. esri.tasks.IdentifyTask). ONLY the textual attribute is return. no matter how to script the client-side script.

Actually, we need the map service to have this behaviour , so as to prevent hacker to get the geometry by using JavaScript in clientside. while textual attribute is open, the spatial polygon want to be see on our map only.

Is there any way to do so on particular map service?

Thank you very much for your help
Best Regards
Eric Yuen

0 Kudos
1 Reply
Esri Regular Contributor

An option would be to disable the Data property from Dynamic Map Service.

All queries disabled but the the problem in that case is the identify task return the geometry from the identified feature.

here is a sample from a identify response

an another approach is this

  • create a tiled map service or a vector tile service in order to present the data (disconnect the data sources from the map service)
  • create a second dynamic map service for queries and identify but on that service use generalized vector data

hope this helps.

0 Kudos