coloa

Getting started

Build an app on your laptop, then ship it to your team’s Coloa server. Coloa is licensed software by Olli Technology. To try it, email son@olli-ai.com.

1. Install the CLI

Your Coloa admin gives you a token. Then:

# macOS and Linux
export COLOA_TOKEN=<your token>
curl -fsSL https://coloa.olli-ai.com/download/install.sh | sh
# Windows (PowerShell)
$env:COLOA_TOKEN = "<your token>"
irm https://coloa.olli-ai.com/download/install.ps1 | iex

The script checks the file’s SHA-256 checksum and installs coloa for your user only, no admin rights needed. You also need Docker (coloa dev runs Postgres in it) and Node.js if the app has a React frontend. On Windows, the Linux build inside WSL 2 is the most tested option.

2. Create an app and run it

coloa init myshop --template react-ts && cd myshop
coloa dev
#   app      http://127.0.0.1:4000
#   console  http://127.0.0.1:4001/#token=…   (printed once)
Template What you get
react-ts React + Vite frontend in web/, TypeScript functions
shop Plain HTML page, TypeScript functions
go Functions in Go
python Functions in Python
blank Just coloa.yaml

coloa dev reloads on every save. It’s free on your own machine (127.0.0.1).

3. Describe your data and who may touch it

schema.coloa defines tables and access rules. Nothing is readable unless a rule allows it:

table orders {
  owner      user  @owner                  // set to whoever creates the row; can't be forged
  item       text
  total      money @default(0)
  card_last4 text  @sensitive @optional    // never sent to the browser, masked in logs

  allow read, update: owner == auth.user
  allow read:         auth.role == "staff"
  allow create:       auth.user != null
  // no delete rule: nobody can delete
}

The rules are enforced by Postgres itself (row-level security), so a bug in your code can’t widen access. The full language is in Schema language.

4. Write functions

Each file in functions/ serves one path: functions/orders.ts answers /api/orders, functions/orders/[id].ts answers /api/orders/<id>.

TypeScript:

export default async function (req: ColoaRequest) {
  if (req.method === "POST") {
    if (!auth.user) return Response.json({ error: "sign in first" }, { status: 401 });
    return await db.from("orders").insert(await req.json()).select("id, item, total").single();
  }
  return await db.from("orders").select("id, item, total").order("created_at", { ascending: false });
}

Python (functions/orders.py):

from coloa import Response, db

def get(req, ctx):
    return db.table("orders").select("id, item, total").order("created_at", desc=True).limit(50).all()

Go (functions/orders.go) uses github.com/olli-ai/coloa/sdk/go/coloa; see the go template.

5. Files

Uploads are declared in schema.coloa with the same kind of rules:

files receipts {
  order    ref(orders)
  max_size 5mb
  types    "image/*", "application/pdf"
  allow read, create: order.owner == auth.user
}

6. Calling other services, with secrets

Outbound calls are blocked unless a person allows the host. Secrets never reach your code: it holds a placeholder, and Coloa inserts the real value only on requests to that secret’s hosts.

coloa egress allow api.stripe.com
coloa secret set STRIPE_KEY --host api.stripe.com     # asks for the value
await fetch("https://api.stripe.com/v1/charges", {
  headers: { Authorization: `Bearer ${env.STRIPE_KEY}` },   // the placeholder; the real key is added on the way out
});

7. Check, preview, promote, roll back

coloa check                       # rules, schema, unknown hosts, sensitive reads, N+1 queries with a cost estimate
coloa deploy --preview pr-1       # a preview with its own database
coloa promote pr-1                # production: a database snapshot first, then the migration
coloa rollback --to <snapshot>    # code and data back to a snapshot (coloa snapshots lists them)

Promoting can require approval by one or more other people (promotion: in coloa.yaml).

8. Ship to your team’s server

export COLOA_SERVER=https://coloa.olli-ai.com COLOA_TOKEN=<your token>
coloa remote login                       # if two-factor sign-in is on: asks for your authenticator code
coloa push --preview pr-1                # → https://pr-1.myshop.coloa.olli-ai.com
coloa remote request-promotion pr-1      # ask an owner…
coloa remote promote pr-1                # …or, as an owner, promote: https://myshop.coloa.olli-ai.com
coloa remote egress api.stripe.com       # allow a host on the server
coloa remote secret STRIPE_KEY --host api.stripe.com

The console is at https://coloa.olli-ai.com/console: sign in with your token (and authenticator code) to see your apps, approvals, audit log and costs. To set up an authenticator app, ask an admin for an invitation from the Members page.

App names. The name in coloa.yaml becomes the address <name>.coloa.olli-ai.com: 1–30 lowercase letters, digits and single dashes, starting with a letter. Names Coloa uses itself or that would look official (console, www, api, admin, login, mail…) can’t be taken. If an app with your name already exists and you’ve never worked on it, the push stops and says who created it: pick another name (or, if you really mean to replace it, coloa push --replace).

Share it with everyone. Once the app is live in production, its owner (or an admin) can list it on the home page under Explore public applications: console → All apps → List…, with a title and a one-line description. Unlist takes it off.

9. Let an AI coding agent work on it

coloa agent connect claude-code    # also cursor, gemini, codex: writes .mcp.json and AGENTS.md
coloa run --sandbox docker --as agent:claude-code --image <agent image> -- claude

The agent gets its own identity and runs in a sandbox whose only way out is Coloa’s gateway. It can write code, deploy previews and ask for promotion. It can’t promote, approve, change policy, add hosts, set secrets or see real secret values; every attempt is in the audit log.

10. Costs and budgets

coloa cost                                     # this month by function, host, LLM model; forecast
coloa cost advise                              # suggestions with estimated monthly savings
coloa budget set 2000000 --on-cap read_only    # hard monthly cap: read_only | pause | throttle | notify_only
coloa budget agent agent:claude-code 200000    # an agent's daily LLM token limit

Every request, query, external call, LLM token and stored file is metered. LLM calls through the gateway are counted per model and per agent.

11. Services in any language

For long-running processes or libraries that don’t fit a function (numpy, a Java service), declare services: in coloa.yaml. Each runs in its own container, as non-root, with memory and CPU limits, reachable at /svc/<name>/ and only through Coloa’s gateway outward. Coloa tells the service who the user is in signed headers; verify them with the helpers in sdk/ (Python, Go, Node).

On Kubernetes installs, services aren’t available yet; use functions there.

12. Leave any time

coloa export --out myshop.tar      # code, a pg_dump of every environment, files, audit log, releases

More