curl --request GET \
--url https://api.jitra.app/public/v1/positions/latest \
--header 'x-api-key: <api-key>'import requests
url = "https://api.jitra.app/public/v1/positions/latest"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.jitra.app/public/v1/positions/latest', 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.jitra.app/public/v1/positions/latest",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.jitra.app/public/v1/positions/latest"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.jitra.app/public/v1/positions/latest")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.jitra.app/public/v1/positions/latest")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"statusCode": 200,
"result": [
{
"id": 101,
"ident": "B-1234-XYZ",
"name": "Truck 01",
"latitude": -6.2,
"longitude": 106.8,
"altitude": 15,
"angle": 230,
"speed": 42,
"time_server": "2023-11-07T05:31:56Z",
"time_device": "2023-11-07T05:31:56Z",
"engine_hours": 123,
"odometer": 123,
"mileage": 123,
"address": "<string>"
}
]
}{
"statusCode": 400,
"errorCode": "PUBLIC.400_001",
"message": "Validation error message",
"timestamp": "2026-05-17T01:00:00.000Z"
}{
"statusCode": 401,
"errorCode": "ERR999",
"message": "Unauthorized",
"timestamp": "2026-05-17T01:00:00.000Z"
}{
"statusCode": 403,
"errorCode": "SUBSCRIPTION.403_002",
"message": "Your subscription is suspended. Please contact your Admin.",
"timestamp": "2026-05-17T01:00:00.000Z"
}{
"statusCode": 429,
"errorCode": "ERR999",
"message": "ThrottlerException: Too Many Requests",
"timestamp": "2026-05-17T01:00:00.000Z"
}Read Latest Positions
Mengembalikan snapshot posisi real-time terbaru untuk setiap Object ID yang diminta.
curl --request GET \
--url https://api.jitra.app/public/v1/positions/latest \
--header 'x-api-key: <api-key>'import requests
url = "https://api.jitra.app/public/v1/positions/latest"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.jitra.app/public/v1/positions/latest', 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.jitra.app/public/v1/positions/latest",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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.jitra.app/public/v1/positions/latest"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
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.jitra.app/public/v1/positions/latest")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.jitra.app/public/v1/positions/latest")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"statusCode": 200,
"result": [
{
"id": 101,
"ident": "B-1234-XYZ",
"name": "Truck 01",
"latitude": -6.2,
"longitude": 106.8,
"altitude": 15,
"angle": 230,
"speed": 42,
"time_server": "2023-11-07T05:31:56Z",
"time_device": "2023-11-07T05:31:56Z",
"engine_hours": 123,
"odometer": 123,
"mileage": 123,
"address": "<string>"
}
]
}{
"statusCode": 400,
"errorCode": "PUBLIC.400_001",
"message": "Validation error message",
"timestamp": "2026-05-17T01:00:00.000Z"
}{
"statusCode": 401,
"errorCode": "ERR999",
"message": "Unauthorized",
"timestamp": "2026-05-17T01:00:00.000Z"
}{
"statusCode": 403,
"errorCode": "SUBSCRIPTION.403_002",
"message": "Your subscription is suspended. Please contact your Admin.",
"timestamp": "2026-05-17T01:00:00.000Z"
}{
"statusCode": 429,
"errorCode": "ERR999",
"message": "ThrottlerException: Too Many Requests",
"timestamp": "2026-05-17T01:00:00.000Z"
}Otorisasi
Organization API key issued from Jitra (Organization → API Key).
Parameter Query
Comma-separated object IDs, for example 101,102,103. Missing or empty value returns PUBLIC.400_003.
"101,102"
Respons
Latest positions for the requested objects.
200
Hide child attributes
Hide child attributes
Object ID.
101
Unique object identifier.
"B-1234-XYZ"
Object display name.
"Truck 01"
Latitude at this point.
-6.2
Longitude at this point.
106.8
Altitude in meters.
15
Heading angle in degrees.
230
Speed at this point.
42
Server timestamp for this point.
Device timestamp for this point.
Engine-hours value associated with the object.
Odometer value associated with the object.
Mileage value associated with the object.
Address at this point, falling back to the object's last known address.
