Skip to content

Instantly share code, notes, and snippets.

@wolivera
Last active February 12, 2019 19:46
Show Gist options
  • Save wolivera/ab7daa95641a9faecf7bce37ea75d6f6 to your computer and use it in GitHub Desktop.
Save wolivera/ab7daa95641a9faecf7bce37ea75d6f6 to your computer and use it in GitHub Desktop.
Breezometer API json samples
// Current Air Quality conditions using SF coordinates (37.7749° N, 122.4194° W) and full features
// https://api.breezometer.com/air-quality/v2/current-conditions?lat=37.7749&lon=-122.4194&key=API_KEY&features=breezometer_aqi,local_aqi,health_recommendations,sources_and_effects,pollutants_concentrations,pollutants_aqi_information
{
"metadata": null,
"data": {
"datetime": "2019-02-12T19:00:00Z",
"data_available": true,
"indexes": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 55,
"aqi_display": "55",
"color": "#E0F30C",
"category": "Moderate air quality",
"dominant_pollutant": "pm10"
},
"usa_epa": {
"display_name": "AQI (US)",
"aqi": 61,
"aqi_display": "61",
"color": "#FFFF00",
"category": "Moderate air quality",
"dominant_pollutant": "pm25"
}
},
"pollutants": {
"co": {
"display_name": "CO",
"full_name": "Carbon monoxide",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 96,
"aqi_display": "96",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 485.47,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Typically originates from incomplete combustion of carbon fuels, such as that which occurs in car engines and power plants.",
"effects": "When inhaled, carbon monoxide can prevent the blood from carrying oxygen. Exposure may cause dizziness, nausea and headaches. Exposure to extreme concentrations can lead to loss of consciousness."
}
},
"no2": {
"display_name": "NO2",
"full_name": "Nitrogen dioxide",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 59,
"aqi_display": "59",
"color": "#FFFF00",
"category": "Moderate air quality"
}
},
"concentration": {
"value": 53.01,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Main sources are fuel burning processes, such as those used in industry and transportation.",
"effects": "Exposure may cause increased bronchial reactivity in patients with asthma, lung function decline in patients with COPD, and increased risk of respiratory infections, especially in young children."
}
},
"o3": {
"display_name": "O3",
"full_name": "Ozone",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 90,
"aqi_display": "90",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 12.79,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Ozone is created in a chemical reaction between atmospheric oxygen, nitrogen oxides, carbon monoxide and organic compounds, in the presence of sunlight.",
"effects": "Ozone can irritate the airways and cause coughing, a burning sensation, wheezing and shortness of breath. Additionally, ozone is one of the major components of photochemical smog."
}
},
"pm10": {
"display_name": "PM10",
"full_name": "Inhalable particulate matter (<10µm)",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 55,
"aqi_display": "55",
"color": "#FFFF00",
"category": "Moderate air quality"
}
},
"concentration": {
"value": 54.03,
"units": "ug/m3"
},
"sources_and_effects": {
"sources": "Main sources are combustion processes (e.g. indoor heating, wildfires), mechanical processes (e.g. construction, mineral dust, agriculture) and biological particles (e.g. pollen, bacteria, mold).",
"effects": "Inhalable particles can penetrate into the lungs. Short term exposure can cause irritation of the airways, coughing, and aggravation of heart and lung diseases, expressed as difficulty breathing, heart attacks and even premature death."
}
},
"pm25": {
"display_name": "PM2.5",
"full_name": "Fine particulate matter (<2.5µm)",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 74,
"aqi_display": "74",
"color": "#84CF33",
"category": "Good air quality"
}
},
"concentration": {
"value": 16.13,
"units": "ug/m3"
},
"sources_and_effects": {
"sources": "Main sources are combustion processes (e.g. power plants, indoor heating, car exhausts, wildfires), mechanical processes (e.g. construction, mineral dust) and biological particles (e.g. bacteria, viruses).",
"effects": "Fine particles can penetrate into the lungs and bloodstream. Short term exposure can cause irritation of the airways, coughing and aggravation of heart and lung diseases, expressed as difficulty breathing, heart attacks and even premature death."
}
},
"so2": {
"display_name": "SO2",
"full_name": "Sulfur dioxide",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 100,
"aqi_display": "100",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 0.78,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Main sources are burning processes of sulfur-containing fuel in industry, transportation and power plants.",
"effects": "Exposure causes irritation of the respiratory tract, coughing and generates local inflammatory reactions. These in turn, may cause aggravation of lung diseases, even with short term exposure."
}
}
},
"health_recommendations": {
"general_population": "If you start to feel respiratory discomfort such as coughing or breathing difficulties, consider reducing the intensity of your outdoor activities. Try to limit the time you spend near busy roads, construction sites, industrial emission stacks, open fires and other sources of smoke.",
"elderly": "Reduce the intensity of your outdoor activities. It is recommended to limit the time you are near busy roads, construction sites, open fires and other sources of smoke. In addition, consider reducing the time you spend near industrial emission stacks. Staying indoors with an activated air filtration system would be best for your long term health.",
"lung_diseases": "Reduce the intensity of your outdoor activities. Keep relevant medication(s) available and consult a doctor with any questions. It is recommended to limit the time you are near busy roads, industrial emission stacks, open fires and other sources of smoke. Staying indoors with an activated air filtration system would be best for your long term health.",
"heart_diseases": "Reduce the intensity of your outdoor activities. Keep relevant medication(s) available and consult a doctor with any questions. It is recommended to limit the time you are near busy roads, construction sites, open fires and other sources of smoke. In addition, consider reducing the time you spend near industrial emission stacks. Staying indoors with an activated air filtration system would be best for your long term health.",
"active": "Reduce the intensity of your outdoor activities. It is recommended to limit the time you are near busy roads, construction sites, industrial emission stacks, open fires and other sources of smoke. Staying indoors with an activated air filtration system would be best for your long term health.",
"pregnant_women": "To keep you and your baby healthy, reduce the intensity of your outdoor activities. It is recommended to limit the time you are near busy roads, construction sites, open fires and other sources of smoke. In addition, consider reducing the time you spend near industrial emission stacks. Staying indoors with an activated air filtration system would be best for your long term health.",
"children": "Reduce the intensity of your outdoor activities. It is recommended to limit the time you are near busy roads, construction sites, open fires and other sources of smoke. In addition, consider reducing the time you spend near industrial emission stacks. Staying indoors with an activated air filtration system would be best for your long term health."
}
},
"error": null
}
// Air Quality Forecast by datetime conditions using SF coordinates (37.7749° N, 122.4194° W) and full features
// https://api.breezometer.com/air-quality/v2/forecast/hourly?lat=37.7749&lon=-122.4194&key=API_KEY&datetime=2019-02-13T19:00:00&features=breezometer_aqi,local_aqi,health_recommendations,sources_and_effects,pollutants_concentrations,pollutants_aqi_information
{
"metadata": null,
"data": {
"datetime": "2019-02-13T19:00:00Z",
"data_available": true,
"indexes": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 66,
"aqi_display": "66",
"color": "#9CD828",
"category": "Good air quality",
"dominant_pollutant": "o3"
},
"usa_epa": {
"display_name": "AQI (US)",
"aqi": 40,
"aqi_display": "40",
"color": "#00E400",
"category": "Good air quality",
"dominant_pollutant": "o3"
}
},
"pollutants": {
"co": {
"display_name": "CO",
"full_name": "Carbon monoxide",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 99,
"aqi_display": "99",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 118.49,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Typically originates from incomplete combustion of carbon fuels, such as that which occurs in car engines and power plants.",
"effects": "When inhaled, carbon monoxide can prevent the blood from carrying oxygen. Exposure may cause dizziness, nausea and headaches. Exposure to extreme concentrations can lead to loss of consciousness."
}
},
"no2": {
"display_name": "NO2",
"full_name": "Nitrogen dioxide",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 98,
"aqi_display": "98",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 3.7,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Main sources are fuel burning processes, such as those used in industry and transportation.",
"effects": "Exposure may cause increased bronchial reactivity in patients with asthma, lung function decline in patients with COPD, and increased risk of respiratory infections, especially in young children."
}
},
"o3": {
"display_name": "O3",
"full_name": "Ozone",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 67,
"aqi_display": "67",
"color": "#84CF33",
"category": "Good air quality"
}
},
"concentration": {
"value": 42.02,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Ozone is created in a chemical reaction between atmospheric oxygen, nitrogen oxides, carbon monoxide and organic compounds, in the presence of sunlight.",
"effects": "Ozone can irritate the airways and cause coughing, a burning sensation, wheezing and shortness of breath. Additionally, ozone is one of the major components of photochemical smog."
}
},
"pm10": {
"display_name": "PM10",
"full_name": "Inhalable particulate matter (<10µm)",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 95,
"aqi_display": "95",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 6.04,
"units": "ug/m3"
},
"sources_and_effects": {
"sources": "Main sources are combustion processes (e.g. indoor heating, wildfires), mechanical processes (e.g. construction, mineral dust, agriculture) and biological particles (e.g. pollen, bacteria, mold).",
"effects": "Inhalable particles can penetrate into the lungs. Short term exposure can cause irritation of the airways, coughing, and aggravation of heart and lung diseases, expressed as difficulty breathing, heart attacks and even premature death."
}
},
"pm25": {
"display_name": "PM2.5",
"full_name": "Fine particulate matter (<2.5µm)",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 94,
"aqi_display": "94",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 4.02,
"units": "ug/m3"
},
"sources_and_effects": {
"sources": "Main sources are combustion processes (e.g. power plants, indoor heating, car exhausts, wildfires), mechanical processes (e.g. construction, mineral dust) and biological particles (e.g. bacteria, viruses).",
"effects": "Fine particles can penetrate into the lungs and bloodstream. Short term exposure can cause irritation of the airways, coughing and aggravation of heart and lung diseases, expressed as difficulty breathing, heart attacks and even premature death."
}
},
"so2": {
"display_name": "SO2",
"full_name": "Sulfur dioxide",
"aqi_information": {
"baqi": {
"display_name": "BreezoMeter AQI",
"aqi": 99,
"aqi_display": "99",
"color": "#009E3A",
"category": "Excellent air quality"
}
},
"concentration": {
"value": 1.21,
"units": "ppb"
},
"sources_and_effects": {
"sources": "Main sources are burning processes of sulfur-containing fuel in industry, transportation and power plants.",
"effects": "Exposure causes irritation of the respiratory tract, coughing and generates local inflammatory reactions. These in turn, may cause aggravation of lung diseases, even with short term exposure."
}
}
},
"health_recommendations": {
"general_population": "With this level of air quality, you have no limitations. Enjoy the outdoors!",
"elderly": "If you start to feel respiratory discomfort such as coughing or breathing difficulties, consider reducing the intensity of your outdoor activities. Try to limit the time you spend near busy roads, construction sites, open fires and other sources of smoke.",
"lung_diseases": "If you start to feel respiratory discomfort such as coughing or breathing difficulties, consider reducing the intensity of your outdoor activities. Try to limit the time you spend near busy roads, industrial emission stacks, open fires and other sources of smoke.",
"heart_diseases": "If you start to feel respiratory discomfort such as coughing or breathing difficulties, consider reducing the intensity of your outdoor activities. Try to limit the time you spend near busy roads, construction sites, industrial emission stacks, open fires and other sources of smoke.",
"active": "If you start to feel respiratory discomfort such as coughing or breathing difficulties, consider reducing the intensity of your outdoor activities. Try to limit the time you spend near busy roads, construction sites, industrial emission stacks, open fires and other sources of smoke.",
"pregnant_women": "To keep you and your baby healthy, consider reducing the intensity of your outdoor activities. Try to limit the time you spend near busy roads, construction sites, open fires and other sources of smoke.",
"children": "If you start to feel respiratory discomfort such as coughing or breathing difficulties, consider reducing the intensity of your outdoor activities. Try to limit the time you spend near busy roads, construction sites, open fires and other sources of smoke."
}
},
"error": null
}
// Weather current conditions using SF coordinates (37.7749° N, 122.4194° W)
// https://api.breezometer.com/weather/v1/current-conditions?lat=37.7749&lon=-122.4194&key=API_KEY&metadata=true
{
"metadata": {
"timestamp": "2019-02-12T19:42:56Z",
"location": {
"country": "United States"
}
},
"data": {
"datetime": "2019-02-12T19:00:00Z",
"is_day_time": true,
"icon_code": 22,
"weather_text": "Overcast",
"temperature": {
"value": 8.53,
"units": "C"
},
"feels_like_temperature": {
"value": 5.81,
"units": "C"
},
"relative_humidity": 63,
"precipitation": {
"precipitation_probability": 0,
"total_precipitation": {
"value": 0,
"units": "mm"
}
},
"wind": {
"speed": {
"value": 4.572,
"units": "km/h"
},
"direction": 82
},
"wind_gust": {
"value": 20.772,
"units": "km/h"
},
"pressure": {
"value": 1014.87,
"units": "mb"
},
"visibility": {
"value": 24,
"units": "km"
},
"dew_point": {
"value": 1.83,
"units": "C"
},
"cloud_cover": 100
},
"error": null
}
// // Weather 3 hours forecast conditions using SF coordinates (37.7749° N, 122.4194° W)
// https://api.breezometer.com/weather/v1/forecast/hourly?lat=37.7749&lon=-122.4194&key=API_KEY&hours=3&metadata=true
{
"metadata": {
"start_timestamp": "2019-02-12T19:45:47Z",
"end_timestamp": "2019-02-12T22:45:47Z",
"location": {
"country": "United States"
}
},
"data": [
{
"datetime": "2019-02-12T20:00:00Z",
"is_day_time": true,
"icon_code": 22,
"weather_text": "Overcast",
"temperature": {
"value": 8.9,
"units": "C"
},
"feels_like_temperature": {
"value": 6.09,
"units": "C"
},
"relative_humidity": 58,
"precipitation": {
"precipitation_probability": 0,
"total_precipitation": {
"value": 0,
"units": "mm"
}
},
"wind": {
"speed": {
"value": 4.32,
"units": "km/h"
},
"direction": 86
},
"wind_gust": {
"value": 25.704,
"units": "km/h"
},
"pressure": {
"value": 1013.96,
"units": "mb"
},
"visibility": {
"value": 24,
"units": "km"
},
"dew_point": {
"value": 0.99,
"units": "C"
},
"cloud_cover": 100
},
{
"datetime": "2019-02-12T21:00:00Z",
"is_day_time": true,
"icon_code": 22,
"weather_text": "Overcast",
"temperature": {
"value": 9.17,
"units": "C"
},
"feels_like_temperature": {
"value": 6.33,
"units": "C"
},
"relative_humidity": 54,
"precipitation": {
"precipitation_probability": 0,
"total_precipitation": {
"value": 0,
"units": "mm"
}
},
"wind": {
"speed": {
"value": 4.032000000000001,
"units": "km/h"
},
"direction": 99
},
"wind_gust": {
"value": 31.319999999999997,
"units": "km/h"
},
"pressure": {
"value": 1013.09,
"units": "mb"
},
"visibility": {
"value": 24,
"units": "km"
},
"dew_point": {
"value": 0.47,
"units": "C"
},
"cloud_cover": 100
},
{
"datetime": "2019-02-12T22:00:00Z",
"is_day_time": true,
"icon_code": 22,
"weather_text": "Overcast",
"temperature": {
"value": 9.39,
"units": "C"
},
"feels_like_temperature": {
"value": 6.53,
"units": "C"
},
"relative_humidity": 54,
"precipitation": {
"precipitation_probability": 11,
"total_precipitation": {
"value": 0,
"units": "mm"
}
},
"wind": {
"speed": {
"value": 4.284,
"units": "km/h"
},
"direction": 123
},
"wind_gust": {
"value": 37.080000000000005,
"units": "km/h"
},
"pressure": {
"value": 1012.49,
"units": "mb"
},
"visibility": {
"value": 24,
"units": "km"
},
"dew_point": {
"value": 0.65,
"units": "C"
},
"cloud_cover": 100
}
],
"error": null
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment