Evaluate a dashboard's data widgets as the caller
Runs the dashboard engine over the dashboard's saved data widgets and returns one frame per widget block, keyed by block id, under the dashboard's saved filter defaults, or under `filters` when sent: the caller's filter bar exactly as shown (`period`, `compare`, shared-field `fields` and `params`), with no saved defaults merged in, so an omitted `period` means all time. Sources are read as the caller sees them, so a database they cannot read is withheld from the frames that need it. App sources are read as the caller's own apps are: time entries and shifts from 400 days back, calendar occurrences six months either side of this month and the workspace's newest 100 visible activity events within the plan's history retention; periods outside what was read are withheld rather than undercounted. A widget whose source fails to read is left out of `frames` rather than failing the request. Frames carry no contributing record ids. `inputs` holds, per block, a key identifying the query its frame answers, so a client shows a frame only while its own widget asks the same query; when workspace changes keep landing during evaluation, `frames` is empty and the client evaluates on its own. Results are cached per person, dashboard and filter bar for up to 30 seconds, retired on any workspace change, and served only while the caller's access to the dashboard and every source read is unchanged; evaluations that read the calendar or the activity feed are not cached. For people signed in to Snoze (the web app's first paint): API keys and automations are refused. Read-only; requires `surfaces:read` on the dashboard.
apiKeyAuthorizationBearer <snoze_sk_…>Workspace API key created in Workspace settings → API keys. Scopes on the key bound what it can read and write.
workspaceId*stringsurfaceId*stringapplication/json- body
filters?|nullSuccess
application/json- response
data*curl -X POST 'https://api.snoze.dev/v1/workspaces/string/surfaces/string/dashboard-frames' \ -H 'Content-Type: application/json' \ -d '{}'{ "data": { "frames": { "property1": { "series": [ { "key": "string", "metricId": "string", "label": "string", "color": "chart-1", "mark": "column", "format": { "style": "auto", "currency": "string", "decimals": 6, "compact": true, "prefix": "string", "suffix": "string" }, "direction": "up", "target": 0, "kind": "aggregate", "breakdown": { "key": "string", "label": "string" } } ], "rows": [ { "key": "string", "label": "string", "longLabel": "string", "color": "chart-1", "start": 0, "other": true, "empty": true, "cells": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previous": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } } } ], "totals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previousTotals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "range": { "start": 0, "end": 0 }, "previousRange": { "start": 0, "end": 0 }, "grain": "day", "dimensionLabel": "string", "complete": true, "warnings": [ { "code": "missing_metric", "message": "string", "metricId": "string" } ], "trend": { "series": [ { "key": "string", "metricId": "string", "label": "string", "color": "chart-1", "mark": "column", "format": { "style": "auto", "currency": "string", "decimals": 6, "compact": true, "prefix": "string", "suffix": "string" }, "direction": "up", "target": 0, "kind": "aggregate", "breakdown": { "key": "string", "label": "string" } } ], "rows": [ { "key": "string", "label": "string", "longLabel": "string", "color": "chart-1", "start": 0, "other": true, "empty": true, "cells": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previous": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } } } ], "totals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previousTotals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "range": { "start": 0, "end": 0 }, "previousRange": { "start": 0, "end": 0 }, "grain": "day", "dimensionLabel": "string", "complete": true, "warnings": [ { "code": "missing_metric", "message": "string", "metricId": "string" } ] } }, "property2": { "series": [ { "key": "string", "metricId": "string", "label": "string", "color": "chart-1", "mark": "column", "format": { "style": "auto", "currency": "string", "decimals": 6, "compact": true, "prefix": "string", "suffix": "string" }, "direction": "up", "target": 0, "kind": "aggregate", "breakdown": { "key": "string", "label": "string" } } ], "rows": [ { "key": "string", "label": "string", "longLabel": "string", "color": "chart-1", "start": 0, "other": true, "empty": true, "cells": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previous": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } } } ], "totals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previousTotals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "range": { "start": 0, "end": 0 }, "previousRange": { "start": 0, "end": 0 }, "grain": "day", "dimensionLabel": "string", "complete": true, "warnings": [ { "code": "missing_metric", "message": "string", "metricId": "string" } ], "trend": { "series": [ { "key": "string", "metricId": "string", "label": "string", "color": "chart-1", "mark": "column", "format": { "style": "auto", "currency": "string", "decimals": 6, "compact": true, "prefix": "string", "suffix": "string" }, "direction": "up", "target": 0, "kind": "aggregate", "breakdown": { "key": "string", "label": "string" } } ], "rows": [ { "key": "string", "label": "string", "longLabel": "string", "color": "chart-1", "start": 0, "other": true, "empty": true, "cells": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previous": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } } } ], "totals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "previousTotals": { "property1": { "value": 0, "count": 0, "recordIds": [ "string" ] }, "property2": { "value": 0, "count": 0, "recordIds": [ "string" ] } }, "range": { "start": 0, "end": 0 }, "previousRange": { "start": 0, "end": 0 }, "grain": "day", "dimensionLabel": "string", "complete": true, "warnings": [ { "code": "missing_metric", "message": "string", "metricId": "string" } ] } } }, "inputs": { "property1": "string", "property2": "string" } }}Render a page against a record for printing
Resolves the page or note surface and the record named by `recordId` independently, then returns a print-ready render of the page with the record's values substituted, laid out for the requested `preset` (`a4` or `80mm`, default `a4`). The caller must have read access to both the surface and the record; surfaces of any other kind are rejected as a validation error.
Apply a batch of block operations to a surface
Applies an ordered batch of insert, update, move, and delete block operations in one transaction and returns the affected blocks with the new workspace version. Requires `surfaces:write` on the surface. Batches are capped at 500 operations, and non-UUID block ids, malformed order keys, and conversions into structural column kinds are rejected as validation errors.