Monday 30 March 2020

Covid 19 API & Auto Updater in NodeJS/Docker.

Recently I made a scraper for Covid 19 to save the data in a MySQL database, and with this, I made an API to recover the data in JSON format.​To maintain always to update the data this scraper runs with a cron every 12 hours, this time can be edited via env variables.​Right now it's published in the next link http://ec2-18-223-118-73.us-east-2.compute.amazonaws.com/​The endpoints are:/countries: http://ec2-18-223-118-73.us-east-2.compute.amazonaws.com/countriesthis endpoint supports a country and a date filter via query params `?country=NAME&date=YYYY-MM-DD` both can be used at the same time or each one by separated/worldwide: http://ec2-18-223-118-73.us-east-2.compute.amazonaws.com/worldwidethis endpoint supports a date filter via query params `date=YYYY-MM-DD`​You can find the repository here https://github.com/AndresMorelos/covid-19-apiI'm open to feedback, Issues and pull requests to make this app better.​​https://preview.redd.it/vyu6u03jewp41.png?width=1898&format=png&auto=webp&s=71bb93bed6e75f57c9e3b8d55d39410128c8c0cf

Submitted March 31, 2020 at 12:55AM by andresmorelos

No comments:

Post a Comment