TrackSolid Api v2.7 (1)

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

Shenzhen Jimi Software Co., Ltd.

JIMI Open API Specification

Version Date Writer Content updated


V1.0 2017/03/29 Yao Jianping The initial release
V1.1 2017/04/18 Yao Jianping Modify the interface parameter description
V1.2 2017/04/27 Yao Jianping Unify all interface url;
Perfect interface return attributes description;
Add return examples
V1.2 2017/05/09 Yao Jianping Add external power voltage attributes in 7.8
and 7.9;
Add api type in chapter 6;
Delete alarm push interface;
Add 7.17
V1.3 2017/06/15 Yao Jianping Modify 7.5.
Add refreshToken and time in returned json;
Add 7.6: refresh accessToken
Add 7.7: create sub-account;
Add 7.19: acquire device location map
V1.4 2017/07/20 Yao Jianping Midify 4, add the error code
Modify the 7.3 section, 0.9 version added in
the general parameters v
Modify Section 7.7 , user type attribute added
Add Device Transfer in section 7.20
V1.5 2017-07-31 Yao Jianping Add API
Add 7.21 7.22 7.23
V1.6 2017-10-24 Jeff Wang make document more readable.
V1.6.1 2018-04-22 Jeff Wang Add field distance for jimi.device.location.get.
V1.6.2 2018-09-08 Jeff Wang Add device_status parameter
for jimi.open.device.update interface to
disable/enable device.
V1.6.3 2018-09-10 Jeff Wang Add jimi.track.device.detail interface
V1.6.4 2018-10-2 Jeff Wang Add create account & remove account
interface.
V1.6.5 2018-12-6 Jeff Wang Add get sharing location URL interface.
Add move account interface.
Add additional fields for get device info
interface.
Add update user expiration date interface.
V1.6.6 2018-03-08 Jeff Wang Add get mileage interface.
V1.6.7 2019-04-24 Jeff Wang Add DVR live streaming page URL
Shenzhen Jimi Software Co., Ltd.

Add get alarm list


V2.1 2019-05-15 Jeff Wang Add Scooter API support
V2.2 2019-06-20 Jeff Wang Add camera photo URL & video URL interface
V2.3 2019-11-07 Jeff Wang Add send/receive raw command interface.
V2.4 2020-02-11 Zou Zeliang Add camera photo or video instructions
interface
V2.5 2020-07-28 dengjie Add get video rtmp url interface
v2.5 2020-1209 chenkuan Add temperature and oil sense fields to the
device real-time data API interface
V2.6 2021-01-28 chenkuan Add API
Add 7.38
V2.7 2021-04-09 darcy Add optional attributes (machineName) of
model alias, Modified interface:
jimi.user.device.list(7.11)
jimi.track.device.detail (7.12)

1 Contents
JIMI OPEN API SPECIFICATION ............................................................................................................ 1

1 CONTENTS ....................................................................................................................................... 2

2 OVERVIEW ...................................................................................................................................... 7

3 USAGE ............................................................................................................................................. 7

4 CONVENTIONS ................................................................................................................................ 8

4.1 ENCODING, FORMAT & TIMEZONE .......................................................................................................... 8


4.2 COMMON RESPONSE FIELDS................................................................................................................... 8

5 WORK FLOW ................................................................................................................................. 10

5.1 API WORK FLOW .............................................................................................................................. 10

6 API FEATURES ................................................................................................................................ 10

7 API DESCRIPTION .......................................................................................................................... 12

7.1 REQUEST URL .................................................................................................................................. 12


7.2 SECURITY ......................................................................................................................................... 12
7.3 COMMON PARAMETERS ..................................................................................................................... 12
7.4 SIGNATURE ....................................................................................................................................... 13
7.5 GET ACCESS TOKEN ............................................................................................................................ 15
Shenzhen Jimi Software Co., Ltd.

7.5.1 Description ............................................................................................................................ 15


7.5.2 Request URL .......................................................................................................................... 15
7.5.3 HTTP request method ............................................................................................................ 15
7.5.4 Request parameter ................................................................................................................ 16
7.5.5 Response ............................................................................................................................... 16
7.6 REFRESH ACCESS TOKEN ...................................................................................................................... 18
7.6.1 Description ............................................................................................................................ 18
7.6.2 Request URL .......................................................................................................................... 18
7.6.3 HTTP Request method ........................................................................................................... 18
7.6.4 Request parameters .............................................................................................................. 18
7.6.5 Response ............................................................................................................................... 18
7.7 LIST ALL SUB-ACCOUNT ....................................................................................................................... 19
7.7.1 Description ............................................................................................................................ 19
7.7.2 Request URL .......................................................................................................................... 19
7.7.3 HTTP request method ............................................................................................................ 20
7.7.4 Request parameters .............................................................................................................. 20
7.7.5 Response ............................................................................................................................... 20
7.8 CREATE SUB-ACCOUNT ........................................................................................................................ 21
7.8.1 Description ............................................................................................................................ 21
7.8.2 Request URL .......................................................................................................................... 22
7.8.3 HTTP request method ............................................................................................................ 22
7.8.4 Request parameters .............................................................................................................. 22
7.8.5 Response ............................................................................................................................... 23
7.9 REMOVE SUB-ACCOUNT ...................................................................................................................... 23
7.9.1 Description ............................................................................................................................ 23
7.9.2 Request URL .......................................................................................................................... 23
7.9.3 HTTP request method ............................................................................................................ 23
7.9.4 Request parameters .............................................................................................................. 24
7.9.5 Response ............................................................................................................................... 24
7.10 MOVE ACCOUNT ............................................................................................................................. 25
7.10.1 Description .......................................................................................................................... 25
7.10.2 Request URL ........................................................................................................................ 25
7.10.3 HTTP request method .......................................................................................................... 25
7.10.4 Request parameters ............................................................................................................ 25
7.10.5 Response ............................................................................................................................. 25
7.11 LIST ALL DEVICES OF SUB-ACCOUNT ..................................................................................................... 26
7.11.1 Description .......................................................................................................................... 26
7.11.2 Request URL ........................................................................................................................ 26
7.11.3 HTTP request method .......................................................................................................... 26
7.11.4 Request parameters ............................................................................................................ 26
7.11.5 Response ............................................................................................................................. 26
7.12 GET DEVICE DETAIL INFORMATION ....................................................................................................... 28
7.12.1 Description .......................................................................................................................... 28
7.12.2 Request URL ........................................................................................................................ 28
Shenzhen Jimi Software Co., Ltd.

7.12.3 HTTP request method .......................................................................................................... 28


7.12.4 Request parameters ............................................................................................................ 28
7.12.5 Response ............................................................................................................................. 29
7.13 GET LOCATION OF DEVICES BY ACCOUNT ............................................................................................... 31
7.13.1 Description .......................................................................................................................... 31
7.13.2 Request URL ........................................................................................................................ 31
7.13.3 HTTP request method .......................................................................................................... 31
7.13.4 Request parameters ............................................................................................................ 31
7.13.5 Response ............................................................................................................................. 32
7.14 GET THE LOCATION OF DEVICE(S) ........................................................................................................ 33
7.14.1 Description .......................................................................................................................... 33
7.14.2 Request URL ........................................................................................................................ 34
7.14.3 HTTP request method .......................................................................................................... 34
7.14.4 Request parameters ............................................................................................................ 34
7.14.5 Response ............................................................................................................................. 34
7.15 GET SHARING LOCATION URL ............................................................................................................. 36
7.15.1 Description .......................................................................................................................... 36
7.15.2 Request URL ........................................................................................................................ 36
7.15.3 HTTP request method .......................................................................................................... 36
7.15.4 Request parameters ............................................................................................................ 36
7.15.5 Response ............................................................................................................................. 36
7.16 UPDATE USER EXPIRATION DATE .......................................................................................................... 37
7.16.1 Description .......................................................................................................................... 37
7.16.2 Request URL ........................................................................................................................ 37
7.16.3 HTTP request method .......................................................................................................... 37
7.16.4 Request parameters ............................................................................................................ 38
7.16.5 Response ............................................................................................................................. 38
7.17 GET THE MILEAGE DATA OF DEVICES ..................................................................................................... 39
7.17.1 Description .......................................................................................................................... 39
7.17.2 Request URL ........................................................................................................................ 39
7.17.3 HTTP request method .......................................................................................................... 39
7.17.4 Request parameters ............................................................................................................ 39
7.17.5 Response ............................................................................................................................. 40
7.18 GET THE TRACK DATA OF DEVICE.......................................................................................................... 41
7.18.1 Description .......................................................................................................................... 41
7.18.2 Request URL ........................................................................................................................ 41
7.18.3 HTTP request method .......................................................................................................... 41
7.18.4 Request parameters ............................................................................................................ 41
7.18.5 Response ............................................................................................................................. 42
7.19 UPDATE VEHICLE INFORMATION BY IMEI .............................................................................................. 43
7.19.1 Description .......................................................................................................................... 43
7.19.2 Request URL ........................................................................................................................ 43
7.19.3 HTTP request method .......................................................................................................... 43
7.19.4 Request parameters ............................................................................................................ 43
Shenzhen Jimi Software Co., Ltd.

7.19.5 Response ............................................................................................................................. 44


7.20 GET DEVICE PHOTO OR VIDEO URL .................................................................................................... 45
7.20.1 Description .......................................................................................................................... 45
7.20.2 Request URL ........................................................................................................................ 45
7.20.3 HTTP request method .......................................................................................................... 45
7.20.4 Request parameters ............................................................................................................ 46
7.20.5 Response ............................................................................................................................. 46
7.21 GET DEVICE LIVE STEAMING PAGE URL ............................................................................................... 47
7.21.1 Description .......................................................................................................................... 47
7.21.2 Request URL ........................................................................................................................ 48
7.21.3 HTTP request method .......................................................................................................... 48
7.21.4 Request parameters ............................................................................................................ 48
7.21.5 Response ............................................................................................................................. 48
7.22 WI-FI, BASE STATION LOCATING ANALYSIS............................................................................................. 50
7.22.1 Description .......................................................................................................................... 50
7.22.2 Request URL ........................................................................................................................ 50
7.22.3 HTTP request method .......................................................................................................... 50
7.22.4 Request parameters ............................................................................................................ 50
7.22.5 Response ............................................................................................................................. 51
7.23 CREATE GEO-FENCE FOR IMEI ........................................................................................................... 51
7.23.1 Description .......................................................................................................................... 51
7.23.2 Request URL ........................................................................................................................ 52
7.23.3 HTTP request method .......................................................................................................... 52
7.23.4 Request parameters ............................................................................................................ 52
7.23.5 Response ............................................................................................................................. 52
7.24 DELETE GEO-FENCE FOR DEVICE ......................................................................................................... 53
7.24.1 Description .......................................................................................................................... 53
7.24.2 Request URL ........................................................................................................................ 53
7.24.3 HTTP request method .......................................................................................................... 53
7.24.4 Request parameters ............................................................................................................ 53
7.24.5 Response ............................................................................................................................. 54
7.25 GET COMMAND LIST SUPPORTED BY DEVICE .......................................................................................... 54
7.25.1 Description .......................................................................................................................... 54
7.25.2 Request URL URL ................................................................................................................. 55
7.25.3 HTTP request method .......................................................................................................... 55
7.25.4 Request parameters ............................................................................................................ 55
7.25.5 Response ............................................................................................................................. 55
7.26 SEND COMMAND TO DEVICE .............................................................................................................. 56
7.26.1 Description .......................................................................................................................... 56
7.26.2 Request URL ........................................................................................................................ 56
7.26.3 HTTP request method .......................................................................................................... 56
7.26.4 Request parameters ............................................................................................................ 56
7.26.5 Response ............................................................................................................................. 57
7.27 GET RESULTS OF COMMAND EXECUTION ............................................................................................... 58
Shenzhen Jimi Software Co., Ltd.

7.27.1 Description .......................................................................................................................... 58


7.27.2 Request URL ........................................................................................................................ 58
7.27.3 HTTP request method .......................................................................................................... 58
7.27.4 Request parameters ............................................................................................................ 58
7.27.5 Response ............................................................................................................................. 59
7.28 SEND RAW COMMAND DATA TO DEVICE ................................................................................................ 60
7.28.1 Description .......................................................................................................................... 60
7.28.2 Request URL ........................................................................................................................ 60
7.28.3 HTTP request method .......................................................................................................... 60
7.28.4 Request parameters ............................................................................................................ 60
7.28.5 Response ............................................................................................................................. 61
7.29 PUSH RECEIVED RAW DATA ............................................................................................................... 61
7.29.1 Description .......................................................................................................................... 61
7.29.2 Message service List ............................................................................................................ 62
7.29.3 Message content ( jimi.open.instruction.raw.receive) ........................................................ 62
7.30 SEND MEDIA INSTRUCTION ................................................................................................................ 63
7.30.1 Description .......................................................................................................................... 63
7.30.2 Request URL ........................................................................................................................ 63
7.30.3 HTTP request method .......................................................................................................... 63
7.30.4 Request parameters ............................................................................................................ 63
7.30.5 Response ............................................................................................................................. 63
7.31 RECEIVE NOTIFICATION ..................................................................................................................... 64
7.31.1 Description .......................................................................................................................... 64
7.31.2 Message service List ............................................................................................................ 64
7.31.3 Message content ( jimi.push.device.alarm) ......................................................................... 65
7.32 GET DEVICE ALARM LIST .................................................................................................................... 66
7.32.1 Description .......................................................................................................................... 66
7.32.2 Request URL ........................................................................................................................ 66
7.32.3 HTTP request method .......................................................................................................... 66
7.32.4 Request parameters ............................................................................................................ 66
7.32.5 Response ............................................................................................................................. 66
7.33 SEND COMMAND (FOR SCOOTER DEVICE).............................................................................................. 68
7.33.1 Description .......................................................................................................................... 68
7.33.2 Request URL ........................................................................................................................ 68
7.33.3 HTTP request method .......................................................................................................... 68
7.33.4 Request parameters ............................................................................................................ 68
7.33.5 Response ............................................................................................................................. 69
7.34 GET DETAIL INFORMATION OF SCOOTER ................................................................................................ 69
7.34.1 Description .......................................................................................................................... 69
7.34.2 Request URL ........................................................................................................................ 70
7.34.3 HTTP request method .......................................................................................................... 70
7.34.4 Request parameters ............................................................................................................ 70
7.34.5 Response ............................................................................................................................. 70
7.35 GET HISTORY VIDEO LIST .................................................................................................................... 76
Shenzhen Jimi Software Co., Ltd.

7.35.1 Description .......................................................................................................................... 76


7.35.2 Request URL ........................................................................................................................ 76
7.35.3 HTTP request method .......................................................................................................... 76
7.35.4 Request parameters ............................................................................................................ 76
7.35.5 Response ............................................................................................................................. 76
7.36 SEND HISTORY VIDEO INSTRUCTION ..................................................................................................... 78
7.36.1 Description .......................................................................................................................... 78
7.36.2 Request URL ........................................................................................................................ 78
7.36.3 HTTP request method .......................................................................................................... 78
7.36.4 Request parameters ............................................................................................................ 78
7.36.5 Response ............................................................................................................................. 78
7.37 GET VIDEO RTMP URL ........................................................................................................................ 79
7.37.1 Description .......................................................................................................................... 79
7.37.2 Request URL ........................................................................................................................ 79
7.37.3 HTTP request method .......................................................................................................... 80
7.37.4 Request parameters ............................................................................................................ 80
7.37.5 Response ............................................................................................................................. 80

8 APPENDIX...................................................................................................................................... 83

2 Overview

 Benefit of JIMI Open API, distributor or application vendor could provide tracking service to
customers by calling the API and use your own GUI client, App or Website, this might improve
the localization or user experience.
 Your App or web client should connect to your application server, rather than connect to JIMI
API Server directly , use your application server connect to JIMI Server instead.

3 Usage
1. Contact us to apply your appKey and appSecrect, you need to provide your account.
2. According to this document to implement your application server to obtain access_token.
3. Calling other interfaces with access_token to fulfil your business logic.
Shenzhen Jimi Software Co., Ltd.

4 Conventions

4.1 Encoding, format & Timezone

 UTF-8 and JSON is used by default.


 Context-Type: default application/json charset=utf-8
 The API use UTC (GMT +0)time in default: format yyyy-MM-dd HH:mm:ss

4.2 Common response fields

Key Type Required Description


code int Yes result code

message string No Description

Result code description


Code Value Description
-1 -1 The system is busy

0 0 success
Parameter error (lack of required parameters or format
1XXX 1001
error). See interface description for details
Illegal user/illegal device (not their own or subordinate
1002
account or device)
1003 Repeat operation
Illegal access, token exception! (Token failure or
1004
nonexistent)
1005 Illegal access, IP access exceeds limit!

1006 Illegal access, too frequently request!

1007 Illegal access, request method error!

1008 Illegal access, abnormal incoming!

12001 platform account creation failed

12002 device transfer failed


12003 Geo-fence creation failed
12004 Geo-fence deletion failed
Shenzhen Jimi Software Co., Ltd.

12005 Fail to send command

Error code:
Code Value Description
213 Account already exist

214 Account does not exist


Create
User type error. Possible reasons: 1.User
account
type is empty; 2. User type does not exist;
215
3. Current login user do not have
permission to create new type of user.
217 Target user does not exist
User can only transfer/sale devices to sub-
218
Device account
transfer 219 IMEI list is illegal
Number of IMEI exceeds limitation.
220

Exceed max number of Geo-fences


41001
supported
41002 Fence name is already exists
Geo-fence
41003 The device is not online
41004 Geo-fence operation failed

225 time out

226 Parameter error

227 The command is not executed correctly

228 The device is not online

Command 229 Network error, connection error, etc.

238 Device interrupted

240 Data format error

243 Not supported by device

252 The device is busy


Shenzhen Jimi Software Co., Ltd.

5 Work Flow

5.1 API Work Flow

Dealer Server JIMI Server

1. Get access_token

2. Return access_token

3. Request JIMI API


interface

Authentication
/limit

Return data

6 API Features
Interface
Method Description
type
Access token jimi.oauth.token.get Get access_token.
jimi.oauth.token.refresh Refresh access_token.
jimi.user.child.list List all sub-account.
User API
jimi.user.device.list List all devices of current
Shenzhen Jimi Software Co., Ltd.

account.
jimi.user.child.create Create sub-account
jimi.user.child.del Remove sub-account
jimi.user.child.move Move sub-account to another
account.
jimi.track.device.detail Get device detail information
for specific IMEI
jimi.user.device.location.list Get the latest location for all
devices.
jimi.device.location.get Get the latest location data for
specific IMEI.
jimi.device.location.URL.share Get URL for showing location on
the Map.
jimi.user.device.expiration.upda Change user expiration date for
te devices
jimi.device.track.list Obtain track data according to
Device API IMEI.
jimi.device.track.mileage Get mileage report for devices.
jimi.open.device.update Modify the vehicle information
for device.
Jimi.device.media.URL Get URL of photo or video
capture by camera.
jimi.device.live.page.url Get device live streaming page
URL
Command jimi.open.instruction.list Gets commands supported by
API the device.
jimi.open.instruction.send Send command to device.
jimi.open.instruction.result Get the command result.
jimi.open.instruction.raw.send Send raw command data to
device
jimi.open.instruction.raw.receive Jimi push raw data to specified
client’s server URL.
jimi.device.meida.cmd.send Send media instruction
Geo-fence jimi.open.device.fence.delete Remove the Geo fence for the
API device.
jimi.open.device.fence.create Create an Geo fence for the
device.
LBS-API jimi.lbs.address.get Wi-Fi base station location
analysis.
Message jimi.push.device.alarm Push alarm notification.
jimi.device.alarm.list Get alarm list for device
Scooter API jimi.scooter.instruction.send Send command to scooter
device.
Shenzhen Jimi Software Co., Ltd.

jimi.scooter.device.detail Get scooter status and other


detail information.

7 API Description

7.1 Request URL

The unique request URL is:


http://open.10000track.com/route/rest
https://hk-open.tracksolidpro.com/route/rest
https://eu-open.tracksolidpro.com/route/rest
https://us-open.tracksolidpro.com/route/rest

Different interfaces are identified by request parameter method.

7.2 Security

Client should get access_token first before calling the interface, which is generated by JIMI
Server by calling jimi.oauth.token.get interface(method=jimi.oauth.token.get) with provided
appKey and appSecrect.

appKey and access_token are required to sign request parameters when calling API. JIMI
server will validate the the request parameters by checking the sign value.

7.3 Common Parameters

The parameters of each request should include common parameters and interface private
parameters. For example, if you call the “jimi.oauth.token.get” interface, you need to provide :
7(common parameters) + 3(private parameters) = 10 (parameters, key/value)

Following are the common parameters:


Name Type Required Description Remark Default
method String Yes API interface name
Timestamp, format:yyyy
-MM-dd HH:mm:ss. Plus
timestamp String Yes or minus10 minutes is GMT(UTC) time.
allowed. e.g:2012-03-25
20:00:00
app_key String Yes appKey from JIMI
sign String Yes A signature base on par
Shenzhen Jimi Software Co., Ltd.

ameters, appKey, appSec


rect.
Yes Optional, signature me
sign_method String thod. Available value: md5 md5
md5
Yes Optional, specify the A 0.9: no signature
PI version. System defa checking
v String
ult 1.0, support versio 1.0: check
n: 0.9, 1.0 signature
Yes Optional, specify respo
format String json
nse format.

7.4 Signature

To protect API calling from hacked, any API calling needs to be with a signature. JIMI server will
check signature based on request parameters. Illegal signature request will be rejected. Signature
algorithms supported is: md5 (sign_method is a common parameter mentioned above). Following
is the algorithm of signature:

1. Sort all request parameters with parameter key in alphabetical order (including common parameters and
method specific parameters, but NOT include sign and byte type parameter.

For example:
foo=1, bar=2, foo_bar=3, foobar=4
Result: bar=2, foo=1, foo_bar=3, foobar=4

2. Remove all equal sign and comma:


bar2foo1foo_bar3foobar4
3. Then concatenate appSecrect to the before and end of the result string and get the md5 value. E.g:

md5(appSecrect+bar2foo1foo_bar3foobar4+appSecrect), the real string should like:


md5(h9lri085eachcz4sn7gwnkh6j0jt0yz4bar2foo1foo_bar3foobar4h9lri085eachcz4sn7gwnkh6j0jt0yz4)

Note that the string should be in UTF-8 encoding.


Note that the sign should be upper case string.
4. If the parameter value is a byte stream, it should be converted to hexadecimal. For example:
hex(“helloworld”.getBytes(“utf-8”)) = “68656C6C6F776F726C64”

MD5 is the 128-bit summary algorithm and is in hexadecimal. a hexadecimal character


can represent four bits, so the signature string length is 32 hexadecimal characters.
Shenzhen Jimi Software Co., Ltd.

JAVA example:
algorithm

public static String signTopRequest(Map<String, String> params, String seccode, String signMethod) throws IOExc
eption {
// 1:sort parameter key
String[] keys = params.keySet().toArray(new String[0]);
Arrays.sort(keys);

// 2:: Put all parameter names and parameter values together


StringBuilder query = new StringBuilder();
if (Constants.SIGN_METHOD_MD5.equals(signMethod)) {
query.append(seccode);
}
for (String key : keys) {
String value = params.get(key);
if (StringUtils.areNotEmpty(key, value)) {
query.append(key).append(value);
}
}

// 3: use MD5/HMAC to encrypt


byte[] bytes;
if (Constants.SIGN_METHOD_HMAC.equals(signMethod)) {
bytes = encryptHMAC(query.toString(), seccode);
} else {
query.append(seccode);
bytes = encryptMD5(query.toString());
}

// 4: convert binary to uppercase hexadecimal


return byte2hex(bytes);
}

public static byte[] encryptHMAC(String data, String seccode) throws IOException {


byte[] bytes = null;
try {
seccodeKey seccodeKey = new seccodeKeySpec(seccode.getBytes(Constants.CHARSET_UTF8), "HmacMD5");
Mac mac = Mac.getInstance(seccodeKey.getAlgorithm());
mac.init(seccodeKey);
bytes = mac.doFinal(data.getBytes(Constants.CHARSET_UTF8));
} catch (GeneralSecurityException gse) {
throw new IOException(gse.toString());
}
return bytes;
Shenzhen Jimi Software Co., Ltd.

public static byte[] encryptMD5(String data) throws IOException {


return encryptMD5(data.getBytes(Constants.CHARSET_UTF8));
}

public static String byte2hex(byte[] bytes) {


StringBuilder sign = new StringBuilder();
for (int i = 0; i < bytes.length; i++) {
String hex = Integer.toHexString(bytes[i] & 0xFF);
if (hex.length() == 1) {
sign.append("0");
}
sign.append(hex.toUpperCase());
}
return sign.toString();
}

7.5 Get access token

7.5.1 Description

Client(distributor’s server) should stored the access_token locally, do NOT get access_token per
request, instead, use the local access_token before it become invalid. JIMI server will not allow to
access if the request frequency is too high from client.

The access token can be used for about 2 hours(depend on the value for expires_in parameter),
do NOT try to get token for every request.

7.5.2 Request URL

See the unique request URL.


Method = jimi.oauth.token.get

7.5.3 HTTP request method

POST
Shenzhen Jimi Software Co., Ltd.

7.5.4 Request parameter

(1)Common parameters
(2)Private parameters as follow:

Name Type Required Description Remark Default


user_id String Yes User ID User’s account
Lowercase md5
user_pwd_md5 String Yes user’s password (md5)
value.
expires_in number Yes access token expired seconds. 60-7200

7.5.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message

result String Result

Key Type Description

accessToken string access token, required by any other following interfaces.

expiresIn string access token expired seconds.


account String user’s account.

appKey string appKey from JIMI.


refreshToken String Refresh token, which is used for updating accessToken
time String Token generated time.

Correct return example:

{
"code": 0,
"message": "success",
"result": {
"appKey": "8FB345B8693CCD003CC2DAB61EC8791D",
Shenzhen Jimi Software Co., Ltd.

"account": "jimitest",
"accessToken": "7da3330ec28e3996b6ef4a7e3390ba71",
"expiresIn": 60
"refreshToken": "7da3330ec28e3996b6ef4a7e3390ba71",
"time": "2017-06-15 10:00:00"

}
}

Return error example:

{"code":xxx,"message":"Incorrect user name or password"}

Postman demo:

user_id = your tracksolid account.


user_pwd_md5 = md5(your tracksolid account password).
Sign = md5(<app_secrect>your alphabet ordered parameters keyvalue, without equal-sign,
comma and not include sign field<app_secrect>).
Note that sign is a 32-length upper case string.

For example:
<app_secrect>app_key9FB345B8693CCD0054E44ADF99139409expires_in7200formatjsonmetho
djimi.oauth.token.getsign_methodmd5timestamp2017-09-28
01:55:00user_id<account>user_pwd_md5<password_md5>v1.0<app_secrect>
Shenzhen Jimi Software Co., Ltd.

7.6 Refresh access token

7.6.1 Description

This interface is used to update token manually when access token is about to be invalid.

7.6.2 Request URL

See the unique request URL.


Method = jimi.oauth.token.refresh

7.6.3 HTTP Request method

POST

7.6.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Description Remark Default


access_token String YES Access token
Authorized refresh access
refresh_token String YES
token
expires_in number YES access token expired seconds 60-7200

7.6.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String result

Key Type Description


Shenzhen Jimi Software Co., Ltd.

accessToken string Access token, required for subsequently interface access.

ExpiresIn string Access token expired seconds.


account String Requested account
appKey string From JIMI

refreshToken String Refresh token for updating access token


time String Token generated time

Example for correct Response:

{
"code": 0,
"message": "success",
"result": {
"appKey": "8FB345B8693CCD003CC2DAB61EC8791D",
"account": "jimitest",
"accessToken": "7da3330ec28e3996b6ef4a7e3390ba71",
"expiresIn": 60,
"refreshToken": "7da3330ec28e3996b6ef4a7e3390ba71",
"time": "2017-06-15 10:00:00"
}
}
Return error example:
{"code":xxx,"message":"Illegal request,token is invalid"}

7.7 List all sub-account

7.7.1 Description

List all sub-account of a specified account.

7.7.2 Request URL

See the unique request URL.


Method = jimi.user.child.list
Shenzhen Jimi Software Co., Ltd.

7.7.3 HTTP request method

POST

7.7.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token for security access JIMI
access_token string Yes -
Server.
target string Yes - The specified account for inquired.

7.7.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result string The returned parameters

Result:
Key Type Description
account string log in account
name string name
Int Account Type
3:App user
8:Distributor
type
9:ordinary users
10:ordinary distributor
11:sales
displayFlag Int Available or not (1:Available,0:not available)
address string location

birth string birthday


companyName string Company Name
email string mailbox
Shenzhen Jimi Software Co., Ltd.

phone string contact number


language string Language (zh,en)

sex int Gender 0 male,1 female


enabledFlag Int Flag:1 Available, 0not available

remark string Remark

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"account": "123123",
"name": "test",
"type": 8,
"displayFlag": 1,
"address": null,
"birth": "2017-04-22 00:00:00",
"companyName": "",
"email": "",
"phone": "",
"language": "zh",
"sex": 0,
"enabledFlag": 1,
"remark": null
}
]
}

Wrong return example:

{"code":xxx,"message":"The account does not exist"}

7.8 Create sub-account

7.8.1 Description

Create a sub-account of a specified account.


Shenzhen Jimi Software Co., Ltd.

7.8.2 Request URL

See the unique request URL.


Method = jimi.user.child.create

7.8.3 HTTP request method

POST

7.8.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token for security access JIMI
access_token string Yes -
Server.
super_accoun The specified parent account. If not
string No -
t provided, use API account instead.
Account id, length of 3~30
characters. Support special
account_id String Yes
characters like “_@.” as well as a-Z,
0-9.
nick_name String Yes Nick name or customer name
account_type int Yes 1-Distributor 2-End User 3-Sales
password String Yes Password with md5.
telephone String No
User could retrieve password if
Email String Yes
forgot it.
contact_perso
String No
n
company_na
String No
me
Web Login
App Login
Send Command
Set Working Mode
permissions String Yes
Edit by Web
Edit by App
6 digital represents enable/disable
perssion.
Shenzhen Jimi Software Co., Ltd.

7.8.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message

result string The returned parameters

Correct return example:

{
"code": 0,
"message": "Vehicle information modification successful",
"result": null
}

Wrong return example:

{"code":xxx,"message":"The account does not exist"}

7.9 Remove sub-account

7.9.1 Description

Remove a sub-account of a specified account.

7.9.2 Request URL

See the unique request URL.


Method = jimi.user.child.del

7.9.3 HTTP request method

POST
Shenzhen Jimi Software Co., Ltd.

7.9.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token for security access JIMI
access_token string Yes -
Server.
The specified parent account. If not
super_account string No -
provided, use API account instead.
Account id, length of 3~30
characters. Support special
account_id String Yes
characters like “_@.” as well as a-Z,
0-9.

7.9.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message

result string The returned parameters

Correct return example:

{
"code": 0,
"message": "Vehicle information modification successful",
"result": null
}

Wrong return example:

{"code":xxx,"message":"no permissions"}
Shenzhen Jimi Software Co., Ltd.

7.10 Move account

7.10.1 Description

Move account from one sub-account to another sub-account.

7.10.2 Request URL

See the unique request URL.


Method = jimi.user.child.move

7.10.3 HTTP request method

POST

7.10.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token for security access JIMI
access_token string Yes -
Server.
account string YES - The account will be moved.
target_account String Yes The target account to move in.

7.10.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result string The returned parameters

Correct return example:

{
Shenzhen Jimi Software Co., Ltd.

"code": 0,
"message": "Vehicle information modification successful",
"result": null
}

Wrong return example:

{"code":xxx,"message":"no permissions"}

7.11 List all devices of sub-account

7.11.1 Description

Query all devices of a specified account.

7.11.2 Request URL

See the unique request URL.


Method = jimi.user.device.list

7.11.3 HTTP request method

POST

7.11.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


Access token for security access JIMI
access_token string
Yes Server.
target string Yes - The specified account for inquired.

7.11.5 Response

Key Type Description


Return code:
code int
0: return correctly
Shenzhen Jimi Software Co., Ltd.

Other: failure. Refer to the error code description

message string If code is not 0, there will be a corresponding error message


result string The returned data

Result:
Key Type Description
imei string Device IMEI
deviceName string Device name

mcType String Device model


mcTypeUseScope String Automobile, electromobile, personal, pet, plane, others

sim String Sim card number


expiration String Platform expiration date
activationTime string Activation time
reMark String Remarks
vehicleName string Vehicle name

vehicleIcon string Vehicle icon


vehicleNumber string License plate number

vehicleModels string Brand


carFrame String VIN
driverName string Driver name

driverPhone string Driver phone number


enabledFlag Int Available or not (1:Available,0:not available)
engineNumber String Engine number
If the user fills in this attribute, the device model will
machineName String display the alias on the platform and for the sub-accounts
users

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"imei": "868120145233604",
"deviceName": "868120145233604",
"mcType": "GT300L",
Shenzhen Jimi Software Co., Ltd.

"mcTypeUseScope": "personal",
"sim": "415451",
"expiration": "2037-04-01 23:59:59",
"activationTime": "2017-04-01 11:02:20",
"reMark": "test",
"vehicleName": null,
"vehicleIcon": "bus",
"vehicleNumber": "粤 B3604",
"vehicleModels": null,
"carFrame": "2235",
"driverName": "driver",
"driverPhone": "13825036579",
"enabledFlag": 1,
"engineNumber": "8565674"
}
]
}

Return error example:

{"code":xxx,"message":"Account queried doesn’t exist"}

7.12 Get device detail information

7.12.1 Description

Get device detail information for specific IMEI.

7.12.2 Request URL

See the unique request URL.


Method = jimi.track.device.detail

7.12.3 HTTP request method

POST

7.12.4 Request parameters

(1)Common parameters
Shenzhen Jimi Software Co., Ltd.

(2)Private parameters

Parameter Type Required Remark Description


Access token for security access JIMI
access_token string
Yes Server.
IMEI string Yes - The specified IMEI for inquired.

7.12.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result string The returned data

Result:
Key Type Description
imei string Device IMEI
deviceName string Device name

mcType String Device model


mcTypeUseScope String Automobile, electromobile, personal, pet, plane, others

sim String Sim card number


expiration String Platform expiration date
User expiration date, format as: account1,2019-01-
user_expiration String 01|account2,2019-02-02

activationTime string Activation time


reMark String Remarks
vehicleName string Vehicle name

vehicleIcon string Vehicle icon


vehicleNumber string License plate number

vehicleModels string Vehicle Model


carFrame String VIN
driverName string Driver name

driverPhone string Driver phone number


enabledFlag Int Available or not (1:Available,0:not available)
Shenzhen Jimi Software Co., Ltd.

engineNumber String Engine number

iccid String

importTime String

imsi String

licensePlatNo String
VIN String

vehicleBrand String

fuel_100km String Fuel consumption for per 100km.

status String 0-disable 1-enable


If the user fills in this attribute, the device model will
machineName String display the alias on the platform and for the sub-accounts
users

Correct return example:

{
"code": 0,
"message": "success",
"result":
{
"imei": "868120145233604",
"deviceName": "868120145233604",
"mcType": "GT300L",
"mcTypeUseScope": "personal",
"sim": "415451",
"expiration": "2037-04-01 23:59:59",
"activationTime": "2017-04-01 11:02:20",
"reMark": "test",
"vehicleName": null,
"vehicleIcon": "bus",
"vehicleNumber": "粤 B3604",
"vehicleModels": null,
"carFrame": "2235",
"driverName": "driver",
"driverPhone": "13825036579",
"enabledFlag": 1,
"engineNumber": "8565674",
"iccid": "xxxxxxx",
"imsi": "xxxx",
"importTime": "2017-04-01 11:02:20",
Shenzhen Jimi Software Co., Ltd.

"licensePlatNo": "8565674",
"VIN": "xxxxxxx",
"vehicleBrand": "xxxx",
"fuel_100km": "9",
"status": "8565674"
}
}

Return error example:

{"code":xxx,"message":"Account queried doesn’t exist"}

7.13 Get location of devices by account

7.13.1 Description

Get the latest location for all devices under an account.

7.13.2 Request URL

See the unique request URL.


Method = jimi.user.device.location.list

7.13.3 HTTP request method

POST

7.13.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token for security access JIMI
access_token string Yes
Server.

target string Yes - Specify the account for inquired.

map_type=GOOGLE, calibrated by google


map_type string No -
calibration.
Shenzhen Jimi Software Co., Ltd.

map_type=null, return origin latitude and


longitude

7.13.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
If code is not 0, there will be a corresponding error message
message string
The returned data
result String The returned data

Result data:
Key Type Description
imei string Device IMEI

deviceName string Device name

icon string Vehicle icon


status string Device status 0 - offline; 1 - online
Lat double Longitude (if the device is expired, the value is 0)
Lng double Latitude (if the device is expired, the value is 0)
expireFlag string Expired or not: 1- expired; 0 - not expired

activationFlag string Activate or not 1 - Activate; 0 - Not active


posType string GPS, LBS, WIFI,BEACON
locDesc string Location information
gpsTime string GPS positioning time
hbTime string Heartbeat time

Speed string Speed (unit: km / h)


accStatus string ACC 0-OFF; 1-ON

electQuantity String Device battery (0-100), some models are not supported
powerValue String External voltage(0-100), some models are not supported

temperature String temperature (unit:℃)

trackerOil String
Oil quantity of the car(Original voltage value)
Shenzhen Jimi Software Co., Ltd.

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"imei": "868120145233604",
"deviceName": "868120145233604",
"icon": "bus",
"status": "0",
"posType": "GPS",
"lat": 22.577282,
"lng": 113.916604,
"hbTime": "2017-04-26 09:14:50",
"accStatus": "0",
"speed": "0",
"gpsTime": "2017-04-26 09:17:46",
"activationFlag": "1",
"expireFlag": "1",
"electQuantity": "60",
"locDesc": null
"powerValue": null,
"temperature": "86.5",
"trackerOil": null

}
]
}

Wrong return example:

{"code":xxx,"message":"The account does not exist"}

7.14 Get the location of device(s)

7.14.1 Description

Get the latest location for one or multiple devices.


Shenzhen Jimi Software Co., Ltd.

7.14.2 Request URL

See the unique request URL.


Method = jimi.device.location.get

7.14.3 HTTP request method

POST

7.14.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


access_token string Yes access token: used to security access JIMI server.

Device IMEI. Separate imei by comma; POST is


imeis string Yes _
recommended if too many devices (maximum 100 IMEI)

map_type=GOOGLE, calibrated by google calibration.


map_type string No _
map_type=null, return origin latitude and longitude

7.14.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data

Result list:
Key Type Description
IMEI string Device IMEI
deviceName string Device name

Icon string Vehicle icon


status string Device status 0, offline; 1, online
Lat double Longitude (if the device expires, the value is 0)
Lng double Latitude (if the device expires, the value is 0)
Shenzhen Jimi Software Co., Ltd.

expireFlag string 1- expired; 0 - not expired


activationFlag string 1 - Activate; 0 - Not active

posType string GPS, LBS, WIFI, BEACON


locDesc string Location information

gpsTime string GPS positioning time


hbTime string Heartbeat time
speed string Speed (unit: km / h)
accStatus string ACC 0- off ;1- on
electQuantity String battery(0-100), Some device models are not supported
powerValue String External voltage(0-100), Some device models are not supported
distance String distance from device.

temperature String temperature (unit:℃)


trackerOil String Oil quantity of the car(Original voltage value)

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"imei": "868120145233604",
"deviceName": "868120145233604",
"icon": "bus",
"status": "0",
"posType": "GPS",
"lat": 22.577282,
"lng": 113.916604,
"hbTime": "2017-04-26 09:14:50",
"accStatus": "0",
"speed": "0",
"gpsTime": "2017-04-26 09:17:46",
"activationFlag": "1",
"expireFlag": "1",
"electQuantity": "60",
"locDesc": null
"powerValue": null,
"temperature": "86.5",
"trackerOil": null
Shenzhen Jimi Software Co., Ltd.

}
]

Wrong return example:

{"code":xxx,"message":"Illegal device"}

7.15 Get sharing location URL

7.15.1 Description

Get the URL of device location showing on the Map.

7.15.2 Request URL

See the unique request URL.


Method = jimi.device.location.URL.share

7.15.3 HTTP request method

POST

7.15.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


access_token string Yes access token: used to security access JIMI server.

imei string Yes _ Device IMEI

7.15.5 Response

Key Type Description


Shenzhen Jimi Software Co., Ltd.

Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message

result String The returned data contains URL information.

Correct return example:

{
"code": 0,
"message": "success",
"result":
{
"URL":
"data.16180track.com/api/share?ver=2&method=trackDevice_abr&deviceinfo=7ae7c62385f2067f16400
2db315854a969a40e3888021cb01dc8f2183ca08dbbd8581f6bb86df4c2e3e1b887cb67c21039b4c0ced18fdf8dd
08e0460c5edd13ad87e16dca9702ce6",
}

Wrong return example:

{"code":xxx,"message":"Illegal device"}

7.16 Update user expiration date

7.16.1 Description

Update user expiration date of devices.

7.16.2 Request URL

See the unique request URL.


Method = jimi.user.device.expiration.update

7.16.3 HTTP request method

POST
Shenzhen Jimi Software Co., Ltd.

7.16.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


access_token string Yes access token: used to security access JIMI server.

imei_list string Yes _ One or multiple devices IMEI.

new_expiration String Yes New user expiration date for devices.

7.16.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data contains URL information.

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"imei": "868120145233604",
"update_result": "0",
"update_msg": "update success"
},
{
"imei": "868120145233605",
"update_result": "1",
"update_msg": "update failed, reason:xxxxxx"
}

}
Shenzhen Jimi Software Co., Ltd.

Wrong return example:

{"code":xxx,"message":"Illegal device"}

7.17 Get the mileage data of devices

7.17.1 Description

Get device(s) mileage data of specified time range.

7.17.2 Request URL

See the unique request URL.


Method = jimi.device.track.mileage

7.17.3 HTTP request method

POST

7.17.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


access_token string Yes - Access token: used to identify legal client.

imeis string Yes - Device imeis, separate by comma.

Start time
begin_time number Yes -
Format: yyyy-MM-dd HH:mm:ss

End time

end_time number Yes - Format: yyyy-MM-dd HH:mm:ss


end_time should be earlier than current time

start_row number No - Row number of result set.

page_size number No Records in one page.


Shenzhen Jimi Software Co., Ltd.

7.17.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data

result list:
Key Type Description
imei String IMEI of device
startTime String Start time

endTime string End time


startLat string Latitude of start position.

startLng string Longitude of start position.


endLat string Latitude of end position.
endLng String Longitude of end position.
runTimeSecond Int Second of elapsed between start and end position.
Doubl
distance Distance(meter) between start and end position.
e
Doubl
avgSpeed Average speed
e

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"imei": “3505831983422342”,
"startTime": "2017-04-26 00:00:58",
"endTime": "2017-04-26 00:03:58",
"startLat": 22.577144898887813,
"startLng": 113.91674845964586,
"endLat": 22.677144898887813,
"endLng": 113.92674845964586,
Shenzhen Jimi Software Co., Ltd.

"elapsed": 2130,
"distance": 25000,
"avgSpeed": 90
}
]

7.18 Get the track data of device

7.18.1 Description

Get device track data of not more than 2 days, within 3 months.

7.18.2 Request URL

See the unique request URL.


Method = jimi.device.track.list

7.18.3 HTTP request method

POST

7.18.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


access_token string Yes - Access token: used to identify legal client.

imei string Yes - Device imei( only 1 each time)

Start time
begin_time number Yes -
Format: yyyy-MM-dd HH:mm:ss

End time

end_time number Yes - Format: yyyy-MM-dd HH:mm:ss


end_time should be earlier than current time

map_type string No - map_type=GOOGLE, calibrated by google


Shenzhen Jimi Software Co., Ltd.

calibration.
map_type=null, return origin latitude and longitude

7.18.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data

result list:
Key Type Description
lng double longitude
lat double latitude
gpsTime string GPS positioning time. Format yyyy-MM-dd HH: mm: ss
direction string Direction, polar coordinates started from due north
gpsSpeed string GPS speed

posType string 1-GPS, 2-LBS, 3-WIFI


satellite String GPS antenna signal strength

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"lat": 22.577144898887813,
"lng": 113.91674845964586,
"gpsTime": "2017-04-26 00:00:58",
"direction": 0,
"gpsSpeed": -1,
"posType": 3
},
{
"lat": 22.57708,
"lng": 113.916631,
"gpsTime": "2017-04-26 00:01:30",
Shenzhen Jimi Software Co., Ltd.

"direction": 184,
"gpsSpeed": 0,
"posType": 1
}
]

Return error example:

{"code":xxx,"message":"IMEI does not exist{353419031939627}"}


{" code ":xxx,"message":"The device has expired{353419031939627}"}

7.19 Update vehicle information by IMEI

7.19.1 Description

Update vehicle information by IMEI

7.19.2 Request URL

See the unique request URL.


Method = jimi.open.device.update

7.19.3 HTTP request method

POST

7.19.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.

imei String Yes - Device IMEI

device_name string No - Device name


Shenzhen Jimi Software Co., Ltd.

vehicle_name string No - Vehicle name

vehicle_icon string No - Vehicle icon

vehicle_number string No - Vehicle plate number

vehicle_models string No - Vehicle brand

driver_name string No - Driver name

driver_phone string No - Driver phone

No 0 - disable/1-enable.
device_status String
Enable/Disable devices.

7.19.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message

result String The returned data

Correct return example:

{
"code": 0,
"message": "Vehicle information modification successful",
"result": null
}

Wrong return example:

{"code":xxx,"message":"imei doesn’t exists"}

Vehicle Icon
Icon key Description
automobile Car
bus Bus
per People
mtc Motorcycle
truck
taxi
plane
schoolBus
excavator
ship
Shenzhen Jimi Software Co., Ltd.

tricycle
policeMtc Police Motorcycle
tractor
policeCar
cow
other

7.20 Get Device Photo or Video URL

7.20.1 Description

Get device photo or video URL which capture by camera.


REMARK: ONLY GET THE VIDEO OR PHOTO WHICH CREATED BY REMOTE COMMAND.
TO GET ALL TYPE PHOTO OR VIDEO, PLEASE USE 7.38 API

7.20.2 Request URL

See the unique request URL.


Method = jimi.device.media.URL

7.20.3 HTTP request method

POST
Shenzhen Jimi Software Co., Ltd.

7.20.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.

imei String Yes - Device IMEI

camera String YES 1-front 2- inward 3 both

media_type String YES 1 -photo 2-video 3-both

start_time Date NO Start time of photo or video created.

end_time Date NO End time of photo or video created.

Token used to validate whether can


token String NO
access photo or video or not.

page_no int NO Zero indexed, 0 by default.

page_size int NO 10 rows by default.

7.20.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data,could be multiple rows.

result list:
Key Type Description
thumb_URL String URL of video or photo thumbnail.

file_URL String URL of video or photo.


mime_type String Mime type of video or photo

create_time Date Create time of video or photo.


media_type string 1-photo 2-video
camera String 0-front camera 1-inward camera

file_size int File size of photo or video.

Correct return example:


Shenzhen Jimi Software Co., Ltd.

{
"code": 0,
"message": "Operation successful",
"result":
[
{
"thumb_URL": “Q9GLAFFqfCrYF6YfQAcON4w4Ezs=/lhWse7ie3wtFrjuQZ22dLAk5CSaR”,
"file_URL": “357730090345670_3949477_2019_04_29_12_32_38_01”,
"mime_type": "video/mp4",
"create_time": 2019-04-29 10:32:43,
"media_type": 2,
"camera": 1,
"file_size": 9949087
},
{
"thumb_URL": “Q9GLAFFqfCrYF6YfQAcON4w4Ezs=/FhCrZEIy3518sR_ylOlqDg7w3Ju-”,
"file_URL": “351609080120911_3949476_2019_04_29_18_32_12”,
"mime_type": "video/3gpp",
"create_time": 2019-04-29 10:32:42,
"media_type": 2,
"camera": 1,
"file_size": 2411318
}

Wrong return example:

{"code":xxx,"message":"imei doesn’t exists"}

7.21 Get Device Live Steaming Page URL

7.21.1 Description

Get device live streaming page URL& last position information.


Shenzhen Jimi Software Co., Ltd.

7.21.2 Request URL

See the unique request URL.


Method = jimi.device.live.page.url

7.21.3 HTTP request method

POST

7.21.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.

imei String Yes - Device IMEI

If v=2, need to provide token

v String No parameter, Jimi server will use this


token to validate URL.

Token used to validate whether can


token String No
access live video or not.
Type=1 real-time video
type String No Default type=1
Type=2 Historical video

voice String No Default 1 0 is disable; 1 is enable

7.21.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data

result list:
Key Type Description
lng double longitude
Shenzhen Jimi Software Co., Ltd.

lat double latitude


gpsTime string GPS positioning time. Format yyyy-MM-dd HH: mm: ss

direction string Direction, polar coordinates started from due north


gpsSpeed string GPS speed

posType string 1-GPS, 2-LBS, 3-WIFI


satellite String GPS antenna signal strength
VIN String VIN
plateNo String License Plate Number
UrlCamera String Live streaming page URL

Correct return example:

{
"code": 0,
"message": "Vehicle information modification successful",
"result":
{
"lat": 22.577144898887813,
"lng": 113.91674845964586,
"gpsTime": "2017-04-26 00:00:58",
"direction": 0,
"gpsSpeed": -1,
"posType": 3,
"satellite": 11,
"VIN": "V12345",
"plateNo":"ABC-12345",
"UrlCamera": "https://www.domain.com/device/video/35408343202342345",
}

Wrong return example:

{"code":xxx,"message":"imei doesn’t exists"}


Shenzhen Jimi Software Co., Ltd.

7.22 Wi-Fi, Base Station locating analysis

7.22.1 Description

Allocate by total devices under the account (10 times/day/device. All sub-accounts included)

7.22.2 Request URL

See the unique request URL.


Method = jimi.lbs.address.get

7.22.3 HTTP request method

POST

7.22.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


access_token string Yes access token: used to identify legal client.

imei number Yes - Device Imei

(wifi/LBS: at least one)


LBS inforamtion group (mcc,mnc,lac,cell,rssi), max 7. Each
group has five, which should not be null and sorted in order.
MCC, China: 460
lbs number No -
MNC
LAC information, 2312 23222
CELL code: 23222
RSSI Semaphore-70

(wifi/LBS: at least one)


mac1,rssi1| mac2,rssi2
wifi string No -
Mac address, no colon in between.
Rssi signal strength
Shenzhen Jimi Software Co., Ltd.

7.22.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result string The returned data

Result list:
Key Type Description
lng string longitude
lat string latitude
accuracy string Accuracy, the greater the value the better

Correct return example:

{
"code": 0,
"message": "success",
"result": {
"lat": 40.65615416521587,
"lng": 109.89894039833524,
"accuracy": 0
}
}

Wrong return example:

{"code":xxx,"message":"illegal device"}

7.23 Create Geo-fence for IMEI

7.23.1 Description

Create Geo-fence for IMEI


Shenzhen Jimi Software Co., Ltd.

7.23.2 Request URL

See the unique request URL.


Method = jimi.open.device.fence.create

7.23.3 HTTP request method

POST

7.23.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


Yes accesstoken: used for
access_token string
identifying legal third party
imei String Yes - Device Imei
fence_name string Yes - Geo-fence name
alarm_type string Yes - Alarm type (in / out / in, out)
Yes - Alarm reporting mode, 0:
report_mode string
GPRS,1: SMS+GPRS
alarm_switch string Yes - Fence alarm switch(ON/OFF)
lng string Yes - Longitude
lat string Yes - latitude
Yes - Fence radius(1~9999;
radius string
unit: 100 meters)
zoom_level string Yes - Zoom level (3-19)
map_type string Yes - Map (GOOGLE)

7.23.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data. Fence serial number returned if succeed.
Shenzhen Jimi Software Co., Ltd.

Correct return example:

{
"code": 0,
"message": "Successfully create geo-fence.",
"result": "5"
}

Wrong return example:

{
"code": 41003,
"message": "Device is not online, geo-fence creation failed ",
"result": null
}

7.24 Delete Geo-fence for device

7.24.1 Description

Delete Geo-fence for device.

7.24.2 Request URL

See the unique request URL.


Method = jimi.open.device.fence.delete

7.24.3 HTTP request method

POST

7.24.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


Shenzhen Jimi Software Co., Ltd.

Yes accesstoken: used for


access_token string
identifying legal third party
imei String Yes - Device imei
Yes Geo-fence command serial
instruct_no string -
number

7.24.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
If code is not 0, there will be a corresponding error message
message string

result String The returned data

Correct return example:

{
"code": 0,
"message": "delete the geo-fence successfully",
"result": null

Return error example:

{
"code": 41003,
"message": "The device is not online and geo-fence can’t be deleted",
"result": null
}

7.25 Get command list supported by device

7.25.1 Description

Get command list supported by device


Shenzhen Jimi Software Co., Ltd.

7.25.2 Request URL URL

See the unique request URL.


Method = jimi.open.instruction.list

7.25.3 HTTP request method

POST

7.25.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


accesstoken: used for
access_token string Yes
identifying legal third party
imei String Yes - Device imei

7.25.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message

result String The returned parameters

Result list:
Key Type Description
id string Command code
orderName string Command name
orderContent string Command template
orderExplain string Command explanation
orderMsg string prompt
isOffLine string if support offline command 0-no; 1-yes

Correct return example:


Shenzhen Jimi Software Co., Ltd.

{
"code": 0,
"message": "success",
"result": [
{
"id": 81,
"orderName": "SOS setting",
"orderContent": "SOS,A,{0},{1},{2}#",
"orderExplain": "SOS is used for receive alerts and SOS alerts. SOS number
should have 3-20 numbers.",
"orderMsg": "",
"isOffLine": "1"
}
...
]

Return error example:

{"code":xxx,"message":"Illegal device"}

7.26 Send command to device

7.26.1 Description

Send command to device.

7.26.2 Request URL

See the unique request URL.


Method = jimi.open.instruction.send

7.26.3 HTTP request method

POST

7.26.4 Request parameters

(1)Common parameters
Shenzhen Jimi Software Co., Ltd.

(2)private parameters

Parameter Type Required Remark Description


accesstoken: used for identifying
access_token string Yes
legal third party
imei String Yes - Device imei
Command message json
inst_param_json string Yes -
character string

inst_param_json description
Parameter Type Required Remark Description
inst_id string Yes Command code

inst_template String Yes - Command template

params Array<string> Yes - Command params string Array

Whether cover the existed offline


is_cover Boolean NO false command or not
true-cover false-not cover

Example:
{"inst_id": "113","inst_template":"RELAY,1#","params":[],"is_cover":"true"}
{"inst_id": "114","inst_template":"RELAY,0#","params":[],"is_cover":"true"}

User-defined command:
{"inst_id": "96","inst_template":"{0}","params":["STATUS#"],"is_cover":"true"}

7.26.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description

message string If code is not 0, there will be a corresponding error message

result String The returned parameters

Correct return example:

{
"code": 0,
"message": "command is successfully sent.",
"result": null

}
Shenzhen Jimi Software Co., Ltd.

Return error example:

{
"code": 12005,
"message": "Fail to send command. Result code:226",
"result": null
}

7.27 Get results of command execution

7.27.1 Description

Get results of sending command.

7.27.2 Request URL

See the unique request URL.


Method = jimi.open.instruction.result

7.27.3 HTTP request method

POST

7.27.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


accesstoken: used for identifying legal
access_token string Yes
third party

imei string Yes - Device imei


Shenzhen Jimi Software Co., Ltd.

7.27.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data

Result list:
Key Type Description
codeId string Command code
code string Command sent
content string Content replied by device
isExecute string command status 0: execution failed, 1: successful execution, 3:
to be sent, 4: canceled
sendTime string Time, format:yyyy-MM-dd HH:mm:ss
sender string sender
receiveDevice string Received imei
isOffLine string 0: online 1: offline
idsource string Command description

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"codeId": "99",
"code": "status#",
"content": "Parameter error",
"isExecute": "4",
"sendTime": "2017-06-19 11:46:00",
"sender": "jimitest",
"receiveDevice": "868120111111117",
"isOffLine": "1",
"idsource": "User-defined command"
}
Shenzhen Jimi Software Co., Ltd.

Return error example:

{"code":xxx,"message":"Illegal device"}

7.28 Send raw command data to device

7.28.1 Description

Send raw command to device.

7.28.2 Request URL

See the unique request URL.


Method = jimi.open.instruction.raw.send

7.28.3 HTTP request method

POST

7.28.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


accesstoken: used for identifying
access_token string Yes
legal third party
imei String Yes - Device imei
raw_cmd string Yes - Raw command data(hex string)

Raw Command Example:

0B02C3A405060708
Shenzhen Jimi Software Co., Ltd.

7.28.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description

message string If code is not 0, there will be a corresponding error message

result String The returned parameters

Correct return example:

{
"code": 0,
"message": "command is successfully sent.",
"result": null

Return error example:

{
"code": 12005,
"message": "Fail to send command. Result code:226",
"result": null
}

7.29 Push Received Raw Data

7.29.1 Description

Third-party platform should provide an URL(same as messages push URL) to receive the raw
data(please contact us and provide the URL manually), JIMI server will push the raw data by
sending a HTTP request using this URL.
Shenzhen Jimi Software Co., Ltd.

7.29.2 Message service List

Message Type Description


jimi.open.instruction.ra
Raw data receive message type, different from alarm message.
w.receive

Request content:
Key Type Description
msgType String Message type, corresponding to the message service list

data String The content of the message, corresponding to msgType

7.29.3 Message content ( jimi.open.instruction.raw.receive)

Alarms pushed are as follows:


Key Type Description

imei string Device imei


deviceName string Device name
raw_data string raw data from device.(hex string)

E.g:
Parameter1:
Key = msgType
Value = jimi.open.instruction.raw.receive

Parameter2:
Key = data
Value = {
"imei": "868120145233604",
"deviceName": "868120145233604",
"raw_data": "0A0C0F01182E0101"
}
Shenzhen Jimi Software Co., Ltd.

7.30 Send media instruction

7.30.1 Description

Send video or photo command to device.

7.30.2 Request URL

See the unique request URL.


Method = jimi.device.meida.cmd.send

7.30.3 HTTP request method

POST

7.30.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.

imei String Yes - Device IMEI

mediaType=1 Only 1-front camera 2- inward camera 3-


camera String YES
limited 1 or 2 front + inward camera

mediaType String YES 1 -photo 2-video

shootTime String NO 0 or 3-10 mediaType=2 Recording duration 3-10

7.30.5 Response

Key Type Description


Return code:
code int 0: Success
outher:failure. Refer to the error code description

{"code":"100","data":"1.3.3","msg":"通信成功响应","cmdSeqNo":"1"}
Result JSON
Return code:
Shenzhen Jimi Software Co., Ltd.

225: time out


226: Parameter error
227: The command is not executed correctly
228: The device is not online
229: Network error, connection error, etc.
238: Device interrupted
240: Data format error

message string Description of sending command result.

Success example:

{
"code": 0,
"message": "Operation successful",
"result": {"code":"255","data":"1.3.3","msg":"通信成功响应","cmdSeqNo":"1"}
}

Exception example:

{
"code": -1,
"message": "Operation successful",
"result": {"code":"228","data":"1.3.3","msg":"设备不在线","cmdSeqNo":"1"}
}

7.31 Receive Notification

7.31.1 Description

Third-party platform should provide an URL address to receive the notification(please contact us
and provide the URL manually), JIMI server will push the notification by sending a HTTP request
using this URL.

7.31.2 Message service List

Message Type Description


jimi.push.device.alarm Alarm data
Shenzhen Jimi Software Co., Ltd.

Request content:
Key Type Description
msgType String Message type, corresponding to the message service list

data String The content of the message, corresponding to msgType

7.31.3 Message content ( jimi.push.device.alarm)

Alarms pushed are as follows:


Key Type Description

imei string Device imei


deviceName string Device name
alarmType string Alarm type

alarmName string Alarm name


lat string Latitude

lng string Longitude


alarmTime string Alarm time, format (yyyy-MM-dd HH: mm: ss)

E.g:
Parameter1:
Key = msgType
Value = jimi.push.device.alarm

Parameter2:
Key = data
Value = {
"imei": "868120145233604",
"deviceName": "868120145233604",
"alarmType": "2",
"alarmName": "Power off alarm",
"lat": 40.65615416521587,
"lng": 109.89894039833524,
"alarmTime": "2017-05-08 12:00:00"
}
Shenzhen Jimi Software Co., Ltd.

7.32 Get device alarm list

7.32.1 Description

Get device alarm list.


Time range of searching criteria should be within 1 month.
Return maximum 1000 rows.

7.32.2 Request URL

See the unique request URL.


Method = jimi.device.alarm.list

7.32.3 HTTP request method

POST

7.32.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


accesstoken: used for identifying legal
access_token string Yes
third party

imei string Yes - Device imei

If not specify alertTypeId, all alert type


alertTypeId String No
will return.

if not provide begin_time & end_time,


begin_time Date NO
returns latest 50 alerts of last 1 month.
end_time Date NO

7.32.5 Response

Key Type Description


Shenzhen Jimi Software Co., Ltd.

Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message

result String The returned data

Result list:
Key Type Description
DeviceName string Device Name
IMEI string IMEI
model string Device Model
account string Account
alertTypeId String Alert type ID
alertType string Alert type
alertTime string Alert time
positioningTi string
Time of alert positioning
me
lng double longitude
lat double latitude

Correct return example:

{
"code": 0,
"message": "success",
"result": [
{
"deviceName": "ABC-34352",
"IMEI": "343503422910345",
"model": "GT06N",
"account": "test1234",
"alertTypeId": "1002",
"alertType": "ACC On",
"alertTime": "2019-03-14 14:02:03",
"positioningTime": "2019-03-14 14:02:03",
"lat": 22.577144898887813,
"lng": 113.91674845964586
}
]
Shenzhen Jimi Software Co., Ltd.

Return error example:

{"code":xxx,"message":"Illegal device"}

7.33 Send command (for scooter device)

7.33.1 Description

Send command to scooter device.

7.33.2 Request URL

See the unique request URL.


Method = jimi.scooter.instruction.send

7.33.3 HTTP request method

POST

7.33.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


accesstoken: used for identifying
access_token string Yes
legal third party
imei String Yes - Device imei
Command send to device, for
example:
To enable scooter, cmd_code can
cmd_code string Yes - be set as: ENABLE#
To lock scooter, cmd_code set as:
LOCK#
Shenzhen Jimi Software Co., Ltd.

Note, sign # is required.

7.33.5 Response

Key Type Description


Return code:
100: Success
200:Invalid parameter
code int 300: Device is offline
301:Device unregistered
400:Network unavailable
600: HTTP request timeout

message string Description of sending command result.

Success example:

{
"code": 100,
"message": "Success"

Exception example:

{
"code": 200,
"message": "Invalid parameter"
}

7.34 Get detail information of scooter

7.34.1 Description

Get detail information and status of device.


Shenzhen Jimi Software Co., Ltd.

7.34.2 Request URL

See the unique request URL.


Method = jimi.scooter.device.detail

7.34.3 HTTP request method

POST

7.34.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


accesstoken: used for identifying legal
access_token string Yes
third party

IMEI of scooter, multiple scooter


imei string Yes - Separated by commas, for example:
350583223422451,350583223422452

7.34.5 Response

Key Type Description


Return code:
code int 0: return success
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data(json)

Result list:
Key Type Description
deviceImei string IMEI of IoT module
realtimeStatus json DLCC status
DLCC 0 - OFF
1 - ON
Brake status
brake 0 - OFF
1 - ON
Shenzhen Jimi Software Co., Ltd.

Setting brake light status


settingBrakeLight 0 - OFF
1 - ON
Setting front light status
0 - OFF
settingFrontLight
1 - ON

Real front light status


realFrontLight 0 - OFF
1 - ON
Real brake light status
realBrakeLight 0 - OFF
1 - ON
Charge status
charge 0 - OFF
1 - ON
0 - OFF
acceleratorStatus
1 - ON
0 - OFF
motoStatus
1 - ON
Driving mode.
0 - Disability mode
1 - Lock mode
workingMode
2 - Enabling mode
3 - Charging mode
4 - Maintenance mode
json BAT level, for example, if
batteryLevel BAT level = 50%,
batteryLevel value is 50.
current Output current
speed Speed(Hall)
voltage BAT voltage
realtimeData
batteryCycle Battery cycle
totalOdometer Total mileage
Mileage of current
currentOdometer
trip(before disabled).
batteryTemperature °C
remainingMileage Remaining mileage
json ECUVersion ECU version
batteryCapacity Battery capacity
scooterProperties
batteryVoltage Scooter rated voltage
bluetoothVersion Bluetooth version
Shenzhen Jimi Software Co., Ltd.

firmwareVersion Firmware version


scooterVersion Scooter version
Scooter maximum
speedLimit
speed
json IoT 0 - OK 1-error
accelerator 0 - OK 1-error
battery 0 - OK 1-error
brakeHandlebar 0 - OK 1-error
scooterError
controller 0 - OK 1-error
dashboard 0 - OK 1-error
voltage 0 - OK 1-error
Motor 0 - OK 1-error
json 0 - GPS not available
gpsStatus
1 - GPS positioning
course Direction of positioning
satellite Satellite number
gpsSpeed Speed
gpsTime Positioning time
GPS
positioningType LBS
WIFI
latitude Latitude
longitude Longitude
IoTModule
0 - No signal
1 - Extremely week
gsmSignal 2 - Week
3 - Strong
4 - Extremely strong
mCC mCC
mNC mNC
BluetoothMac string
iccid string
imsi String
batteryVoltage Battery voltage

Correct return example:


Shenzhen Jimi Software Co., Ltd.

"code": 0,

"msg": "Operation success.",

"result":

"deviceImei": "860425040472944",

"scooterError": {

"IoT": 0,

"accelerator": 0,

"battery": 0,

"brakeHandlebar": 0,

"controller": 0,

"dashboard": 0,

"motor": 0,

"voltage": 0

},
Shenzhen Jimi Software Co., Ltd.

"scooterProperties": {

"ECUVersion": "0.1",

"batteryCapacity": 22834,

"batteryVoltage": 36,

"bluetoothVersion": "2.1",

"firmwareVersion": "c.0",

"scooterVersion": "3.0",

"speedLimit": 50

},

"realtimeData": {

"totalOdometer": 14592,

"batteryCycle": 512,

"batteryLevel": 56,

"batteryTemperature": 23,

"current": 614.39,

"currentOdometer": 217.6,

"remainingMileage": 69.2,

"speed": 99.86,

"voltage": 460.94

},

"realtimeStatus": {

"DLCC": 0,

"DLCCStatus": 0,

"acceleratorStatus": 0,

"brake": 0,

"settingBrakeLight": 1,

"charge": 0,

"settingFrontLight": 0,

"realFrontLight": 0,

"motoStatus": 0,

"realBrakeLight": 0,
Shenzhen Jimi Software Co., Ltd.

"workingMode": 0

},

"drivingSetting": {

"DLCC": 0,

"drivingMode": 2,

"lightMode": 0,

"quickStart": 1,

"speedLimit": 30,

"speedUnit": 0

},

"IoTModule": {

"imsi": "0460045394000271",

"iccid": "89860433231880390271",

"BluetoothMac": "000000000000",

"satellite": 11,

"course": 0,

"gpsMode": 0,

"gpsSpeed": 0,

"gpsTime": "2019-05-09 18:41:12",

"lAC": 0,

"latitude": 22.577137,

"longitude": 113.916756,

"mCC": 0,

"mNC": 0,

"positioningType": "GPS",

"gsmSignal": 4,

"gpsStatus": 0,

"batteryVoltage": 4.15

}
Shenzhen Jimi Software Co., Ltd.

Return error example:

{"code":xxx,"message":"Illegal device"}

7.35Get history video list

7.35.1 Description

Send Historical video file list upload command to device or query file list.

7.35.2 Request URL

See the unique request URL.


Method = jimi.device.history.file.list

7.35.3 HTTP request method

POST

7.35.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.

imei String Yes - Device IMEI

type String Yes 1-upload 2- query

7.35.5 Response

Key Type Description


Return code:
code int 0: Success
outher:failure. Refer to the error code description
Shenzhen Jimi Software Co., Ltd.

type=1
{"code":"100","data":"1.3.3","msg":"Successful
response","cmdSeqNo":"1"}
Return code:
225: time out
226: Parameter error
Result JSON 227: The command is not executed correctly
228: The device is not online
229: Network error, connection error, etc.
238: Device interrupted
240: Data format error
type=2
{" 2018_03_29_16_51_45.mp4,2018_03_29_16_52_46.mp4,"}

message string Description of sending command result.

type=1

Success example:

{
"code": 0,
"message": "Operation successful",
"result": {"code":"255","data":"1.3.3","msg":"Successful response","cmdSeqNo":"1"}
}

Exception example:

{
"code": -1,
"message": "Operation successful",
"result": {"code":"228","data":"1.3.3","msg":"Device is offline","cmdSeqNo":"1"}
}

type=2

{
"code": 0,
"message": "Operation successful",
"result": "2018_03_29_16_51_45.mp4,2018_03_29_16_52_46.mp4,"}
}
Shenzhen Jimi Software Co., Ltd.

7.36Send history video instruction

7.36.1 Description

Send upload history video file command to device.

7.36.2 Request URL

See the unique request URL.


Method = jimi.device.history.cmd.send

7.36.3 HTTP request method

POST

7.36.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.

imei String Yes - Device IMEI

type String Yes 1-Full fragment 2-Event fragment

camera String Yes 1-out 2-in

fileName String No type=1 is not null Historical video file name

Event time point, time format yyyy-


time String No type=2 is not null
MM-dd HH:mm:ss

7.36.5 Response

Key Type Description


Return code:
code int
0: Success
Shenzhen Jimi Software Co., Ltd.

outher:failure. Refer to the error code description

{"code":"100","data":"1.3.3","msg":"Successful
response","cmdSeqNo":"1"}
Return code:
225: time out
226: Parameter error
Result JSON 227: The command is not executed correctly
228: The device is not online
229: Network error, connection error, etc.
238: Device interrupted
240: Data format error

message string Description of sending command result.

Success example:

{
"code": 0,
"message": "Operation successful",
"result": {"code":"255","data":"1.3.3","msg":"Successful response","cmdSeqNo":"1"}
}

Exception example:

{
"code": -1,
"message": "Operation successful",
"result": {"code":"228","data":"1.3.3","msg":"Device is offline","cmdSeqNo":"1"}
}

7.37 get video rtmp url

7.37.1 Description

Get video rtmp url

7.37.2 Request URL

See the unique request URL.


Method = jimi.open.video.rtmp.url
Shenzhen Jimi Software Co., Ltd.

7.37.3 HTTP request method

POST

7.37.4 Request parameters

(1)Common parameters
(2)private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.

imei String Yes - Device IMEI

7.37.5 Response

Key Type Description


Return code:
code int 0: Success
outher:failure. Refer to the error code description

{ "code": 0,"message": "success","result":


“rtmp://36.133.0.208:1935/0/353376110035950?uId=openapi8b7914c3e
4c188def67edd6b4a743146&vhost=8&user=172&expire_stamp=1595923
486798&ext=&channel=0&token=25b422283ff824461b33d8c5059d”
}
Return code:
225: time out
Result JSON
226: Parameter error
227: The command is not executed correctly
228: The device is not online
229: Network error, connection error, etc.
238: Device interrupted
240: Data format error

message string Description of sending command result.

Success example:

{
Shenzhen Jimi Software Co., Ltd.

"code": 0,
"message": "success",
"result":
“rtmp://36.133.0.208:1935/0/353376110035950?uId=openapi8b7914c3e4c188def67edd6b4a743146&vhost=8&
user=172&expire_stamp=1595923486798&ext=&channel=0&token=25b422283ff824461b33d8c5059d”
}

Exception example:

{
"code": 228,
"message": "The device is not online",
"result": “null”
}

7.38Get Device JIMI Photo or Video URL

7.38.1 Description

Get device photo or video URL which capture by camera.

7.38.2 Request URL

See the unique request URL.


Method = jimi.device.jimi.media.URL

7.38.3 HTTP request method

POST

7.38.4 Request parameters

(1)Common parameters
(2)Private parameters

Parameter Type Required Remark Description


Access token: used to identify legal
access_token string Yes
client.
Shenzhen Jimi Software Co., Ltd.

imei String Yes - Device IMEI

1-front camera 2- inward camera 3


camera String YES
both

media_type String YES 1 -photo 2-video 3-both

start_time Date NO Start time of photo or video created.

end_time Date NO End time of photo or video created.

Token used to validate whether can


token String NO
access photo or video or not.

page_no int NO Zero indexed, 0 by default.

page_size int NO 10 rows by default.

7.38.5 Response

Key Type Description


Return code:
code int 0: return correctly
Other: failure. Refer to the error code description
message string If code is not 0, there will be a corresponding error message
result String The returned data,could be multiple rows.

result list:
Key Type Description
thumb_URL String URL of video or photo thumbnail.
file_URL String URL of video or photo.
mime_type String Mime type of video or photo
create_time long Create time of video or photo.Unix timestamp format
long The time at which the alarm was triggered, Unix timestamp
alarm_time
format
media_type string 1-photo 2-video
camera String 0-front camera 1-inward camera
file_size int File size of photo or video.
Remark: Unix timestamp; Example: 1611105520 = 2021-01-20 09:18:40

Correct return example:

{
"code": 0,
"message": "Operation successful",
"result":
[
Shenzhen Jimi Software Co., Ltd.

{
"thumb_URL": "http://8.210.205.58:8081/normal/get?fileKey=2021_01_20_09_17_49_I_28.jpg",
"file_URL": "http://8.210.205.58:8081/normal/get?fileKey=357730090564767_29057540_2021_01_
20_09_17_49_I_28_128.mp4",
"create_time": 1611105520,
"mime_type": "video/mp4",
"media_type": 2,
"alarm_time": 1611105469,
"camera": 0,
"file_size": "12108649"
},
{
"thumb_URL": "http://8.210.205.58:8081/normal/get?fileKey=2021_01_20_08_06_13_I_56.jpg",
"file_URL": "http://8.210.205.58:8081/normal/get?fileKey=357730090564767_00000000_2021_01_
20_08_06_13_I_56_146.mp4",
"create_time": 1611101264,
"mime_type": "video/mp4",
"media_type": 2,
"alarm_time": 1611101173,
"camera": 0,
"file_size": "48452069"
}

Wrong return example:

{"code":xxx,"message":"imei doesn’t exists"}

8 Appendix

Device alarm type(alarm type Id)

Alert type ID.xlsx


Shenzhen Jimi Software Co., Ltd.

Scooter Command List

NCT_SS40_API
command list-1.docx

You might also like