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

# Local Setup

> Run Green Teagentic on your machine.

## Prerequisites

* **Bun** ≥ 1.1
* A the platform project (already provisioned for the hosted app)

## Clone & install

```bash theme={null}
git clone <your-repo>
cd green-teagentic
bun install
```

## Environment variables

`.env` is managed by the platform. For local development, create one with:

```bash theme={null}
VITE_SUPABASE_URL=...
VITE_SUPABASE_PUBLISHABLE_KEY=...
VITE_SUPABASE_PROJECT_ID=...
SUPABASE_URL=...
SUPABASE_PUBLISHABLE_KEY=...
SUPABASE_SERVICE_ROLE_KEY=...
TEAGENTIC_AI_KEY=...
```

See [Environment variables](/reference/environment-variables) for the full list.

## Run

```bash theme={null}
bun run dev
```

The dev server starts on `http://localhost:5173`. The TanStack Router Vite plugin regenerates `src/routeTree.gen.ts` automatically — don't edit it by hand.

## Apply database migrations

Migrations live in `supabase/migrations/`. In the hosted environment, they apply automatically. Locally, point `supabase` CLI at your project and run:

```bash theme={null}
supabase db push
```
