aromidvar1355 commited on
Commit
3d3dfdb
·
verified ·
1 Parent(s): 1b2af98

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -42,7 +42,7 @@ def fetch_openweather_data(lat, lon, datetime_input):
42
 
43
  def fetch_openweather_forecast(lat, lon):
44
  """Fetches 7-day weather forecast data from OpenWeather's One Call API."""
45
- url = f"https://api.openweathermap.org/data/2.5/onecall?lat={lat}&lon={lon}&exclude=current,minutely,hourly,alerts&appid={OPENWEATHER_API_KEY}&units=metric"
46
  try:
47
  response = requests.get(url)
48
  response.raise_for_status() # Raise HTTPError for bad responses
 
42
 
43
  def fetch_openweather_forecast(lat, lon):
44
  """Fetches 7-day weather forecast data from OpenWeather's One Call API."""
45
+ url = f"https://api.openweathermap.org/data/3.0/onecall?lat={lat}&lon={lon}&exclude=current,minutely,hourly,alerts&appid={OPENWEATHER_API_KEY}&units=metric"
46
  try:
47
  response = requests.get(url)
48
  response.raise_for_status() # Raise HTTPError for bad responses