@flowdot.ai/api
v1.2.0
Published
Shared FlowDot API client and types for CLI and MCP server
Readme
@flowdot/api
Shared FlowDot API client and type definitions used by both the FlowDot CLI and MCP Server.
Installation
npm install @flowdot/apiUsage
import { FlowDotApiClient } from '@flowdot/api';
const client = new FlowDotApiClient('https://flowdot.ai', 'your-token');
// List workflows
const workflows = await client.listWorkflows();
// Execute a workflow
const result = await client.executeWorkflow('workflow-id', { input: 'value' });API Reference
The FlowDotApiClient class provides methods for interacting with the FlowDot Hub API:
Workflows
listWorkflows()- List all workflowsgetWorkflow(id)- Get workflow detailsexecuteWorkflow(id, inputs)- Execute a workflowcreateWorkflow(name, description)- Create a new workflowdeleteWorkflow(id)- Delete a workflowduplicateWorkflow(id, name)- Duplicate a workflow
Executions
getExecution(id)- Get execution statuscancelExecution(id)- Cancel a running executionretryExecution(id)- Retry a failed execution
Apps
listApps()- List all appsgetApp(id)- Get app detailscreateApp(input)- Create a new appupdateApp(id, updates)- Update an appdeleteApp(id)- Delete an app
Custom Nodes
listCustomNodes()- List custom nodesgetCustomNode(id)- Get custom node detailscreateCustomNode(input)- Create a custom nodeupdateCustomNode(id, updates)- Update a custom nodedeleteCustomNode(id)- Delete a custom node
Knowledge Base
listKnowledgeCategories()- List categorieslistKnowledgeDocuments()- List documentsqueryKnowledgeBase(input)- Query with RAGuploadTextDocument(input)- Upload text content
Agent Toolkits
listAgentToolkits()- List toolkitsgetAgentToolkit(id)- Get toolkit detailsinvokeToolkitTool(input)- Invoke a toolkit tool
Agent Recipes
listRecipes()- List recipesgetRecipe(hash)- Get recipe detailscreateRecipe(input)- Create a recipeforkRecipe(hash, name)- Fork a recipe
Goals
listGoals(status?)- List goals, optionally filtered by statuscreateGoal(input)- Create a goal (name, description, priority, allowed_actions)getGoal(hash)- Get goal detailsupdateGoal(hash, input)- Update a goaldeleteGoal(hash)- Delete a goalpauseGoal(hash)/resumeGoal(hash)- Pause or resume a goalcompleteGoal(hash)/abandonGoal(hash)- Transition goal statuslistGoalTasks(goalHash, status?)- List tasks for a goaladdGoalTask(goalHash, input)- Add a task (title, task_type, scheduled_for)deleteGoalTask(goalHash, taskId)- Delete a tasklistGoalMilestones(goalHash)- List milestonesaddGoalMilestone(goalHash, input)- Add a milestone (title, target_date)completeGoalMilestone(goalHash, milestoneId)- Complete a milestonedeleteGoalMilestone(goalHash, milestoneId)- Delete a milestone
See the TypeScript type definitions for complete API documentation.
