https://api.apifreaks.com/v1.0/weather/current
$ pip install requests
Click Test it to start the request and see the response here!
| Field | Type | Requirement | Description |
|---|---|---|---|
| location | Object | Mandatory | Resolved location metadata. |
| current | Object | Mandatory | Live weather details. |
"location" (when coordinates Provided) object contains the following fields
| Field | Type | Requirement | Description |
|---|---|---|---|
| latitude | float | Mandatory | Geographic latitude of the given Coordinates |
| longitude | float | Mandatory | Geographic longitude of the given Coordinates |
| country_name | string | Mandatory | Country name by Coordinates |
| state_prov | string | Mandatory | State or province of given Coordinates |
| city | string | Mandatory | City of the given Coordinates |
| locality | string | Optional | Local area, neighborhood, or village name |
| elevation | float | Optional | Elevation above sea level (meters) |
| timezone | string | Mandatory | Timezone identifier (e.g., GMT, PST, etc.) |
| timezone_abbreviation | string | Mandatory | Abbreviation of timezone (e.g., GMT, IST, etc.) |
"location" (when IP Provided) object contains the following fields
| Field | Type | Requirement | Description |
|---|---|---|---|
| continent_code | string | Mandatory | Two-letter code of the continent |
| continent_name | string | Mandatory | Full name of the continent |
| country_code2 | string | Mandatory | Two-letter ISO country code |
| country_code3 | string | Mandatory | Three-letter ISO country code |
| country_name | string | Mandatory | Country name of the location |
| country_name_official | string | Mandatory | Official long-form country name |
| is_eu | boolean | Optional | Indicates if the country is part of the European Union |
| state_prov | string | Mandatory | State or province of the location |
| state_code | string | Optional | ISO code for the state or province |
| district | string | Optional | District or administrative division |
| city | string | Mandatory | City of the location |
| zipcode | string | Optional | Postal or ZIP code |
| latitude | float | Mandatory | Geographic latitude of the location |
| longitude | float | Mandatory | Geographic longitude of the location |
| locality | string | Optional | Local area or neighborhood |
| elevation | float | Optional | Elevation above sea level (meters) |
| timezone | string | Mandatory | Timezone identifier |
| timezone_abbreviation | string | Mandatory | Abbreviation of timezone |
"location" (when location Provided) object contains the following fields
| Field | Type | Requirement | Description |
|---|---|---|---|
| location_string | string | Mandatory | Full address or free-text location input |
| country_name | string | Mandatory | Country name of the location |
| state_prov | string | Mandatory | State or province of the location |
| city | string | Mandatory | City of the location |
| locality | string | Optional | Local area, neighborhood, or village name |
| latitude | float | Mandatory | Geographic latitude of the location |
| longitude | float | Mandatory | Geographic longitude of the location |
| elevation | float | Optional | Elevation above sea level (meters) |
| timezone | string | Mandatory | Timezone identifier |
| timezone_abbreviation | string | Mandatory | Abbreviation of timezone |
"current" Object contains the following fields
| Field | Type | Requirement | Description |
|---|---|---|---|
| timestamp | string | Mandatory | ISO 8601 formatted timestamp of the weather observation |
| temperature_2m | float | Mandatory | Current air temperature measured at 2 meters above ground (°C) |
| relative_humidity_2m | float | Mandatory | Current relative humidity at 2 meters above ground (%) |
| apparent_temperature | float | Optional | Apparent temperature (°C) |
| snowfall | float | Optional | Snowfall amount (cm) |
| rain | float | Optional | Rainfall amount (mm) |
| showers | float | Optional | Shower precipitation (mm) |
| precipitation | float | Optional | Total precipitation (mm) |
| weather_code | integer | Mandatory | weather condition code |
| cloud_cover | float | Optional | Percentage of sky covered by clouds (%) |
| pressure_msl | float | Optional | Atmospheric pressure at mean sea level (hPa) |
| surface_pressure | float | Optional | Atmospheric pressure at surface level (hPa) |
| wind_speed_10m | float | Optional | Wind speed measured at 10 meters above ground (km/h) |
| wind_direction_10m | integer | Optional | Wind direction (°) |
| wind_gusts_10m | float | Optional | Maximum wind gust speed at 10 meters (km/h) |
| astronomy | Object | Mandatory | Astronomical info for the current date. |
| air_quality | Object | Mandatory | Air quality and AQI data. |
"current.astronomy" object contains the following fields
| Field | Type | Requirement | Description |
|---|---|---|---|
| date | string | Mandatory | Calendar date of astronomical data (YYYY-MM-DD) |
| mid_night | string | Optional | Time of true midnight (HH:MM) |
| night_end | string | Optional | Time when astronomical twilight ends, marking dawn beginning (HH:MM) |
| sunrise | string | Mandatory | Time when Sun becomes visible above horizon (HH:MM) |
| solar_noon | string | Optional | Time when Sun reaches highest point in the sky (HH:MM) |
| sunset | string | Mandatory | Time when Sun disappears below horizon (HH:MM) |
| night_begin | string | Optional | Time when astronomical twilight begins, marking night start (HH:MM) |
| day_length | string | Optional | Total daylight duration (HH:MM) |
| sun_status | string | Optional | Current Sun position ("above_horizon", "below_horizon", or "-") |
| moon_phase | string | Optional | Current Moon phase (e.g., NEW_MOON, WAXING_CRESCENT, FULL_MOON, etc.) |
| moonrise | string | Optional | Time when Moon becomes visible above horizon (HH:MM) |
| moonset | string | Optional | Time when Moon disappears below horizon (HH:MM) |
| moon_status | string | Optional | Current Moon visibility ("visible", "not_visible", or "-") |
"current.air_quality" object contains the following fields
| Field | Type | Requirement | Description |
|---|---|---|---|
| timestamp | string | Mandatory | ISO 8601 formatted timestamp of the AQI observation |
| european_aqi | integer | Mandatory | European Air Quality Index (AQI) calculated for different particulate matter and gases individually. The consolidated european_aqi returns the maximum of all individual indices. Ranges from 0–20 (good), 20–40 (fair), 40–60 (moderate), 60–80 (poor), 80–100 (very poor), and exceeds 100 for extremely poor conditions. |
| us_aqi | integer | Mandatory | United States Air Quality Index (AQI) calculated for different particulate matter and gases individually. The consolidated us_aqi returns the maximum of all individual indices. Ranges from 0–50 (good), 51–100 (moderate), 101–150 (unhealthy for sensitive groups), 151–200 (unhealthy), 201–300 (very unhealthy), and 301–500 (hazardous). |
| pm10 | float | Mandatory | Concentration of particulate matter <10 micrometers (10 meters above ground) in μg/m³ |
| pm2_5 | float | Mandatory | Concentration of particulate matter <2.5 micrometers (10 meters above ground) in μg/m³ |
| carbon_monoxide | float | Optional | Concentration of carbon monoxide in the air (10 meters above ground) in μg/m³ |
| nitrogen_dioxide | float | Optional | Concentration of nitrogen dioxide in the air (10 meters above ground) in μg/m³ |
| sulphur_dioxide | float | Optional | Concentration of sulphur dioxide in the air (10 meters above ground) in μg/m³ |
| ozone | float | Optional | Concentration of ozone in the air (10 meters above ground) in μg/m³ |
| dust | float | Optional | Concentration of dust particles in the air (10 meters above ground) in μg/m³ |
| uv_index | float | Optional | Ultraviolet radiation index under current sky conditions (dimensionless) |
| aerosol_optical_depth | float | Optional | Aerosol optical depth at 550 nm of the entire atmosphere to indicate haze (dimensionless) |
| uv_index_clear_sky | float | Optional | Ultraviolet radiation index under clear sky conditions (dimensionless) |