csparpa / pyowm

A Python wrapper around the OpenWeatherMap web API
https://pyowm.readthedocs.io
MIT License
789 stars 171 forks source link

Enhance Air Pollution data #365

Closed csparpa closed 3 years ago

csparpa commented 3 years ago

As per https://openweathermap.org/api/air-pollution OWM added more fields to their airpollution API - they should be provided by OWM as well:

{
  "coord":[
    50,
    50
  ],
  "list":[
    {
      "dt":1605182400,
      "main":{
        "aqi":1
      },
      "components":{
        "co":201.94053649902344,
        "no":0.01877197064459324,
        "no2":0.7711350917816162,
        "o3":68.66455078125,
        "so2":0.6407499313354492,
        "pm2_5":0.5,                      # <<<
        "pm10":0.540438711643219,         # <<<
        "nh3":0.12369127571582794         # <<< 
      }
    }
  ]
} 
csparpa commented 3 years ago

Related to #362