IntroductionWorking With RecordsActivity ReportsLocation ServicesWebhook ManagementExamplesBatching Requests

Location Services

The Location Services API is a versatile and powerful resource, designed for both indoor and outdoor tracking. It offers a REST method for locating people or objects, providing last-reported and historical location data through straightforward query parameters. Additionally, the API includes robust reporting capabilities for reporting time spent in specific zones and a real-time streaming method to stay updated on data changes, alerts, and state changes as they occur

Locate

https://secure.solve360.com/locate

Example request

https://secure.solve360.com/locate?searchvalue=housekeeping

Or

curl -u '{userEmail}:{userApiToken}' -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -d '{"searchvalue": "housekeeping", "lastreportedwithin": "60", "relativedeviceaddress": "5/290792806/10037602"}' https://secure.solve360.com/locate

Example response

{
  "count": 3,
  "records": [
    {
      "contactid": 292114830,
      "contactname": "Maria Sanchez",
      "deviceaddress": "5/290792806/10037608",
      "location": {
        "timestamp": "2024-08-16 12:52:13",
        "areaid": 290794804,
        "areaname": "Default Area",
        "buildingid": 290794805,
        "buildingname": "Orbit Park Circle",
        "floorid": 291034807,
        "floorlabel": "3",
        "floorlevel": "3",
        "zoneid": 29115831,
        "zonename": "3 22 bathroom",
        "position": "42.50042,-90.733624",
        "source": "ble"
      },
      "distancemeters": 3
    },
    {
      "contactid": 292114833,
      "contactname": "Emily Johnson",
      "deviceaddress": "5/290792806/10037609",
      "location": {
        "timestamp": "2024-08-16 11:51:58",
        "areaid": 290794804,
        "areaname": "Default Area",
        "buildingid": 290794805,
        "buildingname": "Orbit Park Circle",
        "floorid": 291034807,
        "floorlabel": "3",
        "floorlevel": "3",
        "zoneid": 291154831,
        "zonename": "3 22 bathroom",
        "position": "42.50042,-90.733624",
        "source": "ble"
      },
      "distancemeters": 15
    },
    {
      "contactid": 292114836,
      "contactname": "Lily Thompson",
      "deviceaddress": "5/290792806/10037622",
      "location": {
        "timestamp": "2024-08-16 12:52:28",
        "areaid": 290794804,
        "areaname": "Default Area",
        "buildingid": 290794805,
        "buildingname": "Orbit Park Circle",
        "floorid": 291034807,
        "floorlabel": "3",
        "floorlevel": "3",
        "zoneid": 291195876,
        "zonename": "3 19",
        "position": "42.500418,-90.733579",
        "source": "ble"
      },
      "distancemeters": 12
    }
  ],
  "status": "success"
}

Parameters

searchvalue The beginning of the contact's name, up to the full first and last name, or a 'tag type' title, or a contactId

{string}
relativedeviceaddress The device's full network address, used to calculate its distance from other devices in the result set

{string}
lastreportedwithin The number of minutes within which the device's location must have been last updated to be included

{integer}
historyminutes Applied when the result is a single record includes all location updates from the past specified number of minutes

{integer}

Required

Time in zone reports

https://secure.solve360.com/{uri}

Example request

curl -u '{userEmail}:{userApiToken}' -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -d '{"min":1,"max":1440,"range":"2024-08-02 00:00:00,2024-08-30 23:23:59", "deviceaddress":"5/290792406/10037602"}' https://secure.solve360.com/report/timebydevice

Example response

{
  "timebydevice": {
    "contactid": 292113855,
    "contactname": "Walter Stevenson",
    "deviceid": "10037602",
    "devicename": "10037602",
    "count": 6,
    "records": [
      {
        "zoneid": 291309755,
        "zonename": "Hall 2 central",
        "minutesinzone": {
          "hall 2 central": 9481
        }
      },
      {
        "zoneid": 291301711,
        "zonename": "Hall 3 north",
        "minutesinzone": {
          "hall 3 north": 903
        }
      },
      {
        "zoneid": 291306841,
        "zonename": "2 20",
        "minutesinzone": {
          "unit 220": 2991
        }
      },
      {
        "zoneid": 291345885,
        "zonename": "Mens bathroom 1",
        "minutesinzone": {
          "mens bathroom 1": 903
        }
      },
      {
        "zoneid": 291194846,
        "zonename": "3 24",
        "minutesinzone": {
          "unit 324": 905
        }
      },
      {
        "zoneid": 291436895,
        "zonename": "MC commons north",
        "minutesinzone": {
          "mc commons north": 9823
        }
      }
    ]
  },
  "status": "success"
}

Parameters

/report/timebydevice Report time grouped by contact

type (integer)

range (date,date)

min {integer}

max {integer}

deviceaddress (string)

detailed [0,1]

page {integer}

sortby [enter,exit]

sortorder [asc,desc]
/report/timebyzone Report time grouped by zone

type (integer)

range (date,date)

min {integer}

max {integer}

zoneid (integer)

deviceaddress (string)

detailed [0,1]

page {integer}

sortby [enter,exit]

sortorder [asc,desc]
/report/timesummary Report time in zone by tag type

type (integer)

range (date,date)

min {integer}

max {integer}

zones (integer)

Required

Multiple values supported separated by comma

Device status

https://secure.solve360.com/lastseen

List of all devices with last date when information was received.

Example request

https://secure.solve360.com/report/lastseen

Or

curl -u '{userEmail}:{userApiToken}' -X GET -H 'Accept: application/json' https://secure.solve360.com/report/lastseen

Example Response

{
  "lastseen": {
    "count": 6,
    "records": [
      {
        "deviceaddress": "5/290792806/10037605",
        "timestamp": "2024-08-15 22:52:27",
        "devicelabel": "10037605",
        "contactid": 292065856,
        "contactname": "Evelyn Parker"
      },
      {
        "deviceaddress": "5/290792806/451441684",
        "timestamp": "2024-08-15 22:51:55",
        "devicelabel": "451441684",
        "contactid": 292065855,
        "contactname": "Dorothy Campbell"
      },
      {
        "deviceaddress": "5/290792806/1939515070",
        "timestamp": "2024-08-19 13:48:59",
        "devicelabel": "1939515070",
        "contactid": null,
        "contactname": null
      },
      {
        "deviceaddress": "5/290792806/10037607",
        "timestamp": "2024-08-19 17:07:26",
        "devicelabel": "10037607",
        "contactid": 292114827,
        "contactname": "Margaret Turner"
      },
      {
        "deviceaddress": "5/290792806/10037606",
        "timestamp": "2024-08-19 16:11:13",
        "devicelabel": "10037606",
        "contactid": 292114824,
        "contactname": "Leonard Harris"
      },
      {
        "deviceaddress": "5/290792806/10037623",
        "timestamp": "2024-08-19 17:12:08",
        "devicelabel": "10037623",
        "contactid": 292114839,
        "contactname": "Mildred Brooks"
      }
    ]
  },
  "status": "success"
}
https://secure.solve360.com/battery

List of all devices with battery status.

Example request

https://secure.solve360.com/report/battery

Or

curl -s -u '{userEmail}:{userApiToken}' -X GET -H 'Accept: application/json' https://secure.solve360.com/report/battery

Example Response

{
  "battery": {
    "count": 6,
    "records": [
      {
        "unit": "V",
        "deviceaddress": "5/290792806/10037605",
        "battery": "2.95",
        "devicelabel": "10037605",
        "contactid": 292065556,
        "contactname": "Beatrice Scott"
      },
      {
        "unit": "V",
        "deviceaddress": "5/290792806/451441684",
        "battery": "3",
        "devicelabel": "451441684",
        "contactid": 292065455,
        "contactname": "Geraldine Hayes"
      },
      {
        "unit": "",
        "deviceaddress": "5/290792806/1939515070",
        "battery": "None",
        "devicelabel": "1939515070",
        "contactid": null,
        "contactname": null
      },
      {
        "unit": "",
        "deviceaddress": "5/290792806/631638513",
        "battery": "3",
        "devicelabel": "631638513",
        "contactid": null,
        "contactname": null
      },
      {
        "unit": "V",
        "deviceaddress": "5/290792806/10037607",
        "battery": "3.03",
        "devicelabel": "10037607",
        "contactid": 292114027,
        "contactname": "Florence Bennett"
      },
      {
        "unit": "",
        "deviceaddress": "5/290792806/10037614",
        "battery": "3.05",
        "devicelabel": "10037614",
        "contactid": null,
        "contactname": null
      }
    ]
  },
  "status": "success"
}

Real-time streaming updates

To provide real-time updates, we offer access to an MQTT (Message Queuing Telemetry Transport) endpoint. MQTT is a lightweight, publish-subscribe network protocol that ensures you receive instantaneous data changes, alerts, and state changes without the need for constant polling. It's easy to implement and supported by most programming languages, making it ideal for this type of use case. Tools like Node-RED can help you start working with MQTT quickly and efficiently. Although MQTT is a newer protocol, it delivers updates in the familiar JSON format.

Each business or site/location is assigned a unique Solve "organization ID". Norada will provide you with the details to connect to our MQTT endpoint(s) via username/password or X509 certificate to authenticate to a specific organization.

There are currently three types of message streams you can subscribe to: "data", "state", and "alert". The topic format is: {organizationId}/{deviceId}/{messageStream} The deviceId can be a wildcard [ + ], but the other segments must be specified exactly.

Examples

topic: 290792806/+/data

{
  "deviceId": "244725855",
  "contactId": 292114863,
  "contactName": "Edward Montgomery",
  "timeStamp": "2024-08-19 18:37:40",
  "data": {
    "proximity": {
      "label": "Proximity",
      "value": {
        "zoneId": 291345829,
        "zoneIds": [291345829],
        "buildingId": 290794805,
        "floorId": 291002884,
        "anchorId": "209042858",
        "anchorIds": [
          {"deviceId": "209042858", "rssi": -66, "locality": "", "registered": true},
          {"deviceId": "296480576", "rssi": -71, "locality": "", "registered": true},
          {"deviceId": "15165710", "rssi": -74, "locality": "", "registered": true}
        ]
      }
    },
    "position": {
      "label": "Position",
      "value": {
        "coordinates": [42.500352, -90.733674],
        "src": "ble",
        "zoneId": 291345829,
        "zoneIds": [291345829],
        "buildingId": 290794805,
        "floorId": 291002884
      }
    },
    "batteryVoltage": {
      "label": "Battery",
      "value": "2.9",
      "unit": "V"
    },
    "travelTime": {
      "label": "Latency",
      "value": "1.9",
      "unit": "s"
    }
  }
}
topic: 290792806/+/state

{
  "deviceId": "10037601",
  "contactId": 291490743,
  "contactName": "Eleanor D.",
  "data": {
    "state": "W",
    "alarmEvent": {
      "label": "Paging",
      "value": "housekeeping"
    },
    "timeStamp": "2024-06-17 14:05:16"
  }
}
topic: 290792806/+/alert

{
  "text": "Warning: Paging housekeeping for Eleanor D., last located at Hall 1 2 north a moment ago",
  "deviceId": "10037601",
  "data": {
    "contactId": 291490743,
    "contactName": "Eleanor D.",
    "channel": "Paging",
    "value": "housekeeping",
    "units": ""
  },
  "audio": "BASE64ENCODEDWAVEREMOVED"
}

The audio payload can be used to play over radios, intercom, etc.

Alerts

The system provides a mechanism to continuously monitor various parameters such as the location of tags and device channel values (e.g., battery, temperature). When these parameters breach a predefined condition, the system generates an alert. These alerts are crucial for notifying users of potential issues and ensuring timely responses.

Type Color Description Use Case
Monitor Blue This type of alert is primarily for logging purposes. It records the event in the system but does not actively notify users. Suitable for non-critical updates or informational purposes where no immediate action is required.
Warn Amber This alert is more urgent and is designed to actively notify users across all communication channels. It includes in-app notifications, native iOS alerts, and emails. Suitable for situations where users need to be aware of an issue.
Alarm Red The most critical alert type, which not only notifies users through all communication channels but also creates a ticket for documentation and follow-up. This ensures that the issue is tracked and resolved. Suitable for severe issues that require immediate attention and follow-up.