docs:workflows.title
docs:workflows.desc
docs:workflows.features.list.title
docs:workflows.features.list.desc
docs:workflows.features.run.title
docs:workflows.features.run.desc
docs:workflows.features.nodes.title
docs:workflows.features.nodes.desc
docs:workflows.features.tracking.title
docs:workflows.features.tracking.desc
docs:workflows.endpoints
GET
/api/sdk/workflowsdocs:workflows.listWorkflows.desc
docs:workflows.listWorkflows.response
| docs:workflows.listWorkflows.field | docs:workflows.listWorkflows.type | docs:workflows.listWorkflows.description |
|---|---|---|
id | number | docs:workflows.fields.id |
name | string | docs:workflows.fields.name |
description | string? | docs:workflows.fields.description |
is_active | boolean | docs:workflows.fields.isActive |
trigger_type | string | docs:workflows.fields.triggerType |
node_count | number | docs:workflows.fields.nodeCount |
docs:workflows.listWorkflows.request
curl -X GET "https://promstack.com/api/sdk/workflows" \
-H "Authorization: Bearer YOUR_API_KEY"GET
/api/sdk/workflows/:iddocs:workflows.getWorkflow.desc
docs:workflows.getWorkflow.nodeTypes
| docs:workflows.listWorkflows.type | docs:workflows.listWorkflows.description |
|---|---|
start | docs:workflows.nodeTypes.start |
agent | docs:workflows.nodeTypes.agent |
transform | docs:workflows.nodeTypes.transform |
condition | docs:workflows.nodeTypes.condition |
end | docs:workflows.nodeTypes.end |
POST
/api/sdk/workflows/:id/rundocs:workflows.run.desc
docs:workflows.run.requestBody
| docs:workflows.listWorkflows.field | docs:workflows.listWorkflows.type | docs:workflows.listWorkflows.description |
|---|---|---|
input | any | docs:workflows.fields.input |
docs:workflows.listWorkflows.response
| docs:workflows.listWorkflows.field | docs:workflows.listWorkflows.type | docs:workflows.listWorkflows.description |
|---|---|---|
runId | number | docs:workflows.fields.runId |
status | string | docs:workflows.fields.status |
output | any | docs:workflows.fields.output |
nodeResults | object | docs:workflows.fields.nodeResults |
docs:workflows.sdk.title
docs:workflows.sdk.listTitle
import { PromStackClient } from '@promstack-1/sdk';
const client = new PromStackClient({
apiKey: process.env.PROMSTACK_API_KEY!,
baseUrl: 'https://promstack.com'
});
// List all workflows
const workflows = await client.getWorkflows();
// Get specific workflow details (with nodes/edges)
const workflow = await client.getWorkflow(1);docs:workflows.sdk.runTitle
// Run with string input
const result = await client.runWorkflow(1, 'Blog post topic: Future of AI');
console.log('Run ID:', result.runId);
console.log('Status:', result.status);
console.log('Output:', result.output);💡 docs:workflows.note.title
- docs:workflows.note.step1
- docs:workflows.note.step2
- docs:workflows.note.step3
- docs:workflows.note.step4
- docs:workflows.note.step5
