Skip to content
Docs

Get Latest Variable Data

Returns the most recently recorded value for the specified variable.

GET /rest/v1/workspaces/{workspace_uuid}/devices/{device_identifier}/variables/{variable_identifier}/latest
HeaderValue
AuthorizationBearer <YOUR_API_KEY>
Content-Typeapplication/json
ParameterTypeRequiredDescription
workspace_uuidStringYesUnique identifier of the workspace.
device_identifierStringYesUnique identifier of the device within the workspace.
variable_identifierStringYesUnique identifier of the variable within the device.
GET /rest/v1/workspaces/01KXYZ123456789/devices/PLANT/variables/CURRENT/latest
Authorization: Bearer <YOUR_API_KEY>

Status: 200 OK

{
"data": {
"t": 1784027551299,
"v": "230.13978"
},
"meta": {
"message": "Latest variable data fetched successfully",
"success": true
}
}
FieldDescription
tTimestamp of the latest recorded value in Unix milliseconds (UTC).
vMost recently recorded value for the variable. The value type depends on the variable’s data type (e.g, Number, Boolean, or String).
HTTP StatusDescription
400 Bad RequestOne or more required path parameters are missing or invalid.
401 UnauthorizedAuthentication failed due to a missing or invalid API key.
404 Not FoundThe specified workspace, device, or variable could not be found.
500 Internal Server ErrorAn unexpected error occurred while retrieving the latest variable value.