In this section, we will be requesting APIs and collecting the required data through them. Technically, data that's obtained through an API isn't similar to performing a scraping activity since we can't only extract data that's required from the API and process it further.
Web scraping using APIs
Example 1 – searching and collecting university names and URLs
In this example, we will be using an API provided by HIPO (https://hipolabs.com/) to search for universities: http://universities.hipolabs.com/search?name=Wales.
This API uses a query parameter called name, which will look for a university name. We will also provide an additional parameter, country, with country names such as United States, and...