OpenSRP allows you to maintain location hierarchy inside OpenMRS and access it on your OpenSRP client.
- To get tree for all locations starting from the top most root send a http request to http://yourserver/location/location-tree. For demo server access the link http://46.101.51.199:8080/oweb/location/location-tree
- The response returned would be a json document mappable to org.opensrp.api.util.LocationTree.
To get subtree starting from a particular location add location id i.e. uuid in OpenMRS to the request as http://yourserver/location/location-tree/uuid as path variable. The returned tree would a json document mappable to org.opensrp.api.util.LocationTree where root location would be the one specified in filter.