# Quick Start — Getting Started

> Get from zero to a running Aerostack project in 3 minutes.

This guide gets you from zero to a running Aerostack project. You'll install the CLI, create a project, and deploy your first function to the edge.

1. **Install the CLI**

   
     
       ```bash
       curl -fsSL https://get.aerostack.dev | sh
       ```
     
     
       ```bash
       npm install -g @aerostack/cli
       ```
     
     
       ```bash
       pnpm add -g @aerostack/cli
       ```
     
     
       ```bash
       bun add -g @aerostack/cli
       ```
     
   

   Verify it works:

   ```bash
   aerostack --version
   ```

2. **Authenticate**

   ```bash
   aerostack login
   ```

   This opens your browser to sign in. Once authenticated, the CLI stores your credentials locally.

   
     Don't have an account yet? Run `aerostack login` — it will guide you through registration.
   

3. **Create a Project**

   ```bash
   mkdir my-project && cd my-project
   aerostack init
   ```

   The CLI asks what you need (Database, Auth, AI, etc.) and scaffolds a ready-to-run project with:
   - `src/index.ts` — your function entry point
   - `aerostack.json` — project configuration
   - `aerostack.toml` — Cloudflare Workers configuration

4. **Start Local Development**

   ```bash
   aerostack dev
   ```

   Your function is now running at `http://localhost:8788`. The local dev server emulates the full Cloudflare edge runtime — including database, cache, and queue bindings.

   ```bash
   curl http://localhost:8788/health
   # {"status":"ok","project":"my-project"}
   ```

5. **Write Your First Function**

   Open `src/index.ts`. This is a fullstack edge function with native access to all platform primitives:

   ```typescript
   export default {
     async fetch(request: Request, env: Env): Promise {
       const url = new URL(request.url)

       if (url.pathname === '/api/hello') {
         // Native database — direct binding, no HTTP call
         const result = await env.DB.prepare(
           'SELECT COUNT(*) as count FROM visits'
         ).first()

         // Native cache — same datacenter
         await env.CACHE.put('last-visit', new Date().toISOString())

         return Response.json({
           message: 'Hello from Aerostack!',
           visits: result?.count ?? 0,
           cached_at: await env.CACHE.get('last-visit')
         })
       }

       return Response.json({ status: 'ok' })
     }
   }
   ```

   
     **This is not a simple serverless function.** Every function has native bindings to Database, Cache, Queue, AI, Vector Search, and Storage — with zero network latency. [Learn more about Functions](/functions).
   

6. **Deploy to Edge**

   When you're ready to go live:

   ```bash
   aerostack deploy
   ```

   Your function is now running on Cloudflare's global edge network — 300+ cities worldwide.

---

## What to Build Next

Pick the path that matches what you're building:

- **[Build a Function](/functions)** — Write fullstack edge functions with native DB, Cache, Queue, AI, and Storage access. The foundation for everything else.
- **[Build a Bot](/bots/create-first-bot)** — Deploy an AI bot to Telegram, Discord, WhatsApp, or Slack. Connect MCP tools. Add workflows for complex logic.
- **[Set Up MCP Servers](/mcp)** — Host MCPs, proxy existing ones, or install from Hub. Give your team secret-free access with per-user analytics.
- **[Create a Workspace](/workspaces)** — Compose multiple MCP servers behind one gateway URL. Connect from Claude Desktop, Cursor, or any MCP client.

---

## Using the Dashboard Instead

Everything you can do with the CLI, you can also do through the **Admin Dashboard** at [app.aerostack.dev](https://app.aerostack.dev):

- Create and manage projects
- Deploy functions, MCP servers, and skills
- Build and configure bots with the visual workflow editor
- Compose workspaces and manage team access
- View analytics, logs, and billing

The dashboard is the recommended starting point for **bots** and **workspaces**, while the CLI is best for **functions** and **MCP server development**.
