Can someone please let me know how I can get Service Workspaces information of a service using ArcGIS API for Python? I need to get the SDE name and the layers associated with the service. Also I need to see if it is Query Layer or not?
I used this to get the properties of the service but looks like
folders = ['Streets']
for container in folders:
services = server1.services.list(folder= container)
for service in services:
print(service.properties)
but apparently this properties is not returning thoses Admin level information
Does anyone has any idea regarding this post?
I don't have a reliable way to test this at the moment, but you would expect to find that kind of information in the service manifest. Per the API Reference,
The service manifest resource documents the data and other resources that define the service origins and power the service. This resource will tell you underlying databases and their location along with other supplementary files that make up the service.
Instead of "service.properties" you would use "service.service_manifest()" - this function returns JSON with the described information.