AWS Builder Center
Saans: Making Air Quality Data Make Sense, Built on AWS

Saans: Making Air Quality Data Make Sense, Built on AWS

Saans is an India-focused air-quality companion. Rather than flashing a bare AQI number, it combines nearby monitors, forecasts, weather, health guidance, route comparisons and local alerts so people can decide what to actually do today.

The problem we wanted to solve

Most air-quality apps answer one question: "What is the number?" But the number alone rarely helps. A reading of 250 means something different to a delivery rider, a parent of a toddler, and a retired person with a heart condition. Our question was a more personal one: what does this air mean for me, where I live and travel?
That question shaped everything about Saans, from the way it onboards people to the way its backend is put together on AWS.

Starting with the person, not the pollutant

On first launch, Saans asks a handful of quick questions: what to call you, your age group, how much time you spend outdoors, what your home environment is like, and whether you have a health condition that affects how you respond to pollution. Email alerts are strictly opt-in.
Those answers map to a persona such as outdoor worker, commuter, child, older adult, or someone with a heart or lung condition. Saans then pairs that persona with local pollutant levels and AQI bands to pick relevant advice. When pollution is high, an outdoor worker might be nudged to reduce exertion or wear a well-fitted N95, while someone with asthma is reminded to keep their prescribed reliever plan in mind.
Two honest notes on this design:
  • The guidance is rules-based and educational. It is not a diagnosis or a clinical risk score.
  • The profile stays on the device for everyday use. Only people who opt in to email alerts have their email, location and alert preferences stored by the backend.

One app, two lenses

Saans offers two views of the same air:
  • Citizen view: Today, Overview, Airspace, Health, Trip Planner, Daily Challenge and More.
  • Government view: Overview, Area Watch and More.
Across product pages, a chat button opens Ask Saans, an assistant you can talk to in everyday language.

What citizens get

Today

A snapshot of local conditions: the dominant pollutant, an indicative AQI, a short forecast and suggestions tailored to your profile. Saans is clear about the difference between its model-based AQI and an official CPCB reading. Behind it, API Gateway receives the request, a Lambda function merges provider data with guidance, and DynamoDB caches the response.

Overview

Hourly air information, historical PM2.5 and ventilation trends, a backtest comparing stagnant days against well-ventilated ones, plain-language explanations of unusual periods, and CSV export. History is cached for six hours. Explanations can come from Amazon Bedrock, Gemini, or weather-based rules. An optional Delhi ward-level forecast runs as a separate, heavier component that reads forecast artifacts from Amazon S3.

Airspace

A map of nearby monitors with readings, reporting details and data freshness. Search any Indian place or use your location. Amazon Location Service powers place search, with Open-Meteo geocoding as a fallback.

Health

Pollutants are listed from highest to lowest. Pick one to see where it may affect the respiratory system, its short- and long-term effects, how it compares with WHO guidelines, and practical tips. The lung animation is an educational illustration: red areas show what a pollutant is associated with, not detected injury.

Trip Planner

Compare up to three driving routes using estimated PM2.5, visibility, hazy kilometres, travel time and nearby monitor coverage. If routes look similar in air quality, Saans can favour the faster one so you spend less time breathing it. You can also compare departure hours across the next day. Lambda combines OSRM route data with forecast and visibility data, and DynamoDB caches results. Route scores are estimates, not street-level guarantees.

Daily Challenge

One air-awareness question per day, in English or Hindi, with a streak and a strip of recent questions. Older questions can be practised without affecting your score. The quiz and progress live entirely on the device, so no extra AWS database is needed.

More

Profile, language, location, health settings, reduced motion, how-to guidance, data and privacy information, and a way to replay the welcome screen. For those who opt in to email alerts, subscriber details sit in DynamoDB and delivery goes through Amazon SNS.

What local authorities get

Area Watch

Combines available fire hotspots with wind and weather, including the upwind area. NASA FIRMS data needs a configured API key. The upwind wedge and smoke path are heuristic and illustrative. They are not a validated plume model and do not prove that a specific fire caused local pollution.

Government advisory preview

Operators can preview a bilingual advisory built from area data for opted-in subscribers nearby. In the current prototype this interface is clearly labelled as simulated. The designed workflow uses SNS for delivery, with EventBridge Scheduler and Step Functions handling scheduled subscriber processing.

Ask Saans

The assistant answers questions about air conditions and guidance using local context and your profile. On the backend it tries Amazon Bedrock first, then Gemini if configured, then falls back to deterministic rules, so it keeps working even if a model provider is unavailable. Provider keys never touch frontend code; they live in AWS Systems Manager Parameter Store as SecureString parameters.

How AWS powers Saans

We wanted a backend with no always-on server. Here is how a request travels through the system:
  1. AWS Amplify Hosting serves the static PWA frontend, deployed from a Git repository.
  1. The frontend calls an Amazon API Gateway HTTP API, which routes requests straight to AWS Lambda.
  1. Lambda assembles air and weather data, prepares history, compares routes and handles assistant requests.
  1. Amazon DynamoDB acts as a short-lived cache to cut repeated calls to external providers. Records carry a TTL timestamp that the app checks before reuse (DynamoDB removes expired items asynchronously). Subscriber records for alerts are kept separately until a person unsubscribes.
  1. Systems Manager Parameter Store (SecureString) holds API keys, encrypted with AWS KMS and guarded by IAM permissions.
  1. Amazon Bedrock powers Ask Saans and explanations when configured.
  1. Amazon Location Service handles place search, and Amazon S3 (encrypted) stores the optional forecast artifacts.
  1. Amazon SNS delivers email alerts. EventBridge Scheduler triggers a Step Functions workflow that processes subscribers in limited batches with retries.
  1. Amazon CloudWatch collects logs and metrics, and the whole stack is defined in AWS SAM and CloudFormation so it can be managed as code.

Keeping costs in check

Beyond avoiding a permanent server, we added a low request throttle on the API, small provisioned capacity on the cache table, and on-demand billing with a configured cap on the subscriber table. These controls limit usage, but they do not guarantee a spending ceiling. Budget alerts are warnings, not hard caps.

Limitations we want to be upfront about

  • Model-based AQI is indicative, not an official CPCB measurement.
  • Forecasts and route scores are estimates, and regional grids cannot capture every street-level difference.
  • Fire and wind visuals suggest context but are not a validated smoke-plume calculation.
  • Health guidance is educational and is no substitute for medical advice.

What's next

We plan to validate data quality across more Indian cities, review the multilingual health guidance, test the advisory workflow with real subscribers, and verify that every AWS component is deployed and monitored as intended.
Saans exists to make air quality easier to understand, and to help both citizens and local authorities act on it.
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article