Skip to content

API Reference Overview

This section provides detailed technical documentation for the Flowcraft API. It is intended for developers who are familiar with the Core Concepts and are looking for specific details on classes, interfaces, and functions.

Key Modules

The Flowcraft API is organized into several key modules, each responsible for a specific aspect of the framework.

  • Flow (createFlow): The fluent builder API for programmatically constructing a WorkflowBlueprint.
  • Runtime (FlowRuntime): The engine responsible for executing workflows.
  • Nodes: The interfaces and base classes for defining node implementations (BaseNode, NodeFunction).
  • Context: The interfaces and classes for managing workflow state (ISyncContext, IAsyncContext).
  • Analysis: Utilities for validating and visualizing blueprints (analyzeBlueprint, generateMermaid).
  • Linter: Tools for static analysis to find common errors before runtime.
  • Extensibility Interfaces:
    • Middleware: The Middleware interface for adding cross-cutting concerns like tracing and transactions.
    • Serializer: The ISerializer interface for custom data serialization.
    • Evaluator: The IEvaluator interface for custom expression evaluation.
    • Logger: The ILogger interface for plugging in custom logging providers.
  • Errors: Custom error classes thrown by the runtime.
  • Distributed Adapter: The base classes and interfaces for building distributed execution adapters.

Released under the MIT License.