Server information
- Fetch a list of Devices
Create a Device
Update a Device
Delete a Device
Update total distance and hours of the Device
Fetch a list of Devices
Traccar (6.10.0)
Traccar GPS tracking server API documentation. To use the API you need to have a server instance. For testing purposes you can use one of free demo servers. For production use you can install your own server or get a subscription service.
Download OpenAPI description
Overview
Languages
Servers
Mock server
https://docs2.mygpsapi.com/_mock/openapi
Doha Dynamics API (Production)
https://mygpsapi.com/api
- Mock serverhttps://docs2.mygpsapi.com/_mock/openapi/devices
- Doha Dynamics API (Production)https://mygpsapi.com/api/devices
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
-u <username>:<password> \
'https://docs2.mygpsapi.com/_mock/openapi/devices?all=true&userId=0&id=0&uniqueId=string'Response
application/json
[ { "id": 0, "name": "string", "uniqueId": "string", "status": "string", "disabled": true, "lastUpdate": "2019-08-24T14:15:22Z", "positionId": 0, "groupId": 0, "phone": "string", "model": "string", "contact": "string", "category": "string", "attributes": {} } ]
- Mock serverhttps://docs2.mygpsapi.com/_mock/openapi/devices
- Doha Dynamics API (Production)https://mygpsapi.com/api/devices
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
-u <username>:<password> \
https://docs2.mygpsapi.com/_mock/openapi/devices \
-H 'Content-Type: application/json' \
-d '{
"id": 0,
"name": "string",
"uniqueId": "string",
"status": "string",
"disabled": true,
"lastUpdate": "2019-08-24T14:15:22Z",
"positionId": 0,
"groupId": 0,
"phone": "string",
"model": "string",
"contact": "string",
"category": "string",
"attributes": {}
}'Response
application/json
{ "id": 0, "name": "string", "uniqueId": "string", "status": "string", "disabled": true, "lastUpdate": "2019-08-24T14:15:22Z", "positionId": 0, "groupId": 0, "phone": "string", "model": "string", "contact": "string", "category": "string", "attributes": {} }
- Mock serverhttps://docs2.mygpsapi.com/_mock/openapi/devices/{id}
- Doha Dynamics API (Production)https://mygpsapi.com/api/devices/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
-u <username>:<password> \
'https://docs2.mygpsapi.com/_mock/openapi/devices/{id}' \
-H 'Content-Type: application/json' \
-d '{
"id": 0,
"name": "string",
"uniqueId": "string",
"status": "string",
"disabled": true,
"lastUpdate": "2019-08-24T14:15:22Z",
"positionId": 0,
"groupId": 0,
"phone": "string",
"model": "string",
"contact": "string",
"category": "string",
"attributes": {}
}'Response
application/json
{ "id": 0, "name": "string", "uniqueId": "string", "status": "string", "disabled": true, "lastUpdate": "2019-08-24T14:15:22Z", "positionId": 0, "groupId": 0, "phone": "string", "model": "string", "contact": "string", "category": "string", "attributes": {} }
- Mock serverhttps://docs2.mygpsapi.com/_mock/openapi/devices/{id}
- Doha Dynamics API (Production)https://mygpsapi.com/api/devices/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X DELETE \
-u <username>:<password> \
'https://docs2.mygpsapi.com/_mock/openapi/devices/{id}'- Mock serverhttps://docs2.mygpsapi.com/_mock/openapi/devices/{id}/accumulators
- Doha Dynamics API (Production)https://mygpsapi.com/api/devices/{id}/accumulators
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
-u <username>:<password> \
'https://docs2.mygpsapi.com/_mock/openapi/devices/{id}/accumulators' \
-H 'Content-Type: application/json' \
-d '{
"deviceId": 0,
"totalDistance": 0,
"hours": 0
}'