Skip to content
MeridFlow AiFlow v8.x • self-hosted

AiFlow API Documentation

AiFlow is a self-hosted AI workforce platform. Each client runs their own deployment, with their own database and their own credentials.

This is the full API reference for your own deployment. It covers configuring agents, knowledge, and tools; wiring up events, triggers, and webhooks; managing your team; and running the multi-model Orchestrator layer.

Every endpoint comes with working examples in cURL, Python, and TypeScript.

  • Credentials


    Every outside account your deployment needs before it can run: Gemini, plus Twilio, WhatsApp, Telegram, Resend, CRM connectors, and SSO if your agents need them.

    Get your credentials

  • Getting started


    Learn how authentication works in a self-hosted AiFlow deployment, then make your first API call in minutes.

    Quickstart

  • Concepts


    A quick tour of Agents, Triggers, Events, and Orchestrators: the core ideas behind everything else on this site.

    Read the overview

  • Configure an agent


    Create agents, upload knowledge, enable tools, and connect MCP servers, all through the API.

    Agents guide

  • Orchestrators


    Delegate tasks across models and agents: Gemini, Anthropic, OpenAI, and 100+ other providers.

    Orchestrators guide

  • Events & webhooks


    Fire outbound calls and messages from your own systems, and get signed notifications back when something happens.

    Sending events

  • API reference


    Every documented endpoint, generated straight from AiFlow's own route definitions.

    Browse the reference

How this site is organized

Getting Started walks through authentication and your first API call. Concepts covers the ideas behind the API before you start writing code against it. Guides is the full task-by-task reference, organized by area:

Area Covers
Agents & configuration Agent lifecycle, knowledge documents, built-in and custom tools, MCP connections, agent-to-agent delegation
Events, triggers & calls Sending and reading events, the trigger rule engine, the call log and transcripts, webhook subscriptions
Orchestrators Multi-model delegation, Orchestrator tools, sub-Orchestrator graphs, shared MCP pools, the Console
Widget & MCP The embeddable website widget, and AiFlow as an MCP server for external clients
Administration API keys, team and role management, the audit log, data retention and deletion, observability

Every guide that documents a real request shows the same call three ways: pick the version that matches your stack.

curl https://api.your-domain.com/health
import httpx

httpx.get("https://api.your-domain.com/health")
await fetch("https://api.your-domain.com/health");

Start with Authentication: every other page on this site assumes you've already read it.