Created
September 8, 2023 19:36
-
-
Save andriilive/69c4a8b2db483222ce312d2f68e52107 to your computer and use it in GitHub Desktop.
Countries GEO
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get the ISO 3166-1 alpha-2 codes for the countries | |
countries=(IT FR CZ DE GB US VN CN AE IN UZ) | |
# Loop through the countries | |
for country in "${countries[@]}" | |
do | |
# Get the URL for the JSON data | |
url="https://api.worldbank.org/v2/country/$country?format=json" | |
# Download the JSON data to a file | |
curl -o data/$country.json $url | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment