Registry API

The IATI Registry holds meta-data on files published in the IATI XML format. The files themselves are stored in different places across the web, and you will need to fetch and process the original files yourself. If you are looking for an API directly onto IATI data, then a number of third-party platforms are in development. Consult the tools section of the IATI Wiki, or ask on the iati-technical mailing list.

You can interact with the registry via it’s API, an implementation of the CKAN API. Versions 1, 2 and 3 are all supported. Full CKAN API documentation is available here.

The API returns data in JSON format.

Example usage (version 1 API)

To fetch organisation files:

http://www.iatiregistry.org/api/search/dataset?extras_filetype=organisation

To fetch activity files:

http://www.iatiregistry.org/api/search/dataset?extras_filetype=activity

These calls will not return all results by default. Page through results with the offset and limit parameters. For example:

http://www.iatiregistry.org/api/search/dataset?extras_filetype=activity&offset=100&limit=100

To fetch an individual dataset use it’s identifier. Full dataset details contain information on downloadable resources (i.e. the IATI XML files)

http://www.iatiregistry.org/api/rest/dataset/aa-organisation

You can also fetch almost all the details of a dataset in the initial response to an API call using the all_fields parameter. For example:

http://www.iatiregistry.org/api/search/dataset?extras_filetype=activity&all_fields=1&offset=0&limit=25

The downloadable file details can be found in the res_url field of the JSON response

Filters

You can filter the responses on the basis of country (by ISO 2-digit code) or publisher (known as ‘organizations’ internally in the registry).

For example, to fetch all the activity files from DFID use:

http://www.iatiregistry.org/api/search/dataset?extras_filetype=activity&organization=dfid&all_fields=1&limit=200

To fetch all the activity files which have Ghana as their primary segment, use:

http://www.iatiregistry.org/api/search/dataset?extras_filetype=activity&extras_country=GH&all_fields=1&limit=200

Note: querying for all the activity files with a country as their primary segment does not guarantee you will get all the activities in that country due to the way activities are split into files. For example, an activity that is 60% in Nigeria, and 40% in Ghana would be be in a Nigeria file. It is not currently possible to be sure you have all the activities for a country without processing all files. Work is ongoing to address this.

More support?

Ask on the IATI Technical mailing list.