From the course: Data Pipeline Automation with GitHub Actions Using R and Python

Unlock the full course today

Join today to access over 24,900 courses taught by industry experts.

Solution: Query the API with Python

Solution: Query the API with Python

(upbeat music) - [Instructor] We are going to use this Jupyter notebook for the solution of chapter one challenge. This notebook Py_challenge_solutions can be found under the course repository chapter one folder. In addition, we're going to use the AI_API Python script as before. This Python script provides a set of functions that will enable us to query data from the API. Let's get started by loading those libraries, and we're going to use the same libraries as before, EIA_API and set it as API. The OS library we're going to use to load environment variables. The date/time we'll use to reformat date and time objects. And last is Plotly, which we're going to use to visualize the data. Let's go to the first question. We were asked to extract from the EIA dashboard, the metadata of the San Diego Gas and Electric Balancing Authority sub region. Let's go to the eia.gov website and navigate to the dashboard. So on the main page of eia.gov, scroll down to the feature section, then click on…

Contents