Pointer Fleet API Guide V1.3o

Download as pdf or txt
Download as pdf or txt
You are on page 1of 92

Pointer Fleet API

Guide

Proprietary and Confidential

Version 1.3o

Revised and Updated: February 23, 2021


Pointer Fleet
Client API User Guide

Legal Notices
IMPORTANT
1. All legal terms and safety and operating instructions should be read thoroughly before the
product accompanying this document is installed and operated.
2. This document should be retained for future reference.
3. Attachments, accessories or peripheral devices not supplied or recommended in writing by
Pointer Telocation Ltd. may be hazardous and/or may cause damage to the product and should
not, in any circumstances, be used or combined with the product.
General
The product accompanying this document is not designated for and should not be used in life
support appliances, devices, machines or other systems of any sort where any malfunction of the
product can reasonably be expected to result in injury or death. Customers of Pointer Telocation
Ltd. using, integrating, and/or selling the product for use in such applications do so at their own risk
and agree to fully indemnify Pointer Telocation Ltd. for any resulting loss or damages.

Warranty Exceptions and Disclaimers


Pointer Telocation Ltd. shall bear no responsibility and shall have no obligation under the foregoing
limited warranty for any damages resulting from normal wear and tear, the cost of obtaining
substitute products, or any defect that is (i) discovered by purchaser during the warranty period but
purchaser does not notify Pointer Telocation Ltd. until after the end of the warranty period, (ii)
caused by any accident, force majeure, misuse, abuse, handling or testing, improper installation or
unauthorized repair or modification of the product, (iii) caused by use of any software not supplied
by Pointer Telocation Ltd., or by use of the product other than in accordance with its
documentation, or (iv) the result of electrostatic discharge, electrical surge, fire, flood or similar
causes. Unless otherwise provided in a written agreement between the purchaser and Pointer
Telocation Ltd., the purchaser shall be solely responsible for the proper configuration, testing and
verification of the product prior to deployment in the field.
POINTER TELOCATION LTD.’S SOLE RESPONSIBILITY AND PURCHASER’S SOLE REMEDY UNDER
THIS LIMITED WARRANTY SHALL BE TO REPAIR OR REPLACE THE PRODUCT HARDWARE,
SOFTWARE OR SOFTWARE MEDIA (OR IF REPAIR OR REPLACEMENT IS NOT POSSIBLE, OBTAIN A
REFUND OF THE PURCHASE PRICE) AS PROVIDED ABOVE. POINTER TELOCATION LTD. EXPRESSLY
DISCLAIMS ALL OTHER WARRANTIES OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING WITHOUT
LIMITATION ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,
SATISFACTORY PERFORMANCE AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL
POINTER TELOCATION LTD. BE LIABLE FOR ANY INDIRECT, SPECIAL, EXEMPLARY, INCIDENTAL OR
CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOSS OR INTERRUPTION OF USE,
DATA, REVENUES OR PROFITS) RESULTING FROM A BREACH OF THIS WARRANTY OR BASED ON
ANY OTHER LEGAL THEORY, EVEN IF POINTER TELOCATION LTD. HAS BEEN ADVISED OF THE
POSSIBILITY OR LIKELIHOOD OF SUCH DAMAGES.

Intellectual Property
Copyright in and to this document is owned solely by Pointer Telocation Ltd. Nothing in this
document shall be construed as granting you any license to any intellectual property rights
subsisting in or related to the subject matter of this document including, without limitation, patents,
patent applications, trademarks, copyrights or other intellectual property rights, all of which remain
the sole property of Pointer Telocation Ltd. Subject to applicable copyright law, no part of this
document may be reproduced, stored in or introduced into a retrieval system, or transmitted in any
form or by any means (electronic, mechanical, photocopying, recording or otherwise), or for any
purpose, without the express written permission of Pointer Telocation Ltd.
© Copyright 2017. All rights reserved.

Pointer Fleet Client API User Guide Page 2 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

Table of Contents
1 Introduction ..............................................................................................................7
1.1 Revisions .................................................................................................................... 7
1.2 Abbreviations .............................................................................................................. 8
1.3 Glossary...................................................................................................................... 8
2 Getting Started..........................................................................................................9
2.1 Authentication Method .................................................................................................. 9
2.2 Post Login ................................................................................................................... 9
3 Login .......................................................................................................................10
3.1.1 Login ........................................................................................................................ 10
3.1.2 Login/Get [new] ......................................................................................................... 10
4 Driver Management .................................................................................................11
4.1.1 CreateDriver [new] ..................................................................................................... 11
4.1.2 AddNewDriver ............................................................................................................ 12
4.1.3 UpdateDriver [new] .................................................................................................... 12
4.1.4 EditExistingDriver ....................................................................................................... 13
4.1.5 DeleteDriver [new] ..................................................................................................... 14
4.1.6 DeleteDriver .............................................................................................................. 14
4.1.7 AssignDriverToVehicle [new] ....................................................................................... 15
4.1.8 AssignDriverToVehicle ................................................................................................. 16
4.1.9 GetDrivers [new] ....................................................................................................... 16
4.1.10 GetDriverDetails [new] ............................................................................................... 17
4.1.11 GetDriver .................................................................................................................. 18
4.1.12 GetVehicle ................................................................................................................. 18
4.1.13 AssignDriverToSubAccount .......................................................................................... 19
4.1.14 GetDriverGroups [new] ............................................................................................... 19
4.1.15 CreateGroup [new] ..................................................................................................... 19
4.1.16 DeleteGroup [new] ..................................................................................................... 20
5 Account Administration ...........................................................................................21
5.1.1 GetAccounts [new] ..................................................................................................... 21
5.1.2 GetAccount................................................................................................................ 21
5.1.3 GetSubaccounts [new] ................................................................................................ 22
5.1.4 GetVehicleGroups [new].............................................................................................. 22
5.1.5 CreateSubaccount [new] ............................................................................................. 22
5.1.6 UpdateSubaccount [new] ............................................................................................ 23
5.1.7 DeleteSubaccount [new] ............................................................................................. 24
5.1.8 DeleteSubAccount ...................................................................................................... 24
5.1.9 GetAccountHierarchy .................................................................................................. 24
5.1.10 SubaccountDynamicAllocation ...................................................................................... 25
5.1.11 GetAccountSwitches [new] .......................................................................................... 25
5.1.12 GetAccountReports [new] ............................................................................................ 25

Pointer Fleet Client API User Guide Page 3 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

5.1.13 AssociateReportsToSubAccounts [new] ......................................................................... 26


6 Vehicles Management .............................................................................................27
6.1.1 GetVehicles [new] ...................................................................................................... 27
6.1.2 GetFuelTypes [new] ................................................................................................... 27
6.1.3 GetManufacturers [new] ............................................................................................. 27
6.1.4 GetManufactureModels [new]....................................................................................... 28
6.1.5 GetVehicleYears [new] ................................................................................................ 28
6.1.6 GetVehicleColors [new] ............................................................................................... 28
6.1.7 GetLicenseTypes [new] ............................................................................................... 28
6.1.8 GetVehicleTypes [new] ............................................................................................... 29
6.1.9 GetVehicleIcons [new] ................................................................................................ 29
6.1.10 UpdateVehicle [new] .................................................................................................. 29
6.1.11 CalibrateUnit [new] .................................................................................................... 30
6.1.12 DeleteVehicle [new] ................................................................................................... 30
6.1.13 UpdateVehicleInstallation [new] ................................................................................... 31
6.1.14 Get Vehicles Information [new] .................................................................................... 32
6.1.15 Get Vehicle Route History Information [new] ................................................................. 35
6.1.16 Get Mobileye Events Information [new] ........................................................................ 38
6.1.17 Get Vehicle Events Activity [new] ................................................................................. 40
6.1.18 Get Vehicle Activity Summary [new] ............................................................................. 42
6.1.19 Get Daily Activity Report API [new] .............................................................................. 44
6.1.1 Odometer Update ....................................................................................................... 46
6.1.2 Connect to Maintenance .............................................................................................. 47
7 Vehicle Groups Management ...................................................................................49
7.1.1 CreateGroup [new] ..................................................................................................... 49
7.1.2 DeleteGroup [new] ..................................................................................................... 49
7.1.3 AssignVehiclesToSubAccount [new] .............................................................................. 49
7.1.4 AssignVehiclesToGroup [new] ...................................................................................... 50
8 Tasks Management..................................................................................................51
8.1 Task / Route .............................................................................................................. 51
8.2 Task / Route State-Machines ....................................................................................... 51
8.3 Tasks ........................................................................................................................ 52
8.3.1 GetTasks [new].......................................................................................................... 52
8.3.2 GetTask .................................................................................................................... 53
8.3.3 AddNewTask .............................................................................................................. 54
8.3.4 EditExistingTask ......................................................................................................... 55
8.3.5 GetTaskStatuses [new] ............................................................................................... 56
8.3.6 GetTaskStatus ........................................................................................................... 56
8.3.7 GetTaskData [new] .................................................................................................... 57
8.3.8 DeleteExistingTask ..................................................................................................... 58
8.3.9 AssignTask ................................................................................................................ 58
8.3.10 GetTaskTypes [new] ................................................................................................... 58
8.3.11 GetTaskType ............................................................................................................. 59
Pointer Fleet Client API User Guide Page 4 of 92
Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3.12 GetTaskMediums [new] ............................................................................................... 59


8.4 Routes ...................................................................................................................... 60
8.4.1 AddNewTask .............................................................................................................. 61
8.4.2 EditExistingRoute ....................................................................................................... 62
8.4.3 GetRouteStatuses [new] ............................................................................................. 62
8.4.4 GetRouteData [new] ................................................................................................... 63
8.4.5 UpdateRouteStatus..................................................................................................... 63
8.4.6 DeleteExistingRoute ................................................................................................... 64
8.4.7 AddTasksToRoute ....................................................................................................... 64
8.4.8 RemoveTaskFromRoute .............................................................................................. 65
8.4.9 AssignRoute .............................................................................................................. 65
8.4.10 GetRoute [new] ......................................................................................................... 66
8.4.11 AddNewRoute ............................................................................................................ 66
8.4.12 GetRouteStatus.......................................................................................................... 67
8.4.13 GetRoute .................................................................................................................. 67
8.5 Proof-of-Work ............................................................................................................ 68
8.5.1 Get Tasks Details ....................................................................................................... 68
9 Speed Limits APIs [Safety360] ...............................................................................70
9.1.1 Get Account’s License Plates ........................................................................................ 70
9.1.2 Get Account’s Drivers ................................................................................................. 71
9.1.3 Get Account’s License Plates/Drivers Over-Speeding Events ............................................ 72
9.1.4 Get Accounts Dashboard Data ...................................................................................... 73
9.1.5 Get User Details ......................................................................................................... 74
9.1.6 Update User Details .................................................................................................... 76
9.1.7 Create an Override Event ............................................................................................ 77
9.1.8 Update an Override Event State ................................................................................... 80
9.1.9 Delete an Override Rule .............................................................................................. 82
9.1.1 Get Override Rules ..................................................................................................... 83
9.2 API Actions ................................................................................................................ 85
9.2.1 API Action Example .................................................................................................... 85
10 API Objects .............................................................................................................87
10.1 LayerInfo .................................................................................................................. 87
10.2 PointInfo ................................................................................................................... 87
10.3 TransferAccountModel ................................................................................................. 87
10.4 TransferedItems ........................................................................................................ 87
10.5 AccountInfo ............................................................................................................... 87
10.6 TaskInfo ................................................................................................................... 88
10.7 TaskStatus ................................................................................................................ 89
10.8 AssignInfo ................................................................................................................. 89
10.9 RouteInfo .................................................................................................................. 89
10.10 Task....................................................................................................................... 90

Pointer Fleet Client API User Guide Page 5 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

10.11 AssignRouteInfo ...................................................................................................... 90


10.12 Status .................................................................................................................... 90
10.13 DriverInfo ............................................................................................................... 90
10.14 LicenseTypes........................................................................................................... 91
11 API Call Example .....................................................................................................92
11.1 Example Scenario: GetTaskStatus ................................................................................ 92

Pointer Fleet Client API User Guide Page 6 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

1 Introduction
This guide is intended to provide clients of Pointer Fleet with complete instructions for
creating, managing, and monitoring activities related to tasks and routes.

1.1 Revisions
Author Date Remarks Rev
Modified:
1. Added Fleet Alias and Fleet Number as
input parameters to GetVehiclesInfo
Ziv Rotner 22/11/2020 API 1.3o
2. Added the odometer and direction fields
in the GetVehiclesInfo API response,
available for all API executions.
Modified:
1. Added CAN bus data in Get Vehicle Route
Ziv Rotner 14/06/2020 History API 1.3n
2. Added CAN bus data in Get Vehicles
Information API
Modified:
Added SubType parameter to the Connect to
Ziv Rotner 14/05/2020 1.3m
Maintenance API for sending Connect to
Cellocator+ AutoCAN command
Added:
Ziv Rotner 14/01/2020 1.3l
Connect to Maintenance API
Date/Time correction for the GetDailyActivity
Ziv Rotner 19/09/2019 1.3ka
API
GetVehicleRouteHistoryInformation update:
Ziv Rotner 15/06/2019 1. New OptionalProps optional parameter. 1.3k
Values are per custom account usage.
GetVehiclesInfo updates:
1. Parameters that are used with null
Ziv Rotner 07/04/2019 value are no longer mandatory. 1.3j
2. New OptionalProps optional parameter.
Values are per custom account usage.
Ziv Rotner 11/03/2019 Minor corrections and updates. 1.3i
Updated:
Skip Email Notification for Create Override
Ziv Rotner 03/02/2019 1.3h
Event & UpdateOverride Event APIs (Safety
360)
Added:
Ziv Rotner 09/01/2019 [Proof-of-Work] Get Tasks Details 1.3g
[Vehicle Management] Odometer Update

Pointer Fleet Client API User Guide Page 7 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

1.2 Abbreviations
Abbreviation Description
POI Point of Interest

Ext External

1.3 Glossary
Name Definition

A single planned mission that needs to be done at a certain


Task
time and location.

A collection of ordered tasks, at least one, created by fleet


Route
manager assigned to a driver or vehicle.

ETA Estimated Time of Arrival

XML Extensible Markup Language

Entity identifier used solely by the client; for example, Task


External ID
ID, Route ID and so on.

Pointer Fleet Client API User Guide Page 8 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

2 Getting Started
This section describes how to get started with the Pointer Fleet Client API, including the
initial steps you need to take when trying to integrate your system with the Pointer Fleet
using the API.

----------------------------------------------------------------------------------------------------
NOTE: For this release, there are two different API available, each of which are described
in this guide.

The existing API uses methods and calls structured in this format:
http://localhost/FleetAPI/Fleet.API.*.svc

The new API uses methods and calls structured in this format:
http://localhost/FleetAPI/api/

The new API always returns a JSON object; the existing API returns responses in XML
format.

Throughout this guide, the new API methods and calls are indicated by .
----------------------------------------------------------------------------------------------------

2.1 Authentication Method


The Pointer Fleet API uses a token-based mechanism to authenticate users and manage
their permissions and sessions.
Upon a successful execution of the login function (as detailed in sections 3.1.1 or 3.1.2)
with the relevant account username and password, the function returns a token number.
During its lifetime (1 hour by default), the token key should be used to execute other
functions like adding a new task, editing driver details and so on.
When there is no activity for a period of 1 hour, or your application has executed the
logoff function, the token will expire, and a new token will be generated again when
logging in once again).
Note that without the return token string, you will not be able to work with the Pointer
Fleet API.

2.2 Post Login


Following a successful login and receiving the token, the entire function list is available for
you to use, per the permissions granted to your account. You can add new tasks, create a
route based on existing tasks, update driver details, and so on.
Please note that for some entities there are mandatory fields, limitations on the number
of characters or values that can be used, or a limitation in switching task or route
statuses. Please refer to the API object table (section 0) to learn more about these
limitations.

Pointer Fleet Client API User Guide Page 9 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

3 Login
This section includes the various methods for logging in via the API.

3.1.1 Login
Action Name: Login
XML Parameters: UserName (String), Password (String)

http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/Login?xml=

XML String Structure


<Login>
<UserName></UserName>
<Password></Password>
</Login>

Success Return Value: Token (string)


Mandatory Fields: Username & Password

3.1.2 Login/Get [new]


Action Name: Login/Get
Description: Logs in to Fleet system with username and password and gets a temporary
token.
Input Parameters: Username: Fleet username (string), Password: Fleet password
(string)

http://localhost/FleetAPI/api/Login/Get?username=ofir&password=Aa1111

Success Return Value: Token (string)


Example:
{"Version":"1.0.0.0","StatusCode":200,"Result":{"Token":"561700592620000043"}}

Pointer Fleet Client API User Guide Page 10 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

4 Driver Management
This section includes various Driver functions available through the API, including: Create
Driver, Get Driver, Add New Driver, Edit Existing Driver, Delete Driver, Assign Driver to
Vehicle, Get Vehicle, Assign Driver to Subaccount.

4.1.1 CreateDriver [new]


Description: Creates a new driver.
Input Parameter: Token (string)
PostBody =

<ROOT>
<ExternalDriverId>3070</ExternalDriverId>
<FirstName>John</FirstName>
<MiddleName>Mistery</MiddleName>
<LastName>Due</LastName>
<NationalId>7756</NationalId>
<Code_input></Code_input>
<Code></Code>
<LTList>6,137</LTList>
<DriverGroupId>4255</DriverGroupId>
<Status>1</Status>
<SAList>4521</SAList> (list of subaccount ids)
<EXList>101</EXList> (list of external subaccount ids)
<LicenseNum>665655bb</LicenseNum>
<LicenseExpire>2016/09/29 00:00</LicenseExpire>
<LicenseIssue>2016/09/23 00:00</LicenseIssue>
<Birthday>2016/02/11 00:00</Birthday>
<Address>address</Address>
<Mobile>mobile</Mobile>
<HomePhone>phone</HomePhone>
<Email>[email protected]</Email>
<Remarks>remarks</Remarks>
<Login>lgn</Login>
<Password>Apsp1234</Password>
<DefaultTaskMedium>1</DefaultTaskMedium>
<ManagerId></ManagerId>
<DriverFeatures>0</DriverFeatures>
</ROOT>
Server/Driver/CreateDriver
HTTP Method: POST
Response: Returns a successfully created message
{"Version":"1.0.23","StatusCode":200,"Result":{"Message":"Driver Created
Successfully"}}

Pointer Fleet Client API User Guide Page 11 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

4.1.2 AddNewDriver
XML Parameters: Token (string), DriverInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AddNewDriver?xml=

XML String Structure


<AddNewDriver>
<Token></Token>
<DriverInfo>
<Status></Status>
<Code></Code>
<NationalId></NationalId>
<LicenseNum></LicenseNum>
<LicenseExpire></LicenseExpire>
<LicenseIssue></LicenseIssue>
<Birthday></Birthday>
<Address></Address>
<Mobile></Mobile>
<HomePhone></HomePhone>
<DriverGroupId></DriverGroupId>
<FirstName></FirstName>
<LastName></LastName>
<MiddleName></MiddleName>
<LicenseTypes>
<NameIdTypeInfo>
<Id></Id>
</NameIdTypeInfo>
</LicenseTypes>
<Login></Login>
<Password></Password>
<DefaultTaskMedium></DefaultTaskMedium>
<ManagerId></ManagerId>
</DriverInfo>
</AddNewDriver>

Success Return Value: DriverInfo


Mandatory Fields: Token, FirstName & LastName

4.1.3 UpdateDriver [new]


Description: Updates existing driver.
Input Parameter: Token (string)
PostBody = <ROOT>

<ExternalDriverId>3070</ExternalDriverId>
<FirstName>bbbbb</FirstName>
<MiddleName>cccc</MiddleName>
<LastName>ddd</LastName>
<NationalId>7756</NationalId>
<Code_input></Code_input>
<Code></Code>

Pointer Fleet Client API User Guide Page 12 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

<LTList>6,137</LTList>
<DriverGroupId>4255</DriverGroupId>
<Status>1</Status>
<SAList>4521</SAList>(list of subaccount ids)
<EXList>101</EXList> (list of external subaccount ids)
<LicenseNum>665655bb</LicenseNum>
<LicenseExpire>2016/09/29 00:00</LicenseExpire>
<LicenseIssue>2016/09/23 00:00</LicenseIssue>
<Birthday>2016/02/11 00:00</Birthday>
<Address>address</Address>
<Mobile>mobile</Mobile>
<HomePhone>phone</HomePhone>
<Email>[email protected]</Email>
<Remarks>remarks</Remarks>
<Login>lgn</Login>
<Password>Apsp1234</Password>
<DefaultTaskMedium>1</DefaultTaskMedium>
<ManagerId></ManagerId>
</ROOT>
Server/Driver/UpdateDriver

HTTP Method: POST


Response: Returns a successfully updated message
{"Version":"1.0.23","StatusCode":200,"Result":{"Message":"Driver Updated
Successfully"}}

4.1.4 EditExistingDriver
XML Parameters: Token (string), DriverInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/EditExistingDriver?xml=

XML String Structure


<EditExistingDriver>
<Token></Token>
<DriverInfo>
<Id></Id>
<Status></Status>
<Code></Code>
<NationalId></NationalId>
<LicenseNum></LicenseNum>
<LicenseExpire></LicenseExpire>
<LicenseIssue></LicenseIssue>
<Birthday></Birthday>
<Address></Address>
<Mobile></Mobile>
<HomePhone></HomePhone>
<DriverGroupId></DriverGroupId>
<FirstName></FirstName>
<LastName></LastName>
<MiddleName></MiddleName>
<LicenseTypes>
<NameIdTypeInfo>

Pointer Fleet Client API User Guide Page 13 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

<Id></Id>
</NameIdTypeInfo>
</LicenseTypes>
<Login></Login>
<Password></Password>
<DefaultTaskMedium></DefaultTaskMedium>
<ManagerId></ManagerId>
</DriverInfo>
</EditExistingDriver>

Success Return Value: True / False


Mandatory fields: Token, Id

4.1.5 DeleteDriver [new]


Description: Deletes an existing driver from the account.
Input Parameter: Token (string)
PostBody = {Id=222 (int), ExternalDriverId = 232 (int)}
one of the parameters is required

Server/Driver/DeleteDriver

HTTP Method: POST


Response: Returns a successfully deleted message
{"Version":"1.0.23","StatusCode":200,"Result":{"Message":"Driver Deleted
Successfully"}}

4.1.6 DeleteDriver
XML Parameters: Token (string), DriverInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/DeleteDriver?xml=

XML String Structure


<DeleteDriver>
<Token></Token>
<DriverId></DriverId>
</DeleteDriver>

Success Return Value: True / False


Mandatory Fields: Token, DriverId

Pointer Fleet Client API User Guide Page 14 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

4.1.7 AssignDriverToVehicle [new]


Description: Assign / Unassign driver to a vehicle.
Input Parameters:
Token (String)
DriverId (int; either DriverId or ExternalDriverId is mandatory)
ExternalDriverId (int, optional) required if DriverId not sent
VehicleId (int; either VehicleId or ExternalVehicleId is mandatory)
ExternalVehicleId (int, optional)
LisencePlate (string, optional) required if VehicleId and ExternalVehicleId not sent
PostBody = {XML = <ROOT>
<ExternalDriverId>42215</ExternalDriverId>
<FirstName>QWQf44ttg</FirstName>
<MiddleName></MiddleName>
<LastName>ls</LastName>
<NationalId>7756</NationalId>
<Code_input></Code_input>
<Code></Code>
<LTList>6,137</LTList>
<DriverGroupId>4255</DriverGroupId>
<Status>1</Status>
<SAList>4352,4506,4337</SAList>
<LicenseNum>665655bb</LicenseNum>
<LicenseExpire>2016/09/29 00:00</LicenseExpire>
<LicenseIssue>2016/09/23 00:00</LicenseIssue>
<Birthday>2016/02/11 00:00</Birthday>
<Address>address</Address>
<Mobile>mobile</Mobile>
<HomePhone>phone</HomePhone>
<Email>[email protected]</Email>
<Remarks>remarks</Remarks>
<Login>lgn</Login>
<Password>Apsp1234</Password>
<DefaultTaskMedium>1</DefaultTaskMedium>
<ManagerId></ManagerId>
</ROOT>"}
Server/Driver/AssignDriverToVehicle

HTTP Method: GET


Response: Success or error with proper message
Mandatory Fields: ExternalDriverId

Pointer Fleet Client API User Guide Page 15 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

4.1.8 AssignDriverToVehicle
XML Parameters: Token (string), DriverId (int), LisencePlate (string)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AssignDriverToVehicle?xml=

XML String Structure


<AssignDriverToVehicle>
<Token></Token>
<DriverId></DriverId>
<LicensePlate></LicensePlate>
</AssignDriverToVehicle>

Success Return Value: True / False


Mandatory fields: Token, DriverId & LicensePlate

4.1.9 GetDrivers [new]


Description: Gets a list of drivers.
Input Parameters:
Token (string)
SubAccountId (int optional)
ExternalId (int optional)
URL: FleetAPI/api/Driver/GetDrivers

HTTP Method: GET


Response: List of drivers; if subaccountId/externalId was entered then the response is
the list of subaccount drivers
{
"Version": "1.0.45.0",
"StatusCode": 200,
"Result": {
"Drivers": [
{
"ExternalDriverId": null,
"FirstName": "Driver",
"MiddleName": null,
"LastName": "3",
"GroupId": 4832,
"Subaccount": [
{
"Id": 5042,
"Name": "Test_A"
},
{
"Id": 5046,

Pointer Fleet Client API User Guide Page 16 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

"Name": "Test_b"
}
],
"EXSubaccount": [
{
"Id": 0,
"Name": "Test_A"
},
{
"Id": 0,
"Name": "Test_b"
}
]
},
}
}

4.1.10 GetDriverDetails [new]


Description: Gets driver details.
Input Parameter:
Token (string)
DriverId (int optional)
Ext. DriverId (int optional); at least one of the parameters is required.
Server/Driver/GetDriverDetails

HTTP Method: GET


Response: Driver details
{"driver":{"Id":37186,"ExternalDriverId":3000,"PhoneNumber":null,"Code":null,"N
ationalId":"7756","LicenseNum":"665655bb","LicenseExpire":"2016-09-
29T00:00:00","LicenseIssue":"2016-09-23T00:00:00","Birthday":"2016-02-
11T00:00:00","Address":"address","Mobile":"mobile","HomePhone":"phone","Email":
"[email protected]","DriverGroupId":4255,"FirstName":"bbbbb","LastName":"ddd","
MiddleName":"cccc","Remarks":"remarks","SubAccounts":[{"Id":4521,"Name":"API_TE
ST__11"}],"EXSubAccounts":[{"Id":101,"Name":"API_TEST__11"}],"LicenseTypes":[{"
Id":6,"Name":"1 -
Tractor"},{"Id":137,"Name":"12121212"}],"Login":"lgn","Password":"Apsp1234","De
faultTaskMedium":1,"ManagerId":null,"OwnerName":"A noam"}}

Pointer Fleet Client API User Guide Page 17 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

4.1.11 GetDriver
XML Parameters: Token (string), DriverInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetDriver?xml=

XML String Structure


<GetDriver>
<Token></Token>
<DriverInfo>
<Id></Id>
<FirstName></FirstName>
<LastName></LastName>
</DriverInfo>
</GetDriver>

Success Return Value: DRIVER


Mandatory fields: Token, Id, FirstName or LastName

4.1.12 GetVehicle
XML Parameters: Token (string), VehicleInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetVehicle?xml=

XML String Structure


<GetVehicle>
<Token></Token>
<VehicleInfo>
<VehicleId></VehicleId>
<LicensePlate></LicensePlate>
</VehicleInfo>
</GetVehicle>

Success Return Value: VEHICLE


Mandatory fields: Token, VehicleId or LicensePlate

Pointer Fleet Client API User Guide Page 18 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

4.1.13 AssignDriverToSubAccount
XML Parameters: Token (string), DriverId (int), SubAccountId (int)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AssignDriverToSubAccount?xml=

XML String Structure


<AssignDriverToSubAccount>
<Token></Token>
<DriverId></DriverId>
<SubAccountId></SubAccountId>
</AssignDriverToSubAccount>

Success Return Value: True / False


Mandatory fields: Token, DriverId & SubAccountId

4.1.14 GetDriverGroups [new]


Description: Gets a list of driver groups.
Input Parameter: Token (string)
Server/Driver/GetDriverGroups

HTTP Method: GET


Response: List of groups
{"Groups":[{"Id":4256,"Name":"BIBI","Description":"DDDDD","IsDefault":false},{"
Id":4014,"Name":"Default Group","Description":"Default
Group","IsDefault":true},{"Id":4255,"Name":"nnmm","Description":"Description","
IsDefault":false},{"Id":4273,"Name":"Default Group
(API_TEST__11)","Description":"Default
Group","IsDefault":false},{"Id":4254,"Name":"Default Group
(API_TEST_6)","Description":"Default Group","IsDefault":false}]}}

4.1.15 CreateGroup [new]


Description: Creates new driver group.
Input Parameter: Token (string)
PostBody = {Name="Group name", Description ="GroupDiscription"}

Server/Driver/CreateGroup

HTTP Method: POST


Response: If successful, returns the new groupId, otherwise will return an error message
{"Version":"1.0.23","StatusCode":200,"Result":{"GroupId":"11624"}}

Pointer Fleet Client API User Guide Page 19 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

4.1.16 DeleteGroup [new]


Description: Deletes group.
Input Parameter: Token (string)
PostBody = {Id=GroupId(int)}

Server/Driver/DeleteGroup

HTTP Method: POST


Response: Returns a successfully deleted message
{"Version":"1.0.18","StatusCode":200,"Result":{"Message":"Deleted
Successfully"}}

Pointer Fleet Client API User Guide Page 20 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

5 Account Administration
The functions in this section can be used to dynamically organize sub accounts in different
hierarchies. This is useful, for example, when your field technicians are moving from one
geographical location to another.
You can further read about the functionality in the Fleet Management System User Guide
(in the Managing Accounts section), and it is highly advisable to contact technical
authority of Pointer to fully understand the functionality.
Account functions include: Get Account, Get Account Hierarchy, Subaccount Dynamic
Allocation, and Delete Subaccount.

5.1.1 GetAccounts [new]


Description: Gets a list of accounts (LookupTable).

http://localhost/FleetAPI/api/Account/GetAccounts?key=88750014772000004

Input Parameter: Token (string)


Output Objects:
Id: account id (int)
Name: account name (string)

5.1.2 GetAccount
XML Parameters: Token (string), AccountInfo (object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetAccount?xml=

XML String Structure


<GetAccount>
<Token></Token>
<AccountInfo>
<AccountId></AccountId>
<AccountName></AccountName>
</AccountInfo>
</GetAccount>

Success Return Value: AccountInfo


Mandatory Fields: Token, AccountId or AccountName

Pointer Fleet Client API User Guide Page 21 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

5.1.3 GetSubaccounts [new]


Description: Gets a list of sub accounts.
Input Parameter: TokenId
Server/Account/GetSubaccount

HTTP Method: GET


Response: List of subaccounts
{"SubAccounts":[{"AccountId":4318,"AccountName":"eli"},{"AccountId":4319,"Ac
countName":"Carlos"},{"AccountId":4320,"AccountName":"Orli"},{"AccountId":43
21,"AccountName":"newq"},{"AccountId":4322,"AccountName":"QQQ"}….]}

5.1.4 GetVehicleGroups [new]


Description: Gets a list of vehicle groups (Lookup Table).
Input Parameter: Token (string)
http://localhost/FleetAPI/api/Vehicle/GetVehicleGroups?key=

Output Objects:
Id: group id (int)
Name: group name (string)

5.1.5 CreateSubaccount [new]


Description: Creates a new sub account.
Input Parameter: TokenId
PostBody = {XML = "<ROOT>
<ExternalAccountId>444</ ExternalAccountId >
<CSSFileId>51</CSSFileId>
<LogoFileId>50</LogoFileId>
<AccountType>3</AccountType>
<Name>API_TEST_3</Name>
<Switches>0,1,2,3,4,5,6,7,8,9,11,12,13,14,20</Switches>
<UserName>rfg</UserName>
<Password>Aa1111</Password>
<Street>stre1et</Street>
<City>vvfg</City>
<State>dfg</State>
<Zip>sdf</Zip>
<Country>sdfsdf</Country>
<ContactPerson>44fr</ContactPerson>
<PhoneNumber>5435345</PhoneNumber>
<Email>[email protected]</Email>
<SMS></SMS>
<Remarks>qwe</Remarks>
<EmailSubject>mmasdasd</EmailSubject>

Pointer Fleet Client API User Guide Page 22 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

<DefaultLanguage>1</DefaultLanguage>
<Zoom>50</Zoom>
<InitX>31</InitX>
<InitY>34</InitY>
</ROOT>"}
Server/Account/CreateSubaccount
HTTP Method: POST
Response: True or False
Mandatory Fields: ExternalDriverId, Name

5.1.6 UpdateSubaccount [new]


Description: Updates a sub account.
Input Parameter: TokenId
PostBody = {XML "<ROOT>
<AccountId>444</AccountId>
<ExternalAccountId>444</ ExternalAccountId >
<CSSFileId>51</CSSFileId>
<LogoFileId>50</LogoFileId>
<AccountType>3</AccountType>
<Name>API_TEST_3</Name>
<Switches>0,1,2,3,4,5,6,7,8,9,11,12,13,14,20</Switches>
<UserName>rfg</UserName>
<Password>Aa1111</Password>
<Street>stre1et</Street>
<City>vvfg</City>
<State>dfg</State>
<Zip>sdf</Zip>
<Country>sdfsdf</Country>
<ContactPerson>44fr</ContactPerson>
<PhoneNumber>5435345</PhoneNumber>
<Email>[email protected]</Email>
<SMS></SMS>
<Remarks>qwe</Remarks>
<EmailSubject>mmasdasd</EmailSubject>
<DefaultLanguage>1</DefaultLanguage>
<Zoom>50</Zoom>
<InitX>31</InitX>
<InitY>34</InitY>
</ROOT>"}
Server/Account/UpdateSubaccount
HTTP Method: POST
Response: True or False
Mandatory Fields: ExternalDriverId

Pointer Fleet Client API User Guide Page 23 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

5.1.7 DeleteSubaccount [new]


Description: Deletes a sub account.
Input Parameters: TokenId and SubAccountId
Server/Account/DeleteSubaccount

HTTP Method: GET


Response: True / False

5.1.8 DeleteSubAccount
XML Parameters: Token (string), SubAccountId (int)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/DeleteSubAccount?xml=

XML String Structure


<DeleteSubAccount >
<Token></Token>
<SubAccountId></SubAccountId>
</DeleteSubAccount>

Success Return Value: True / False


Mandatory Fields: Token, SubAccountId

5.1.9 GetAccountHierarchy
XML Parameters: Token (string)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetAccountHierarchy?xml=

XML String Structure


<GetAccountHierarchy>
<Token></Token>
</GetAccountHierarchy>

Success Return Value: AccountInfo list


Mandatory Fields: Token

Pointer Fleet Client API User Guide Page 24 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

5.1.10 SubaccountDynamicAllocation
XML Parameters: Token (string)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/SubaccountDynamicAllocation?xml=

XML String Structure


<SubaccountDynamicAllocation>
<Token></Token>
<TransferAccountModel>
<AccountId></AccountId>
<DestinationId></DestinationId>
</TransferAccountModel>
</SubaccountDynamicAllocation >

Success Return Value: TransferedItems obj


Mandatory Fields: Token, AccountId & DestinationId

5.1.11 GetAccountSwitches [new]


Description: Gets a list of account switches.
Input Parameter: Token (string)
Server/Account/GetAccountSwitches

HTTP Method: GET


Response: List of account switches
{"Switches":[{"Id":0,"Name":"Address Search"},{"Id":1,"Name":"Route
history"}..]}

5.1.12 GetAccountReports [new]


Description: Gets a list of assigned account reports.
Input Parameter: Token (string)
Server/Account/GetAccountReports

HTTP Method: GET


Response: List of account reports

Pointer Fleet Client API User Guide Page 25 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

"AccountReports":[{"Id":53,"Name":"Abastecimentos"},{"Id":160,"Name":
"AccountHistory"}..]}

5.1.13 AssociateReportsToSubAccounts [new]


Description: Associates reports to sub accounts.
Input Parameters: TokenId and SubAccounts (string)
Server/Account/AssociateReportstoSubaccounts

HTTP Method: GET


Response: True / False

Pointer Fleet Client API User Guide Page 26 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6 Vehicles Management
This section includes vehicle functions available with the API.

6.1.1 GetVehicles [new]


Description: Gets a list of vehicles.
Input Parameter: TokenId (string)
server/Vehicle/GetVehicles

HTTP Method: GET


Response: Returns a list of vehicles

{"Vehicles":[{"ExternalVehicleId":0,"LicencePlate":"293087","FleetNumber":nul
l,"FleetAlias":null,"ColorId":171,"ProducerId":271,"ModelId":0,"GroupId":2369
,"IconId":5,"ConfigurationId":null,"SAList":"4321"},{"ExternalVehicleId":0,"L
icencePlate":"C93323","FleetNumber":null,"FleetAlias":null,"ColorId":101,"Pro
ducerId":111,"ModelId":0,"GroupId":2373,"IconId":5,"ConfigurationId":null,"SA
List":"4320,5361"}…]

6.1.2 GetFuelTypes [new]


Description: Gets a list of optional fuel types.
Input Parameter: Token (string)
server/Vehicle/GetFuelTypes

HTTP Method: GET


Response: List of fuel types
[{{"Id":1,"Name":"Diesel"},{"Id":2,"Name":"Petrol"},{"Id":3,"Name":"Ethanol"}}]

6.1.3 GetManufacturers [new]


Description: Gets a list of optional vehicle manufacturers.
Input Parameter: Token (string)
server/FleetAPI/api/Vehicle/GetManufactures

HTTP Method: GET


Response: List of manufacturers
{"Manufacturers":[{"Id":111,"Name":"Acura"}..]}

Pointer Fleet Client API User Guide Page 27 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.4 GetManufactureModels [new]


Description: Gets a list of optional vehicle manufacturer models.
Input Parameters: Token (string), ManufactureId (int)
server/FleetAPI/api/Vehicle/GetManufactureModels?

HTTP Method: GET


Response: List of models
{"ManufactureModels":[{"Id":704,"Name":"TL","CO2E":2.7}]}}

6.1.5 GetVehicleYears [new]


Description: Gets a list of optional year of manufacture.
Input Parameter: Token (string)
Server/Vehicle/GetVehicleYears

HTTP Method: GET


Response: List of years
{"VehicleYears":[{"Id":1980,"Name":"1980"},{"Id":1981,"Name":"1981"},…]}

6.1.6 GetVehicleColors [new]


Description: Gets a list of vehicle colors.
Input Parameter: Token (string)
Server/Vehicle/GetColors

HTTP Method: GET


Response: List of colors
{"Colors":[{"Id":62,"Name":"Azul"},{"Id":64,"Name":"Verde"}]}

6.1.7 GetLicenseTypes [new]


Description: Gets a list of vehicle/driver license types.
Input Parameter: Token (string)
Server/Vehicle/GetLicenseTypes

HTTP Method: GET


Response: List of license types
{"LicenseTypes":[{"Id":6,"Name":"1 - Tractor"},…]}

Pointer Fleet Client API User Guide Page 28 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.8 GetVehicleTypes [new]


Description: Gets a list of optional vehicle types.
Input Parameter: Token (string)
Server/Vehicle/GetVehicleTypes

HTTP Method: GET


Response: List of vehicle types
{"VehicleTypes":[{"Id":1,"Name":"Private"},{"Id":2,"Name":"Large Van"}]}

6.1.9 GetVehicleIcons [new]


Description: Gets a list of optional vehicle icons.
Input Parameter: Token (string)
Server/Vehicle/GetVehicleIcons

HTTP Method: GET


Response: List of vehicle icons
{"VehicleIcons":[{"IconId":4191,"Name":"2pickup","description":null,"IsDefault"
:false,"IconType":1,"IsNew":false},…]}

6.1.10 UpdateVehicle [new]


Description: Updates a vehicle record.
Input Parameters: Token (string), ExternalVehicleId or VehicleId
http://localhost/FleetAPI/api

PostBody = {XML "<ROOT>


<ExternalVehicleId>100</ExternalVehicleId>
OR
<VehicleId>232</VehicleId>
<GroupId>2450</GroupId>
<LicencePlate>LicencePlate</LicencePlate>
<FleetAlias>FleetAlias</FleetAlias>
<FleetNumber>FleetNumber</FleetNumber>
<TankASize>10</TankASize>
<MaintenanceInitialDate></MaintenanceInitialDate>
<TankBSize>30</TankBSize>
<MaintenanceInitialMileCounter>93</MaintenanceInitialMileCounter>
<ConfigurationId>94</ConfigurationId>
<MaintenanceInitialHourmeter>1000</MaintenanceInitialHourmeter>
<MaintenanceDateInterval>1</MaintenanceDateInterval>
<MaintenanceKMInterval>100</MaintenanceKMInterval>
<MaintenanceHMCycle>1000</MaintenanceHMCycle>
<ProducerId>111</ProducerId>

Pointer Fleet Client API User Guide Page 29 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

<ModelId>1216</ModelId>
<Year>2010</Year>
<FuelConsumptionIdling>12</FuelConsumptionIdling>
<FuelConsumptionDriving>10</FuelConsumptionDriving>
<CO2Emission>2.7</CO2Emission>
<ColorId>101</ColorId>
<LicenseTypeId>2</LicenseTypeId>
<VehicleTypeId>3</VehicleTypeId>
<IconId>2</IconId>
<RemarksAdmin>123456</RemarksAdmin>
</ROOT>"}

6.1.11 CalibrateUnit [new]


Description: The CalibrateUnit command sends a Leave Calibration command to an IQ
Cello unit (Cello-iQ or CAN-iQ unit) which instructs the unit to delete its calibration data
and to start a new calibration process.
This function should be used when an IQ unit was deinstalled from a vehicle and installed
again, either in the same vehicle or another vehicle. This operation requires the unit to be
recalibrated again due to its new installation location and position.
Input Parameter: Token (string)
PostBody = VehicleId = 53583 (int),

UnitSysId = 79590470 (int),


ExternalVehicleId =33 (int),
LicensePlate ="" (string)
FleetNumber ="" (string)
FleetAlias ="" (string)

Server/Vehicle/CalibrateUnit

Note that one of the parameters above is required to find the vehicle in the account.
HTTP Method: POST
Response: Returns a successfully sent message
{"Version":"1.0.23","StatusCode":200,"Result":{"Calibration Command sent
Successfully"}}

Note that an error will occur when a vehicle is not found in the list of account vehicles or
the unit is not a CSA unit.

6.1.12 DeleteVehicle [new]


Description: Deletes vehicle from vehicle account (this is a permanent action and cannot
be undone).
Input Parameter: Token (string)
PostBody = VehicleId = 53583 (int),
UnitSysId = 79590470 (int),

Pointer Fleet Client API User Guide Page 30 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

ExternalVehicleId =33 (int),


LicensePlate ="" (string)

Server/Vehicle/DeleteVehicle

Note that one of the parameters above is required to find the vehicle in the account.
HTTP Method: POST
Response: Returns a successfully deleted message
{"Version":"1.0.23","StatusCode": 200, "Result”: {"Vehicle was deleted
Successfully"}}

Note that an error will occur when a vehicle is not found in the list of account vehicles.

6.1.13 UpdateVehicleInstallation [new]


Description: Updates the vehicle unitSysId, licensePlate, fleetNumber, fleetAlias.
Input Parameter: Token (string)
PostBody = VehicleId = 53583 (int),
UnitSysId = 79590470 (int),
ExternalVehicleId =33 (int),
NewUnitSysId = (int),
NewLicensePlate ="" (string),
NewFleetNumber ="" (string),
NewFleetAlias ="" (string),

Server/Vehicle/UpdateVehicleInstallation

Note that one of the parameters (VehicleId, ExternalVehicleId, UnitSysId, LicensePlate) is


required to find the vehicle in the account. Similarly, one of the NewUnitSysId,
NewLicensePlate, NewFleetNumber, or NewFleetAlias parameters is required to update the
vehicle.
HTTP Method: POST
Response: Returns a successfully updated message
{"Version":"1.0.23","StatusCode": 200, "Result”: {"Vehicle was updated Successfully
"}}

Note that an error will occur when a vehicle is not found in the list of account vehicles or
one of the new properties is taken by another vehicle.

Pointer Fleet Client API User Guide Page 31 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.14 Get Vehicles Information [new]

Description The function retrieves the latest dynamic information transmitted by vehicles.

HTTP Method GET

Parameters Key Token (mandatory; string)

Accounts Account(s) IDs (optional, single, or


multiple)

Groups Vehicle group(s) IDs (optional).


Use the GetVehicleGroups function to
retrieve the vehicle group IDs.

LicensePlates / VehicleIds / ExternalIds Vehicle identifiers (optional, single, or


FleetAlias / FleetNumber multiple)

OptionalProps Optional fields parameter (int)


Contact CS for further details.
Value 2 will return the closest CAN bus
uplink.

Usage 1. Executing the function only with the token will retrieve all relevant vehicles
(token-based permission)
2. Executing the function with a token and account ID will retrieve all the
account’s vehicles.
3. Executing the function with group ID (single or multiple), and/or one of the
vehicle identifiers (License Plate, Vehicle ID or External IDs), will retrieve only
the group’s vehicles or specific vehicles.
4. Date and time values will be formatted according to the account time-zone
settings.
5. In case one of the account IDs, group IDs or vehicle identifier does not exist,
the response shall include only the entities which are valid (found).
6. In case there is a CAN bus uplink, and the XML file is missing
1) The XMLId field will display the XML Id as reported by the unit.
2) The CANBusDateTime will display the date/time of the CAN bus uplink
3) The Sensors information will be blank.
7. In case there is no CAN bus uplink in the last hour
1) The XMLId will display the XML Id as reported by the unit.
2) The CANBusDateTime will be null
3) The Sensors information will be null.

Pointer Fleet Client API User Guide Page 32 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

URL Server IP/FleetAPI/api/Vehicle/GetVehiclesInfo?

URL Example FleetAPI/api/Vehicle/GetVehiclesInfo?Accounts=1045&Groups=16580&LicensePlat


es=&VehicleIds=&ExternalIds=&Key=48628420520000041

Response OptionalProps=null
{
"Version": "1.0.30",
"StatusCode": 200,
"Result": {
"5040_Real": [
{
"ExternalId": 0,
“Direction”: -1,
"AccountID": 5040,
"GroupId": 16580,
"AccountName": "1_Daniel",
"UnitID": 50030370,
"LicensePlate": "50030371",
"FleetAlias": "50030372",
"FleetNumber": "50030372",
"FuelType": 1,
"Manufacturer": "Acoplado ",
"Model": "Acoplado",
"Year": 2009,
"VehicleID": 55094,
"LastMessageTime": "6/25/2018 9:12:07 AM",
"LastLocationTime": "6/25/2018 9:12:07 AM",
"Lat": 32.107987,
"Long": 34.96845,
"Address": "HaMelacha 8-20, Rosh HaAyin, Israel",
"Speed": 0,
"Battery": "14.11",
"Ignition": 0,
"DriverName": "Driver 3",
“Odometer”: 49581
},

OptionalProps=2
{
"Version": "1.0.30",
"StatusCode": 200,
"Result": {
"5040_Real": [
{
"ExternalId": 0,
“Direction”: -1,
"AccountID": 5040,
"GroupId": 16580,
"AccountName": "1_Daniel",
"UnitID": 50030370,
"LicensePlate": "50030371",
"FleetAlias": "50030372",
"FleetNumber": "50030372",

Pointer Fleet Client API User Guide Page 33 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

"FuelType": 1,
"Manufacturer": "Acoplado ",
"Model": "Acoplado",
"Year": 2009,
"VehicleID": 55094,
"LastMessageTime": "6/25/2018 9:12:07 AM",
"LastLocationTime": "6/25/2018 9:12:07 AM",
"Lat": 32.107987,
"Long": 34.96845,
"Address": "HaMelacha 8-20, Rosh HaAyin, Israel",
"Speed": 0,
"Battery": "14.11",
"Ignition": 0,
"DriverName": "Driver 3"
“Odometer”: 49581
"SensorsData": {
"XMLId": "2633E423",
"CANBusDateTime": "6/14/2020 9:28:01 AM",
"Sensors": [
{
"Name": "Vehicle speed",
"Value": "10.00",
"Units": "km/hour"
},
{
"Name": "Total odometer",
"Value": "46481.00",
"Units": "km"
},
{
"Name": "Real Ground Speed",
"Value": "277.70",
"Units": "cm/sec"
}
]
}
},

Pointer Fleet Client API User Guide Page 34 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.15 Get Vehicle Route History Information [new]

Description This function retrieves uplink-based information for the specific vehicle, like
the information retrieved when the route history functionality is used in the
web app.

HTTP Method GET

Parameters Key Token (mandatory; string)


StartDate Information start date/time (single,
mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 09:00
EndDate Information range end date/time
(single, mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 10:00
LicensePlate / VehicleID / ExternalID One of the vehicle identifier fields
(single, mandatory)
OptionalProps Optional fields parameter (int)
Contact CS for further details.
Value 2 will return the closest CAN
bus uplink.

Usage 1. When the function is used with a TSP token, no validation is done to
ensure that the vehicle is associated with the token’s account.
2. In case the vehicle identifier is not associated with the token’s account,
an error message (error 1) is displayed.
Error 1 - The requested license plate is not associated with the account.
3. In case the vehicle identifier is not found in the database, an error
message (error 2) shall be presented.
Error 2 - The requested license plate does not exist on the platform.
4. The function shall return only active vehicles.
5. The function will time-out after 5 minutes of operation.
6. Time-Zone – The data shall be adapted according to the account’s time-
zone settings.
7. In case there is a CAN bus uplink, and the XML file is missing.
a. The XMLId field will display the XML Id as reported by the unit.
b. The CANBusDateTime will display the date/time of the CAN bus
uplink.
c. The Sensors information will be blank.
8. In case there is no CAN bus uplink in the last hour
a. The XMLId will display the XML Id as reported by the unit.

Pointer Fleet Client API User Guide Page 35 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

b. The CANBusDateTime will be null


c. The Sensors information will be null.

URL Server IP/FleetAPI/api/Vehicle/GetVehicleRouteHistoryInfo?

URL Example FleetAPI/api/Vehicle/GetVehicleRouteHistoryInfo?key=12266727620000041


&StartDate=2018/06/26 09:00&EndDate=2018/06/26
10:00&LicensePlate=&VehicleId=55094&ExternalId=

Response OptionalProps = 0
{
"Version": "1.0.30",
"StatusCode": 200,
"Result": [
{
"ExternalId": 0,
"DriverId": 37383,
"DateTime": "6/26/2018 9:00:28 AM",
"TxReason": "Timed event",
"Direction": 195,
"AlertName": null,
"Feedback": null,
"GroupId": 16580,
"UnitID": 50030370,
"LicensePlate": "50030371",
"FleetAlias": "50030372",
"FleetNumber": "50030372",
"VehicleID": 55094,
"Lat": 32.008942,
"Long": 34.804458,
"Address": "HaOrgim 23-27, Holon, Israel",
"Speed": 1,
"Battery": "0.00",
"Ignition": 1,
"DriverName": "Driver 3"
}

OptionalProps = 2
{
"ExternalId": 200100,
"DriverId": 37073,
"DateTime": "6/14/2020 9:28:01 AM",
"TxReason": null,
"Direction": -1,
"AlertName": "8080 CAN Trigger Alerts",
"Feedback": null,
"GroupId": 17394,
"UnitID": 50808070,
"LicensePlate": "8080[86-356-34] Vladi",
"FleetAlias": "8080[86-356-34] Vladi",

Pointer Fleet Client API User Guide Page 36 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

"FleetNumber": "8080[86-356-34] Vladi",


"VehicleID": 55378,
"Lat": null,
"Long": null,
"Address": "Jerusalem 33, Kfar Saba, Israel: Bait",
"Speed": 0,
"Battery": "N\\A",
"Ignition": 1,
"DriverName": "",
"SensorsData": {
"XMLId": "2633E423",
"CANBusDateTime": "6/14/2020 9:28:01 AM",
"Sensors": [
{
"Name": "Vehicle speed",
"Value": "10.00",
"Units": "km/hour"
},
{
"Name": "Total odometer",
"Value": "46481.00",
"Units": "km"
},
{
"Name": "Real Ground Speed",
"Value": "277.70",
"Units": "cm/sec"
}
]
}

Pointer Fleet Client API User Guide Page 37 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.16 Get Mobileye Events Information [new]

Description The function retrieves Mobileye events information of a selected vehicle. The
information is parsed according to the vehicle’s XML uploaded to the platform.

HTTP Method GET

Parameters Key Token (mandatory; string)


Start Date Information start date/time (single,
mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 09:00
End Date Information range end date/time (single,
mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 10:00
LicensePlates / VehicleIDs / Vehicle identifiers (Mandatory, one
ExternalIDs of them should be used, single)

Usage 1. When the function is used with a TSP token, no validation is done to ensure
that the vehicle is associated with the token’s account.
2. In case the vehicle identifier is not associated with the token’s account, an
error message (error 1) shall be displayed.
Error 1 - The requested license plate is not associated with the account.
3. In case the vehicle identifier is not found in the database, an error message
(error 2) shall be presented.
Error 2 - The requested license plate doesn't exist on the platform.
4. Time-Zone – The data shall be adapted according to the account’s time-zone
settings.
5. Date and time values will be formatted according to the account time-zone
settings.

URL Server IP/ FleetAPI/api/Vehicle/GetMobileyeEventsInfo?

URL Example FleetAPI/api/Vehicle/GetMobileyeEventsInfo?key=5453781620000041&startDate=


2017/0/722 21:56&endDate=2017/08/22
15:00&licensePlate=&vehicleId=55265&externalId=

Response {
"Version": "1.0.30",
"StatusCode": 200,
"Result": [

Pointer Fleet Client API User Guide Page 38 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

{
"ExternalId": 0,
"DriverId": 38128,
"DateTime": "7/23/2017 9:30:17 AM",
"EventName": "FCW On",
"GroupId": 16915,
"UnitID": 256204470,
"LicensePlate": "2062044 (40-380-38)[SR]",
"FleetAlias": "",
"FleetNumber": "",
"VehicleID": 55265,
"Lat": 32.174777,
"Long": 34.807525,
"Address": "Arieh Ben Eliezer 29-39, Herzliya, Israel",
"DriverName": "Sagit Rahmani",
"Sensors": [
{
"SensorName": "RPM",
"SensorValue": "200"
},
{
"SensorName": "Coolent",
"SensorValue": "29.01"
}
]
},
{
"ExternalId": 0,
"DriverId": 38128,
"DateTime": "7/23/2017 11:29:36 AM",
"EventName": "LDW Left",
"GroupId": 16915,
"UnitID": 256204470,
"LicensePlate": "2062044 (40-380-38)[SR]",
"FleetAlias": "",
"FleetNumber": "",
"VehicleID": 55265,
"Lat": 32.141802,
"Long": 34.801028,
"Address": "Yunitsman, Tel Aviv, Israel",
"DriverName": "Sagit Rahmani",
"Sensors": [
{
"SensorName": "RPM",
"SensorValue": "200"
},
{
"SensorName": "Coolent",
"SensorValue": "29.01"
}
]
},
}
]
}

Pointer Fleet Client API User Guide Page 39 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.17 Get Vehicle Events Activity [new]

Description The function retrieves vehicle’s activity, such as driving time, idling time, and other
information for a specific duration.

HTTP Method GET

Parameters Key Token (mandatory; string)


Account ID Single, mandatory
Group ID Optional (single or multiple)
Start Date Information start date/time (single,
mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 09:00
End Date Information range end date/time (single,
mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 10:00
LicensePlates / VehicleIDs / Vehicle identifiers (Mandatory, one
ExternalIDs of them should be used, single)

Usage 1. In case only token ID and account ID are provided, the function shall return all
of the account’s vehicles information.
2. In case only token ID is provided, the function shall return all the account’s
vehicles information.
3. In case token ID and one or more group ID are provided, the function shall
return the relevant group’s vehicles information.
4. In case token ID, group ID and specific vehicle identifier are provided, the
function shall return information for the specific vehicles.

URL Server IP/FleetAPI/api/Vehicle/GetVehiclesEvents?

URL Example FleetAPI/api/Vehicle/GetVehiclesEvents?key=394101849320000044&AccountId=4


326&Groups=16415&LicensePlates=200200VLADI&VehicleIds=55895&ExternalIds
=&StartDate=2018/06/24 18:00&EndDate=2018/06/25 18:00

Response {
"Version": "1.0.30",
"StatusCode": 200,
"Result": {
"4326_2395": [

Pointer Fleet Client API User Guide Page 40 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

{
"ExternalVehicleId": 200100,
"AccountId": 4326,
"UnitSysId": 50808070,
"VehicleId": 55378,
"LicensePlate": "8080[86-356-34] Vladi",
"FleetAlias": "",
"FleetNumber": "",
"GroupId": 2395,
"StartDate": "6/24/2018 2:00:00 PM",
"EndDate": "6/24/2018 2:00:00 PM",
"DrivingDuration": "00:00:00",
"Distance": 0,
"MaxSpeed": 0,
"StopDuration": "00:15:04",
"IdlingDuration": null,
"Address": "HaMa&apos;apilim 42-58, Herzliya, Israel",
"DriverId": 0,
"DriverName": "Vladi C"
},
{
"ExternalVehicleId": 200100,
"AccountId": 4326,
"UnitSysId": 50808070,
"VehicleId": 55378,
"LicensePlate": "8080[86-356-34] Vladi",
"FleetAlias": "",
"FleetNumber": "",
"GroupId": 2395,
"StartDate": "6/24/2018 2:25:04 PM",
"EndDate": "6/24/2018 2:51:14 PM",
"DrivingDuration": "00:15:70",
"Distance": 16,
"MaxSpeed": 131,
"StopDuration": "00:00:73",
"IdlingDuration": "00:05:17",
"Address": "HaMa&apos;apilim 42-58, Herzliya, Israel",
"DriverId": 0,
"DriverName": "Vladi C"
},
}
}

Pointer Fleet Client API User Guide Page 41 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.18 Get Vehicle Activity Summary [new]

Description The function retrieves activity summary per vehicle, such as driving time, idling
time, average speed, max speed, and other information for a specific time range.

HTTP Method GET

Parameters Key Token (mandatory; string)


Account ID Single, mandatory
Relevant only for TSP token
Group ID Optional (single or multiple)
Start Date Information start date/time (single,
mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 09:00
End Date Information range end date/time (single,
mandatory)
Format: YYYY/MM/DD HH:MM
Example: 2018/06/26 10:00
VehicleIds / LicensePlates / Vehicle identifiers (Mandatory, one
ExternalVehicleIds / VehicleGroupIds of them should be used, single)
DriverIds / DriverNames / Driver identifiers (one of them
ExternalDriverIds / DriverGroupIds should be used when API called by
driver entity type, single or multiple)

Usage 1. The API call be used to retrieve either vehicles or driver’s information. In case
the API is used with both vehicle and driver fields, following error message
should be returned: ‘Only vehicles or drivers can be used in single API call.’
2. Once an entity type is selected, only a single identifier field (Vehicle ID, License
plate, Ext. vehicle ID or Group ID) shall be used. In case multiple identifier
fields are used, the following error message shall be returned: ‘Only a single
entity type field should be used.’
3. In case the account ID parameter is provided, and the token is not TSP token,
the function shall ignore the Account ID parameter and get the Account ID
from the used token.
4. In case the vehicle/driver identifier is not associated with the account (not TSP
account) or doesn’t exists on the platform the following error message shall be
displayed: ‘The requested driver/vehicle doesn't exist on the platform.
5. In case the TSP credentials are used, and License Plate or Driver name are
provided, an Account Id must be specified.

Pointer Fleet Client API User Guide Page 42 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6. In case one of the provided driver/vehicles does not exist on the platform, the
rest of the valid entities are returned, and the missing vehicle/driver are
ignored.

URL Server IP/FleetAPI/api/Vehicle/GetActivitySummaries?

URL Example /FleetAPI/api/Vehicle/GetActivitySummaries?key=


369444130720000043&StartDate=2018-07-03 9:00&EndDate=2018-07-03
18:00&AccountId=4326&VehicleIds=55378,55646

Response {
"Version": "1.0.30",
"StatusCode": 200,
"Result": [
{
"ExternalVehicleId": 0,
"VehicleId": 55646,
"LicensePlate": "2111340",
"GroupId": 16998,
"DriverId": null,
"Distance": 16,
"DrivingDuration": "01:37:20",
"MaxSpeed": 67,
"AvgSpeed": 9,
"IdlingDuration": "01:08:46",
"ParkingDuration": "07:22:40",
"NumbreOfStops": 12
},
{
"ExternalVehicleId": 0,
"VehicleId": 55378,
"LicensePlate": "8080[86-356-34] Vladi",
"GroupId": 2395,
"DriverId": null,
"Distance": 15,
"DrivingDuration": "00:22:13",
"MaxSpeed": 130,
"AvgSpeed": 40,
"IdlingDuration": "00:07:42",
"ParkingDuration": "08:37:47",
"NumbreOfStops": 4
}
]
}

Pointer Fleet Client API User Guide Page 43 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.19 Get Daily Activity Report API [new]

Description The function retrieves daily activity summary that includes total distance driven,
parking duration, idling duration and other information.

HTTP Method GET

Parameters Key Token (mandatory; string)


Account ID Single, mandatory
Relevant only when TSP token is used.
Start Date Information start date (single,
mandatory)
Format: YYYY/MM/DD
Example: 2018/06/26
End Date Information range end date (single,
mandatory)
Format: YYYY/MM/DD
Example: 2018/06/26
VehicleIds / LicensePlates / Vehicle identifiers (Mandatory, one
ExternalVehicleIds / VehicleGroupIds of them should be used, single)
DriverIds / DriverNames / Driver identifiers (one of them
ExternalDriverIds / DriverGroupIds should be used when API called by
driver entity type, single or multiple)

Usage 1. Single entity type (vehicle or driver) shall be used.


In case the API is used with both vehicle and driver fields, the following error
message will be returned:
Only vehicles or drivers can be used in single API call.
2. Once an entity type is selected, only a single identifier field (Vehicle ID, or
License plate, or Ext. vehicle ID or Group ID) shall be used.
In case multiple identifier fields are used, the following error message will be
returned:
Only a single entity type field should be used.
3. In case the account ID parameter is used, and the token is not a TSP token, the
function shall ignore the Account ID parameter and get the Account ID from
the token that was used during the login.
4. In case the vehicle or driver identifier is not associated with the account (and
the token is not a TSP account) or does not exists on the platform the following
error message will be displayed:
The requested driver/vehicle does not exist on the platform.
5. In case a TSP credentials are used, and the License Plate or Driver name are
provided, an Account Id must be specified.

Pointer Fleet Client API User Guide Page 44 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6. In case one of the provided driver/vehicles identifiers does not exist on the
platform, the rest of the valid entities are returned, and the missing
vehicle/driver are ignored.

URL Server IP/FleetAPI/api/Vehicle/GetDailyActivity?

URL Example /FleetAPI/api/Vehicle/GetDailyActivity?key=369444130720000043&StartDate=201


80919&EndDate=20180920&AccountId=4326&VehicleIds=55069,53560

Response {
"Version": "1.0.44.0",
"StatusCode": 200,
"Result": [
{
"ExternalVehicleId": 200100,
"VehicleId": 55378,
"LicensePlate": "8080[86-356-34] Vladi",
"FleetAlias": "",
"FleetNumber": "",
"GroupId": 2395,
"DriverName": null,
"DriverId": null,
"ExternalDriverId": null,
"DateTime": "12/5/2018",
"TotalDistance": 27,
"MaxSpeed": 127,
"AvgSpeed": 41,
"NumbreOfStops": 2,
"NumberOfGeoFences": 5,
"IdlingDuration": "00:06:29",
"ParkingDuration": "23:20:57",
"DrivingDuration": "00:39:03",
"HourMeter": "00:39:03"
}
]
}

Pointer Fleet Client API User Guide Page 45 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.1 Odometer Update


Description The Odometer Update API receives an odometer value and vehicle identifier
(single) and communicates the value in-front of the vehicle.

HTTP Method POST

Parameters Name Type Comments


Key String Mandatory
VehicleIds / String Vehicle identifiers (Mandatory, one
LicensePlates / of them should be used, single)
ExternalVehicleIds

Usage 1. The odometer minimum value can be 0 and maximum 16777215 (km) or
10424878 (ml).
2. The odometer value should be entered according to the account’s
measurement settings, in kilometer for account defined with metric or in miles
for account defined with imperial setting.
3. Successful response indicates that the command was successfully received by
the backend, and not that the command was successfully received by the unit.
4. The backend will start communication attempts with the vehicle to update the
odometer value.
5. The attempts are limited to 10 retries, with an interval of 10 minutes between
each retry.

URL Server IP/FleetAPI/api/Vehicle/OdometerUpdate?

URL Example /FleetAPI/api/Vehicle/OdometerUpdate?key={{Token}}


Body:
{
"VehicleId": "54575",
"OdometerValue": "16777215"
}

Response
{
"Version": "1.0.46.0",
"StatusCode": 200,
"Result": {
"Message": "Odometer value successfully updated"
}
}

Pointer Fleet Client API User Guide Page 46 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

6.1.2 Connect to Maintenance


Description The Connect to Maintenance API enable TSPs to send Connect to Maintenance
command to vehicle(s), and to query the command status.

HTTP Method POST

Parameters Name Type Comments


Key String Mandatory
Type Int Mandatory; Single value
SubType Int Optional; Single value
VehicleIds / String Vehicle identifiers (Mandatory, one
LicensePlates / of them should be used, single or
ExternalVehicleIds multiple values)

Usage 1. The Type parameter accepts the following values.


a. Value = 1 – A Connect to Maintenance command shall be sent.
b. Value = 2 - Query command status.
2. The SubType parameter accepts the following values.
a. Value = 1 – A Connect to Maintenance (AutoCAN) command shall
be sent.
3. The Status field when using value 2 in the Type parameter returns the
following options.
a. 2 – Command is sent.
b. 4 – Vehicle has acknowledged the command.
c. -1 – The command was not acknowledged by the vehicle.
4. In case a command was never sent to the vehicle, and retry number and
response shall return 0, and the date/time shall return a null value.
5. Request payload should be in the following JSON format.
{
“VehicleIds”: “1,2,3,4,5”,
“Type”: “1”,
“SubType”:”1”
}
6. Only one of the vehicle identifiers (VehicleId, LicensePlate or
ExternalVehicleId) should be used.
7. The number of vehicles the API can be used is limited to 5,000 vehicles.
8. API header should be set to Content-Type = application/json

URL Server IP/FleetAPI/api/Vehicle/ConnectToMaintenance?

URL Example /FleetAPI/api/Vehicle/ ConnectToMaintenance?key=369444130720000043

Pointer Fleet Client API User Guide Page 47 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

JSON request payload:


{
“VehicleIds” or ”LicensePlates” or ”ExternalVehicleIds”: “1,2,3,4,5”
“Type”: 2
}

Response Type = 1
{
"Version": "1.0.52.0",
"StatusCode": 200,
"Result": {
"Message": "Command sent successfully for all vehicles which belong to the
account",
"Error": "Vehicle/s 3,4,5 is/are not associated with your account."
}
}

Type = 2
{
"Version": "1.0.52.0",
"StatusCode": 200,
"Result": {
"VehicleStatuses": [
{
"Vehicle": "1",
"StatusDate": "1/10/2020 6:00:22 PM",
"Status": 2,
"NumOfTries": 1
},
{
"Vehicle": "2",
"StatusDate": "1/10/2020 6:00:22 PM",
"Status": 2,
"NumOfTries": 1
}
],
"Error": "Vehicle/s 3,4,5 is/are not associated with your account"
}
}

Pointer Fleet Client API User Guide Page 48 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

7 Vehicle Groups Management


This section includes vehicle group functions available with the API.

7.1.1 CreateGroup [new]


Description: Creates a new vehicle group.
Input Parameter: TokenId (string)
PostBody = {Name: "groupName", Description: "groupDescription"}
Server/Vehicle/CreateGroup

HTTP Method: POST


Response: Returns the groupid of the new group
{"Version":"1.0.18","StatusCode":200,"Result":{"GroupId":"17014"}}

7.1.2 DeleteGroup [new]


Description: Deletes a vehicle group.
Input Parameter: TokenId (string)
PostBody = {Id: 33333}
Server/Vehicle/DeleteGroup

HTTP Method: POST


Response: Returns a deleted successfully message
{"Version":"1.0.18","StatusCode":200,"Result":{"Message":"Deleted
Successfully"}}

7.1.3 AssignVehiclesToSubAccount [new]


Description: Assigns vehicles to a sub account.
Input Parameters TokenId (string)
PostBody = {SubAccountId =4234, LicensePlates ="plate1","plate2"}

Server/Vehicle/AssignVehiclesToSubAccount

HTTP Method: POST


Response: Returns a successfully assigned message
{"Version":"1.0.18","StatusCode":200,"Result":{"Message":"Assign Successfully"}}

Pointer Fleet Client API User Guide Page 49 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

7.1.4 AssignVehiclesToGroup [new]


Description: Assigns vehicles to a group.
Input Parameter: TokenId (string)
PostBody = {GroupId =4234, LicensePlates ="plate1","plate2"}

Server/Vehicle/AssignVehiclesToGroup

HTTP Method: POST


Response: Returns a successfully assigned message
{"Version":"1.0.18","StatusCode":200,"Result":{"Message":"Assign Successfully"}}

Pointer Fleet Client API User Guide Page 50 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8 Tasks Management
8.1 Task / Route
To start working with tasks or routes, you need to perform the following steps:
1. Create a task (using the Add New Task function (if this is your initial interaction with
the Pointer Fleet API), or Get Task function, as described in detail in section 8.3 below)
2. Assign the task to a driver or vehicle. Of course, if you want to assign the task to a
driver/vehicle, the specific driver/vehicle also must exist in the system or to be created
using the relevant function. In addition, you will have to refer to the Lookup Table to
extract the relevant IDs you will need for Type ID, Vehicle ID and so on.
3. Monitor task status changes.
Please note that per your account settings, task or route status can be changed
automatically (meaning the Arrived & Done states) by the system per the driver or vehicle
location.

8.2 Task / Route State-Machines


The following drawing details the various states that are utilized by a task or a route and
the possible connections from one state to another.
The drawing details which entity can switch a task from one state to another and what is
the action it needs to perform or select. For example, to switch a task state from Assigned
to Sent, the user entity (fleet manager) needs to select a specific task and associate it to
a specific driver. Then, if the driver is acknowledging the task, the task state will be
changed to Accepted.
User refers to the fleet manager, Driver refers to the driver or field employee, while
System refers to an automated process that switches the task or route state without the
fleet manager’s intervention.

Pointer Fleet Client API User Guide Page 51 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3 Tasks
8.3.1 GetTasks [new]
Description: Gets a list of task data associated to the current account and user.
Input Parameters: Token (string)
http://localhost/FleetAPI/api/Route/GetTasks?key=561700592620000043

Output Objects:
List of task objects, as listed in the GetTaskData method
Return Example:
{"Version":"1.0.0.0","StatusCode":200,"Result":{"Tasks":[{"Id":21456,"Status":106,"N
ame":"Kfar Blum 01","Lat":33.1731921,"Long":35.6032562,"Address":" 9778, Kfar Blum,
Israel ","DueDate":"2016-03-
21T03:08:39","EstimatedWorkTime":10},{"Id":21457,"Status":10,"Name":"Haifa
01","Lat":32.7849655,"Long":34.9804688,"Address":" Harofe Zlochisti 22-28, Haifa,
Israel ","DueDate":"2016-03-
21T04:47:43","EstimatedWorkTime":15},{"Id":21458,"Status":10,"Name":"Natanya
01","Lat":32.3126701,"Long":34.8431396,"Address":" Israel National Trail, Netanya,

Pointer Fleet Client API User Guide Page 52 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

Israel ","DueDate":"2016-03-
21T06:04:09","EstimatedWorkTime":20},{"Id":21459,"Status":10,"Name":"Tel Aviv
01","Lat":32.081411,"Long":34.7799683,"Address":" Malkhei Yisra'el St, Tel Aviv-
Yafo, Israel ","DueDate":"2016-03-
21T07:24:38","EstimatedWorkTime":17},{"Id":21460,"Status":100,"Name":"Beer Sheva
01","Lat":31.2550742,"Long":34.788208,"Address":" Yehuda Halevi St 104, Be'er Sheva,
Israel ","DueDate":"2016-03-
21T15:00:00","EstimatedWorkTime":10},{"Id":21461,"Status":9,"Name":"Mizpe
Ramon","Lat":30.6142774,"Long":34.8074341,"Address":" 40, Mitzpe Ramon, Israel
","DueDate":"2016-03-
21T15:30:00","EstimatedWorkTime":15},{"Id":21462,"Status":9,"Name":"Eilat
01","Lat":29.5710683,"Long":34.9530029,"Address":" Sderot Sheshet HaYamim 41, Eilat,
Israel ","DueDate":"2016-03-
21T15:30:00","EstimatedWorkTime":15},{"Id":21463,"Status":9,"Name":"test
01","Lat":31.956823,"Long":34.7799683,"Address":" 431, Rishon LeTsiyon, Israel
","DueDate":"2016-03-
24T12:00:00","EstimatedWorkTime":10},{"Id":21464,"Status":9,"Name":"test
02","Lat":31.2421595,"Long":34.7950745,"Address":" David Hacham Blvd, Be'er Sheva,
Israel ","DueDate":"2016-03-
24T13:30:00","EstimatedWorkTime":0},{"Id":21465,"Status":100,"Name":"Tiberias","Lat"
:32.8242111,"Long":35.5682373,"Address":" 90, Tiberias, Israel ","DueDate":"2016-
03-28T16:41:31","EstimatedWorkTime":12},{"Id":21466,"Status":10,"Name":"Sde
Boker","Lat":30.8621526,"Long":34.7964478,"Address":" Unnamed Road, Israel
","DueDate":"2016-03-
28T16:41:31","EstimatedWorkTime":15},{"Id":21467,"Status":106,"Name":"test
105","Lat":31.2492041,"Long":34.7937012,"Address":" Brenner St 13, Be'er Sheva,
Israel Israel","DueDate":"2016-03-
29T06:28:42","EstimatedWorkTime":10},{"Id":21468,"Status":9,"Name":"test
106","Lat":31.7912207,"Long":35.2111816,"Address":" Harav Moshe Zev Feldman St,
Jerusalem, Israel Israel","DueDate":"2016-03-
29T22:30:00","EstimatedWorkTime":0},{"Id":21469,"Status":9,"Name":"test
107","Lat":32.0686107,"Long":34.7689819,"Address":" Carmel Market, Tel Aviv-Yafo
Israel","DueDate":"2016-03-29T23:00:00","EstimatedWorkTime":10}]}}

8.3.2 GetTask
XML Parameters: Token, TaskInfo (Object)
http://localhost/TasksAPI/Service/TasksService.svc/GetTask?xml=

XML String Structure


<GetTask>
<Token></Token>
<TaskInfo>
<Id></Id>
<ExternalId></ExternalId>
</TaskInfo>
</GetTask>

Success Return Value: TaskInfo


Mandatory fields: Token, Id or ExternalId

Pointer Fleet Client API User Guide Page 53 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3.3 AddNewTask
XML Parameters: Token, TaskInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AddNewTask?xml=

XML String Structure


<AddNewTask>
<Token></Token>
<TaskInfo>
<TemplateId></TemplateId
<Name></Name>
<ExternalId></ExternalId>
<Message></Message>
<TypeId></TypeId>
<Enabled></Enabled>
<DriverId></DriverId>
<VehicleId></VehicleId>
<Country></Country>
<State></State>
<City></City>
<Street></Street>
<AddressDetails></AddressDetails>
<Lat></Lat>
<Long></Long>
<PointId></PointId>
<LocationIndex></LocationIndex>
<IconId></IconId>
<Comment></Comment>
<EstimateWorkTime></EstimateWorkTime>
<ContactPerson></ContactPerson>
<ContactPosition></ContactPosition>
<OfficePhone></OfficePhone>
<CellPhone></CellPhone>
<Status></Status>
<Medium></Medium>
<ExecutionDate></ExecutionDate>
<ArrivalTime></ArrivalTime>
</TaskInfo>
</AddNewTask>

Success Return Value: TaskId (int)


Mandatory fields: Token, Name

Pointer Fleet Client API User Guide Page 54 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3.4 EditExistingTask
XML Parameters: Token, TaskInfo (Object)
http://localhost/TasksAPI/Service/TasksService.svchttp://localhost/FleetAPI/
Fleet.API.FleetAPIService.svc/EditExistingTask?xml=

XML String Structure


<EditExistingTask>
<Token></Token>
<TaskInfo>
<TemplateId></TemplateId>
<Id></Id>
<Name></Name>
<ExternalId></ExternalId>
<Message></Message>
<TypeId></TypeId>
<Enabled></Enabled>
<DriverId></DriverId>
<VehicleId></VehicleId>
<Country></Country>
<State></State>
<City></City>
<Street></Street>
<AddressDetails></AddressDetails>
<Lat></Lat>
<Long></Long>
<PointId></PointId>
<LocationIndex></LocationIndex>
<IconId></IconId>
<Comment></Comment>
<EstimateWorkTime></EstimateWorkTime>
<ContactPerson></ContactPerson>
<ContactPosition></ContactPositio>
<OfficePhone></OfficePhone>
<CellPhone></CellPhone>
<Status></Status>
<Medium></Medium>
<ExecutionDate></ExecutionDate>
<ArrivalTime></ArrivalTime>
</TaskInfo>
</EditExistingTask>

Success Return Value: True / False


Mandatory fields: Token, Id or ExternalId

Pointer Fleet Client API User Guide Page 55 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3.5 GetTaskStatuses [new]


Description: Gets a list of task statuses (LookupTable)
Input Parameter: Token (string)
http://localhost/FleetAPI/api/Route/GetTaskStatuses?key=561700592620000043

Output Objects:
TaskStatuses: (List of Id Name objects)
Id: task status id (int)
Name: task status description (string)
Return Example:
{"Version":"1.0.0.0","StatusCode":200,"Result":{"TaskStatuses":[{"Id":0,"Nam
e":"Disabled"},{"Id":1,"Name":"Enabled"},{"Id":8,"Name":"Rejected"},{"Id":9,
"Name":"Assigned"},{"Id":10,"Name":"Sent"},{"Id":11,"Name":"Accepted"},{"Id"
:100,"Name":"Active"},{"Id":101,"Name":"Done"},{"Id":102,"Name":"Skipped"},{
"Id":103,"Name":"Arrived"},{"Id":105,"Name":"Active,delayed"},{"Id":106,"Nam
e":"Active late"},{"Id":107,"Name":"Arrived*"},{"Id":108,"Name":"Done*"}]}}

8.3.6 GetTaskStatus
XML Parameters: Token, TaskInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetTaskStatus?xml=

XML String Structure


<GetTaskStatus>
<Token></Token>
<TaskInfo>
<Id></Id>
<ExternalId></ExternalId>
</TaskInfo>
</GetTaskStatus>

Success Return Value: TaskStatus


Mandatory fields: Token, Id or ExternalId

Pointer Fleet Client API User Guide Page 56 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3.7 GetTaskData [new]


Description: Gets specific task data by task ID.
Input Parameters: Task id (int), Token (string)
http://localhost/FleetAPI/api/Route/GetTaskData?taskId=21456&key=56170059262
0000043

Output Objects:
Id: task id (int)
Name task name (string)
StatusId: task status id (int), see GetTaskStatuses method (page 86)
TaypeId: task type id (int), see GetTaskTypes method (page 86)
DueDate: task due date (datetime: yyyy:mm:dd HH:MM)
Lat: Latitude (decimal)
Long: Longitude (decimal)
Address: task address (string)
EstimatedWorkTime: task estimated work time (int: minutes)
MediumId: task medium id (int), see GetTaskMediums method (page 86)
DriverId: assigned driver id (int), see GetDrivers method (page 86)
VehicleId: assigned vehicle id (int), see GetVehicles method (page 86)
AccountId: assigned account id (int), see GetAccounts method (page 86)
Street: street (string)
City: city (string)
StateId: state id (int) (Contact your account administrator for a list of your country
states)
CountryId: country id (int) (As per StateId)
Message: task message (string)
Return Example:
{"Version":"1.0.0.0","StatusCode":200,"Result":{"Task":{"Id":21456,"Status":
1,"Name":"Kfar Blum 01","Lat":33.1731921,"Long":35.6032562,"Address":"9778,
Kfar Blum, Israel","DueDate":"2016-03-21T03:08:39","EstimatedWorkTime":10}}}

Pointer Fleet Client API User Guide Page 57 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3.8 DeleteExistingTask
XML Parameters: Token, TaskInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/DeleteExistingTask?xml=

XML String Structure


<DeleteExistingTask>
<Token></Token>
<TaskInfo>
<Id></Id>
<ExternalId></ExternalId>
</TaskInfo>
</DeleteExistingTask>

Success Return Value: True / False


Mandatory fields: Token, Id or ExternalId

8.3.9 AssignTask
XML Parameters: Token, AssignInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AssignTask?xml=

XML String Structure


<AssignTask>
<Token></Token>
<AssignInfo>
<TaskId></TaskId>
<ExternalId></ExternalId>
<DriverId></DriverId>
<VehicleId></VehicleId>
</AssignInfo>
</AssignTask>

Success Return Value: AssignInfo


Mandatory fields: Token, TaskId or ExternalId, DriverId or VehicleId

8.3.10 GetTaskTypes [new]


Description: Gets a list of task types (lookup table).
Input Parameter: Token (string)
http://localhost/FleetAPI/api/Route/GetTaskTypes?key=561700592620000043

Output Objects:
Id: task type id (int)
Name: task type description (string)

Pointer Fleet Client API User Guide Page 58 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.3.11 GetTaskType
XML Parameters: Token, TaskType (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetTaskType?xml=

XML String Structure


<GetTaskType>
<Token></Token>
<TaskType>
<TaskTypeId></TaskTypeId>
<Name></Name>
</TaskType>
</GetTaskType>

Success Return Value: TaskType


Mandatory fields: Token, TaskTypeId or Name

8.3.12 GetTaskMediums [new]


Description: Gets a list of task types (lookup table).
Input Parameter: Token (string)
http://localhost/FleetAPI/api/Route/GetTaskMediums?key=561700592620000043

Output Objects:
Id: task medium id (int)
Name: task medium description (string)

Pointer Fleet Client API User Guide Page 59 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.4 Routes
Working with Route functions is almost identical to working with the Task functions,
however the Route runctions need 1 or more tasks that have not been assigned or
already started in order to call correctly.

The following diagram illustrates the general route workflow.

Functions available for routes include Add New Route, Edit Existing Route, Delete Existing
Route, Add Tasks To Route, Remove Task from Route, Get Route Status, Update Route
Status, Assign Route, and Get Route.

Pointer Fleet Client API User Guide Page 60 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.4.1 AddNewTask
XML Parameters: Token, TaskInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AddNewTask?xml=

XML String Structure


<AddNewTask>
<Token></Token>
<TaskInfo>
<TemplateId></TemplateId
<Name></Name>
<ExternalId></ExternalId>
<Message></Message>
<TypeId></TypeId>
<Enabled></Enabled>
<DriverId></DriverId>
<VehicleId></VehicleId>
<Country></Country>
<State></State>
<City></City>
<Street></Street>
<AddressDetails></AddressDetails>
<Lat></Lat>
<Long></Long>
<PointId></PointId>
<LocationIndex></LocationIndex>
<IconId></IconId>
<Comment></Comment>
<EstimateWorkTime></EstimateWorkTime>
<ContactPerson></ContactPerson>
<ContactPosition></ContactPosition>
<OfficePhone></OfficePhone>
<CellPhone></CellPhone>
<Status></Status>
<Medium></Medium>
<ExecutionDate></ExecutionDate>
<ArrivalTime></ArrivalTime>
</TaskInfo>
</AddNewTask>

Success Return Value: TaskId (int)


Mandatory fields: Token, Name

Pointer Fleet Client API User Guide Page 61 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.4.2 EditExistingRoute
XML Parameters: Token (string), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/EditExistingRoute?xml=

XML String Structure


<EditExistingRoute>
<Token></Token>
<RouteInfo>
<Id></Id>
<ExternalId></ExternalId>
<Name></Name>
</RouteInfo>
</EditExistingRoute>

Success Return Value: True / False


Mandatory fields: Token, Id or ExternalId

8.4.3 GetRouteStatuses [new]


Description: Gets a list of task mediums (LookupTable).
Input Parameters: Token (string)
http://localhost/FleetAPI/api/Route/GetRouteStatuses?key=561700592620000043

Output Objects:

Id: route status id (int)


Name: route status description (string)
Return Example:
{"Version":"1.0.0.0","StatusCode":200,"Result":{"RouteStatuses":[{"Id":1008,"Na
me":"UnAssigned"},{"Id":1009,"Name":"Assigned"},{"Id":1010,"Name":"Pending
Sent"},{"Id":1011,"Name":"Accepted"},{"Id":1100,"Name":"In
Process"},{"Id":1101,"Name":"In Process Delayed"},{"Id":1102,"Name":"In
process-
Pending"},{"Id":1103,"Name":"Finished"},{"Id":1104,"Name":"Ended"},{"Id":1105,"
Name":"Arrived"},{"Id":1106,"Name":"Rejected"},{"Id":1107,"Name":"Deleted"}]}}

Pointer Fleet Client API User Guide Page 62 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.4.4 GetRouteData [new]


Description: Gets specific route data by route IDs, including the assigned tasks.
Input Parameters: Route id (int), Token (string)
http://localhost/FleetAPI/api/Route/GetRouteData?routeId=212&key=56170059262
00000432

Output Objects:
Id: route id (int)
Name route name (string)
StatusId: route status id (int), see GetRouteStatuses method (page 86)
DueDate: route due date (datetime: yyyy:mm:dd HH:MM)
UserId: user id (int)
DriverId: assigned driver id (int)
VehicleId: assigned vehicle id (int)
DynamicSchedule: is dynamic (int)
Message: route message (string)
Tasks: List of Task objects associate to the current route (see the following
GetTaskData method)
Return Example:
{"Version":"1.0.0.0","StatusCode":200,"Result":{"Route":{"Id":212,"Name":"Dynamic
Route 01","Status":1102,"DueDate":"2016-03-
21T00:00:00","UserId":3939,"DriverId":0,"VehicleId":40020,"DynamicSchedule":1,"Ta
sks":[{"Id":21456,"Status":106,"Name":"Kfar Blum 01","Order":1,"DueDate":"2016-
03-21T03:08:39"},{"Id":21457,"Status":10,"Name":"Haifa
01","Order":2,"DueDate":"2016-03-
21T04:47:43"},{"Id":21458,"Status":10,"Name":"Natanya
01","Order":3,"DueDate":"2016-03-
21T06:04:09"},{"Id":21459,"Status":10,"Name":"Tel Aviv
01","Order":4,"DueDate":"2016-03-21T07:24:38"}]}}}

8.4.5 UpdateRouteStatus
XML Parameters: Token (string), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/UpdateRouteStatus?xml=

XML String Structure


<UpdateRouteStatus>
<Token></Token>
<RouteInfo>
<Id></Id>
<ExternalId></ExternalId>
<Status></Status>
</RouteInfo>
</UpdateRouteStatus>

Success Return Value: True / False


Pointer Fleet Client API User Guide Page 63 of 92
Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

Mandatory fields: Token, Id or ExternalId, Status (RouteInfo tag)

8.4.6 DeleteExistingRoute
XML Parameters: Token (string), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/DeleteExistingRoute?xml=

XML String Structure


<DeleteExistingRoute>
<Token></Token>
<RouteInfo>
<Id></Id>
<ExternalId></ExternalId>
</RouteInfo>
</DeleteExistingRoute>

Success Return Value: True / False


Mandatory fields: Token, Id or ExternalId

8.4.7 AddTasksToRoute
XML Parameters: Token (string), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AddTasksToRoute?xml=

XML String Structure


<AddTaskToRoute>
<Token></Token>
<RouteInfo>
<Id></Id>
<ExternalId></ExternalId>

<Tasks>
<Task>
<Id></Id>
<Order></Order>

</Task>

</Tasks>
</RouteInfo>
</AddTaskToRoute>

Success Return Value: True / False


Mandatory fields: Token, Id or ExternalId (RouteInfo tag), Id & Order (Task tag)

Pointer Fleet Client API User Guide Page 64 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.4.8 RemoveTaskFromRoute
XML Parameters: Token (string), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/RemoveTasksFromRoute?xml=

XML String Structure


<RemoveTaskFromRoute>
<Token></Token>
<RouteInfo>
<ExternalId></ExternalId>
<Id></Id>
<Tasks>
<Task>
<Id></Id
</Task>

</Tasks>
</RouteInfo>
</RemoveTaskFromRoute>

Success Return Value: True / False


Mandatory fields: Token, Id or ExternalId (RouteInfo tag), Id (Task tag)

8.4.9 AssignRoute
XML Parameters: Token (string), AssignRouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/UpdateRouteStatus?xml=

XML String Structure


<AssignRoute>
<Token></Token>
<AssignRouteInfo>
<RouteIds></RouteIds>
<ExternalIds></ExternalIds>
<DriverId></DriverId>
<VehicleId></VehicleId
<UnAssign></UnAssign>
</AssignRouteInfo>
</AssignRoute>

Success Return Value: AssignRouteInfo


Mandatory fields: Token, RouteIds or ExternalIds, DriverId or VehicleId

Pointer Fleet Client API User Guide Page 65 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.4.10 GetRoute [new]


Description: Gets a list of route data associated to the current account and user.
Input Parameter: Token (string)
http://localhost/FleetAPI/api/Route/GetRoutes?key=561700592620000043

Return Example:
{"Version":"1.0.0.0","StatusCode":200,"Result":{"Routes":[{"Id":212,"Name":"
Dynamic Route 01","Status":1102,"DueDate":"2016-03-
21T00:00:00","UserId":3939,"AccountId":4344,"VehicleId":40020,"DynamicSchedu
le":1},{"Id":213,"Name":"Dynamic Schdule 02","Status":1100,"DueDate":"2016-
03-
21T00:00:00","UserId":3939,"AccountId":4344,"VehicleId":40020,"DynamicSchedu
le":1},{"Id":214,"Name":"route test 01","Status":1009,"DueDate":"2016-03-
24T00:00:00","UserId":3939,"AccountId":4344,"VehicleId":40020},{"Id":215,"Na
me":"route test 05","Status":1102,"DueDate":"2016-03-
28T00:00:00","UserId":3939,"AccountId":4344,"VehicleId":40020,"DynamicSchedu
le":1},{"Id":216,"Name":"test 105","Status":1100,"DueDate":"2016-03-
29T00:00:00","UserId":3939,"AccountId":4344,"VehicleId":40020,"DynamicSchedu
le":1}]}}

8.4.11 AddNewRoute
XML Parameters: Token (string), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/AddNewRoute?xml=

XML String Structure


<AddNewRoute>
<Token></Token>
<RouteInfo>
<Name></Name>
<ExternalId></ExternalId>
<Tasks>
<Task> <Id></Id>
<Order></Order>
</Task>

</Tasks>
</RouteInfo>
</AddNewRoute>

Success Return Value: RouteId (int)


Mandatory fields: Token, Name

Pointer Fleet Client API User Guide Page 66 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.4.12 GetRouteStatus
XML Parameters: Token (string), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetRouteStatus?xml=

XML String Structure


<GetRouteStatus>
<Token></Token>
<RouteInfo>
<Id></Id>
<ExternalId></ExternalId>
</RouteInfo>
</GetRouteStatus>

Success Return Value: Status


Mandatory fields: Token, Id or ExternalId

8.4.13 GetRoute
Gets a list of route data associated to the current account and user
XML Parameters: Token (string)), RouteInfo (Object)
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetRoute?xml=

XML String Structure


<GetRoute>
<Token></Token>
<RouteInfo>
<Id></Id>)
<ExternalId></ExternalId>
</RouteInfo>
</GetRoute>

Success Return Value: RouteInfo


Mandatory fields: Token, Id or ExternalId

Pointer Fleet Client API User Guide Page 67 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

8.5 Proof-of-Work
8.5.1 Get Tasks Details
Description The GetTasksDetails API receives a list of task’s ids and returns a URL per each
image associated with the tasks, with its metadata information.
The GetTasks API above can be utilized to retrieve a list of task ids.

HTTP Method GET

Parameters Name Type Comments


Certificate String Mandatory
Taskids String Mandatory

Usage 1. The image URL returned in the API contains a Shared Access Signature (SAS)
that is valid for 60 min with a read-only permission.
2. In case the image cannot be found in the Azure Blob Storage, the following
message will be displayed in the place of the image URL:
Cannot find a corresponding Image.
3. The format for ImageTakenDatetime is according to the account’s selected
language.
4. In case some of the provided task Ids doesn’t exist on the platform/account,
the rest of the valid entities are returned, and the missing tasks are not
displayed. In case all the task ids provided don’t exist, an empty list will be
returned.

URL Server IP/Fleet/DocumentHandling/GetTasksDetails?

URL Example Server


IP/Fleet/DocumentHandling/GetTasksDetails?Certificate=123&TaskIds=10,12

Response {
"Error": null,
"TokenId": 0,
"ReturnValue": 0,
"ResultValue": false,
"IsSucceded": true,
"ResultObject": [
{
"TaskId": 10,
"TaskDetails": [
{
"DriverId": 36964,

Pointer Fleet Client API User Guide Page 68 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

"ImageUrl":
"https://pointerdevstorageaccount.blob.core.windows.net/devdrivermobile/2019/4317/1
0_33ffd82c-e10c-45c5-8cd2-52b94e066f51.PNG?sv=2018-03-
28&sr=b&sig=K2Lw1p7lADQ6D%2BxKD8d4PM8%2FRM2EnAAJDxfdOpuUFCY%3D&st=2019
-01-08T15%3A29%3A55Z&se=2019-01-08T15%3A39%3A55Z&sp=r",
"LicensePlate": "sk123ab",
"ImageTakenDatetime": "11/22/2018 3:54:22 PM",
"ImageLatitude": 41.992684,
"ImageLongitude": 21.421112,
"UploadLatitude": 41.992685,
"UploadLongitude": 21.421112,
"ImageDescription": "Lorem ipsum dolor sit amet, consectetur adipiscing elit,
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua."
},
{
"DriverId": 36964,
"ImageUrl":
"https://pointerdevstorageaccount.blob.core.windows.net/devdrivermobile/2019/4317/1
0_74098646-e3e0-43ab-bd19-763f6f9094af.png?sv=2018-03-
28&sr=b&sig=5RW9Q4KtEWD5OWNVzn2hLh%2FHUy1%2FFL7dImyAgzIgkbM%3D&st=2019
-01-08T15%3A29%3A55Z&se=2019-01-08T15%3A39%3A55Z&sp=r",
"LicensePlate": "sk123ab",
"ImageTakenDatetime": "11/22/2018 3:54:22 PM",
"ImageLatitude": 41.992684,
"ImageLongitude": 21.421112,
"UploadLatitude": 41.992685,
"UploadLongitude": 21.421112,
"ImageDescription": "Lorem ipsum dolor sit amet, consectetur adipiscing elit,
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua."
}
]
}
],
"Params": null
}

Pointer Fleet Client API User Guide Page 69 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9 Speed Limits APIs [Safety360]

9.1.1 Get Account’s License Plates


Description The function retrieves all the account’s vehicles.

HTTP Method GET

Parameters Name Type Comments


Token String Mandatory
Props Optional, the vehicle properties to return
By default, returns id, licensePlate.
Possible values:
• Id
• LicensePlate
• UnitId
• Alias
• Driver
• GroupId
• GPSDateTime

Usage

URL Server IP/fleetcore.api/api/360/Vehicles

URL Example Server IP/fleetcore.api/api/360/vehicles?props=Driver

Response {
"data":[
{"Id": 54924, "LicensePlate": "422"},
{"Id": 55920, "LicensePlate": "582-ABC"},
{"Id": 55921,"LicensePlate": "GF-583"},
{"Id": 55922,"LicensePlate": "ER-584"},
{"Id": 55923,"LicensePlate": "EW-585"},
{"Id": 55924,"LicensePlate": "586"},
{"Id": 55925,"LicensePlate": "587"},
{"Id": 55926,"LicensePlate": "588"},
{"Id": 55927,"LicensePlate": "589"}
],
"isSucceded": true
}

Pointer Fleet Client API User Guide Page 70 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.2 Get Account’s Drivers


Description The function lists the account drivers.

HTTP Method GET

Parameters Name Type Comments


Token String Mandatory
Props Optional, the driver properties to return
By default, returns id, Name.
Possible values:
• Id
• Name
• AccountId
• GroupId
• Code

URL Server IP/fleetcore.api/api/360/drivers

URL Example curl -X GET "http://62.0.95.30/fleetcore.api/api/360/drivers" -H "accept:


application/json" -H "Authorization: bearer
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJBY2NvdW50SWQiOiI0MzI2IiwiVXNl
cklkIjoiMzkyMiIsIlVzZXJUeXBlIjoiMiIsIkxhbmdJZCI6IjAiLCJQZXJtaXNzaW9ucyI
6IjQyNjAzNjMyNjMiLCJOYW1lIjoiX1ZsYWRpIiwiVXNlck5hbWUiOiJ2bGFkaSIsIlR
pbWVab25lIjoiMiIsIkNsaWVudElkIjoiMzEyMzgwNyIsImp0aSI6ImUwYjFiZDlkLT
kwMTktNDMxYy1hYjNhLTg3ZDM0YjQzNGE5MyIsImV4cCI6MTU0NzE0NjczNSwi
aXNzIjoiUG9pbnRlci5TZWN1cml0eS5CZWFyZXIiLCJhdWQiOiJQb2ludGVyLlNlY3
VyaXR5LkJlYXJlciJ9.fecEpECDcjCTwClC6rzd4vccasp4NHvbeSH1eZlDK-Y"

Response {
"data": [
{
"Id": 37251,
"Name": "Art Garfunkel"
},
{
"Id": 38281,
"Name": "ASDFFGH ASDGFGH"
},
],
"isSucceded": true
}

Pointer Fleet Client API User Guide Page 71 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.3 Get Account’s License Plates/Drivers Over-Speeding Events


Description The function retrieves the account's RSS Safety over-speeding events.
Results set can be filtered by event type, event severity, license plates or
driverId's.

HTTP Method GET

Parameters Name Type Comments


Token String Mandatory
StartDate Mandatory
Format: YYYY/MM/DD Example:
2018/06/26
EndDate Mandatory
Format: YYYY/MM/DD Example:
2018/06/26
LicensePlates Comma
separated string
DriverIds Comma
separated string
RoutLimitType Optional rss, custom
EventSeverity Optional 0,1,2

Usage 1. The results can be filtered by event type, event severity, license plate or
driver id.

URL Server IP/fleetcore.api/api/360/ safety/rssevents

URL Example Server IP/fleetcore.api/api/360/


safety/rssevents?StartDate=2018/11/18&EndDate=2018/11/19T15:03:56&Driv
erIds=37073

Response {
"data":[
{"licensePlate":"8080[86-356-34]
Vladi","driverId":37073,"driverName":"Vladi
C","unitId":50808070,"startTime":"2018-11-
18T19:58:15+02:00","address":"Shaldag 222, Hagor,
Israel","routLimitType":"RSS","speedLimit":76,"actualSpeed":94,"severity":1,"
lat":32.131258,"lng":34.938835},
{"licensePlate":"8080[86-356-34]
Vladi","driverId":37073,"driverName":"Vladi
C","unitId":50808070,"startTime":"2018-11-

Pointer Fleet Client API User Guide Page 72 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

19T10:22:07+02:00","address":"5050, 48000 ‫ ישראל‬,‫ראש העין‬: Park Afek Kafr


Qasim","routLimitType":"RSS","speedLimit":60,"actualSpeed":107,"severity":
3,"lat":32.107073,"lng":34.962078}],
"isSucceded":true}

9.1.4 Get Accounts Dashboard Data


Description The function retrieves account’s summary of overspending events.

HTTP Method GET

Parameters Name Type Comments


Token String Mandatory
StartDate Mandatory
Format: YYYY/MM/DD Example:
2018/06/26
EndDate Mandatory
Format: YYYY/MM/DD Example:
2018/06/26

URL Server IP/fleetcore.api/api/360/safety/eventCount

URL Example Server IP/fleetcore.api/api/360/safety/eventCount?StartDate=2011-11-


19T12:59:27.001Z&EndDate=2018-11-19T12:59:27.001Z

Response {"data":{"low":404,"medium":297,"high":504,"total":1205},"isSucceded":tru
e}

Pointer Fleet Client API User Guide Page 73 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.5 Get User Details


Description The function retrieves the list of users associated with the account of the user
who sent the request.

HTTP Method GET

Parameters Name Type Comments


Token String Mandatory
Key Description
• Props (optional; string)
Comma-separated names of resulting
objects fields. If omitted, result object
will contain all of them.
Possible values:
• AccountId
• AccountName
• UserId
• ExternalUserId
• Name
• CustomPermissions
• Email

Usage 1. The function can be used with credentials of parent account, and sub-
account.
2. The list of drivers will be according to the credentials supplied.
3. For incorrect requests, the result object will contain `isSucceded` field
with value of `false`, and `error` object field with according `code` and
`message` fields inside.
Example call for `/api/360/account/users?Props=foo`, will result in:
{
"isSucceded": false,
"error": {
"code": 0,
"message": "property foo is not valid "
}
}
4. If the Props parameter is used, it must contain a comma-separated list of
field names to be included in resulting objects.
Example call for
`/api/360/account/users?Props=UserId,Name,CustomPermissions,Email`,
will result in:
{
"data": [
{
"UserId": 3919,
"Name": "Joe Doe",
"CustomPermissions": "isSafetyOfficer",
"Email": "[email protected]"
},

Pointer Fleet Client API User Guide Page 74 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

{
"UserId": 4167,
"Name": "Jane Jackson",
"CustomPermissions": "isSafetyOfficer",
"Email": "[email protected]"
}
],
"isSucceded": true
}
5. Request `/api/360/account/users `, will result in:
{
"data": [
{
"AccountId": 4326,
"AccountName": "joedoe",
"UserId": 3919,
"ExternalUserId": 0,
"Name": "Joe Doe",
"CustomPermissions": "isSafetyOfficer",
"Email": "[email protected]"
},
{
"AccountId": 4326,
"AccountName": "joedoe",
"UserId": 4167,
"ExternalUserId": 0,
"Name": "Jane Jackson",
"CustomPermissions": "isFleetManager",
"Email": "[email protected]"
}
],
"isSucceded": true
}

URL /api/360/account/users

URL Example api/360/account/users" -H "Authorization: Bearer {%User token%}"

Response

Pointer Fleet Client API User Guide Page 75 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.6 Update User Details


Description The function updates the value of the CustomPermissions field for the specified
user.

HTTP Method GET

Parameters Name Type Comments


Token String Mandatory
UserId CustomPermissio Description
ns (mandatory; integer)
Id of the user that should be updated.
(mandatory; integer)
Integer value that represents user's
custom permissions in the system.

Usage 1. For incorrect requests, the result object will contain according error codes and
messages.
2. Update operation can only be performed by user that has
`CustomPermissions` field value = 2 (`isSafetyOfficer`). All requests from users
without proper `CustomPermissions` will be rejected.
3. Update operation can only be performed on users under same account or sub-
account.
4. If a user with `CustomPermissions` = 2 (`isSafetyOfficer`) will perform an
update operation for himself and changes the value of his
`CustomPermissions` field to any other value that 2 (`isSafetyOfficer`), he
immediately will lose the privilege to perform update operations.

URL api/360/account/users

URL Example curl -X POST "{%Server address%}/api/360/account/users" -H "Authorization:


Bearer {%User token%}" -H "Content-Type: application/json" -d
"{\"UserId\":3919,\"CustomPermissions\":2}"

Response

Pointer Fleet Client API User Guide Page 76 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.7 Create an Override Event


Description The function creates an override rule for safety events.
Overrides can be created either for a specific individual event, or as a permanent
rule for a specified address (street).
A permanent rule will affect the assessment of all those events whose
transmission location corresponds to the address (street) specified in rule.

HTTP Method POST

Parameters Name Type Comments


Token String Mandatory
EventType Integer Mandatory
Type of override. Possible values:
1. Permanent rule
2. Single event
EventDateTime string Mandatory (Only for requests where
`EventType` parameter value = 2)
Time of event occurrence. Required
precision are milliseconds, therefore
expected format is
yyyy/MM/dd HH:mm:ss.fff
EventUnitId Integer Mandatory
Only for requests where `EventType`
parameter value = 2;)
Id of a unit that transmitted an event.
Address String Mandatory only for requests where
From 1 to 500 EventType parameter value = 1.
characters. Address (street name), which will be
associated with the newly created
rule.
RuleType Integer Mandatory
Only for requests where `EventType`
parameter value = 1
OriginalSpeed Integer Mandatory
Only for requests where `EventType`
parameter value = 1.
The speed that was originally set as a
limit for the address (street name)
associated with the newly created
rule.

Pointer Fleet Client API User Guide Page 77 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

NewSpeed Integer (mandatory only for requests where


`EventType` parameter value = 1;
integer)
The speed that will be set as a new
limit for calculating the safety
indicator for events that occurred at
the address (street name) associated
with the newly created rule.

SkipEmailNotification Boolean Optional (default false)


Can be used to avoid default
behavior of notifying all the account's
users via email when override has
been created by Safety Officer with
status approved.

Justification String Mandatory


From 10 to 500
characters.
With justification
of override.

Usage 1. For incorrect requests the result object will contain the according error codes
and messages.
2. In case of success the result object will contain the Id of the created override.
3. Overrides can be created by all types of users.
4. Overrides for single event can be created only for the events transmitted by
units of the same account or sub-account.
5. Permanent rule will only affect assessment of the events transmitted by units
of the same account or sub-account.
6. Only overrides with Approved (RuleState = 2) status could be applied to affect
the assessment of the according events.
7. When a request to create an override was made by the user with
CustomPermissions field value other than 2 (NOT isSafetyOfficer), it will be
created with the status `pending` (RuleState = 1).
8. Overrides can be `approved` (RuleState = 2) only by the users with
CustomPermissions value = 2 (isSafetyOfficer).
When override is being created by user with CustomPermissions value = 2
(isSafetyOfficer), it automatically will receive the approved (RuleState = 2) status.

URL /api/360/safety/eventsOverride/create

Pointer Fleet Client API User Guide Page 78 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

URL Example • For single event override:


(using CURL) curl -X POST "{%Server address%}/api/360/safety/eventsOverride/create" -H
"Authorization: Bearer {%User token%}" -H "Content-Type: application/json" -d
"{\"eventType\": 2,\"eventDateTime\": \"2018/11/19
12:59:27.150\",\"eventUnitId\":\"50808070\",\"justification\": \"Some good
reason to override this event.\"}"
• For permanent rule:
curl -X POST "{%Server address%}/api/360/safety/eventsOverride/create" -H
"Authorization: Bearer {%User token%}" -H "Content-Type: application/json" -d
"{\"eventType\": 1,\"address\": \"David Flusser St 14, Jerusalem\",\"
ruleType\":2,\"originalSpeed\":60, \"newSpeed\":90,\"justification\": \"Some good
reason to create permanent rule.\"}"

Response {
"data": {
"id": 42,
"address": "David Flusser St 14, Jerusalem",
"oldSpeed": 60,
"newSpeed": 90,
"justification": "Some good reason to create permanent rule.",
"eventType": "PermanentRule"
},
"isSucceded": true
}

Pointer Fleet Client API User Guide Page 79 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.8 Update an Override Event State


Description The function updates the Status (ruleState) for both single event override and
permanent rules. Permanent rules can be updated the value of field newSpeed as
well.

HTTP Method POST

Parameters Name Type Comments


Token String Mandatory
ruleId Integer Mandatory
Id of rule that being updated.
ruleState Integer Mandatory
Desired status that should be set for
the rule. Possible values:
• 1 - Pending
• 2 - Approved
• 3 - Unapproved
newSpeed Integer Mandatory
Desired new speed for permanent
rule.
Value must be in range between 1 and
maximum value for integer.
In case of single event, will be ignored
by server.
skipEmailNotification Boolean Optional (default false)
Can be used to avoid default behavior
of notifying all the account's users via
email when override has been created
by Safety Officer with status
approved.

Justification String Mandatory


From 10 to 500
characters.
With justification
of override.

Usage 1. For incorrect requests, the result object will contain the according error codes
and messages.
2. Overrides can be updated by all types of users.

Pointer Fleet Client API User Guide Page 80 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

3. Only the rules and single event overrides of the same account or sub-account
can be updated.
4. When a request to update a rule or a single event override was made by the
user with the CustomPermissions field value other than 2 (NOT isSafetyOfficer),
it will be updated but will receive the pending (RuleState = 1) status.
5. Overrides can be `approved` (RuleState = 2) or `unapproved` (RuleState = 3)
only by the users with the CustomPermissions value = 2 (isSafetyOfficer).
6. When override status changes to `approved`, all of the account's users will be
notified via email, unless request was performed with parameter
skipEmailNotification = true.
7. When a new rule is created it’s automatically set at pending state, and there is
no effect on the Safety score.
• When the rule state is changed from Pending to Approved, the rule
configuration becomes active and the Safety score is calculated
accordingly.
• When a rule with a state of Approved is modified, the rule configuration
stays active and a new rule is created in a state of Pending.
• When the pending rule is approved, it replaces the original rule.

URL api/360/safety/eventsOverride/update

URL Example • For single event override:


curl -X POST "{%Server address%}/api/360/safety/eventsOverride/update" -H
"Authorization: Bearer {%User token%}" -H "Content-Type: application/json" -d
"{\"ruleId\":42,\"ruleState\": 2,\"newSpeed\":1,\"justification\": \"Some good
reason to update this override.\"}"
• For permanent rule:
curl -X POST "{%Server address%}/api/360/safety/eventsOverride/update" -H
"Authorization: Bearer {%User token%}" -H "Content-Type: application/json" -d
"{\"ruleId \": 42,\"ruleState \":1,\"newSpeed\":90,\"justification\": \"Some good
reason to update permanent rule.\"}"

Response {
"data": {
"id": 42,
"newSpeed": 75,
"justification": "Some good reason to create override",
"eventType": "PermanentRule"
},
"isSucceded": true
}

Pointer Fleet Client API User Guide Page 81 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.9 Delete an Override Rule


Description The function deletes permanent rules and single evet overrides for safety events.

HTTP Method GET

Parameters Name Type Comments


Token String Mandatory
ruleId Integer Mandatory
Id of rule that being deleted.
Justification String Mandatory
from 10 to 500
characters.
String with
justification of
override update.

Usage 1. For incorrect requests, the result object will contain the according error codes
and messages.
2. Overrides can be deleted only by the users with the `CustomPermissions` value
= 2 (`isSafetyOfficer`).
Only the rules and single event overrides of the same account or sub-account can
be deleted.

URL /api/360/safety/eventsOverride/delete

URL Example curl -X POST "{%Server address%}/api/360/safety/eventsOverride/delete" -H


"Authorization: Bearer {%User token%}" -H "Content-Type: application/json" -d
"{\"ruleId\":42,\"justification\": \"Some good reason to delete override.\"}"

Response

Pointer Fleet Client API User Guide Page 82 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.1.1 Get Override Rules


Description The Get Override Rules API retrieve list of override rules (that can be filtered by
event type; permanent rule or single event) that were created during specific
period.

HTTP Method GET

Parameters Name Type Comments


Key String Mandatory
Event Type Mandatory, single, range between 1-3
(1 - permanent rule, 2 - single event, 3
- all)
StartDate Information start date/time (single,
mandatory)
Format: YYYY/MM/DD Example:
2018/06/26
End Date Information range end date/time
(single, mandatory)
Format: YYYY/MM/DD
Example: 2018/06/26

Usage Enables to retrieve all override events of type <Event type> and in state <Rule
state>, under the calling user's account.

URL Server IP/fleetcore.api/api/360/safety/overrideEvents?

URL Example Server IP/fleetcore.api/api/360/safety/overrideEvents?


eventType=1&ruleState=8000&startDate=2018/01/01&endDate=2019/01/01

Response {
"data": [
{
"requestUserId": 5170,
"originalSpeed": 45,
"newSpeed": 25,
"requestJustification": "permanent rule created by safety officer",
"approvalDate": "2018/12/05",
"approvedUserId": 5170,
"approveJustification": "Update from Vita new"
},
{
"ruleId": 21,

Pointer Fleet Client API User Guide Page 83 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

"eventType": 1,
"ruleState": 2,
"address": "Amal 9-17, Rosh HaAyin, Israel City",
"requestDate": "2018/12/06",
"requestUserId": 5170,
"originalSpeed": 34,
"newSpeed": 50,
"requestJustification": "Custom rule made by safety officer",
"approvalDate": "2018/12/06",
"approvedUserId": 5170,
"approveJustification": "Custom rule made by safety officer"
},
"approvalDate": "2018/12/06",
"approvedUserId": 5170,
"approveJustification": "Custom rule made by safety officer"
}
],
"isSucceded": true
}

Pointer Fleet Client API User Guide Page 84 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

9.2 API Actions


All API requests must use http GET method.
All API requests gets a string parameter:
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc /GetTask?xml=…
The xml parameter has to be in XML format.
All API responses return an XML Result object containing the IsSucceded and
ResultObject structure shown in the table below.

Field name Explanation Values

IsSucceded Indicates whether True / False


<IsSucceded>True</IsSucceded> the request
succeeded or failed.
ResultObject The result object of If the request failed
<ResultObject></ResultObject> the response. Return an Error object
Else
Return an xml object

9.2.1 API Action Example


Request:
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc /GetTask?xml=

<GetTask>
<Token>xxxxxxxxxxxxxxxxxx</Token>
<TaskInfo>
<Id>yyyy</Id>
<ExternalId></ExternalId>
</TaskInfo>
</GetTask>

Response (success):
<string xmlns="http://schemas.microsoft.com/2003/10/Serialization/">
<Result>
<IsSucceded>True</IsSucceded>
<ResultObject>
<TASK>
<AccountId>4317</AccountId>
<Id>20751</Id>
<Name>test02</Name>
<Enabled>True</Enabled>
<AddressDetails>224, Israel</AddressDetails>
<Lat>31.0460510</Lat>
<Long>34.8516120</Long>
<CreatedByUserId>3900</CreatedByUserId>
<CreationDate>02/07/2014 10:01:47</CreationDate>
<ExecutionDate>2014-07-16T00:00:00</ExecutionDate>
<ArrivalTime>2014-07-21T10:00:00</ArrivalTime>

Pointer Fleet Client API User Guide Page 85 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

<CheckAlerts>1</CheckAlerts>
</TASK>
</ResultObject>
</Result>
</string>

Response (failure):
<string xmlns="http://schemas.microsoft.com/2003/10/Serialization/">
<Result>
<IsSucceded>False</IsSucceded>
<ResultObject>
<Error>
<Msg><![CDATA[Message: Task not exists Source: Fleet.Data StackTrace:
at Fleet.Data.TaskRepository.GetTask(TaskInfo task) in
D:\Pointer\FLEET\31A\Source\Fleet.Data\Repository\Task\TaskRepository.cs:lin
e 367; Description : ErrorCode: 0 Source: Custom StackTrace: None;]]>
</Msg>
</Error>
</ResultObject>
</Result>
</string>

Pointer Fleet Client API User Guide Page 86 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

10 API Objects
10.1 LayerInfo
Object Name Object Format Object Description

Id int (nullable)

Name string

10.2 PointInfo
Object Name Object Format Object Description

Id int (nullable)

Name string

LayerId int

10.3 TransferAccountModel
Object Name Object Format Object Description

AccountId int

DestinationId int

10.4 TransferedItems
Object Name Object Format Object Description

VehiclesCount int

DriversCount int

10.5 AccountInfo
Object Name Object Format Object Description

AccountId int (nullable)

AccountName string

ParentAccount int

Level int

Pointer Fleet Client API User Guide Page 87 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

10.6 TaskInfo

Object Name Object Format Object Description

TemplateId int (nullable)

Id int (nullable)

Name string

ExternalId int (nullable)

Message string

TypeId int

Enabled bool

DriverId int (nullable)

VehicleId int (nullable)

Country int

State int

City string

Street string

AddressDetails string

Lat decimal

Long decimal

PointId int (nullable)

LocationIndex int (nullable)

Comment string

EstimateWorkTime int

ContactPerson string

ContactPosition string

OfficePhone string

CellPhone string

Status int (nullable)

Medium int (nullable)

ExecutionDate DateTime
(nullable)

Pointer Fleet Client API User Guide Page 88 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

Object Name Object Format Object Description

ArrivalTime DateTime
(nullable)

CheckAlerts int

DriverName string

LicencePlate string

10.7 TaskStatus

Object Name Object Format Object Description

StatusId int

StatusName string

10.8 AssignInfo

Object Name Object Format Object Description

TaskId string

ExternalId string

DriverId int

VehicleId int

ErrorList string

10.9 RouteInfo

Object Name Object Format Object Description

Id int (nullable)

Name Staring

ExternalId int (nullable)

Tasks List<TaskInRoute>

Pointer Fleet Client API User Guide Page 89 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

10.10 Task

Object Name Object Format Object Description

Id int

Order int

10.11 AssignRouteInfo

Object Name Object Format Object Description

RouteIds string

ExtenalIds string

DriverId int (nullable)

VehicleId int (nullable)

UnAssign int

ErrorList string

10.12 Status

Object Name Object Format Object Description

Id int

Name string

10.13 DriverInfo

Object Name Object Format Object Description

Id int

Status bool

Code decimal

NationalId string

LicenseNum string

LicenseExpire DateTime (nullable)

Pointer Fleet Client API User Guide Page 90 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

Object Name Object Format Object Description

LicenseIssue DateTime (nullable)

Birthday DateTime (nullable)

Address string

Mobile string

HomePhone string

DriverGroupId int (nullable)

FirstName string

LastName string

MiddleName string

Login string

Password string

DefaultTaskMedium int (nullable)

ManagerId int (nullable)

LicenseTypes List<IdNameInfo>

10.14 LicenseTypes
Object Name Object Format Object Description

Id int

Name string

Pointer Fleet Client API User Guide Page 91 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.
Pointer Fleet
Client API User Guide

11 API Call Example


11.1 Example Scenario: GetTaskStatus
Note: For this example, TasksAPI service is installed on the localhost -
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc

1. Login to the API using the Login action:


If I wish to login as user "A", whose password is "Aa1111", the call should be:
http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetTaskStatus?xml=
<GetTaskStatus>
<Token>239516444020000040</Token>
<TaskInfo>
<Id>20751</Id>
<ExternalId></ExternalId>
</TaskInfo>
</GetTaskStatus>
Response: If the login name and password are correct, and the user is active, the
response shall be as displayed below:
<string xmlns="http://schemas.microsoft.com/2003/10/Serialization/">
<Result>
<IsSucceded>True</IsSucceded>
<ResultObject>
<Token>891597051720000054</Token>
</ResultObject>
</Result>
</string>

2. GetTaskStatus using the token from above:


http://localhost/FleetAPI/Fleet.API.FleetAPIService.svc/GetTaskStatus?xml=
<GetTaskStatus>
<Token>856706531720000050</Token>
<TaskId>20611</TaskId>
</GetTaskStatus>
Response: The response message will be as shown below:
<string
xmlns="http://schemas.microsoft.com/2003/10/Serialization/"><Result>
<IsSucceded>True</IsSucceded>
<ResultObject>
<TaskStatus>
<StatusId>0</StatusId>
<StatusName>Disabled</StatusName>
</TaskStatus>
</ResultObject>
</Result></string>

Pointer Fleet Client API User Guide Page 92 of 92


Copyright © 2020 PowerFleet Inc. All rights reserved.

You might also like