Scrapping all historic result data of raffle and saving in mongodb database, already exists the Official API of Loteria, but this project it will be done for student purposes.
The project is building for filter all results history using a API for GET the data filtered according with the seted params in search. This is a start and a little part of the system like a all.
- PuppeteerJs (Chrome automation)
- Axios (GET and POST requests)
- Cheerio (Manipulation of data returned of Axios and Puppeteer)
-
Cloning the repository
git clone https://github.com/leoelias023/megasena_scrapping.git
-
Installing all dependences
yarn
-
Set your connection string mongodb
Create archive .env and inside set DB_USER, DB_PASSWORD
Example:mongodb://localhost:27017
-
Running Project
yarn start
Delete all informations in table Draw, reset all data for a possible restart
Return the count of all draws that have the number passed as an argument
Return the bigger and minor currencly and the number