tasq/node_modules/agentic-flow/.claude/commands/flow-nexus/workflow.md

2.5 KiB

name description
flow-nexus-workflow Event-driven workflow automation with message queues

Flow Nexus Workflows

Create and manage automated workflows with event-driven processing.

Create Workflow

mcp__flow-nexus__workflow_create({
  name: "CI/CD Pipeline",
  description: "Automated testing and deployment",
  steps: [
    { id: "test", action: "run_tests", agent: "tester" },
    { id: "build", action: "build_app", agent: "builder" },
    { id: "deploy", action: "deploy_prod", agent: "deployer" }
  ],
  triggers: ["push_to_main", "manual_trigger"]
})

Execute Workflow

mcp__flow-nexus__workflow_execute({
  workflow_id: "workflow_id",
  input_data: {
    branch: "main",
    commit: "abc123"
  },
  async: true // Execute via message queue
})

Monitor Workflows

// Get workflow status
mcp__flow-nexus__workflow_status({
  workflow_id: "id",
  include_metrics: true
})

// List workflows
mcp__flow-nexus__workflow_list({
  status: "running",
  limit: 10
})

// Get audit trail
mcp__flow-nexus__workflow_audit_trail({
  workflow_id: "id",
  limit: 50
})

Agent Assignment

mcp__flow-nexus__workflow_agent_assign({
  task_id: "task_id",
  agent_type: "coder",
  use_vector_similarity: true // AI-powered matching
})

Queue Management

mcp__flow-nexus__workflow_queue_status({
  include_messages: true
})

Common Workflow Patterns

CI/CD Pipeline

mcp__flow-nexus__workflow_create({
  name: "Deploy Pipeline",
  steps: [
    { action: "lint", parallel: true },
    { action: "test", parallel: true },
    { action: "build", depends_on: ["lint", "test"] },
    { action: "deploy", depends_on: ["build"] }
  ],
  triggers: ["github_push"]
})

Data Processing

mcp__flow-nexus__workflow_create({
  name: "ETL Pipeline",
  steps: [
    { action: "extract_data", agent: "data_extractor" },
    { action: "transform_data", agent: "transformer" },
    { action: "load_data", agent: "loader" },
    { action: "validate", agent: "validator" }
  ],
  triggers: ["schedule:0 2 * * *"] // Daily at 2 AM
})

Multi-Stage Review

mcp__flow-nexus__workflow_create({
  name: "PR Review",
  steps: [
    { action: "code_analysis", agent: "analyzer" },
    { action: "security_scan", agent: "security" },
    { action: "performance_test", agent: "perf_tester" },
    { action: "approve_merge", agent: "reviewer" }
  ],
  metadata: { priority: 10 }
})