Skip to Content
API📦 Data Types

📦 Data Types

This section describes the response structures returned by the Skycaster API. All data is sourced from the Open-Meteo API.

Note: The fields returned in each response depend on your dashboard settings (choosenInfo, choosenInfoHourly, choosenInfoDaily). Only the fields you have configured are included in the response. Two fields are always present in every entry: icon and weather_description.


🌐 Common Response Wrapper

All three public endpoints return responses with the same top-level shape:

1type ApiResponse = {
2message: CityResult[];
3};
4
5type CityResult = {
6city: string;       // Display name of the city
7locale?: string;    // BCP 47 locale tag, e.g. "de-CH", "en-US"
8data: WeatherData | ForecastData;
9};

☀️ WeatherData

Returned by GET /weather. The data object contains one key per configured field, plus two always-present fields.

1// Always present
2type WeatherDataBase = {
3icon: string;               // URL to animated weather icon gif
4weather_description: string; // Human-readable description, e.g. "Clear sky"
5};
6
7// Additional fields depend on user's choosenInfo settings.
8// Field names match the setting key (see Available Fields table below).
9type WeatherData = WeatherDataBase & {
10[fieldName: string]: number | string | null;
11};

Example data object:

{
"icon": "https://cdn.skycaster.tv/set-1-gif/01d.gif",
"weather_description": "Clear sky",
"temperature": 18.5,
"humidity": 62,
"dew_point": 11.2,
"wind_speed": 4.1,
"wind_direction": 180,
"wind_direction_label": "S",
"heat_index": 18.2
}

🕐 ForecastData (Hourly)

Returned by GET /forecast-hourly. The data object contains a forecast map keyed by ISO 8601 datetime strings.

1type HourlyForecastData = {
2forecast: {
3  [isoDatetime: string]: HourlyEntry; // e.g. "2025-05-17T06:00"
4};
5type: "hourly";
6};
7
8// Always present per entry
9type HourlyEntryBase = {
10time: string;               // ISO 8601 datetime, e.g. "2025-05-17T06:00"
11icon: string;               // URL to animated weather icon gif
12weather_description: string;
13};
14
15// Additional fields from choosenInfoHourly (or choosenInfo as fallback)
16type HourlyEntry = HourlyEntryBase & {
17[fieldName: string]: number | string | null;
18};

🌤️ ForecastData (Daily)

Returned by GET /forecast-daily. The data object contains a forecast map keyed by ISO 8601 date strings.

1type DailyForecastData = {
2forecast: {
3  [isoDate: string]: DailyEntry; // e.g. "2025-05-17"
4};
5type: "daily";
6days: number; // Number of days returned
7};
8
9// Always present per entry
10type DailyEntryBase = {
11time: string;               // ISO 8601 date, e.g. "2025-05-17"
12icon: string;               // URL to animated weather icon gif
13weather_description: string;
14};
15
16// Additional fields from choosenInfoDaily (or choosenInfo as fallback)
17type DailyEntry = DailyEntryBase & {
18[fieldName: string]: number | string | null;
19};

📋 Available Field Names

Configure these in your dashboard. Use the Field Name as the key when reading the response.

Current / Hourly Fields

Field NameDescriptionUnit
temperatureAir temperature at 2 m°C or °F
feels_likeApparent temperature°C or °F
humidityRelative humidity%
dew_pointDew point temperature°C or °F
heat_indexComputed heat index (from temp + humidity)°C or °F
wind_speedWind speed at 10 mkm/h, m/s, or mph
wind_directionWind direction at 10 mdegrees (0–360)
wind_direction_labelCardinal direction label (auto-added with wind_direction)e.g. "N", "SW"
wind_gustsWind gust speed at 10 mkm/h, m/s, or mph
wind_speed_80mWind speed at 80 mkm/h, m/s, or mph
wind_speed_120mWind speed at 120 mkm/h, m/s, or mph
wind_speed_180mWind speed at 180 mkm/h, m/s, or mph
pressureMean sea level pressurehPa
surface_pressureSurface pressurehPa
cloud_coverTotal cloud cover%
cloud_cover_lowLow-altitude cloud cover%
cloud_cover_midMid-altitude cloud cover%
cloud_cover_highHigh-altitude cloud cover%
visibilityVisibilitymeters
precipitationTotal precipitationmm or inch
precipitation_probabilityPrecipitation probability%
rainRain amountmm or inch
showersShowers amountmm or inch
snowfallSnowfall amountcm
snow_depthSnow depthm
uv_indexUV index
uv_index_clear_skyUV index under clear sky
sunshine_durationSunshine durationseconds
shortwave_radiationGlobal horizontal irradianceW/m²
direct_radiationDirect solar radiationW/m²
diffuse_radiationDiffuse solar radiationW/m²
capeCAPE (convective available potential energy)J/kg
vapour_pressure_deficitVapour pressure deficitkPa
et0_fao_evapotranspirationET₀ reference evapotranspirationmm
is_dayDaytime flag1 = day, 0 = night
weather_descriptionWMO weather descriptionstring
soil_temperature_0cmSoil temperature at 0 cm depth°C or °F
soil_temperature_6cmSoil temperature at 6 cm depth°C or °F
soil_temperature_18cmSoil temperature at 18 cm depth°C or °F
soil_temperature_54cmSoil temperature at 54 cm depth°C or °F
soil_moisture_0_to_1cmSoil moisture 0–1 cmm³/m³
soil_moisture_1_to_3cmSoil moisture 1–3 cmm³/m³
soil_moisture_3_to_9cmSoil moisture 3–9 cmm³/m³
soil_moisture_9_to_27cmSoil moisture 9–27 cmm³/m³
soil_moisture_27_to_81cmSoil moisture 27–81 cmm³/m³

Daily-Only Fields

Field NameDescriptionUnit
temperature_maxDaily max temperature°C or °F
temperature_minDaily min temperature°C or °F
temperature_meanDaily mean temperature°C or °F
apparent_temperature_maxDaily max apparent temperature°C or °F
apparent_temperature_minDaily min apparent temperature°C or °F
apparent_temperature_meanDaily mean apparent temperature°C or °F
sunriseSunrise timeISO datetime string
sunsetSunset timeISO datetime string
daylight_durationDaylight durationseconds
sunshine_durationSunshine durationseconds
precipitation_sumTotal daily precipitationmm or inch
rain_sumTotal daily rainmm or inch
showers_sumTotal daily showersmm or inch
snowfall_sumTotal daily snowfallcm
precipitation_probability_maxMax precipitation probability%
precipitation_hoursNumber of hours with precipitationhours
wind_speed_maxMax daily wind speedkm/h, m/s, or mph
wind_gusts_maxMax daily wind gustskm/h, m/s, or mph
wind_direction_dominantDominant wind directiondegrees
uv_index_maxMax daily UV index
uv_index_clear_sky_maxMax daily UV index under clear sky
shortwave_radiation_sumDaily solar radiation sumMJ/m²
et0_fao_evapotranspirationDaily ET₀ reference evapotranspirationmm

Air Quality Fields

Field NameDescriptionUnit
air_qualityEuropean AQI (1–5: Good → Very Poor)index
ozone_levelOzone concentrationμg/m³
pm2_5PM2.5 particulate matterμg/m³
pm10PM10 particulate matterμg/m³
carbon_monoxideCO concentrationμg/m³
nitrogen_dioxideNO₂ concentrationμg/m³
sulphur_dioxideSO₂ concentrationμg/m³
european_aqiEuropean AQIindex
us_aqiUS AQIindex
dustDust concentrationμg/m³
pollen_alderAlder pollengrains/m³
pollen_birchBirch pollengrains/m³
pollen_grassGrass pollengrains/m³
pollen_mugwortMugwort pollengrains/m³
pollen_oliveOlive pollengrains/m³
pollen_ragweedRagweed pollengrains/m³

📞 Need Assistance?

If you have questions or need support:

Last updated on