Examples4Wings Reports
Report region id (Chile) daily grided data and filter by unmatched detections (JSON)
Example 4Wings report of daily gridded data for Chile, filtered to SAR detections unmatched to AIS, as JSON.
To get details of existing regions, check Regions in the Reference data section
Query parameters
| Parameter | Value | Description |
|---|---|---|
spatial-resolution | HIGH | High spatial resolution |
temporal-resolution | HOURLY | Aggregate by hour |
datasets[0] | public-global-sar-presence:latest | SAR vessel detections dataset |
date-range | 2022-01-01,2022-01-06 | Filter to this time period |
format | JSON | Response format |
filters[0] | matched='false' | Only detections that didn't match with AIS vessels |
Request body
| Field | Value | Description |
|---|---|---|
region.dataset | public-eez-areas | Existing region dataset |
region.id | 8465 | Chile EEZ region id |
Request
# Make sure to replace [TOKEN] with your API Access Token.
curl --location --globoff 'https://gateway.api.globalfishingwatch.org/v3/4wings/report?spatial-resolution=HIGH&temporal-resolution=HOURLY&datasets[0]=public-global-sar-presence%3Alatest&date-range=2022-01-01%2C2022-01-06&format=JSON&filters[0]=matched%3D%27false%27' \
--header 'Authorization: Bearer [TOKEN]' \
--header 'Content-Type: application/json' \
--data '{
"region": {
"dataset": "public-eez-areas",
"id": 8465
}
}'result = await gfw_client.fourwings.create_report(
datasets=["public-global-sar-presence:latest"],
spatial_resolution="HIGH",
temporal_resolution="HOURLY",
filters=["matched='false'"],
start_date="2022-01-01",
end_date="2022-01-06",
region={"dataset": "public-eez-areas", "id": 8465},
)gfw_sar_vessel_detections(
spatial_resolution = "HIGH",
temporal_resolution = "HOURLY",
start_date = "2022-01-01",
end_date = "2022-01-06",
region = 8465,
region_source = "EEZ",
filter_by = "matched='false'"
)// Make sure to replace [TOKEN] with your API Access Token.
const res = await fetch(
'https://gateway.api.globalfishingwatch.org/v3/4wings/report?spatial-resolution=HIGH&temporal-resolution=HOURLY&datasets[0]=public-global-sar-presence%3Alatest&date-range=2022-01-01%2C2022-01-06&format=JSON&filters[0]=matched%3D%27false%27',
{
method: 'POST',
headers: {
Authorization: 'Bearer [TOKEN]',
'Content-Type': 'application/json',
},
body: JSON.stringify({
region: { dataset: 'public-eez-areas', id: 8465 },
}),
}
)
const data = await res.json()Response
{
"total": 1,
"limit": null,
"offset": null,
"nextOffset": null,
"metadata": {},
"entries": [
{
"public-global-sar-presence:v3.0": [
{
"date": "2022-01-05 23:00",
"detections": 1,
"lat": -52.66,
"lon": -72.19
},
{
"date": "2022-01-05 23:00",
"detections": 1,
"lat": -52.57,
"lon": -72.03
}
]
}
]
}Generate report with total fishing hours per Lat/Lon grid cell using existing regions (MPA Dorsal de Nasca) in JSON format and buffer of 4 nautical miles
Example 4Wings report of total fishing hours per grid cell in the Dorsal de Nasca MPA with a 4 nautical mile buffer, as JSON.
Report Indonesia filter by matched detections - noisy vessel
Example 4Wings report for Indonesia filtered to SAR detections matched to AIS, showing a noisy vessel.