curl -X DELETE "https://developer.encrata.com/api/workflows/6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77" \
-H "Authorization: Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
import requests
workflow_id = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77"
resp = requests.delete(
f"https://developer.encrata.com/api/workflows/{workflow_id}",
headers={"Authorization": "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"},
)
print(resp.json())
const workflowId = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77";
const resp = await fetch(
`https://developer.encrata.com/api/workflows/${workflowId}`,
{ method: "DELETE", headers: { Authorization: "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" } },
);
const data = await resp.json();
{ "ok": true }
Workflows
Delete Workflow
Archive a workflow, cancel its pending runs, and keep its history.
DELETE
/
api
/
workflows
/
{id}
curl -X DELETE "https://developer.encrata.com/api/workflows/6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77" \
-H "Authorization: Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
import requests
workflow_id = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77"
resp = requests.delete(
f"https://developer.encrata.com/api/workflows/{workflow_id}",
headers={"Authorization": "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"},
)
print(resp.json())
const workflowId = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77";
const resp = await fetch(
`https://developer.encrata.com/api/workflows/${workflowId}`,
{ method: "DELETE", headers: { Authorization: "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" } },
);
const data = await resp.json();
{ "ok": true }
Overview
Deleting a workflow is a soft delete. The workflow is marked deleted, its status becomesarchived, and any pending runs are cancelled. It stops
appearing in List workflows and can no
longer be triggered.
Run history and audit records are kept. Existing runs stay readable
through List workflow runs.
Authentication
Requires an API key in theAuthorization header.
Authorization: Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Request
string
required
The workflow’s UUID. The route matches a UUID only - a non-UUID id returns
404.Example request
curl -X DELETE "https://developer.encrata.com/api/workflows/6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77" \
-H "Authorization: Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
import requests
workflow_id = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77"
resp = requests.delete(
f"https://developer.encrata.com/api/workflows/{workflow_id}",
headers={"Authorization": "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"},
)
print(resp.json())
const workflowId = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77";
const resp = await fetch(
`https://developer.encrata.com/api/workflows/${workflowId}`,
{ method: "DELETE", headers: { Authorization: "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" } },
);
const data = await resp.json();
Response
boolean
true when the workflow was archived.Errors
| Status | Cause |
|---|---|
401 | Missing or invalid API key |
404 | No such workflow, the id is not a UUID, or it is already archived |
429 | Rate limit exceeded. See Rate limits |
500 | Unexpected server failure |
curl -X DELETE "https://developer.encrata.com/api/workflows/6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77" \
-H "Authorization: Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
import requests
workflow_id = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77"
resp = requests.delete(
f"https://developer.encrata.com/api/workflows/{workflow_id}",
headers={"Authorization": "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"},
)
print(resp.json())
const workflowId = "6f1c2e94-2b6a-4a1e-9b3a-6c9f0f2a1d77";
const resp = await fetch(
`https://developer.encrata.com/api/workflows/${workflowId}`,
{ method: "DELETE", headers: { Authorization: "Bearer enc_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" } },
);
const data = await resp.json();
{ "ok": true }
Next steps
- List workflows: Confirm the workflow is gone from your active list.
- List workflow runs: Its run history is still there.
Was this page helpful?