- Support portal
- Evaluation Kits and partner products
u-blox Support
- Product documentation
Documentation
- About
- Sustainability
- Partners and Alliances
- Contact
About u-blox
- Investor relations
Investor relations
Angle of Arrival
Application Programming Interface
Bluetooth Low Energy
Coordinate Reference System
Hypertext Transfer Protocol
Identifier
International Organization for Standardization
JavaScript Object Notation
Media Access Control
Message Queuing Telemetry Transport
Representational State Transfer — an architectural style for distributed systems like APIs, using HTTP requests.
Received Signal Strength Indicator
Unicode Transformation Format 8-bit
A device/receiver that receives the AoA consisting of an array of antennas.
The spatial region covered by a set of APs.
A server that facilitates communication using the MQTT protocol.
Devices or applications that connect to an MQTT broker to publish or subscribe to messages.
The data transmitted via MQTT between clients and brokers.
A lightweight communication protocol specifically designed for low-bandwidth, high-latency, or unreliable networks.
A :term: UTF-8 string used by the MQTT broker to filter messages for each connected client.
A device/transmitter equipped with positioning technology, in our case BLE.
Interaction with u-locateEngine can be achieved using the following application interface and data types.
u-locateEngine uses JSON over MQTT protocol through the deployment of an MQTT Broker. Interaction with the MQTT Broker can be achieved using MQTT clients. The address (default : localhost) and the port (default : 1883) of this server is preset in the device but can be changed to use your own server.
The u-locateEngine provides both REST and MQTT APIs for different tasks:
RESTAPI (at http://ulocateengine.local:8000) handles device management and configuration using JSON over HTTP.
MQTTAPI (broker at ulocateengine.local:1883) manages real-time tasks like location updates and sensor data via JSON over MQTT protocol. The MQTT Broker is preset in the device but can be changed to use your own server.
This documentation provides an overview of the MQTTAPI topics and their respective operations.
u-locateEngine retrieves AoA from APs and registers Tags by subscribing to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
angles | Default
| JSON
|
where:
u-locateEngine publishes the calculated positions to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
positions | Default
| JSON
|
where :
id
: is the ID of the Tag (usually the MAC address)
area_id
: is the term:’ID’ of the Area where the APs, that define the position, belong to
x
: is the x coordinate of the Tag relative to an arbitrary user-selected coordinate system
y
: is the y coordinate of the Tag relative to an arbitrary user-selected coordinate system
z
: is the z coordinate of the Tag relative to an arbitrary user-selected coordinate system
timestamp
: is the time formatted according to ISO
The configuration of each AP is defined by the following JSON format:
MQTT main AP’s configuration Payload |
---|
Default
|
where :
area_id
: is the term:’ID’ of the Area where the APs belong to
x
: is the x coordinate of the AP relative to an arbitrary user-selected coordinate system
y
: is the y coordinate of the AP relative to an arbitrary user-selected coordinate system
z
: is the z coordinate of the AP relative to an arbitrary user-selected coordinate system
azimuth_norm
: is the azimuth angle of the AP
elevation_norm
: is the elevation angle of the AP
MQTT main AP’s configuration Example |
---|
JSON
|
The respective API for APs configuration consists of the below topics:
u-locateEngine publishes the new created AP to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
provision/anchor/created |
u-locateEngine publishes the updated or the new created if it doesn’t exist AP to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
provision/anchor/updated |
u-locateEngine publishes the deleted AP id to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
provision/anchor/deleted | Default
| JSON
|
The configuration of each Area is defined by the following JSON format:
MQTT main Area’s configuration Payload |
---|
Default
|
where :
MQTT main Area’s configuration Example |
---|
JSON
|
The respective API for Areas configuration consists of the below topics:
u-locateEngine publishes the new created Area to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
provision/area/created |
u-locateEngine publishes the updated Area to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
provision/area/updated |
u-locateEngine publishes the deleted Area id to this topic.
MQTT Topic | MQTT Payload | Example |
---|---|---|
provision/area/deleted | Default
| JSON
|
Create Anchor
Creates a new anchor.
Example request:
POST/anchorsHTTP/1.1Host:example.comContent-Type:application/json{"anchor_id":"string","area_id":"string","x":1.0,"y":1.0,"z":1.0,"azimuth_norm":1.0,"elevation_norm":1.0}
Resource created successfully
Example response:
HTTP/1.1201CreatedContent-Type:application/json{"anchor_id":"string","area_id":"string","x":1.0,"y":1.0,"z":1.0,"azimuth_norm":1.0,"elevation_norm":1.0}
Conflict between given and existing data
Example response:
HTTP/1.1409ConflictContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Anchors
Get all anchors.
area_id ({'null', 'string'}) –
Example request:
GET/anchorsHTTP/1.1Host:example.com
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json[{"anchor_id":"string","area_id":"string","x":1.0,"y":1.0,"z":1.0,"azimuth_norm":1.0,"elevation_norm":1.0}]
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
Update Anchor
Updates or creates an anchor with the specified ID.
anchor_id (string) –
Example request:
PUT/anchors/{anchor_id}HTTP/1.1Host:example.comContent-Type:application/json{"anchor_id":"string","area_id":"string","x":1.0,"y":1.0,"z":1.0,"azimuth_norm":1.0,"elevation_norm":1.0}
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{"anchor_id":"string","area_id":"string","x":1.0,"y":1.0,"z":1.0,"azimuth_norm":1.0,"elevation_norm":1.0}
Resource created successfully
Example response:
HTTP/1.1201CreatedContent-Type:application/json{"anchor_id":"string","area_id":"string","x":1.0,"y":1.0,"z":1.0,"azimuth_norm":1.0,"elevation_norm":1.0}
The payload does not match the URL parameters
Example response:
HTTP/1.1400Bad RequestContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Delete Anchor
Delete the anchor with the specified ID.
anchor_id (string) –
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{}
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Anchor
Get the anchor with the specified ID.
anchor_id (string) –
Example request:
GET/anchors/{anchor_id}HTTP/1.1Host:example.com
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{"anchor_id":"string","area_id":"string","x":1.0,"y":1.0,"z":1.0,"azimuth_norm":1.0,"elevation_norm":1.0}
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
Get Areas
Get all areas.
Example request:
GET/areasHTTP/1.1Host:example.com
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json[{"area_id":"string","name":"string","anchors":["string"]}]
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
Create Area
Creates a new area.
Example request:
POST/areasHTTP/1.1Host:example.comContent-Type:application/json{"name":"string"}
Resource created successfully
Example response:
HTTP/1.1201CreatedContent-Type:application/json{"area_id":"string","name":"string"}
Conflict between given and existing data
Example response:
HTTP/1.1409ConflictContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Update Area
Updates the area with the specified ID.
area_id (string) –
Example request:
PUT/areas/{area_id}HTTP/1.1Host:example.comContent-Type:application/json{"name":"string"}
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{"area_id":"string","name":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
Conflict between given and existing data
Example response:
HTTP/1.1409ConflictContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Delete Area
Delete the area with the specified ID.
area_id (string) –
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{}
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Conflict between given and existing data
Example response:
HTTP/1.1409ConflictContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Area
Get the area with the specified ID.
area_id (string) –
Example request:
GET/areas/{area_id}HTTP/1.1Host:example.com
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{"area_id":"string","name":"string","anchors":["string"]}
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
Retrieve Logs
Retrieve logs for all containers.
Example request:
GET/logsHTTP/1.1Host:example.com
200 OK – Request successful
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Retrieve Specific Logs
Retrieve logs for a specific folder.
container (string) –
Example request:
GET/logs/{container}HTTP/1.1Host:example.com
200 OK – Request successful
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Folder Structure
Get logs’ folder structure.
Example request:
GET/logs-structureHTTP/1.1Host:example.com
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{"folder_name":"string","items":[{"name":"string","is_folder":true}]}
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Beacons Blacklisted
Get all blacklisted beacon ids.
Example request:
GET/beacons_black_listHTTP/1.1Host:example.com
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{"beacons_blacklisted":[{"beacon_id":"string"}]}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
Add Beacon Black List
Adds a beacon in blacklist.
Example request:
POST/beacons_black_listHTTP/1.1Host:example.comContent-Type:application/json{"beacon_id":"string"}
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{}
Conflict between given and existing data
Example response:
HTTP/1.1409ConflictContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Remove Beacon Black List
Remove a beacon from blacklist.
Example request:
DELETE/beacons_black_listHTTP/1.1Host:example.comContent-Type:application/json{"beacon_id":"string"}
200 OK –
Request successful
Example response:
HTTP/1.1200OKContent-Type:application/json{}
Resource not found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Validation Error
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"loc":["string",1],"msg":"string","type":"string"}
An unexpected error occurred
Example response:
HTTP/1.1500Internal Server ErrorContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Engine Statistics
Get statistics data for the ulocateEngine.
component (string) –
field ({'null', 'string'}) –
Example request:
GET/statistics/{component}HTTP/1.1Host:example.com
200 OK –
Successful Response
Example response:
HTTP/1.1200OKContent-Type:application/json{"fields":{}}
Not Found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Bad Request
Example response:
HTTP/1.1400Bad RequestContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Unprocessable Entity
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Statistics
Get combined statistics data for each component.
Example request:
GET/statisticsHTTP/1.1Host:example.com
200 OK –
Successful Response
Example response:
HTTP/1.1200OKContent-Type:application/json{"components":{}}
Not Found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Unprocessable Entity
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Get Statistics Structure
Get statistics’ structure.
Example request:
GET/statistics-structureHTTP/1.1Host:example.com
200 OK –
Successful Response
Example response:
HTTP/1.1200OKContent-Type:application/json{"components":{}}
Not Found
Example response:
HTTP/1.1404Not FoundContent-Type:application/json{"msg":"string","type":"string","input":"string"}
Unprocessable Entity
Example response:
HTTP/1.1422Unprocessable EntityContent-Type:application/json{"msg":"string","type":"string","input":"string"}