← Back to API Ninjas
GET/v1/covid19

Get Covid-19 case count or death data.

Returns Covid-19 case counts or deaths by country, administrative region, or US county, as a series or a single-day snapshot. Either `date` or `country` must be set.

API Ninjas·$0.001 per call

Example code

// Using @orth/sdk - The simplest way to call APIs // Install: npm install @orth/sdk import Orthogonal from "@orth/sdk"; const orthogonal = new Orthogonal({ apiKey: process.env.ORTHOGONAL_API_KEY, }); const output = await orthogonal.run({ api: "api-ninjas", path: "/v1/covid19" }); console.log(output);

Query parameters

date
string

Date to retrieve single-day snapshot. Must be in the form of YYYY-MM-DD (e.g. 2022-01-01). Either date or country must be set.

country
string

Country name (case insensitive). Either date or country must be set.

region
string

Administrative region (also known as state or province in many countries) name (case insensitive). Must be used in conjunction with country. If not set, countries with data broken down by administrative regions will return separate data for each region.

county
string

County name for US states (case insensitive). For United States data only. Must be used in conjunction with country (United States) and region (e.g. California).

type
string

Type of data to retrieve. Must be either cases or deaths. If not set, cases will be used by default. (Allowed: cases, deaths)

    Orthogonal - Giving AI agents the tools they need.