These are the two event types the Global Forest Watch integration needs. Set up the integration itself first; this article covers only the event types it writes to.
Supported event types
| EarthRanger event type | Display title | What raises it |
|---|---|---|
gfwgladalert |
GFW Integrated Deforestation Alerts | Global Forest Watch detects likely deforestation inside your area of interest. |
gfwfirealert |
GFW Fire Alerts | Global Forest Watch detects a fire inside your area of interest. |
Deforestation alert fields
| Field | Label | Type | What it holds |
|---|---|---|---|
confidence |
Confidence | Number |
How sure Global Forest Watch is about the alert. It arrives as
0, 0.5 or 1, meaning nominal, high or highest.
|
Fire alert fields
| Field | Label | Type | What it holds |
|---|---|---|---|
confidence |
Confidence | Text | How sure Global Forest Watch is about the fire alert. |
alert_time |
Alert Time | Text | When Global Forest Watch raised the alert. |
Confidence is a number on deforestation alerts and text on fire alerts. The two feeds report it differently, so the field types differ between the two event types even though the field has the same name.
How to create these event types
1. Install the command-line tool and sign in
You need a terminal with Python 3.11 or newer and pipx installed, and an
EarthRanger account on the target site.
pipx install earthranger-cli # install the tool; this gives you the 'er' command
er profile add sitename --server sitename --username you # save the site as a profile ('sitename' is the site's subdomain, e.g. 'borana' for borana.pamdas.org)
export ER_PROFILE=sitename # tell 'er' to use that profile in this terminal
er auth login # asks for your EarthRanger password and signs you in
Important: the account you log in with must have permissions on the Event Category that will host these event types.
2. Save this spec as gfw.yaml
The spec puts both types in Monitoring. Change the category block
at the top to use a different one.
category:
value: monitoring
display: Monitoring
event_types:
- value: gfwgladalert
display: GFW Integrated Deforestation Alerts
geometry_type: point
fields:
- {key: confidence, label: Confidence, type: number}
- value: gfwfirealert
display: GFW Fire Alerts
geometry_type: point
fields:
- {key: confidence, label: Confidence, type: string}
- {key: alert_time, label: Alert Time, type: string}
The spec does not set priorities or icons — pick those in EarthRanger under Activity → Event Types.
3. Preview, then apply
er events apply gfw.yaml --dry-run # shows what will be created or changed
er events apply gfw.yaml # actually does it
Applying is safe to repeat: it creates what is missing and patches only what differs. Nothing is ever deleted.
4. Verify
er events show event-type gfwgladalert
er events show event-type gfwfirealert
CLI tool and full spec documentation: https://github.com/PADAS/earthranger-cli
