The REST API server makes Cognee accessible from any programming language or platform that can make HTTP requests, with complete API documentation available in the interactive reference.

Quick Start

1

Clone Repository

Get the Cognee source code with Docker Compose configuration.
2

Configure Environment

Set up your .env file with API keys and database settings.
3

Start with Docker Compose

Launch the API server using Docker Compose profiles.
4

Access API Documentation

Use the interactive API documentation to test endpoints.

Docker Compose Setup

Cognee uses Docker Compose with modular profiles for flexible deployment:
Minimal Setup
# Clone repository
git clone https://github.com/topoteretes/cognee.git
cd cognee

# Create environment file
cp .env.template .env
# Edit .env with your LLM_API_KEY

# Start basic API server
docker compose up
What you get:
  • Cognee API server on port 8000
  • SQLite database (no external dependencies)
  • Ready for basic development and testing

Service Architecture

Cognee’s Docker setup includes modular services:

Core Services

Main Components
  • Cognee API: Main backend server (port 8000)
  • Cognee MCP: Model Context Protocol server
  • Frontend: Next.js web interface (work in progress)

Database Options

Storage Backends
  • PostgreSQL: Relational database with pgvector
  • Neo4j: Graph database with APOC plugins
  • ChromaDB: Vector database for embeddings
  • FalkorDB: Alternative graph database

Environment Configuration

Create a .env file with your configuration:
# .env (minimal setup)
LLM_API_KEY=your_openai_api_key_here
LLM_PROVIDER=openai
LLM_MODEL=gpt-4o-mini

API Documentation

Once your server is running, access the comprehensive API documentation:
API Base URL: http://localhost:8000 - All endpoints are documented in the interactive Swagger UI and complete API reference.

Docker Compose Profiles

Use profiles to run only the services you need:

Available Profiles

Next Steps

Quick Start: Run docker compose --profile postgres up -d and visit http://localhost:8000/docs to explore the interactive API documentation!