The Ambee Air Quality API provides real-time, hyper-local air quality data for over a million postal codes across 150+ countries, cities, and coordinates. It offers data granularity at a spatial resolution of 500 meters and follows the US EPA standard for Air Quality Index.
Access real-time air quality data for over 150 countries with a specified resolution of 500 meters (0.3 miles).
Get air quality data using geographic coordinates (latitude/longitude).
x-api-key
Content-type
Accept-Language
lat
lng
https://api.ambeedata.com/latest/by-lat-lng?lat=12&lng=77
const http = require("https");
const options = {
"method": "GET",
"hostname": "api.ambeedata.com",
"port": null,
"path": "/latest/by-lat-lng?lat=12.9889055&lng=77.574044",
"headers": {
"x-api-key": "API_KEY",
"Content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
Get air quality data using the postal code of your desired location.
x-api-key
Content-type
Accept-Language
postalCode
https://api.ambeedata.com/latest/by-postal-code?postalCode=560020&countryCode=IND
const http = require("https");
const options = {
"method": "GET",
"hostname": "api.ambeedata.com",
"port": null,
"path": "/latest/by-postal-code?postalCode=560020&countryCode=IND",
"headers": {
"x-api-key": "API_KEY",
"Content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
Get air quality data by entering the name of the city.
x-api-key
Content-type
Accept-Language
city
limit
https://api.ambeedata.com/latest/by-city?city=Bengaluru
const http = require("https");
const options = {
"method": "GET",
"hostname": "api.ambeedata.com",
"port": null,
"path": "/latest/by-city?city=Bengaluru",
"headers": {
"x-api-key": "API_KEY",
"Content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
Get air quality data by entering the 3-digit ISO country code.
x-api-key
Content-type
Accept-Language
limit
https://api.ambeedata.com/latest/by-country-code?countryCode=IND
const http = require("https");
const options = {
"method": "GET",
"hostname": "api.ambeedata.com",
"port": null,
"path": "/latest/by-country-code?countryCode=IND",
"headers": {
"x-api-key": "API_KEY",
"Content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
Access historical air quality data for your selected timeframe across the supported regions.
Access 30+ years of historical AQ data. Download historical data.
Get air quality data using geographic coordinates (latitude/longitude).
x-api-key
Content-type
Accept-Language
lat
lng
from
to
https://api.ambeedata.com/history/by-lat-lng?lat=12&lng=73&from=2020-07-13 12:16:44&to=2020-07-18 08:16:44
const http = require("https");
const options = {
"method": "GET",
"hostname": "api.ambeedata.com",
"port": null,
"path": "/history/by-lat-lng?lat=12.9889055&lng=77.574044&from=2020-07-13 12:16:44&to=2020-07-14 12:16:44",
"headers": {
"x-api-key": "API_KEY",
"Content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
Get air quality data using the postal code of your desired location.
x-api-key
Content-type
Accept-Language
postalCode
from
to
https://api.ambeedata.com/history/by-postal-code?postalCode=560020&countryCode=IND&from=2020-12-01 00:00:00&to=2020-12-03 00:00:00
const http = require("https");
const options = {
"method": "GET",
"hostname": "api.ambeedata.com",
"port": null,
"path": "/history/by-postal-code?postalCode=560020&countryCode=IND&from=2020-07-13 12:16:44&to=2020-07-14 12:16:44",
"headers": {
"x-api-key": "API_KEY",
"Content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
The air quality forecasts API provides predictions of air quality levels, allowing you to plan and take preventive measures against poor air conditions.
The API delivers forecasts for up to 48 hours in advance, offering data at a level of specific geographic coordinates. This API is ideal for applications that require accurate and timely air quality information, such as environmental monitoring, health advisories, and smart city integrations. With easy-to-use endpoints and robust data coverage, you can seamlessly integrate air quality forecasts into your platform or service.
You can get a forecast of the air up to 4 days in advance. This service is available on demand. Get in touch.
Get air quality forecasts for the USA using specific geographic coordinates.
x-api-key
Content-type
Accept-Language
lat
lng
https://api.ambeedata.com/forecast/aq/by-lat-lng?lat=12&lng=73
const http = require("https");
const options = {
"method": "GET",
"hostname": "api.ambeedata.com",
"port": null,
"path": "/forecast/aq/by-lat-lng?lat=12.9889055&lng=77.574044",
"headers": {
"x-api-key": "API_KEY",
"Content-type": "application/json"
}
};
const req = http.request(options, function (res) {
const chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function () {
const body = Buffer.concat(chunks);
console.log(body.toString());
});
});
req.end();
Next
Playground
Yes
No