I have some code that queries the esri webserver for a list of services.

I start off with:


That code worked for years.

We recently attached a portal to our esri webserver. We're now running v10.5 of both.

Now, the esri admin can issue this command in the browser and it still works, but if I issue it I get an empty list back.

I thought it might be a permissions issue except for three facts:

(1) If I go to https://MyEsriUrl/arcgis/rest/services I can see everything I ought to see.

(2) I've found out that I can now use https://MyEsriUrl/arcgis/rest/services?f=json and that also works correctly.

(3) Esri admin added me to the esri admin role and I still can't see anything with ?f=sitemap.

Obviously, I can rewrite the code to work, but that app is scheduled to be replaced and I would rather spend time working on the replacement app...

Any ideas on how to get ?f=sitemap to work properly?

  • By "We recently attached a portal to our esri webserver", do you mean ArcGIS Server got federated with the portal? @ MyEsriUrl/arcgis/rest/services, do you have to log in to see the services? Fact 3 in your submission sounds like a browser cache problem. Is it the same from Incognito window?
    – Don
    Jul 19, 2017 at 23:56
  • Yes, they were federated. (I didn't do that installation so I had to double check on the terms in order to answer your question.) I don't have to log into MyEsriUrl/arcgis/rest/services by hand, it's happening automatically via active directory. Good call on #3, I now get data. I'll check to see if the ?f=json works once admin is taken away once our gis administrator gets in... Jul 20, 2017 at 11:58

1 Answer 1


Tested this today. If ArcGIS Server is Federated with Portal and there's no service Shared with "EVERYONE", services?f=sitemap will list no services because they are locked down. Federating ArcGIS Server with Portal hands over the security of ArcGIS Server to Portal. So, to get f=sitemap to list the services, they need to be shared with "EVERYONE".

  • Beat me to it! I just found a reference in some docs that said this is the intended behavior. However, the ?f=json still appears to work even without admin privs, so I can get the same info with recursive calls to the webserver. Don't know what they were thinking... Jul 20, 2017 at 13:54
  • Good to see all is well now!
    – Don
    Jul 20, 2017 at 15:22
  • I've rewritten my code to make multiple calls to the server and it's slow as all get out. Yuck! So, I'm going to create a service acct with GIS admin privs and create a web service to wrap the call to the ?f=sitemap option. That way, the web service will ask as an admin and pass the data I need back much faster. For gis websites that aren't "ours" (so we don't have admin access), we'll use the new code I've written. . Jul 21, 2017 at 13:19

Your Answer

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

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