Retrieve machine data for a single day
Retrieves comprehensive machine analytics for a single calendar day (with adjustments for shift boundaries). It aggregates shift data, real-time status info, live and planned orders, and optional timeseries data for features or legacy pulse. It supports processing either synchronously or asynchronously.
When async is true, the response returns an actor_name and message_id immediately.
You must then use the POST /v2/analytics/ endpoint with the actor_name and message_id to retrieve the result.
curl -X POST "https://wm.novoai.de/v2/analytics/day?async=false&csv_format=false" \
-H "Content-Type: application/json" \
-H "accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN (JWT)" \
-H "X-API-KEY: YOUR_API_KEY" \
-d '{
"machine_list": [
1
],
"date": "2025-02-24",
"features": true,
"timeline": true,
"live_orders": true,
"window_period": "5m"
}'
import requests
import json
url = "https://wm.novoai.de/v2/analytics/day?async=false&csv_format=false"
headers = {
"Content-Type": "application/json",
"accept": "application/json",
"Authorization": "Bearer YOUR_API_TOKEN (JWT)",
"X-API-KEY": "YOUR_API_KEY"
}
data = {
"machine_list": [
1
],
"date": "2025-02-24",
"features": true,
"timeline": true,
"live_orders": true,
"window_period": "5m"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const response = await fetch("https://wm.novoai.de/v2/analytics/day?async=false&csv_format=false", {
method: "POST",
headers: {
"Content-Type": "application/json",
"accept": "application/json",
"Authorization": "Bearer YOUR_API_TOKEN (JWT)",
"X-API-KEY": "YOUR_API_KEY"
},
body: JSON.stringify({
"machine_list": [
1
],
"date": "2025-02-24",
"features": true,
"timeline": true,
"live_orders": true,
"window_period": "5m"
})
});
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"net/http"
"bytes"
"encoding/json"
)
func main() {
data := []byte(`{
"machine_list": [
1
],
"date": "2025-02-24",
"features": true,
"timeline": true,
"live_orders": true,
"window_period": "5m"
}`)
req, err := http.NewRequest("POST", "https://wm.novoai.de/v2/analytics/day?async=false&csv_format=false", bytes.NewBuffer(data))
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("accept", "application/json")
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "Bearer YOUR_API_TOKEN (JWT)")
req.Header.Set("X-API-KEY", "YOUR_API_KEY")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println("Response Status:", resp.Status)
}
require 'net/http'
require 'json'
uri = URI('https://wm.novoai.de/v2/analytics/day?async=false&csv_format=false')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri)
request['Content-Type'] = 'application/json'
request['accept'] = 'application/json'
request['Content-Type'] = 'application/json'
request['Authorization'] = 'Bearer YOUR_API_TOKEN (JWT)'
request['X-API-KEY'] = 'YOUR_API_KEY'
request.body = '{
"machine_list": [
1
],
"date": "2025-02-24",
"features": true,
"timeline": true,
"live_orders": true,
"window_period": "5m"
}'
response = http.request(request)
puts response.body
{
"machine_dict": {
"1": {
"id": 1,
"name": "Machine A",
"hall": {
"id": 1,
"name": "Hall 1"
},
"shift_group": {
"id": 2,
"name": "Group A"
},
"ratings": 4.5,
"state": 1,
"last_heartbeat": "2025-02-24 15:29:55",
"live_timeline_reason": {
"idx": 12345,
"is_set": false,
"created_at": "2025-02-24 15:00:00",
"can_set": true
},
"day_data": {
"availability": 0.85,
"performance": 0.9,
"quality": 0.99,
"oee": 0.757,
"production_duration": 25000,
"idle_duration": 2000,
"off_duration": 0,
"timeline_reason": {
"columns": [
"timeline_reason_id",
"timeline_reason_name",
"duration_sec",
"idx",
"total_sec",
"color"
],
"data": [
[
1,
"Setup",
1200,
1,
1200,
"#CCCCCC"
]
]
}
},
"shift_data": {
"Shift 1": {
"shift_start": "2025-02-24T06:00:00",
"shift_end": "2025-02-24T14:00:00",
"availability": 0.88
}
},
"tag_list": [
{
"id": 11,
"name": "Tag1"
}
],
"timeline": {
"columns": [
"idx",
"start",
"end",
"state",
"timeline_reason_id",
"start_timestamp",
"end_timestamp"
],
"data": [
[
101,
"2025-02-24 06:00:00",
"2025-02-24 07:00:00",
2,
null,
1740376800,
1740380400
]
]
},
"features": [
{
"id": 10,
"name": "Speed",
"unit": "rpm",
"multiplication_factor": 1,
"field_name": "rpm"
}
],
"timeseries_features": {
"Speed": {
"columns": [
"_time",
"value"
],
"data": [
[
1740376800,
1200
],
[
1740376860,
1205
]
]
}
},
"live_orders": [
{
"order_id": 505,
"order_name": "Order-ABC",
"assignment_id": 99,
"status": "active",
"product": {
"id": 10,
"name": "Widget X"
}
}
],
"interval_list": [
{
"id": 800,
"start": "2025-02-24 08:00:00",
"end": "2025-02-24 09:00:00",
"produced_qty": 500,
"product": {
"id": 10,
"name": "Widget X"
}
}
],
"range_analysis": [
{
"range_label": {
"lower": 300,
"upper": 600
},
"instance_count": 5,
"total_seconds": 2000
}
]
}
},
"status": 1,
"response_time": 0.452
}
{
"actor_name": "machinesingledaytimescalex",
"message_id": "3be56d78-3a9d-4786-9a2f-123456789abc"
}
{
"status": 0,
"message": "You do not have access to requested machine",
"machine_dict": {},
"response_time": 0.123
}
{
"status": 1,
"message": "No machines found in the company for the provided machine_list",
"machine_dict": {},
"response_time": 0.05
}
{
"status": 0,
"message": "Invalid current_time_reset format..."
}
{
"status": 0,
"message": "An unexpected error occurred."
}
/v2/analytics/day
Target server for requests. Edit to use your own host.
JWT Bearer token authentication. Include in the Authorization header as Bearer <token>.
Bearer <token>.API-Access Key authentication. Include the generated key in the X-API-KEY header.
X-API-KEY header.Default false. If true, returns an actor_name and message_id immediately instead of
waiting for the full result. Use the POST /v2/analytics/ endpoint to retrieve the result afterward.
Default false. If true, returns CSV formatted data inside the JSON result (if the actor supports it).
The media type of the request body
Must be application/json.
Must be application/json for POST requests.
IDs of machines. If empty or missing, fetches all accessible machines.
Target date (YYYY-MM-DD). Defaults to today if not provided.
Include energy_consumption and energy_wastage in calculations.
Include anomaly detection data.
Include cycle lists (cycles).
Include status timeline segments (timeline).
Include reason codes/durations nested within day/shift data properties.
Include legacy pulse timeseries (pulse).
Include generic machine feature timeseries (features and timeseries_features).
Aggregation bucket size for pulse (e.g., 1m, 5s).
Include external data timeseries (extern).
Include uptime range distribution analysis (range_analysis).
Include lists of currently running (live_orders) and planned (planned_orders) orders.
Include detailed production intervals (interval_list).
Overrides the lookback window for the timeline request (e.g., 3h for last 3 hours).
Request Preview
Response
Response will appear here after sending the request
Authentication
Bearer token (JWT). JWT Bearer token authentication. Include in the Authorization header as Bearer \<token\>.
API Key for authentication. API-Access Key authentication. Include the generated key in the X-API-KEY header.
Query Parameters
Default false. If true, returns an actor_name and message_id immediately instead of
waiting for the full result. Use the POST /v2/analytics/ endpoint to retrieve the result afterward.
falseDefault false. If true, returns CSV formatted data inside the JSON result (if the actor supports it).
falseHeaders
Body
IDs of machines. If empty or missing, fetches all accessible machines.
[1,2]Include energy_consumption and energy_wastage in calculations.
Include anomaly detection data.
Include cycle lists (cycles).
Include status timeline segments (timeline).
Include reason codes/durations nested within day/shift data properties.
Include legacy pulse timeseries (pulse).
Include generic machine feature timeseries (features and timeseries_features).
Include external data timeseries (extern).
Include uptime range distribution analysis (range_analysis).
Include lists of currently running (live_orders) and planned (planned_orders) orders.
Include detailed production intervals (interval_list).
Overrides the lookback window for the timeline request (e.g., 3h for last 3 hours).
3hResponses
Machine analytics data keyed by machine ID (as string).
Indicates the success of the request. 1 for success, 0 for failure.
Optional message (present in logical error responses, e.g., no access or no machines found).
Response time in seconds.