Location history is the sequence of points a tracker reported over a period of time. To reconstruct yesterday’s deliveries, you need more than the vehicle’s last known position. The recorded points let you draw the route in order and see when each position was recorded.
Choose a device and send the start and end dates and times in the request body. You can request coordinates for a route map or include readings such as speed. The response lists the recorded positions from oldest to newest.
Request Details
POST /api/devices/{deviceId}/locations
Request Parameters
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
deviceIdStringRequired | String | Yes | Tracker identifier in the path. Use the id from the device list. |
JSON body parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
fromDate-timeRequired | Date-time | Yes | Start of the interval in ISO 8601 format. The example uses UTC. |
toDate-timeRequired | Date-time | Yes | End of the interval in ISO 8601 format. Split longer periods into queries of up to 1,440 minutes. |
fieldsString arrayOptional | String array | No | Fields in each position. Send a list of names. Matching is case-insensitive and dateTime is always included. |
Replace the sample identifier with a device id visible in GET /api/devices.
Omitting fields returns the usual available fields. Request outputs explicitly to include device outputs. The position fields table lists the accepted names.
Optional fields with no reading can be omitted. The contract allows null values for latitude, longitude and milleage.
Authentication Required
Send the access token in the Authorization: Bearer <token> header. See Authentication.
Example Request
POST /api/devices/123456789012345/locations HTTP/1.1
Host: api.plaspy.com
Authorization: Bearer {token}
Content-Type: application/jsonExample Request Body
{
"from": "2026-06-10T09:00:00Z",
"to": "2026-06-10T10:00:00Z",
"fields": [
"latitude",
"longitude"
]
}Response Parameters
Read the locations array. It is empty when the interval contains no positions. Each position returned uses one unit, with a minimum of one per query. If the query uses the last available unit for the user or tracker, the API returns HTTP 200 with the positions retrieved so far.
| Field | Type | Presence | Description |
|---|---|---|---|
locationsObject arrayAlways | Object array | Always | Positions within the requested interval, oldest first. |
successBooleanAlways | Boolean | Always | In a successful response, true confirms the operation. |
apiUsageIntegerAlways | Integer | Always | Units charged for this request. |
apiDailyUsageIntegerAlways | Integer | Always | API units all users had used for this tracker today before this request. |
apiUserDailyUsageIntegerAlways | Integer | Always | API units the user had used today before this request. |
Fields in each position
| Field | Type | Presence | Description |
|---|---|---|---|
dateTimeDate-timeIn every position | Date-time | In every position | Record date and time in the user’s time zone. |
latitudeNumberDepends on selection and data | Number | Depends on selection and data | Latitude of the location. |
longitudeNumberDepends on selection and data | Number | Depends on selection and data | Longitude of the location. |
speedNumberDepends on selection and data | Number | Depends on selection and data | Speed in metres per second. |
courseNumberDepends on selection and data | Number | Depends on selection and data | Course (direction) at the location. |
batteryIntegerDepends on selection and data | Integer | Depends on selection and data | Battery level of the device at the location. |
fuelIntegerDepends on selection and data | Integer | Depends on selection and data | Fuel level of the device at the location. |
fuel2IntegerDepends on selection and data | Integer | Depends on selection and data | Secondary fuel level at the location. |
temperatureNumberDepends on selection and data | Number | Depends on selection and data | Temperature measured at the location. |
temperature2NumberDepends on selection and data | Number | Depends on selection and data | Secondary temperature measured at the location. |
sensorTime1IntegerDepends on selection and data | Integer | Depends on selection and data | Sensor 1 time at the location. |
sensorTime2IntegerDepends on selection and data | Integer | Depends on selection and data | Sensor 2 time at the location. |
sensorTime3IntegerDepends on selection and data | Integer | Depends on selection and data | Sensor 3 time at the location. |
sensorTime4IntegerDepends on selection and data | Integer | Depends on selection and data | Sensor 4 time at the location. |
inactiveSecondsIntegerDepends on selection and data | Integer | Depends on selection and data | Inactive seconds at the location. |
rpmIntegerDepends on selection and data | Integer | Depends on selection and data | Revolutions per minute at the location. |
milleageNumberDepends on selection and data | Number | Depends on selection and data | Mileage at the location. |
warningTextsString arrayDepends on selection and data | String array | Depends on selection and data | Warning texts at the location. |
alertTextsString arrayDepends on selection and data | String array | Depends on selection and data | Alert texts at the location. |
alertsString arrayDepends on selection and data | String array | Depends on selection and data | Alerts at the location. |
warningsString arrayDepends on selection and data | String array | Depends on selection and data | Warnings at the location. |
hasBooleanDepends on selection and data | Boolean | Depends on selection and data | Indicates if there are critical alerts at the location. |
attributesObjectDepends on selection and data | Object | Depends on selection and data | Additional attributes at the location. |
accessoriesObject arrayDepends on selection and data | Object array | Depends on selection and data | Additional attributes of accessories at the location. |
inputsBoolean arrayDepends on selection and data | Boolean array | Depends on selection and data | State of the inputs at the location. |
outputsBoolean arrayIf requested and available | Boolean array | If requested and available | State of the outputs at the location. |
Example HTTP 200 response
{
"success": true,
"apiUsage": 1,
"apiDailyUsage": 12,
"apiUserDailyUsage": 38,
"locations": [
{
"dateTime": "2026-06-10T09:12:00",
"latitude": 4.61,
"longitude": -74.08
}
]
}Errors
| Field | Type | Presence | Description |
|---|---|---|---|
successBooleanDepends on the error | Boolean | Depends on the error | In the operation errors shown here, the value is false. |
errorStringDepends on the error | String | Depends on the error | Message explaining why the request was rejected. |
The tracker must be enabled. The call uses both the user’s allowance and the tracker’s shared allowance. If either allowance is already exhausted when the query starts, the API returns HTTP 400 with success set to false. These are examples of the error field.
- User —
Your user has reached its daily API request limit of 4000 requests (used 4000). The limit resets at 00:00 UTC. - Tracker —
You have reached your daily API request limit of 2000 requests (used 2000). The limit resets at 00:00 UTC.
If a field is unknown, the API returns HTTP 400 and lists the accepted names in error. Correct the selection and repeat the query. Also check the identifier and device access.
If the message says the date range is too long, shorten the interval and run the query again.
Example HTTP 400 error
{
"success": false,
"error": "Maximum date range is 1440 minutes."
}- Welcome to Factory IL GPS help
- Map
- Viewing a Device's Route History
- Device Control Panel
- Detailed Device Information
- Buttons on the Map
- Details
- Timeline
- Device Menu
- GeoFences
- Bulk Alert Editing
- Enable map notifications
- Mileage Calculation
- Atributes
- Dashboard
- Arrange the dashboards
- Dashboard blocks
- Devices
- Certificates
- Marker Icon
- Information
- Sensors
- Reassign Digital Sensors
- Commands
- Alerts
- Types
- Configuration
- Reminders
- Limits
- History
- Setting Up a New Tracker
- Solution for Identifier Already in Use by Another Account
- Device Issues
- Email alerts sending limits
- Reports
- New Report
- My Account
- Password Change
- Email Notifications
- Telegram Accounts
- Update Mobile Phone Number
- Primary Email
- Alternative Email
- Enable Two-Factor Authentication (2FA)
- Security Log
- Password Recovery
- Recover Username
- Delete Your Account
- Receipts
- Transfer a receipt to another account
- Activate a scheduled receipt now
- Statistics
- Activity Summary
- Groups
- Users
- Share Access
- Developers
- Enable the API
- REST API
- Authentication
- Devices API
- GET /api/devices
- GET /api/devices/{deviceId}
- GET /api/devices/{deviceId}/lastLocation
- POST /api/devices/{deviceId}/locations
- POST /api/devices/{deviceId}/alerts
- POST /api/devices
- PUT /api/devices/{deviceId}
- DELETE /api/devices/{deviceId}
- GET /api/devices/deleted
- POST /api/devices/{deviceId}/restore
- POST /api/devices/{deviceId}/sendCommand
- Groups API
- GET /api/groups
- POST /api/groups
- PUT /api/groups/{groupId}
- DELETE /api/groups/{groupId}
- GET /api/groups/{groupId}
- PATCH /api/groups/{groupId}
- Users API
- GET /api/users
- POST /api/users
- GET /api/users/countries
- GET /api/users/timeZones
- GET /api/users/{userId}
- PUT /api/users/{userId}
- PATCH /api/users/{userId}
- DELETE /api/users/{userId}
- Alerts API
- GET /api/alerts/types
- GET /api/alerts/{deviceId}
- PUT /api/alerts/{deviceId}
- POST /api/alerts/add
- POST /api/alerts/copy
- Reports API
- GET /api/reports
- POST /api/reports/{reportId}/run
- Scheduled reports API
- GET /api/scheduledReports
- POST /api/scheduledReports
- GET /api/scheduledReports/{reportId}
- PUT /api/scheduledReports/{reportId}
- DELETE /api/scheduledReports/{reportId}
- Shared access API
- GET /api/shares
- POST /api/shares
- POST /api/shares/link
- GET /api/shares/{shareId}
- PUT /api/shares/{shareId}
- DELETE /api/shares/{shareId}
- SMS API
- GET /api/sms
- POST /api/sms
- GET /api/sms/balance
- GET /api/sms/settings
- PUT /api/sms/settings
- Zones API
- GET /api/zones
- PUT /api/zones
- DELETE /api/zones/{zoneId}
- Account settings API
- GET /api/settings
- PATCH /api/settings