WiFi Motion Core APIs (v3-x-x)

The WiFi Motion Core Cloud APIs facilitate the creation, configuration, and management of WiFi Motion networks via RESTful APIs. Additionally, it offers interfaces for accessing topologies, events, and motion data. This documentation outlines the endpoints for engaging with the WiFi Motion cloud and includes specifications for the following APIs:

Network Settings

Motion History

The motion history APIs provide various historical motion metrics.

Live Motion

The live motion API opens a web socket and triggers the network to emit recorded motion at a 500ms interval.

Events

The events APIs allow you to retrieve, create or tag events emitted by the network.

Network Status

High-level APIs for retrieving the network's topology, last status message, or to view or modify the network's metadata.

Location Data

The location data APIs expose localized motion data. Localization happens on a per mac, or custom location name base.

Find

A set of APIs to find a network in the WiFi Motion Cloud. Individual, or groups of networks can be queried by their primary identifiers or by MAC.

Insights (advanced)

APIs of the internal Home Insights Microservice. Used for motion-based activity and sleep insights.

Config (advanced)

Fine-grained network configuration. These APIs give full access to the underlying motion detection controls, but have no safeguards to prevent unwanted side effects. For friendlier configuration management, see the Network Settings APIs.

Node (advanced)

Interface to manage the access point or mesh nodes of a network. Provides APIs to find, delete or alter the configuration of nodes.

Gatekeeper (advanced)

Endpoint used by WiFi Motion agent for the initial cloud connection. This API returns credentials for connecting to the MQTT broker and stores the initial network configuration. We don't recommend using this API directly.

Management (advanced)

Execute commands directly on the network's access point, or on a mesh node. We recommend using the NOC Management Page for these actions.

Debug (advanced)

Debug endpoints, for internal use only.

Application Settings (advanced)

The application settings API allows users to create, update, delete, and retrieve configurations based on network ID.

Download OpenAPI description
Languages
Servers
Mock server

https://docs.cognitivesystems.com/_mock/assets/specs/mns/v3-x-x/

Network Settings

Operations

Motion History

Operations

Live Motion

Operations

Events

Operations

Network Status

Operations

Network Meta

Operations

Location Data

Operations

Find

Operations

Find by Node ID of Master

Request

Path
master_idintegerrequired

ID of Master Radar Node

Query
arrayboolean

The default behavior is to return an array when there are multiple results and a single object in the case of a single result. When this parameter is true the response will always be an array.

Default false
expandNodesboolean

If true, will also return an array of all nodes belonging to this network under the 'nodes' key.

Default false
curl -i -X GET \
  'https://docs.cognitivesystems.com/_mock/assets/specs/mns/v3-x-x/network/find/masterid/{master_id}?array=false&expandNodes=false'

Responses

OK.

Bodyapplication/jsonArray [
last_guardian_statusobject or null(GuardianStatusReport)

Status report emitted by the network on a regular interval. Contains information on the network's topology, health and motion detection metrics.

radar_configobject(RadarConfig)

Configuration that's shared by all Nodes in this Motion Network.

guardian_configobject(GuardianConfig)

Configuration for gateway or mesh root.

created_atnumber(float)required

UTC second timestamp of network creation.

updated_atnumber(float)required

UTC second timestamp of last configuration update.

guardian_idstringrequired

Unique network identifier. Populated by location_id on network creation.

last_heardnumber(float)

UTC timestamp of last guardian-status message.

metaobject(MetaConfig)

Network metadata storage.

master_node_idintegerrequired

Unique ID of gateway or mesh root node.

shard_idintegerrequired

Identifies the shard the network is stored in.

guardian_typestringrequired

String representation of network's shard in shard-shard-id format.

disconnected_atnumber(float)

UTC second timestamp of recorded disconnection.

nodesArray of objects(MotionNetworkRadarNode)

When expandNodes=true or in a configuration update context, the nodes part of this network are returned in this array.

idinteger(int64)required

Unique network integer identifier.

connection_statusboolean or null

Current connection status (null if has never been connected).

connection_reportobject(GuardianEvent)
device_infoobject

Mac-address keyed device info for all clients in this network.

]
Response
application/json
[ { "last_guardian_status": { … }, "radar_config": { … }, "guardian_config": { … }, "created_at": 0.1, "updated_at": 0.1, "guardian_id": "string", "last_heard": 0.1, "meta": { … }, "master_node_id": 0, "shard_id": 0, "guardian_type": "string", "disconnected_at": 0.1, "nodes": [ … ], "id": 0, "connection_status": true, "connection_report": { … }, "device_info": { … } } ]

Find by Network ID

Request

Path
network_idintegerrequired

Motion Network ID (returned as 'id' by Find API calls)

Query
arrayboolean

The default behavior is to return an array when there are multiple results and a single object in the case of a single result. When this parameter is true the response will always be an array.

Default false
expandNodesboolean

If true, will also return an array of all nodes belonging to this network under the 'nodes' key.

Default false
curl -i -X GET \
  'https://docs.cognitivesystems.com/_mock/assets/specs/mns/v3-x-x/network/find/id/{network_id}?array=false&expandNodes=false'

Responses

OK.

Bodyapplication/jsonArray [
last_guardian_statusobject or null(GuardianStatusReport)

Status report emitted by the network on a regular interval. Contains information on the network's topology, health and motion detection metrics.

radar_configobject(RadarConfig)

Configuration that's shared by all Nodes in this Motion Network.

guardian_configobject(GuardianConfig)

Configuration for gateway or mesh root.

created_atnumber(float)required

UTC second timestamp of network creation.

updated_atnumber(float)required

UTC second timestamp of last configuration update.

guardian_idstringrequired

Unique network identifier. Populated by location_id on network creation.

last_heardnumber(float)

UTC timestamp of last guardian-status message.

metaobject(MetaConfig)

Network metadata storage.

master_node_idintegerrequired

Unique ID of gateway or mesh root node.

shard_idintegerrequired

Identifies the shard the network is stored in.

guardian_typestringrequired

String representation of network's shard in shard-shard-id format.

disconnected_atnumber(float)

UTC second timestamp of recorded disconnection.

nodesArray of objects(MotionNetworkRadarNode)

When expandNodes=true or in a configuration update context, the nodes part of this network are returned in this array.

idinteger(int64)required

Unique network integer identifier.

connection_statusboolean or null

Current connection status (null if has never been connected).

connection_reportobject(GuardianEvent)
device_infoobject

Mac-address keyed device info for all clients in this network.

]
Response
application/json
[ { "last_guardian_status": { … }, "radar_config": { … }, "guardian_config": { … }, "created_at": 0.1, "updated_at": 0.1, "guardian_id": "string", "last_heard": 0.1, "meta": { … }, "master_node_id": 0, "shard_id": 0, "guardian_type": "string", "disconnected_at": 0.1, "nodes": [ … ], "id": 0, "connection_status": true, "connection_report": { … }, "device_info": { … } } ]

Find by BSSID

Request

Path
bssidstringrequired

Access point BSSID

Query
arrayboolean

The default behavior is to return an array when there are multiple results and a single object in the case of a single result. When this parameter is true the response will always be an array.

Default false
expandNodesboolean

If true, will also return an array of all nodes belonging to this network under the 'nodes' key.

Default false
curl -i -X GET \
  'https://docs.cognitivesystems.com/_mock/assets/specs/mns/v3-x-x/network/find/mac/{bssid}?array=false&expandNodes=false'

Responses

OK.

Bodyapplication/json
One of:
Array [
last_guardian_statusobject or null(GuardianStatusReport)

Status report emitted by the network on a regular interval. Contains information on the network's topology, health and motion detection metrics.

radar_configobject(RadarConfig)

Configuration that's shared by all Nodes in this Motion Network.

guardian_configobject(GuardianConfig)

Configuration for gateway or mesh root.

created_atnumber(float)required

UTC second timestamp of network creation.

updated_atnumber(float)required

UTC second timestamp of last configuration update.

guardian_idstringrequired

Unique network identifier. Populated by location_id on network creation.

last_heardnumber(float)

UTC timestamp of last guardian-status message.

metaobject(MetaConfig)

Network metadata storage.

master_node_idintegerrequired

Unique ID of gateway or mesh root node.

shard_idintegerrequired

Identifies the shard the network is stored in.

guardian_typestringrequired

String representation of network's shard in shard-shard-id format.

disconnected_atnumber(float)

UTC second timestamp of recorded disconnection.

nodesArray of objects(MotionNetworkRadarNode)

When expandNodes=true or in a configuration update context, the nodes part of this network are returned in this array.

idinteger(int64)required

Unique network integer identifier.

connection_statusboolean or null

Current connection status (null if has never been connected).

connection_reportobject(GuardianEvent)
device_infoobject

Mac-address keyed device info for all clients in this network.

]
Response
application/json
{ "last_guardian_status": { "leafblower": { … }, "network_id": 0, "shard_id": "string", "radars": { … }, "ts": 0.1, "last_motion": 0.1, "motion_tripped": 0, "startup": true, "version": { … }, "health": { … }, "capabilities": [ … ], "coverage": { … }, "guardian_id": "string", "dhcp": { … }, "motion_enabled": 0, "armed": 0 }, "radar_config": { "dynamic_sensitivity": "string", "bridge": { … }, "motion80211": { … } }, "guardian_config": { "history_motion": { … }, "device_events": { … }, "live_motion": { … }, "link_events": { … }, "leafblower": { … }, "debug": { … }, "user_priority": [ … ], "motion_events": { … } }, "created_at": 0.1, "updated_at": 0.1, "guardian_id": "string", "last_heard": 0.1, "meta": { "dwm": { … }, "home": { … }, "location": { … }, "neuron_env": "string", "mqSecureRadarPort": 0, "auto_segment": 0, "guardian_env": "string", "friendly_name": { … }, "new_network_id": 0, "old_network_id": 0, "new_guardian_id": "string", "gatekeeper_redirect": "string", "property1": "string", "property2": "string" }, "master_node_id": 0, "shard_id": 0, "guardian_type": "string", "disconnected_at": 0.1, "nodes": [ { … } ], "id": 0, "connection_status": true, "connection_report": { "_id": "string", "category": "Link", "loc": [ … ], "detail": { … }, "link_dst_name": "string", "network_id": 0, "ts": 0.1, "evt_detected_ts": 0.1, "intensity_window": [ … ], "link_id": "string", "loc_name": "string", "tag": "string", "link_src_name": "string", "guardian_id": "string", "node_id": 0, "deviceId": "string", "node_name": "string", "debug": { … }, "armed": 0, "event": "MotionDetectedEvent", "_consumer": "string", "data": { … } }, "device_info": { "property1": { … }, "property2": { … } } }

Config

Operations

Node

Operations

Gatekeeper

Operations

Management

Operations

Debug

Operations

Insights

Operations

Insights v2

Operations

Universal Alerting

Operations

Application Settings

Operations