Get Server Information
Get general about your Traccar server instance into your laravel application.
Request
Use the ThingsTelemetry\Traccar\Facades\Server::getInformation() method to get information about your Traccar server instance.
$info = \ThingsTelemetry\Traccar\Facades\Server::getInformation();Results
The response is an instance of ThingsTelemetry\Traccar\Dto\ServerData DTO class
$version = $info->version; // 6.10
$mapProvider = $info->map->label(); // Google Satellite
$speedUnit = $info->attributes->speedUnit->value; // kmh
$speedUnit = $info->attributes->speedUnit->label(); // Kilometers per Hour (km/h)
$timezone = $info->attributes->timezone; // UTCKey Results Items
While most fields are cast into a string or ints, some are cast into a DTO/Service class.
ServerAttributesData→ThingsTelemetry\Traccar\Dto\ServerAttributesData
Data Transfer Object for Traccar server attributes.map→ThingsTelemetry\Traccar\Enums\Map
Enum representing available map providers.coordinateFormat→ThingsTelemetry\Traccar\Enums\CoordinateFormat
Enum defining how coordinates are displayed or formatted.storage→ThingsTelemetry\Traccar\Support\StorageInfo
Service class representing storage information (total, free, etc.).
IMPORTANT
Refer to the ServerData DTO documentation for more details on the DTO structure.