curl --request GET \
--url https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group', 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://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group",
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: Basic <encoded-value>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body[
{
"id": "groupID",
"name": "group-name",
"parentId": "rootGroupId",
"path": "rootGroupId.groupID",
"countDrivers": 1,
"countSecondaryDrivers": 1,
"countSecondaryVehicles": 0,
"dataCleanupSettings": {
"truncate": true,
"daysRetention": 123,
"daysRetentionLong": 123
},
"countVehicles": 0
}
]List Group
Returns the group hierarchy starting from the root node.
curl --request GET \
--url https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group', 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://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group",
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: Basic <encoded-value>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.masternautconnect.com/connect-webservices/services/public/v1/customer/{customerId}/group")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body[
{
"id": "groupID",
"name": "group-name",
"parentId": "rootGroupId",
"path": "rootGroupId.groupID",
"countDrivers": 1,
"countSecondaryDrivers": 1,
"countSecondaryVehicles": 0,
"dataCleanupSettings": {
"truncate": true,
"daysRetention": 123,
"daysRetentionLong": 123
},
"countVehicles": 0
}
]Authorizations
Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.
Path Parameters
Response
List of Groups visible to request context with counts of drivers and vehicles
ID of group
1 - 24^[a-z0-9]+$"groupID"
Group name
255"group-name"
ID of parent group, in case for changing the hierarchy
"rootGroupId"
Hierarchy path from root group
"rootGroupId.groupID"
Count of assigned drivers to group
1
Count of assigned secondary drivers to group
1
Count of assigned secondary vehicles to group
0
Data retention and cleanup configuration inherited or explicitly set for this group. A null value for any field indicates that the setting is unspecified at this level and will be inherited from the nearest ancestor group in the hierarchy that has a value defined, or from the customer-level data retention settings if no ancestor group specifies one. Fields must NOT be defaulted to 0 or false when unset, as those values carry distinct functional meaning.
Show child attributes
Show child attributes
Count of assigned vehicles to group
0
Was this page helpful?
