ExamplesBulk Download
Get data as json sort by structure start date DESC
Example query of a completed bulk report as JSON, sorted by structure start date descending, with limit and offset.
Query parameters
| Parameter | Value | Description |
|---|---|---|
id | adbb9b62-5c08-4142-82e0-b2b575f3e058 | ID of the bulk report to query |
limit | 2 | Maximum number of records to return |
offset | 0 | Number of records to skip |
sort | -structure_start_date | Sort by structure start date, descending |
Request
# Make sure to replace [TOKEN] with your API Access Token.
curl --location 'https://gateway.api.globalfishingwatch.org/v3/bulk-reports/adbb9b62-5c08-4142-82e0-b2b575f3e058/query?limit=2&offset=0&sort=-structure_start_date' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer TOKEN'// Make sure to replace [TOKEN] with your API Access Token.
const res = await fetch(
'https://gateway.api.globalfishingwatch.org/v3/bulk-reports/adbb9b62-5c08-4142-82e0-b2b575f3e058/query?limit=2&offset=0&sort=-structure_start_date',
{ headers: { Authorization: 'Bearer [TOKEN]' } }
)
const data = await res.json()Response
{
"metadata": {},
"limit": 2,
"offset": 0,
"nextOffset": 2,
"total": 43,
"entries": [
{
"detection_id": "S1AB_AD_MEDIAN_COMP_20240201T000000_20240801T000000_FULL_41_TILE_154;-65.0214080;-42.736182",
"detection_date": "2024-05-01",
"structure_id": "1054536",
"lon": -65.02140773749714,
"lat": -42.73618183211688,
"structure_start_date": "2024-05-01",
"structure_end_date": "2024-05-01",
"label": "oil",
"label_confidence": "low"
},
{
"detection_id": "S1AB_AD_MEDIAN_COMP_20240501T000000_20241101T000000_FULL_23_TILE_332;-67.3234300;-53.089715",
"detection_date": "2024-08-01",
"structure_id": "1051638",
"lon": -67.32289149541135,
"lat": -53.0895574340617,
"structure_start_date": "2024-02-01",
"structure_end_date": null,
"label": "oil",
"label_confidence": "high"
}
]
}