Skip to main content

Alerts Report

Generated alerts with event details, location, and notification channel.

GET/apidev/v1/reports/gt/alerts
PermissionAPICLI_RPTGT_ALERTAS
Rate Limit10 req/min
Cache300s
Max Range31 days

Overview

Returns alerts generated over a date range, each with its event details (group and code), the moment it was generated and notified, the device and driver involved, the location (address plus coordinates), and the speed and temperature at the time. Filter by devices, event codes, or specific alert IDs.


Request

Request Headers

Every request to a protected endpoint requires these headers:

HeaderRequiredDescription
AuthorizationYesBearer token obtained from the Login endpoint. Format: Bearer <token>
X-API-KeyYesCompany integration key provided during onboarding. Format: gtk_xxx...
tenantYesYour assigned tenant domain (default: geotareas.com) — always send your assigned tenant
Content-TypeConditionalapplication/json — required for POST and PUT requests

Query Parameters

ParameterTypeRequiredDefaultDescription
startdatestringYesISO 8601 start date-time (e.g. 2026-03-01T00:00:00).
enddatestringYesISO 8601 end date-time. Max range 31 days from startdate.
devicesstringNoComma-separated device IDs. Max 500.
eventsstringNoEvent codes filter. Max 200 chars.
alert_idsstringNoAlert IDs filter. Max 200 chars.
limitintegerNo25Number of records per page (1100).
offsetintegerNo0Number of records to skip for pagination.

Code Examples

curl -s -H "Authorization: Bearer $TOKEN" \
-H "X-API-Key: $APIKEY" \
-H "tenant: $TENANT" \
"https://$TENANT/apidev/v1/reports/gt/alerts?startdate=2026-03-01T00:00:00&enddate=2026-03-15T23:59:59&limit=25"

Response

Response Fields

FieldTypeDescription
alert_namestringAlert configuration name.
event_groupstringEvent group/category.
event_codestringEvent code.
generated_atstring | nullTimestamp when alert was generated.
sent_atstring | nullTimestamp when notification was sent.
device_namestringVehicle name.
driver_namestringDriver name.
addressstringLocation address.
latitudenumber | nullLatitude.
longitudenumber | nullLongitude.
speednumberSpeed at event time (km/h).
temperaturenumberTemperature at event time.
channelstringNotification channel (email, sms, etc.).

Example Response

{
"success": true,
"data": [
{
"alert_name": "Speed Limit",
"event_group": "Velocity",
"event_code": "117",
"generated_at": "2026-03-05T14:22:15",
"sent_at": "2026-03-05T14:22:18",
"device_name": "Truck A-101",
"driver_name": "Carlos Martinez",
"address": "Ruta 1 km 45, San Jose",
"latitude": -34.3426,
"longitude": -56.7135,
"speed": 118,
"temperature": 22.5,
"channel": "email"
}
],
"meta": {
"total": 1,
"limit": 25,
"offset": 0
}
}

Errors

CodeHTTPDescription
VALIDATION_ERROR400Invalid params: missing dates, range > 31 days, invalid enum values.
UNAUTHORIZED401Missing, invalid, or expired tenant / Authorization / X-API-Key
FORBIDDEN403User lacks required permission.
RATE_LIMITED429Exceeded 10 req/min.
INTERNAL_ERROR500Unexpected server error.