Weather app CLI#
Want to see if it is going to rain in the next hour, but you don’t want to leave your coding workflow and check a website? Using a public API (Application Programming Interface), you can collect the information right from your terminal. Wrap it in a Python script, install the script to your conda environment and you get a single command that prints the exact weather information you are interested in.
While creating this application, you will work with nested dictionaries and learn some best practices for turning on-off Python scripts into reusable programs.
Weather data#
The weather data used in this demo is provided by the Open-Meteo API, free for non-commercial use and licensed under CC BY 4.0 (Open-Meteo, n.d.). See References for the full citation.