driver_status
The driver_status function is used to check the status of a unit that has an assigned driver.
svc=resource/driver_status¶ms={"phoneNumber":"<text>",
"password":"<text>",
"app":"<text>",
"fl":<uint>}
Parameters
Name | Description |
---|---|
phoneNumber | The driver's prone number. |
password | The mobile key. The field can't be empty. |
app | The application name for the generated token. The field is optional. The default value is "Wialon Logistics". |
fl | Optional flags:
|
Returned result
{
"drv":{ /* driver params */
"rid":<uint>, /* resource ID */
"id":"<text>", /* driver ID */
"nm":"<text>"} /* driver name */
},
"un":{ /* unit params */
"nm":"<text>",
"cls":<uint>,
"id":<uint>,
"mu":<uint>,
"ct":<uint>,
"ftp":{ ... },
"pos":{ ... },
"lmsg":{ ... },
"uri":"<text>",
"ugi":<uint>,
"uacl":<int>
},
"uh":"<text>", /* encrypted device information (for WiaTag) */
"ul":"<text>", /* encrypted phone number */
"h":"<text>" /* token */
}
You can find the description of the parameters and the entry for “pos”, “lmsg” here.
Possible error codes:
Code | Description |
---|---|
8 | Wrong password or phone number. |
7 | Failed to fetch unit, unit account, user creator or driver plugin. |
6 | Failed to find the first assigned driver or undefined error. |
4 | One of the following errors in the request:
|