Skip to content

Instantly share code, notes, and snippets.

@jaxatax
Last active March 6, 2019 01:34
Show Gist options
  • Save jaxatax/1126017a305464255d13b8f1f7df29f1 to your computer and use it in GitHub Desktop.
Save jaxatax/1126017a305464255d13b8f1f7df29f1 to your computer and use it in GitHub Desktop.
Get Weather For Dallas/Love Field
#https://www.geeksforgeeks.com/get-post-requests-using-python/
import requests
URL = "https://api.weather.gov/stations/KDAL/observations/latest/"
server_response = requests.get(url = URL)
data = server_response.json()
temperature = data['properties']['temperature']['value']
temperature = temperature*9/5+32
print(temperature)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment