I'm accessing an ArcGIS mapserver in cesium using ArcGisMapServerImageryProvider.
The server has multiple layers that I would believe would normally be accessed using the esri api with setVisibleLayers. The layers can be viewed fine in an arcgis.com map.
If I access the root of the server (with cesium) at something like <//arcgis/rest/services/MapServer>, I can load all of the layers provided in one go, but I am unable to work with individual layers. I have tried accessing the layer URL directly, as well as the direct url to the json. (e.g. <arcgis/rest/services/MapServer/0> or <arcgis/rest/services/MapServer/0?f=pjson>).
In all cases trying to use an individual layer, I get a bad request error.
Any thoughts? Sorry if this is obvious. I'm pretty new to GIS stuff in general.