Skip to content

This repository contains source code for a Rest API that can be used to retrieve historical data on the ongoing coronavirus pandemic.

Notifications You must be signed in to change notification settings

KirubelTolosa/CovidAPI_.NETCore

Repository files navigation

COVID-19 REST API

This covid-19 Rest-API can be used to retrieve global covid related data, ConfirmedCases, Deaths, and Recoveries. It contains an injestion console application which ports over .csv format data from the source to store in a Microsoft SQL Server database, and WebApplication that exposes several endpoints to query the database.

The technologies/libraries used in the application are the following

  • Autofac (For dependency injection)
  • ASP.NET (For the web application)
  • ADO.NET (For the data access to SQL db)
  • CSVHelper (For reading .csv responce)
  • AWS Toolkit for VS(Deployment to elastic beanstalk)
  • SQL Server Replication (To migrate local DB to Amazon RDS)
  • ....

Hosting the application requires changing the endpoint to the databases and scheduling a task to update it with recent data. The running version of the application is running in aws elasticbeanstalk environment at the specified urls below. A scheduled task is running every five minutes on a t2.micro EC2 instance to make a call to data source API, filter the most recent data and replenish the database.

*** The data source I used is provided by "Johns Hopkins University_Center for Systems Science and Engineering (CSSE).

URI to access running versions of the application:

(Documentation included)

Here are a few example URI refernces to resource usage


Use the following uri reference to get national count of cases(metrics) from all nations in the world.  
          "kirubeltolosa.com/api/covid/Confirmed_Cases",
          "kirubeltolosa.com/api/covid/Deaths",
          "kirubeltolosa.com/api/covid/Recoveries"                  
          
Use the following uri reference to get the worldwide count of cases(metrics). 
         "kirubeltolosa.com/api/covid/{metrics}/GlobalCount"
                
Use the following uri reference to get the national count of cases(metrics) of a nation. Optionally, you can include a date to find the count of cases on that date. 
        "kirubeltolosa.com/api/covid/{metrics}/Country/{Date : Optional}"
       
Use the following uri refernce to get the totalled count of cases of nation for each tracked date. 
        "kirubeltolosa.com/api/covid/{metrics}/Country/DailyCount"  

I hope you will find this useful and please reach out to me at info@kirubeltolosa.com if you have any question or feedback. Thanks.

About

This repository contains source code for a Rest API that can be used to retrieve historical data on the ongoing coronavirus pandemic.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages