Skip to content
/ covid Public

Tracking covid, data visualization and API for COVID-19 (novel corona virus)

Notifications You must be signed in to change notification settings

avencera/covid

Repository files navigation

Covid API

GraphQL

{
  regions(names: ["Ontario", "Georgia"]) {
    name
    days {
      cases
      date
      day
      predicted
    }
  }
  countries(names: ["Canada", "US", "Korea, South"]) {
    population
    name
    days {
      cases
      date
      day
      predicted
    }
  }
}

REST API

Countries

  • METHOD: GET
  • URL: https://api.trackingcovid.com/api/countries
  • RESPONSE:
{"Georgia": {"regions": [], population: xxxxxx},
"Latvia": {"regions": [], population: xxxxxx},
"Jamaica": {"regions": [], population: xxxxx},
"Poland": {"regions": [], population: xxxxxxx},
"Canada": {
  "population": 37590000
  "regions": [
    "British Columbia",
    "Ontario",
    "Alberta",
    "Quebec",
    "New Brunswick",
    "Manitoba",
    "Saskatchewan",
    "Grand Princess"
  ],
 ...
 }

By Country

{
  "country": "Canada",
  "cases": [0, 0, 1,...],
  "predictions": [0.6292397306678004, 0.6990728897808295, ...],
  "prediction_type": "weighted_exponential",
  "start": "2020-01-22"
}

By Countries

{
  "regions": {},
  "countries": {
    "Canada": {
      "cases": [
        0,
        0,
        1,
        ...
      ],
      "predictions": [
        0.6292397306678004,
        0.6990728897808295,
        ...
      ],
      "prediction_type": "weighted_exponential",
      "country": "Canada",
      "start": "2020-01-22"
    },
    "US": {
      "country": "US",
      "cases": [
        0,
        0,
        1,
        ...
      ],
      "predictions": [
        0.1602764754993061,
        0.19285269106150466,
        ...
      ],
      "prediction_type": "weighted_exponential",
      "start": "2020-01-22"
    }
  }
}

By Regions

{"regions":
  {"Ontario": {
    "cases": [0, 0, 1,...],
    "predictions": [0.6292397306678004, 0.6990728897808295, ...],
    "prediction_type": "weighted_exponential",
    "region": "Ontario",
    "start": "2020-01-22"
   },
  "Georgia": {
    "region": "Georgia",
    "cases": [0, 0, 1,...],
    "predictions": [0.1602764754993061, 0.19285269106150466, ...],
    "prediction_type": "weighted_exponential",
    "start": "2020-01-22"
   },
  },
  "countries": {}
}

By Countries & Regions

{
  "regions": {
    "Ontario": {
      "cases": [
        0,
        0,
        1,
        ...
      ],
      "predictions": [
        0.6292397306678004,
        0.6990728897808295,
        ...
      ],
      "prediction_type": "weighted_exponential",
      "region": "Ontario",
      "start": "2020-01-22"
    },
    "Georgia": {
      "region": "Georgia",
      "cases": [
        0,
        0,
        1,
        ...
      ],
      "predictions": [
        0.1602764754993061,
        0.19285269106150466,
        ...
      ],
      "prediction_type": "weighted_exponential",
      "start": "2020-01-22"
    }
  },
  "countries": {
    "Canada": {
      "cases": [
        0,
        0,
        1,
        ...
      ],
      "predictions": [
        0.6292397306678004,
        0.6990728897808295,
        ...
      ],
      "prediction_type": "weighted_exponential",
      "country": "Canada",
      "start": "2020-01-22"
    },
    "US": {
      "country": "US",
      "cases": [
        0,
        0,
        1,
        ...
      ],
      "predictions": [
        0.1602764754993061,
        0.19285269106150466,
        ...
      ],
      "prediction_type": "weighted_exponential",
      "start": "2020-01-22"
    },
    ...
  }
}

Sources

All data from: Johns Hopkins CSSE