Devices Locations

Create a location report

POST
/loc/v1/locationreports

Request an asynchronous device location report.

Authorization

thingspace_oauth VZ-M2M-Token
AuthorizationBearer <token>

This is the ThingSpace token, from Credentials and Tokens is used

In: header

VZ-M2M-Token<token>

M2M Session Token (How to generate an M2M session token?)

In: header

Request Body

*/*

Request for device location report.

Request for device location report.

accountName*string

Account identifier in "##########-#####".

deviceList*array<>

Device list.

accuracyMode?"0"

Accurary, currently only 0-coarse supported.

Value in

  • "0"
cacheMode?CacheMode

Location cache mode.

Value in

  • "0"
  • "1"
  • "2"

Response Body

application/json

application/json

curl -X POST "https://example.com/loc/v1/locationreports" \  -H "Content-Type: */*" \  -d '<accountName>1234567890-00001</accountName>  <accuracyMode>0</accuracyMode>  <cacheMode>1</cacheMode>  <deviceList>    <id>980003420535573</id>    <kind>imei</kind>    <mdn>7892345678</mdn>  </deviceList>  <deviceList>    <id>375535024300089</id>    <kind>imei</kind>    <mdn>7897654321</mdn>  </deviceList>  <deviceList>    <id>A100003861E585</id>    <kind>meid</kind>    <mdn>7897650914</mdn>  </deviceList>'
{  "txid": "2c90bd28-eeee-ffff-gggg-7e3bd4fbff33",  "status": "QUEUED"}