Skip to main content

API Documentation

Comprehensive API reference for all Nadoo AI platform components.

Available APIs


Flow Core APIs

Python framework for building AI workflows and agents.

Core Modules

ModuleDescriptionStatus
baseCore types and workflow execution✅ Stable
chainChaining API with pipe operator✅ Stable
batchBatch processing operations✅ Stable
callbacksEvent handling and observability✅ Stable

Feature Modules

ModuleDescriptionStatus
memoryChat history and session management✅ Stable
memory_dbDatabase-backed persistent storage✅ Stable
streamingReal-time event streaming✅ Stable
resilienceRetry and fallback patterns✅ Stable
cachingResponse caching mechanisms✅ Stable
rate_limitingAPI quota management✅ Stable
toolsTool registry and management✅ Stable
parsersOutput parsing and extraction✅ Stable
promptsPrompt templates and formatting✅ Stable
backendsMulti-backend support✅ Stable

Quick Example

from nadoo_flow import ChainableNode, NodeResult

class MyNode(ChainableNode):
    async def execute(self, node_context, workflow_context):
        return NodeResult(success=True, output={"result": "data"})

# Chain nodes with pipe operator
workflow = MyNode() | ProcessNode() | OutputNode()
result = await workflow.run({"input": "data"})

Plugin SDK APIs

SDK for developing custom plugins and tools.

Available APIs

APIDescriptionDocumentation
llmInvoke LLM models✅ Available
knowledgeSearch knowledge bases✅ Available
toolsInvoke other tools✅ Available
storagePersistent storage✅ Available

Quick Example

from nadoo_plugin import NadooPlugin, tool, parameter

class MyPlugin(NadooPlugin):
    @tool(name="process_text", description="Process text using AI")
    @parameter("text", type="string", required=True)
    def process_text(self, text: str) -> dict:
        # Use Nadoo's LLM
        response = self.api.llm.invoke(
            messages=[
                {"role": "user", "content": f"Process: {text}"}
            ]
        )

        return {"processed": response.content}

Sandbox APIs

Secure code execution in 12+ programming languages.

Endpoints

EndpointDescriptionDocumentation
/executeSynchronous execution✅ Available
/async-executeAsynchronous execution✅ Available
/batchBatch execution✅ Available

Supported Languages

Python, JavaScript, TypeScript, Java, Go, Rust, C++, C#, Ruby, PHP, SQL, Bash

Quick Example

curl -X POST http://localhost:8002/api/v1/execute \
  -H "X-API-Key: your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "code": "print(\"Hello, World!\")",
    "language": "python"
  }'

Builder APIs

Coming SoonBuilder platform APIs for visual workflow creation and management.
Planned APIs:
  • REST API for workflow management
  • Webhooks for event notifications
  • SDK for programmatic access

API Conventions

Import Structure

All APIs follow consistent import patterns:
# Flow Core
from nadoo_flow import ChainableNode, WorkflowExecutor

# Plugin SDK
from nadoo_plugin import NadooPlugin, tool, parameter

# For Sandbox, use REST API

Async-First Design

Flow Core and Plugin SDK use async/await:
# Async execution
result = await node.execute(node_context, workflow_context)
result = await workflow.run(input_data)

# Streaming
async for chunk in workflow.stream(input_data):
    process(chunk)

Type Safety

All APIs use type hints and Pydantic models:
from typing import Dict, Any
from pydantic import BaseModel

class Config(BaseModel):
    timeout: float = 30.0
    retries: int = 3

Error Handling

Consistent error handling across all APIs:
from nadoo_flow import NodeResult

try:
    result = await node.execute(context)
    return NodeResult(success=True, output=data)
except Exception as e:
    return NodeResult(success=False, error=str(e))

Authentication

Flow Core

No authentication required - local Python library

Plugin SDK

Uses workspace API keys configured in Nadoo platform

Sandbox

API key authentication via X-API-Key header:
curl -H "X-API-Key: your-api-key" ...

Builder

OAuth 2.0 and API key authentication (coming soon)

Getting Started


Support