Trillet AI logo

Delete Node Flow

Delete a node flow and its companion call flow.

DELETEhttps://api.trillet.ai/v2/api/node-graphs/{id}

Deleting a node flow also deletes its companion call flow (the pathway._id from Get Node Flow). After that, the graph no longer shows in List Node Flows and Get Node Flow returns 404.

A node flow can't be deleted while another call flow (not its own companion) still uses it. Archive or delete that call flow first.

Headers

x-workspace-idstringrequired

Workspace identifier for the API.

Path Parameters

idstringrequired

The graph _id (not the call flow ID).

Errors

StatusBodyWhen
400{"error": "Workspace ID required", "code": "WORKSPACE_ID_REQUIRED"}No x-workspace-id
403{"error": "Insufficient permissions", ...}Your role can't delete call flows
404{"code": "NODE_GRAPH_NOT_FOUND"}No graph with that ID in the workspace
409{"code": "NODE_GRAPH_IN_USE", "params": {"pathwayCount": 1}}Another call flow still uses this graph. pathwayCount is how many

Response Fields

deletedboolean

Always true.

curl -X DELETE "https://api.trillet.ai/v2/api/node-graphs/{id}" \
  -H "x-api-key: YOUR_API_KEY" \
  -H "x-workspace-id: YOUR_WORKSPACE_ID"
200 Deleted
{
  "deleted": true
}
409 In use
{
  "code": "NODE_GRAPH_IN_USE",
  "params": { "pathwayCount": 1 }
}

Last updated on