> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chattermate.chat/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

> Get started with ChatterMate in minutes

# Quickstart Guide

This guide will help you get ChatterMate up and running quickly using our CLI tool.

## Quick Start with CLI (Recommended)

The fastest way to get ChatterMate running is with our CLI tool:

<Steps>
  <Step title="Install CLI">
    Install the ChatterMate CLI globally:

    ```bash theme={null}
    npm install -g chattermate-cli
    ```
  </Step>

  <Step title="Create Project">
    Initialize a new ChatterMate project:

    ```bash theme={null}
    chattermate init my-chattermate-project
    cd my-chattermate-project
    ```
  </Step>

  <Step title="Start Services">
    Start all services with Docker:

    ```bash theme={null}
    chattermate start
    ```
  </Step>

  <Step title="Access Dashboard">
    Open your browser and visit:

    * Frontend Dashboard: `http://localhost/`
    * Backend API: `http://localhost:8000`
    * API Documentation: `http://localhost:8000/docs`
  </Step>
</Steps>

### CLI Commands

<CodeGroup>
  ```bash Project Management theme={null}
  chattermate init <project-name>    # Initialize a new project
  chattermate reset                  # Reset and cleanup project
  ```

  ```bash Service Management   theme={null}
  chattermate start                  # Start all services
  chattermate stop                   # Stop all services
  chattermate status                 # Check service status
  chattermate logs                   # View service logs
  ```
</CodeGroup>

## Manual Installation

If you prefer to set up ChatterMate manually or need custom configuration:

### Backend Setup

<CodeGroup>
  ```bash Setup Commands theme={null}
  # Clone the repository
  git clone https://github.com/chattermate/chattermate
  cd chattermate/backend

  # Create and activate virtual environment
  python -m venv venv
  source venv/bin/activate  # Windows: venv\Scripts\activate

  # Install dependencies
  pip install -r requirements.txt

  # Copy and configure environment variables
  cp .env.example .env
  # Edit .env file with your configurations
  ```

  ```bash .env theme={null}
  # Copy .env.example to .env and configure these values:
  DATABASE_URL=postgresql://user:pass@localhost:5432/chattermate
  FIREBASE_CREDENTIALS=firebase-credentials.json
  JWT_SECRET_KEY=your-secret-key
  CONVERSATION_SECRET_KEY=yoursecretkey
  ENCRYPTION_KEY=encryption.key
  CORS_ORIGINS=["https://yourdomain.com"]
  ```
</CodeGroup>

### Frontend Setup

<CodeGroup>
  ```bash Setup Commands theme={null}
  # Navigate to frontend directory
  cd frontend

  # Install dependencies
  npm install

  # Copy and configure environment variables
  cp .env.example .env
  # Edit .env file with your configurations
  ```

  ```bash .env theme={null}
  # Copy .env.example to .env and configure these values:
  VITE_API_URL=http://localhost:8000
  VITE_WS_URL=ws://localhost:8000
  ```
</CodeGroup>

### Database Setup

<Steps>
  <Step title="Create Database">
    Create a PostgreSQL database and enable the vector extension:

    ```sql theme={null}
    CREATE DATABASE chattermate;
    \c chattermate
    CREATE EXTENSION vector;
    ```
  </Step>

  <Step title="Run Migrations">
    Apply the database migrations:

    ```bash theme={null}
    alembic upgrade head
    ```
  </Step>
</Steps>

### Running the Application

<CodeGroup>
  ```bash Backend theme={null}
  # Start the backend server
  uvicorn app.main:app --reload --port 8000
  ```

  ```bash Frontend theme={null}
  # Start the frontend development server
  npm run dev
  ```
</CodeGroup>

## Verify Installation

1. Open your browser and navigate to `http://localhost:8000/docs` to view the API documentation
2. Visit `http://localhost/` to access the web interface (CLI) or `http://localhost:3000` (manual setup)
3. Try sending a test message in the chat widget

## Next Steps

<CardGroup cols={2}>
  <Card title="Setup Organization" icon="building" href="features/organization">
    Setup new organization
  </Card>

  <Card title="Configure AI" icon="robot" href="features/ai-configuration">
    Configure AI provider
  </Card>

  <Card title="Customize AI Agent" icon="wand-magic-sparkles" href="features/ai-customization">
    Customizing AI agent
  </Card>

  <Card title="Knowledge Base" icon="book" href="features/knowledge-base">
    Adding knowledge to AI agent
  </Card>

  <Card title="Testing" icon="vial" href="features/testing">
    Testing AI agent
  </Card>

  <Card title="Widget Integration" icon="code" href="features/widget">
    Adding chat widget to the website
  </Card>

  <Card title="Human Agents" icon="user-plus" href="features/human-agents">
    Adding Human Agent
  </Card>

  <Card title="Roles & Permissions" icon="shield" href="features/roles">
    Managing Roles and Permission
  </Card>

  <Card title="Chat Management" icon="messages" href="features/chat-management">
    Managing Customer chat and Taking over chat
  </Card>
</CardGroup>
