Created
May 9, 2022 08:36
-
-
Save tuna2134/86040e9e15b6b36df69d453f91455ec2 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
import requests | |
r = requests.get( | |
"https://www.jma.go.jp/bosai/forecast/data/forecast/270000.json" | |
) | |
data = r.json()[0] | |
print("発表管区:{}".format(data["publishingOffice"])) | |
timeSeries = data["timeSeries"][0] | |
print("発表時間:{}".format(timeSeries["timeDefines"][1])) | |
area = timeSeries["areas"][0] | |
print("天気:{}".format(area["weathers"][1])) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment