Skip to main content

PraisonAI API

PraisonAI provides a unified HTTP API for all server capabilities. Start a local server and test endpoints directly in this documentation.

Quick Start

Security Note (PR #1597): PraisonAI API servers are now secure-by-default. Authentication is enabled and servers bind to 127.0.0.1 by default. If no token is provided, a random bearer token is generated and printed to stderr.
Server running at: http://127.0.0.1:8765

Authentication

Use the bearer token printed at startup:
Override defaults with environment variables:
Setting PRAISONAI_API_HOST=0.0.0.0 exposes the server on all interfaces. Always pair external binding with authentication or a fronting proxy.

Base URL

All examples use http://127.0.0.1:8765 as the base URL. Change the port if you started the server on a different port.

Server Types

Discovery Endpoint

All servers expose a unified discovery endpoint:
Response:

API Endpoints Summary

Core Endpoints

Agents API

Recipe API

MCP API

A2A API

A2U API

Jobs API (Async)

Authentication

Authentication is optional and configurable per server:
Using API key: --api-key accepts either Authorization: Bearer or X-API-Key.
The async Jobs API uses a separate key — see Jobs API Authentication.

Common Options

Safety Notes

Binding to 0.0.0.0: Only bind to 0.0.0.0 if you need external access. For local development, use 127.0.0.1.
CORS: By default, CORS is not configured. Add --cors-origins "*" for development only.

Next Steps

Discovery API

Unified discovery endpoint

Agents API

Agent invocation endpoints

Recipe API

Recipe runner endpoints

A2U API

Event streaming endpoints