Project – scraping data from websites with your Pi
HTML scraping is the process of making a request to a webpage in order to obtain the HTML itself, so data can be parsed out of it. We're going to build a bot that shows whether johnny-five.io
is up or not by scraping https://downforeveryoneorjustme.com/, a site that tells you if a site is down from multiple sources.
You don't need to change the wiring setup from the weather dashboard for this project, our current hardware is all we need.
Scraping downforeveryoneorjustme.com for johnny-five.io
First, go to https://downforeveryoneorjustme.com/ and enter johnny-five.io
in the URL input, and hit Enter. You should end up at https://downforeveryoneorjustme.com/johnny-five.io, where hopefully you'll see a rather simple page that looks like this:

Now to prepare for our web scraping code, we need to know what HTML element we're looking for as well as the URL. Right-click the It's just you.
and select Inspect
(or whichever variation it is on your browser...