List Workflows
const workflows = await client.workflow.list({ limit: 100 });
for (const workflow of workflows) {
console.log(`${workflow.id}: ${workflow.name}`);
}
workflows = client.workflow.list(limit=100)
for workflow in workflows:
print(f"{workflow.id}: {workflow.name}")
curl -X GET "https://api.kadoa.com/v4/workflows" \
-H "x-api-key: YOUR_API_KEY"
Get Workflow
const workflow = await client.workflow.get({
workflowId: 'YOUR_WORKFLOW_ID'
});
workflow = client.workflow.get(workflow_id="YOUR_WORKFLOW_ID")
curl -X GET "https://api.kadoa.com/v4/workflows/YOUR_WORKFLOW_ID" \
-H "x-api-key: YOUR_API_KEY"
Pause & Resume
// Pause
await client.workflow.pause({ workflowId: 'YOUR_WORKFLOW_ID' });
// Resume
await client.workflow.resume({ workflowId: 'YOUR_WORKFLOW_ID' });
# Pause
client.workflow.pause(workflow_id="YOUR_WORKFLOW_ID")
# Resume
client.workflow.resume(workflow_id="YOUR_WORKFLOW_ID")
Update
await client.workflow.update({
workflowId: 'YOUR_WORKFLOW_ID',
name: 'New Name',
interval: 'DAILY',
});
client.workflow.update(
workflow_id="YOUR_WORKFLOW_ID",
name="New Name",
interval="DAILY",
)
curl -X PATCH "https://api.kadoa.com/v4/workflows/YOUR_WORKFLOW_ID" \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"name": "New Name", "interval": "DAILY"}'
Delete
This permanently deletes the workflow and all its data.
await client.workflow.delete({ workflowId: 'YOUR_WORKFLOW_ID' });
client.workflow.delete(workflow_id="YOUR_WORKFLOW_ID")
curl -X DELETE "https://api.kadoa.com/v4/workflows/YOUR_WORKFLOW_ID" \
-H "x-api-key: YOUR_API_KEY"
Templates
Workflows can be linked to templates that manage their prompt, schema, and notification settings. When linked, those fields become read-only on the workflow. See Templates for linking, unlinking, and applying template updates via the API.Fetch Data
const workflows = await client.workflow.list({ limit: 100 });
for (const workflow of workflows) {
const data = await client.extraction.fetchAllData({
workflowId: workflow.id,
});
console.log(`${workflow.name}: ${data.length} records`);
}
from kadoa_sdk import FetchDataOptions
workflows = client.workflow.list(limit=100)
for workflow in workflows:
data = client.extraction.fetch_all_data(
FetchDataOptions(workflow_id=workflow.id)
)
print(f"{workflow.name}: {len(data)} records")
curl -X GET "https://api.kadoa.com/v4/workflows/YOUR_WORKFLOW_ID/data?limit=50&page=2" \
-H "x-api-key: YOUR_API_KEY"