Skip to content

Cognitive Systems App Cloud API

The App Cloud APIs expose the Core API endpoints, but with the addition of adding per user authentication and authorization. For example, you may choose to build with App Cloud APIs when developing for a mobile platform.

Download OpenAPI description
Languages
Servers
Mock server
https://docs.cognitivesystems.com/_mock/assets/specs/api/app_cloud
https://docs.cognitivesystems.com/api/v1

Overview

Operations

Out of Box

Operations

Logging In

Operations

Geofencing

Operations

Account Management

Operations

Network Settings

Operations

Sounding v2

Operations

Events, History, and Visualizations

Operations

Household Insights

Operations

Retrieve Activity InsightsBeta

Request

Activity Insights provides you activity related data.

Query
start_timenumber

UNIX timestamp, will floor to the nearest 15 minute e.g 20:14 to 20:00. Default is set to 7 days ago.

end_timenumber

UNIX timestamp, will ceil to the nearest 15 minutes 21:33 to 21:44:59:9999. Default is set to now.

flattenedboolean

If set to true, the results will be provided in a one dimensional array.

Default false
curl -i -X GET \
  'https://docs.cognitivesystems.com/_mock/assets/specs/api/app_cloud/insights/v2/activity?start_time=0&end_time=0&flattened=false'

Responses

200 OK

Bodyapplication/json
One of:

The results are not flattened

first_bucketnumber(First Bucket)

The UNIX timestamp of the first bucket.

intervalinteger(Bucket Interval)

The number of seconds that a bucket represents.

dataArray of objects(Activity Data)
Response
application/json
{ "first_bucket": 1743521400, "interval": 900, "data": [ 0, 0.559, 0.36765, 0.44425, null ] }

Daily Activity InsightsBeta

Request

Provides a percentage of daily activity for the queried days. Please allow for a warmup period of between 2 and 4 hours after first being activated.

Query
start_datestring(date)(Start Date)required

The first date to include within the results.

Example: start_date=2025-03-20
end_datestring(date)(End Date)required

The last date to include within the results.

Example: end_date=2025-04-24
timezonestring(string)(timezone)

Optional If set, the provided value will be used to perform end of day calculations.

Example: timezone=America/Toronto
curl -i -X GET \
  'https://docs.cognitivesystems.com/_mock/assets/specs/api/app_cloud/insights/v2/activity/daily?start_date=2025-03-20&end_date=2025-04-24&timezone=America%2FToronto'

Responses

200 - OK

Bodyapplication/jsonArray [
datestring

Date that the results are related to.

percent_activenumber(float)

Percentage of time that activity occurred within the sample.

tsinteger

Epoch timestamp.

]
Response
application/json
[ { "date": "2025-03-19", "percent_active": 0.10266202688217163, "ts": 1742356800 }, { "date": "2025-03-20", "percent_active": 0.19775460163752237, "ts": 1742443200 }, { "date": "2025-03-21", "percent_active": 0.21174768606821695, "ts": 1742529600 }, { "date": "2025-03-22", "percent_active": 0.1452083388964335, "ts": 1742616000 } ]

Household Sleep-Wake Times DataDeprecated

Request

This endpoint retrieves the timezone of the user from the network model and supplies it to the micro service. The micro service will return hour values for wake and sleep in the network's timezone.

Security
Authorization
Path
queried_daysinteger[ 1 .. 7 ]required

can be omitted. when omitted defaults to 7

Query
force_pastboolean

Specifically for QA and load validation, this switch if set to true force allows a request sleep data to query the full 7 days back despite the enable time being later than this. The number of queried days will be respected in the path param

Default false
curl -i -X GET \
  'https://docs.cognitivesystems.com/_mock/assets/specs/api/app_cloud/sleep_times/data/{queried_days}?force_past=false' \
  -H 'Authorization: YOUR_API_KEY_HERE'

Responses

Bodyapplication/json
avg_sleep_time_sinteger
Example: 82380
avg_wake_time_sinteger
Example: 23280
average_interruptionsnumber
duration_avg_sinteger
Example: 27900
queried_daysinteger

the number of days actually queried to the insights micro-service

Example: 6
motion_stateobject

the unarmed/home/0 or armed/away/ 1 history of the network

Example: {"data":[0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"from_ts":1618243200,"bucket":3600}
dataArray of objects

the array of days queried, length of array will match queried number of days

Example: [{"house_day":18729,"sleep_ts":1618266600,"sleep_weight":0.923879533,"wake_ts":1618286400,"wake_weight":0.965925826},{"house_day":18730,"sleep_ts":1618353900,"sleep_weight":0.896872742,"wake_ts":1618372800,"wake_weight":0.965925826},{"house_day":18731,"sleep_ts":1618440300,"sleep_weight":0.896872742,"wake_ts":1618476300,"wake_weight":0.555570233},{"house_day":18732,"sleep_ts":1618517700,"sleep_weight":0.98078528,"wake_ts":1618545600,"wake_weight":0.965925826},{"house_day":18734,"sleep_ts":1618687800,"sleep_weight":0.923879533,"wake_ts":1618711200,"wake_weight":0.707106781},{"house_day":18735,"sleep_ts":1618766100,"sleep_weight":0.555570233,"wake_ts":1618807500,"wake_weight":0.997858923}]
Response
application/json
{ "avg_sleep_time_s": 82380, "avg_wake_time_s": 23280, "duration_avg_s": 27900, "queried_days": 6, "motion_state": { "data": [ … ], "from_ts": 1618243200, "bucket": 3600 }, "data": [ { … }, { … }, { … }, { … }, { … }, { … } ] }

Zone Priority

Operations

Universal Alerting

Operations

Meta

Operations

Sensor Integration

Operations