Algeria Coronavirus Tracker API

Provides up-to-date data about COVID19 Coronavirus outbreak in Algeria. Includes numbers about confirmed cases, deaths, recovered, and more.

API Reference

All endpoints are located at api.corona-dz.live and are accessible via https. For instance: you can get latest country data by using this URL:
https://api.corona-dz.live/country/latest

You can open the URL in your browser to further inspect the response. Or you can make this curl call in your terminal to see the prettified response:

curl https://api.corona-dz.live/country/latest | json_pp

API Endpoints

Country Level Data

Latest

Getting latest amount of total confirmed cases, deaths, and recovered.

GET /country/latest

Sample response

{
	"date" : "2020-06-02T00:00:00.000Z",
	"confirmed" : 9626,
	"deaths" : 667,
	"recovered" : 6067,
	"treatment" : 18545,
	"newConfirmed" : 113,
	"newRecovered" : 173,
	"newTreatment" : 75,
	"newDeaths" : 6,
	"avg7Deaths" : 7.14,
	"avg7Confirmed" : 132.71,
	"avg7Treatment" : 449.29,
	"avg7Recovered" : 164.14,
	"updatedAt" : "2020-06-02T17:19:50.515Z"
}

All

Getting all data since 25 Feb, 2020.

GET /country/all

Sample response

[
	{
		"updatedAt" : "2020-05-21T22:20:27.306Z",
		"recovered" : 4062,
		"avg7Recovered" : 129.14,
		"date" : "2020-02-25T00:00:00.000Z",
		"treatment" : 13332,
		"deaths" : 575,
		"avg7Treatment" : 368.43,
		"newRecovered" : 94,
		"avg7Confirmed" : 183.71,
		"newDeaths" : 7,
		"newTreatment" : 397,
		"newConfirmed" : 186,
		"confirmed" : 7728,
		"avg7Deaths" : 6.57
	},
	{
		...
	}
]

Date

Getting data for a particular day.

GET /country?date=YYYY-MM-DD

Query String Parameters

Query string parameter Description Type
date Date in ISO 8601 format and between 25 Feb, 2020 and current date. Example: 2020-05-21. Date

Sample response

{
	"avg7Recovered" : 129.14,
	"updatedAt" : "2020-05-21T22:40:47.621Z",
	"newDeaths" : 7,
	"newTreatment" : 397,
	"avg7Confirmed" : 183.71,
	"newRecovered" : 94,
	"avg7Deaths" : 6.57,
	"confirmed" : 7728,
	"treatment" : 13332,
	"deaths" : 575,
	"recovered" : 4062,
	"avg7Treatment" : 368.43,
	"date" : "2020-05-21T00:00:00.000Z",
	"newConfirmed" : 186
}

Age Latest

Getting latest data for cases by age.

GET /country/age/latest

Sample response

[
	{
		"confirmed" : 13,
		"deaths" : 0,
		"date" : "2020-06-03T00:00:00.000Z",
		"label" : "'< 1'"
	},
	{
		"confirmed" : 285,
		"date" : "2020-06-03T00:00:00.000Z",
		"deaths" : 2,
		"label" : "'1 - 14'"
	},
	{
		"deaths" : 1,
		"date" : "2020-06-03T00:00:00.000Z",
		"confirmed" : 451,
		"label" : "'15 - 24'"
	},
	...
]

Age All

Getting all data for cases by age since 25 Feb, 2020.

GET /country/age/all

Sample response

[
	{
		"confirmed" : 13,
		"deaths" : 0,
		"date" : "2020-06-03T00:00:00.000Z",
		"label" : "'< 1'"
	},
	{
		"confirmed" : 285,
		"date" : "2020-06-03T00:00:00.000Z",
		"deaths" : 2,
		"label" : "'1 - 14'"
	},
	{
		"deaths" : 1,
		"date" : "2020-06-03T00:00:00.000Z",
		"confirmed" : 451,
		"label" : "'15 - 24'"
	},
	...
]

Gender Latest

Getting latest data for cases by gender.

GET /country/gender/latest

Sample response

{
	"date" : "2020-06-03T00:00:00.000Z",
	"male" : 5396,
	"female" : 4337
}

Gender All

Getting all cases by gender data since 25 Feb, 2020.

GET /country/gender/all

Sample response

[
	{
		"date" : "2020-05-10T00:00:00.000Z",
		"female" : 1500,
		"male" : 2000
	},
	{
		"date" : "2020-05-11T00:00:00.000Z",
		"male" : 2050,
		"female" : 1520
	},
	{
		"male" : 2526,
		"female" : 1948,
		"date" : "2020-05-03T00:00:00.000Z"
	},
	...
]

Summary

Getting a summary latest data for cases, age and gender.

GET /country/summary

Sample response

{
	"days" : 102,
	"gender" : {
		"male" : 5396,
		"female" : 4337
	},
	"rates" : {
		"treatment" : "0.73%",
		"recovery" : "63.89%",
		"deaths" : "6.91%"
	},
	"latest" : {
		"newTreatment" : 136,
		"newConfirmed" : 107,
		"date" : "2020-06-03T00:00:00.000Z",
		"newDeaths" : 6,
		"avg7Deaths" : 7.14,
		"avg7Treatment" : 419.71,
		"recovered" : 6218,
		"avg7Recovered" : 155.57,
		"deaths" : 673,
		"avg7Confirmed" : 125.14,
		"confirmed" : 9733,
		"newRecovered" : 151,
		"treatment" : 18681,
		"updatedAt" : "2020-06-03T17:01:23.520Z"
	},
	"age" : [
		{
		"confirmed" : 13,
		"deaths" : 0,
		"label" : "'< 1'"
		},
		{
		"label" : "'1 - 14'",
		"confirmed" : 285,
		"deaths" : 2
		}
		...
	]
}

Province Level Data

Latest

Getting latest amount of total confirmed cases, deaths, and recovered for all provinces.

GET /province/latest

Sample response

[
	{
		"name" : "Adrar",
		"data" : [
			{
				"confirmed" : 129,
				"newDeaths" : 0,
				"date" : "2020-06-03T00:00:00.000Z",
				"avg7Confirmed" : 1.29,
				"newRecovered" : 0,
				"newConfirmed" : 0,
				"provinceId" : 1,
				"deaths" : 5,
				"recovered" : 0,
				"updatedAt" : "2020-06-03T17:01:24.832Z",
				"avg7Recovered" : 0,
				"avg7Deaths" : 0.14
			}
		],
		"firstReported" : "2020-03-15T00:00:00.000Z",
		"latitude" : 27.9716342,
		"lastReported" : "2020-06-02T00:00:00.000Z",
		"provinceId" : 1,
		"longitude" : -0.1869644
	},
	...
]

All

Getting all provinces data since 25 Feb, 2020.

GET /province/all

Sample response

[
	{
		"provinceId" : 1,
		"lastReported" : "2020-06-02T00:00:00.000Z",
		"firstReported" : "2020-03-15T00:00:00.000Z",
		"data" : [
			{
				"date" : "2020-02-25T00:00:00.000Z",
				"confirmed" : 0,
				"deaths" : 0,
				"provinceId" : 1,
				"avg7Confirmed" : 0,
				"avg7Recovered" : 0,
				"newDeaths" : 0,
				"recovered" : 0,
				"avg7Deaths" : 0,
				"newConfirmed" : 0,
				"newRecovered" : 0
			},
			...
		]
	...
	}
]

Province ID Latest

Getting latest data for a particular province.

GET /province/:id/latest

Query String Parameters

Query string parameter Description Type
id Province Id between 1 and 48. Example: 27. Integer

Sample response

[
	{
		"latitude" : 36.0131235,
		"firstReported" : "2020-03-23T00:00:00.000Z",
		"longitude" : 0.1401381,
		"provinceId" : 27,
		"name" : "Mostaganem",
		"lastReported" : "2020-06-03T00:00:00.000Z",
		"data" : [
			{
				"newDeaths" : 0,
				"recovered" : 0,
				"newRecovered" : 0,
				"confirmed" : 84,
				"date" : "2020-06-03T00:00:00.000Z",
				"avg7Deaths" : 0,
				"deaths" : 4,
				"provinceId" : 27,
				"newConfirmed" : 4,
				"avg7Confirmed" : 2.57,
				"avg7Recovered" : 0
			}
		]
	}
]

Province ID All

Getting all data for a particular province.

GET /province/:id/all

Query String Parameters

Query string parameter Description Type
id Province Id between 1 and 48. Example: 27. Integer

Sample response

[
	{
		"latitude" : 36.0131235,
		"firstReported" : "2020-03-23T00:00:00.000Z",
		"longitude" : 0.1401381,
		"provinceId" : 27,
		"name" : "Mostaganem",
		"lastReported" : "2020-06-03T00:00:00.000Z",
		"data" : [
			{
				"newDeaths" : 0,
				"recovered" : 0,
				"newRecovered" : 0,
				"confirmed" : 84,
				"date" : "2020-06-03T00:00:00.000Z",
				"avg7Deaths" : 0,
				"deaths" : 4,
				"provinceId" : 27,
				"newConfirmed" : 4,
				"avg7Confirmed" : 2.57,
				"avg7Recovered" : 0
			},
			...
		]
	}
]

License

The code for this project is released under the MIT License. You are free to re-use it but we ask that you please include a link back to the COVID-19 Algeria website or this GitHub repository.

Core Contributors