I have an ArcGIS online webmap that I'd like to update using the ArcGIS REST API. The Web Map has many layers but I'd like to update just one layer and leave the rest as-is. It appears that I have to create JSON to fully specify the webmap (the base layer, all operational layers, all tables, etc). The problem with this is that I don't know the full specification (a user may have altered the original web map) and I don't see any way to retrieve the full specification in a way that can be simply updated and sent back on the update. Is it possible to either
1) create JSON that will selectively update the webmap specification (eg. add/update/remove just one layer) OR
2) retrieve the full webmap specification in a JSON form that can be tweaked and sent back to the server on an update request?
Solved! Go to Solution.
Did you have a look at the ArcGIS Online Assistant already?
Here you can login with your Esri account to search your web map, and - by clicking I want to... View an item's JSON - retrieve the full web map specification in JSON format to be edited or updated.
Is this the answer to your question?
Egge-Jan
Did you have a look at the ArcGIS Online Assistant already?
Here you can login with your Esri account to search your web map, and - by clicking I want to... View an item's JSON - retrieve the full web map specification in JSON format to be edited or updated.
Is this the answer to your question?
Egge-Jan
This looks very promising. I was not aware of ArcGIS Online Assistant but I think it will do the trick. From the browser trace it looks like the https://<my_org>.maps.arcgis.com/sharing/rest/content/items/<item_id>/data request is the one that returns the full specification that I'm looking for. I'll add that to my script later today to verify that it does what I need. Thanks!
No thanks at all 🙂
If you think your question is answered, please feel free to mark it as such.
This will also help to limit the number of apparently answered questions in this forum.
Cheers,
E-J