The organisationUnits resource follows the standard conventions as other metadata resources in DHIS2. This resource supports some additional query parameters.
To get a list of organisation units you can use the following resource.
|userOnly||false | true||Data capture organisation units associated with current user only.|
|userDataViewOnly||false | true||Data view organisation units associated with current user only.|
|userDataViewFallback||false | true||Data view organisation units associated with current user only with fallback to data capture organisation units.|
|query||string||Query against the name, code and ID properties.|
|level||integer||Organisation units at the given level in the hierarchy.|
|maxLevel||integer||Organisation units at the given max level or levels higher up in the hierarchy.|
|memberCollection||string||For displaying count of members within a collection, refers to the name of the collection associated with organisation units.|
|memberObject||UID||For displaying count of members within a collection, refers to the identifier of the object member of the collection.|
To get an organisation unit with related organisation units you can use the following resource.
|includeChildren||false | true||Include immediate children of the specified organisation unit, i.e. the units at the immediate level below in the subhierarchy.|
|includeDescendants||false | true||Include all children of the specified organisation unit, i.e. all units in the sub-hierarchy.|
|includeAncestors||false | true||Include all parents of the specified organisation unit.|
|level||integer||Include children of the specified organisation unit at the given level of the sub-hierarchy (relative to the organisation unit where the immediate level below is level 1).|