curl --request GET \
--url https://fleet.graviton.ma/api/v2/events \
--header 'Authorization: <api-key>'import requests
url = "https://fleet.graviton.ma/api/v2/events"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://fleet.graviton.ma/api/v2/events', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://fleet.graviton.ma/api/v2/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"success": true,
"data": [
{
"event_id": 123,
"type": "<unknown>",
"name": "<unknown>",
"active": "<unknown>",
"week_days": "<unknown>",
"day_time": "<unknown>",
"imei": "<unknown>",
"checked_value": "<unknown>",
"route_trigger": "<unknown>",
"zone_trigger": "<unknown>",
"routes": "<unknown>",
"zones": "<unknown>",
"notify_system": "<unknown>",
"notify_email": "<unknown>",
"notify_email_address": "<unknown>",
"notify_sms": "<unknown>",
"notify_sms_number": "<unknown>",
"notify_telegram": "<unknown>",
"email_template_id": "<unknown>",
"sms_template_id": "<unknown>",
"cmd_send": "<unknown>",
"cmd_gateway": "<unknown>",
"cmd_type": "<unknown>",
"cmd_string": "<unknown>"
}
],
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
},
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
},
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
},
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}List events
Works with resources accessible to your account. Subaccounts need the event_notifications permission.
curl --request GET \
--url https://fleet.graviton.ma/api/v2/events \
--header 'Authorization: <api-key>'import requests
url = "https://fleet.graviton.ma/api/v2/events"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://fleet.graviton.ma/api/v2/events', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://fleet.graviton.ma/api/v2/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"success": true,
"data": [
{
"event_id": 123,
"type": "<unknown>",
"name": "<unknown>",
"active": "<unknown>",
"week_days": "<unknown>",
"day_time": "<unknown>",
"imei": "<unknown>",
"checked_value": "<unknown>",
"route_trigger": "<unknown>",
"zone_trigger": "<unknown>",
"routes": "<unknown>",
"zones": "<unknown>",
"notify_system": "<unknown>",
"notify_email": "<unknown>",
"notify_email_address": "<unknown>",
"notify_sms": "<unknown>",
"notify_sms_number": "<unknown>",
"notify_telegram": "<unknown>",
"email_template_id": "<unknown>",
"sms_template_id": "<unknown>",
"cmd_send": "<unknown>",
"cmd_gateway": "<unknown>",
"cmd_type": "<unknown>",
"cmd_string": "<unknown>"
}
],
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
},
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
},
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
},
"meta": {
"request_id": "<string>",
"page": 123,
"per_page": 123,
"total": 123,
"pages": 123
}
}Authorizations
Your Graviton API token. Send Authorization: Bearer YOUR_API_TOKEN or Authorization: YOUR_API_TOKEN. Each token has individual permissions; a valid token without the permission required by the method and route returns 403 TOKEN_PERMISSION_DENIED.
Query Parameters
x >= 11 <= x <= 500Partial text search across the resource's registered safe search fields. Whitespace is trimmed; literal percent and underscore characters are escaped. Search is applied after account, ownership, privilege, and object scope.
2 - 100asc, desc Registered field used for sorting.
event_id, type, name, active, week_days, day_time, imei, checked_value, route_trigger, zone_trigger, routes, zones, notify_system, notify_email, notify_email_address, notify_sms, notify_sms_number, notify_telegram, email_template_id, sms_template_id, cmd_send, cmd_gateway, cmd_type, cmd_string Exact-match filter for type.
Exact-match filter for name.
Exact-match filter for active.
Exact-match filter for week_days.
Exact-match filter for day_time.
Exact-match filter for imei.
Exact-match filter for checked_value.
Exact-match filter for route_trigger.
Exact-match filter for zone_trigger.
Exact-match filter for routes.
Exact-match filter for zones.
Exact-match filter for notify_system.
Exact-match filter for notify_email.
Exact-match filter for notify_email_address.
Exact-match filter for notify_sms.
Exact-match filter for notify_sms_number.
Exact-match filter for notify_telegram.
Exact-match filter for email_template_id.
Exact-match filter for sms_template_id.
Exact-match filter for cmd_send.
Exact-match filter for cmd_gateway.
Exact-match filter for cmd_type.
Exact-match filter for cmd_string.

