The NSW Rural Fire Service (RFS) publishes a GeoJSON feed of major incidents, this project aims to make that feed more developer friendly.
You can either build this application into your own pipeline or use the hosted URL at https://www.beyondtracks.com/contrib/nsw-rfs-majorincidents.geojson (no service availability guarantees!), preview it at geojson.io.
NSW RFS Current Incidents are © State of New South Wales (NSW Rural Fire Service). For current information go to www.rfs.nsw.gov.au. Licensed under the Creative Commons Attribution 4.0 International (CC BY 4.0).
Where is it used?
This pipeline has been built for www.beyondtracks.com to provide information about bush fires nearby bushwalks.
The upstream feed lacks the Access-Control-Allow-Origin header which means web applications aren't able to use the feed directly. This was reported to the NSW RFS on the 3rd of December 2015, and as of January 2018 the header still isn't present.
The sample crontab file allows you to mirror the RFS feed and serve it with your own HTTP server, add the Access-Control-Allow-Origin HTTP header.
The upstream feed uses nested GeometryCollections, although allowed by the GeoJSON spec, the recommendation is they SHOULD be avoided.
These are converted to flat GeometryCollections when including different Geometry types or a multipart type where possible.
Although extra coordinate precision can help retain geometry shape even beyond the capture precision, the upstream feed uses 14 decimal places. Practically fire extents or geometry shape won't be more than 10m in accuracy so limiting to 4 decimal places will suffice.
The upstream feed overloads properties into the
description field in a format like
KEY: Value <br />KEY: Value. These are exploded out to make them easier to read in applications. The original overloaded description is dropped from the output.
Machine readable schema
Within schema/ are JSON files containing the values and descriptions for Status, Alert Level and Incident Type. These can be used within web applications to provide users more information about what these terms mean.
The upstream feed uses dates in the format
3/01/2018 5:20:00 AM and also
3 Jan 2018 16:20 in local time. These datetimes are converted into ISO8601 datetimes assuming the 'Australia/Sydney' time zone to avoid any ambiguities in interpretation.
For extra assurances the GeoJSON winding order is enforced with https://github.com/mapbox/geojson-rewind.
This is really just a workaround for the inability to sort features within a Mapbox Style put in just for the BeyondTracks use case, to avoid client side sorting of the GeoJSON. In the future this may be removed. Features are first sorted by status then alert level. Again this is purely driven by the needs of BeyondTracks where status is more important than alert level, the reasoning being that an "Advice" "Out of Control" bushfire is more dangerous to a bushwalker than an "Emergency Warning" "Under Control".
Install the Node dependencies with:
Run the script with:
This will download the upstream feed, process it and save the resulting GeoJSON file at
Each GeoJSON Feature represents a major incident. Each Feature may have multiple geometries using a GeometryCollection. For example both a point and a polygon showing a bushfire extent. Although so far every feature contains at a minimum a point geometry, without any documented guarantees about this consumers should accept features with no geometry or only a polygon geometry.
Each feature has a properties field as follows. Note that these vary from the upstream feed, the full list of possible values is unknown these are just the ones I've come across.
|title||String||A short name used as the tile of this incident, given to assist with managing multiple incidents. Usually this is the name of a nearby road or geographic feature but it doesn't necessarily reflect the exact location of that incident.||
|alert-level||String||Alert level of the incident, see #alert-level||
|status||String||Status of the incident, see #status||
|guid||String||A globally unique identifier for this incident. Usually it is a non-publicly accessible URL||
|pub-date||String||Datetime in ISO8601 of when the incident was first published||
|updated||String||Datetime in ISO8601 of when the incident details were last updated||
|responsible-agency||String||The name of the agency responsible for responding to the incident||
|size||String||The ground area which the incident affects||
|type||String||The type of incident, see #incident-type||
|fire||boolean||Indicates if this this incident a fire (
|council-area||String||Short name of the council area the incident falls in||
|location||String||A description of the location of the incident||
|Out of control||A fire which is spreading on one or more fronts. Effective containment strategies are not in place for the entire perimeter.|
|Being controlled||Effective strategies are in operation or planned for the entire perimeter.|
|Under control||The fire is at a stage where fire fighting resources are only required for patrol purposes and major re-ignition is unlikely.|
|Alert Level Name||Description|
|Emergency Warning||An Emergency Warning is the highest level of Bush Fire Alert. You may be in danger and need to take action immediately. Any delay now puts your life at risk.|
|Watch and Act||There is a heightened level of threat. Conditions are changing and you need to start taking action now to protect you and your family.|
|Advice||A fire has started. There is no immediate danger. Stay up to date in case the situation changes.|
|Incident Type Name||Description|
|Bush Fire||Forest and/or Scrub Fire|
|Grass Fire||Grass Fire|
|Hazard Reduction||Planned controlled burns to reduce bush fire hazards|
|Structure Fire||A fire involving a residential, commercial or industrial building|
|Haystack Fire||Haystack fire|
|HAZMAT||The NSW RFS provides operational support to the Fire & Rescue NSW for hazardous materials incidents|
|MVA/Transport||Transport incidents including motor vehicle accident, aircraft incident and incidents involving a railway or railway rolling stock|
|Assist Other Agency||Assist other agency such as Fire & Rescue NSW, NSW Police, NSW SES, NSW Ambulance, Defence Force, interstate deployments etc|
|Search/Rescue||Search and Rescue, rescue animal|
|Flood/Storm/Tree Down||Assisting with Flood or storm damage or tree down|
|Vehicle/Equipment Fire||Vehicle or Equipment fire such as car fire, farm machinery fire, transformer fire etc|
|Burn off||Burn off such as stubble fire, pile burn etc|
|Fire Alarm||Automatic Fire Alarm or Domestic Smoke Alarm|
|Medical||Medical incident such as medical evacuation|
|Other||Other incidents such as smoke in vicinity, gas leak, building collapse etc|
The information in the RFS feed can affect life and property. Although the aim of this project is to make the RFS feed more safe, usable and reliable for data consumers, errors or omissions may be present and/or the upstream supplied data structure may change without any notice causing issues. Use at your own risk.
THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.