Skip to main content
Both endpoints are completely free and require no API key or account registration.
Sky AI Forecast calls two Open-Meteo endpoints. First, the geocoding endpoint resolves a city name to coordinates. Those coordinates are then passed to the forecast endpoint to retrieve weather data.

Geocoding endpoint

GET https://geocoding-api.open-meteo.com/v1/search
Converts a city name into geographic coordinates plus display metadata.

Parameters

name
string
required
City name to search for (e.g. London, Tokyo, New York).
count
integer
default:"1"
Maximum number of results to return. Sky AI Forecast always passes count=1 to take the single best match.

Example request

GET https://geocoding-api.open-meteo.com/v1/search?name=London&count=1

Example response

{
  "results": [
    {
      "name": "London",
      "country": "United Kingdom",
      "latitude": 51.5085,
      "longitude": -0.1257
    }
  ]
}

Response fields used by the app

The app reads results[0] and extracts the following fields:
results
object[]
Array of matching locations. The app always reads index 0.

Forecast endpoint

GET https://api.open-meteo.com/v1/forecast
Returns current conditions, hourly data, and a 16-day daily outlook for a given location.

Full URL built by the app

https://api.open-meteo.com/v1/forecast?latitude=LAT&longitude=LON&current=temperature_2m,relative_humidity_2m,weather_code&hourly=temperature_2m,weather_code&daily=temperature_2m_max,temperature_2m_min,weather_code&forecast_days=16&timezone=auto

Parameters

latitude
number
required
Latitude of the location, taken from the geocoding result.
longitude
number
required
Longitude of the location, taken from the geocoding result.
current
string
required
Comma-separated list of current-condition variables to include. The app requests: temperature_2m, relative_humidity_2m, weather_code.
hourly
string
required
Comma-separated list of hourly variables to include. The app requests: temperature_2m, weather_code.
daily
string
required
Comma-separated list of daily aggregate variables to include. The app requests: temperature_2m_max, temperature_2m_min, weather_code.
forecast_days
integer
default:"16"
Number of days of forecast data to return. Fixed at 16.
timezone
string
default:"auto"
Timezone for time values. Set to auto so Open-Meteo infers the local timezone from the coordinates.

Response fields used by the app

current
object
Current weather conditions at the time of the request.
hourly
object
Hourly data arrays. Each array is ordered chronologically and shares the same index with hourly.time.
daily
object
Daily aggregate arrays. Each array is ordered by date and shares the same index with daily.time.

Build docs developers (and LLMs) love