# DHIS2 in Python

Send case and aggregate data to DHIS2, read it back, and connect it to laboratories and other systems from Python services.

## Get started

Read metadata from a DHIS2 instance and send a weekly report to it, step by step.

[Tutorial](https://zato.io/docs/dev/healthcare/dhis2/tutorial.html)

service.py

```
# Write a lab result to its DHIS2 case ..
conn = self.rest['DHIS2 Tracker']
response = conn.post({'events': [event]}, params)

# .. and read the import summary.
response.data['status']
'OK'

response.data['stats']
{'created': 1, 'updated': 0, 'deleted': 0, 'ignored': 0, 'total': 1}
```

## Start here

[Tutorial Connect to DHIS2, read a data set and send data values with a dry run first.](https://zato.io/docs/dev/healthcare/dhis2/tutorial.html) [Security Personal access tokens, event hooks, the Route API and case data in the audit log.](https://zato.io/docs/dev/healthcare/dhis2/security.html)

## Use cases

[Lab results Match results to cases by specimen ID, hold results that arrive early and report weekly counts.](https://zato.io/docs/dev/healthcare/dhis2/lab-results/index.html) [Outbreak alerts Check weekly counts against thresholds, notify districts and keep the 7-1-7 dates.](https://zato.io/docs/dev/healthcare/dhis2/outbreak-alerts/index.html) [One Health Carry zoonoses between animal and public health and load AMR and environmental data.](https://zato.io/docs/dev/healthcare/dhis2/one-health/index.html) [Supply chain Receive cold chain telemetry, alert on alarms and confirm consignment receipts.](https://zato.io/docs/dev/healthcare/dhis2/supply-chain/index.html)
