-
Notifications
You must be signed in to change notification settings - Fork 0
Endpoints
Endpoint: /api/countries
Description:
Returns an array of countries in the database
Params
sort
sort the array by either iso3
or name
, defaults to name
Endpoint: /api/overview
Description:
Returns a country displacement information and includes population and refugee numbers
Params:
iso3
The country iso3 code
Example:
/api/overview?iso3=rus
Endpoint: /api/conflict_data
Description:
Returns all available conflict displacement data
Params:
iso3
The country iso3 code (if neglected then all the countries)
year
The year of the records (default all years, it also accept ranges)
range
When set to 1 the API expects multiple year values and returns records below to the year range
limit
Limit the number of records returned by the endpoint
Examples:
- Country by year e.g.
/conflict_data?iso3=rus&year=2015
- All countries for a year e.g.
/conflict_data?year=2015
- Country by range of years e.g.
/conflict_data?iso3=rus&year=2011&year=2015&range=1
Endpoint: /api/disaster_data
Description
Returns all available disaster displacement data by event and includes hazard type information
Params
iso3
The country iso3 code (if neglected then all the countries)
year
The year of the records (default all years, it also accept ranges)
range
When set to 1 the API expects multiple year values and returns records below to the year range
limit
Limit the number of records returned by the endpoint
Endpoint: /api/displacement_data
Description
Returns all available displacement data for both disaster and conflict by year and country
Params:
iso3
The country iso3 code (if neglected then all the countries)
year
The year of the records (default all years, it also accept ranges)
range
When set to 1 the API expects multiple year values and returns records below to the year range
limit
Limit the number of records returned by the endpoint
Endpoint: /api/aggregated/disaster_data
Description:
Returns all available disaster displacement data by country aggregating all the events
Params:
iso3
The country iso3 code (if neglected then all the countires)
year
The year of the records (one entry for a year, two for a range + range=1
)
range
When set to 1
the API expect multiple year
values and it return a records for each year if available
limit
Limit the returned results to a specific number of records
Example:
/api/aggregated/disaster_data?iso3=AFG&year=2009&year=2011&range=1
Endpoint: /api/strata_data
Description:
Returns the strata data for a country by type of displacement and fact type
Params:
iso3
The country iso3 code
Example:
/api/strata_data?iso3=AFG
Endpoint:
/api/figure_analysis
Description:
Returns the figure analysis for a country
Example:
/api/figure_analysis?iso3=AFG
Params:
iso3
The country iso3 code
Endpoint: /api/confidence_assessment
Description:
Returns the confidence assessment data for a country by type of displacement and fact type
Params:
iso3
The country iso3 code
Example:
/api/confidence_assessment?iso3=AFG
Endpoint: /api/disaster_events
Description:
Returns events associated with an iso code
Params:
iso3
The country iso3 code
Example:
/api/disaster_events?iso3=AFG