Real Time APIs

Example Request For Real Time API

The full list of Realtime APIs are available at: https://data.gov.sg/datasets?formats=API

PM 2.5

get

https://api-open.data.gov.sg/v2/real-time/api/pm25

  • Updated hourly from NEA.

  • Readings are provided for each major region in Singapore

  • Filter for specific date or date-time by providing date in query parameter.

    • use YYYY-MM-DD format to retrieve all of the readings for that day

    • use YYYY-MM-DDTHH:mm:ss to retrieve the latest readings at that moment in time

    • example: ?date=2024-07-16 or ?date=2024-07-16T23:59:00

  • If date is not provided in query parameter, API will return the latest reading

  • The region_metadata field in the response provides longitude/latitude information for the regions. You can use that to place the readings on a map.

  • Unit of measure for readings is µg/m3.

Authorizations
x-api-keystringRequired
Query parameters
datestringOptional

SGT date for which to retrieve data (YYYY-MM-DD or YYYY-MM-DDTHH:MM:SS)

paginationTokenstringOptional

Pagination token for retrieving subsequent data pages (only exists when there is a next page available for requests with date filters)

Responses
200

PM 2.5 Information

application/json
get
/pm25

Last updated

Was this helpful?