Skip to main content
An AI can read a workflow’s canvas analytics and change the graph from them. There is no separate analytics GET — counters live on the GET workflow document as analytics.

Fetch

GET https://workflows.pingmee.co.il/workflows/{workflowId} (URL-encode the id). Same Cookie + x-api-key as other Workflows calls. analytics is present on the Expert AI plan. If the field is missing, do not invent numbers — tell the user the plan may not include canvas analytics. If it is present but totalStarted is 0, there is nothing to analyze yet (new workflow or a reset). List (POST /workflows) returns minimal { id, name, folderId } only — it does not include analytics. GET a fresh document immediately before you edit. A graph PUT prunes stats for removed node / edge / button ids. After you rewrite ids, old keys no longer match.

Shape

Still in progress: max(0, totalStarted - totalCompleted - totalDropped). Conversion (what the board shows): totalCompleted / totalStarted.

Edge keys and sourceHandle

Root outgoing edges use sourceHandle: "out". Sub-node outgoing edges (answers, If true/false, switch cases, fallback) use "in". Older runs may key a branch by the sub-node id instead of "in" — look up both {source}->{target}:in and {source}->{target}:{sourceNodeId}. If/Else and switch paths are node + edge stats on the branch sub-node, not buttonStats.

Buttons

buttonStats maps to answer sub-nodes. Compare clickCount among siblings that share parentNodeId. A click also increments the answer’s nodeStats.enteredCount and the parent’s exitedCount.

Interpret

Use only fields that exist. Rank by counts; do not invent percentages the API does not store.

Act

  1. GET the workflow. Keep analytics, lastModified, data, parsedData, and trigger.
  2. If analytics is missing, stop (plan gating). If totalStarted is 0, say there is no data yet.
  3. Propose concrete graph edits, for example: reroute or rewrite low-click buttons, add a fallback / timeout, change copy, split an If condition, or add a path after a drop-off node.
  4. PUT both data and parsedData plus trigger / triggerType / variables, echoing lastModified. On 409, GET again and retry.
  5. If the workflow is inactive, activate with PUT { "isActive": true } only (no graph fields).
  6. Do not send analytics on PUT. The server prunes stats for node / edge / button ids that no longer exist on the new graph; totals stay. New or renamed ids have no stats until new executions.
See Hard rules and Canvas vs execution.

Reset (optional)

POST /workflows//analytics/reset zeros every counter. It is destructive. Call it only when the user explicitly asks. Expert AI only (403 otherwise). The response is the updated workflow; use its lastModified on the next graph PUT.
Last modified on September 4, 2026