Skip to main content
The Widgets Dashboard API lets you retrieve revenue data broken down per machine, per day, and per month. For filter and field reference, see Widget Filters Reference.

Discover Widget IDs

Call the list-widgets endpoint to see all available widgets and their IDs:
curl -X GET "https://<host>/operational/v1/dashboard/widgets?screenTypeId=1" \
  -H "Authorization: Bearer <token>"
From the response, identify the widgetTypeId values for revenue-related widgets (look for names containing “Revenue”, “Sales”, or similar).

Revenue Per Machine Per Day

Use the groupBy: day filter with a date range to retrieve daily revenue totals:
curl -X POST "https://<host>/operational/v1/dashboard/get-widget-data" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "screenTypeId": 1,
    "widgetTypeId": 193,
    "entityId": <operatorId>,
    "filters": [
      { "name": "startDate", "value": "2025-01-01", "type": "Date" },
      { "name": "endDate",   "value": "2025-01-31", "type": "Date" },
      { "name": "groupBy",   "value": "day",        "type": "string" }
    ]
  }'

Revenue Per Machine Per Month

Switch groupBy to month and widen the date range to retrieve monthly revenue totals:
curl -X POST "https://<host>/operational/v1/dashboard/get-widget-data" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "screenTypeId": 1,
    "widgetTypeId": 193,
    "entityId": <operatorId>,
    "filters": [
      { "name": "startDate", "value": "2025-01-01", "type": "Date" },
      { "name": "endDate",   "value": "2025-12-31", "type": "Date" },
      { "name": "groupBy",   "value": "month",      "type": "string" }
    ]
  }'

Revenue for a Specific Machine

Pass the machine ID via entityId (if the widget is machine-scoped) or via the MachineId filter:
curl -X POST "https://<host>/operational/v1/dashboard/get-widget-data" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "screenTypeId": 1,
    "widgetTypeId": 193,
    "entityId": null,
    "filters": [
      { "name": "startDate", "value": "2025-01-01", "type": "Date"   },
      { "name": "endDate",   "value": "2025-12-31", "type": "Date"   },
      { "name": "MachineId", "value": "<machineId>","type": "int"    },
      { "name": "groupBy",   "value": "day",        "type": "string" }
    ]
  }'
The exact filter names and groupBy values supported by a widget depend on its stored procedure in Cortex Reports. If a filter name is not recognized, it is silently ignored. Test with and without each filter and compare responses.