SYS ONLINE · v0.4.8 FOR EVERYONE

Stop paying
the token tax

routre — the 10-MB gateway you forget is running

Routre sits between your apps and AI providers — like a smart power strip. One address, less cost, stays online when a provider is busy. 10 MiB, runs quietly on your computer.

you@gateway: ~ bash

$

LIVE · 127.0.0.1:20128 UPTIME 00:00:00 BENCH 91.5%
LVL 02 · Manual

What is routre, in plain words?

Your AI tools (Claude Code, Codex, Cursor…) normally talk directly to an AI provider. Routre sits in the middle on your computer and does three simple things: it remembers answers so you don't pay twice, it shrinks sent data without losing meaning, and it switches providers automatically if one is busy.

You change one line in your app — point it to http://127.0.0.1:20128 — and everything else is automatic. Not 80 MB + leak. Not Python/Postgres GBs. Just Go.

10 MiB RAM, idle stdlib only
10.6 MiB single binary 6 platforms
~11 ms proxy overhead per request
91.5% Bench, tool reduction pass 90% gate
QST-01

Pay less

Remembers identical asks & compresses tool output — ≥90% less on repetitive tasks. See savings in routre list.

QST-02

Stay online

If a provider says “overloaded” (common on free models), routre tries the next one instantly. No error shown if another works.

QST-04

See what you spend

Built-in ledger per app — tokens, cost, cache hits. Doctor checks each provider. All on http://127.0.0.1:20128/ui.

LVL 03 · Directives

Our goals

01Save you money — every repeated question and large tool result is made smaller before billing. Cache + RTK, measured by a build gate (>90%).
02Never block you — free-tier “overloaded” is not your fault. Fail over so your work continues.
03Stay light & forgettable — one 10-MB binary, ~10 MB RAM idle, stdlib only. No cloud, no account. Dashboard for non-programmers — no JSON editing.

Analogy: like a travel adapter — one plug you trust, it picks the best socket behind the scenes.

LVL 04 · Deployment

Install

macOS · Linux bash
curl -fsSL https://raw.githubusercontent.com/mariobgsp/routre/main/install.sh | sh
routre version
routre setup              # wizard: providers + keys → config.json + routre.env (0600)
routre serve            # gateway on 127.0.0.1:20128

# point any agent at it:
export OPENAI_BASE_URL=http://127.0.0.1:20128
export ANTHROPIC_BASE_URL=http://127.0.0.1:20128
Windows · PowerShell ps1
# download from Releases → unzip → add to PATH →
routre setup
routre serve   # http://127.0.0.1:20128  ·  dashboard /ui

Self-update built in: routre update verifies sha256 — or let your AI do it.

LVL 05 · Deployment

Windows

No installer, no admin rights. One zip, one folder, one PATH entry.

Option A — manual (2 min)
PowerShell ps1
# 1. Download the zip for your CPU from Releases:
#    https://github.com/mariobgsp/routre/releases/latest

# 2. Unzip to a permanent folder:
Expand-Archive .\routre_windows_amd64.zip -DestinationPath $HOME\routre

# 3. Add to PATH for this user (no admin):
$dir = "$HOME\routre"
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";$dir", "User")
$env:Path += ";$dir"   # also for this shell

# 4. Setup + run:
routre version
routre setup              # wizard → config.json + routre.env (0600) next to the exe
routre serve            # gateway + dashboard at http://127.0.0.1:20128/ui

# Verify:
curl http://127.0.0.1:20128/healthz   # → ok
routre check            # validates config + keys
routre list             # providers + savings + BUDGET HIT
Option B — PowerShell one-liner (auto PATH)
PowerShell ps1
irm https://raw.githubusercontent.com/mariobgsp/routre/main/install.ps1 | iex
# (falls back to manual zip if ps1 is not yet published — same 3 steps above)

SmartScreen: More info → Run anyway · one exe, autostart needs no admin.

LVL 06 · Deployment

Install with an AI prompt

Paste one prompt into Claude Code, Codex, Cursor, or opencode — the agent runs the same commands you would.

Copy → paste into your agent
agent prompt txt
Install routre (github.com/mariobgsp/routre) on this machine:

1. Detect OS/CPU, fetch the latest release asset for this platform
   (curl install.sh on macOS/Linux, zip from Releases on Windows), verify sha256, and put the binary on PATH as routre (keep routre-cli as alias).
2. Run: routre setup   (wizard; non-interactive if keys already in env)
   If OPENCODE_GO_API_KEY / OPENROUTER_API_KEY / ANTHROPIC_API_KEY are missing, ask me once and write them to routre.env (0600).
3. Start the gateway: routre serve (or routre start --autostart for boot).
4. Point this agent at it:
   export OPENAI_BASE_URL=http://127.0.0.1:20128
   export ANTHROPIC_BASE_URL=http://127.0.0.1:20128
5. Verify: curl http://127.0.0.1:20128/healthz  and  routre list
6. Open the dashboard: http://127.0.0.1:20128/ui

Keep it stdlib-only, ~10 MiB RAM. Do not install Python/Postgres/Node.
Non-interactive one-shot
you@gateway: ~ bash
curl -fsSL https://raw.githubusercontent.com/mariobgsp/routre/main/install.sh | sh && routre setup && routre serve
Windows prompt variant
agent prompt txt
Install routre on Windows (PowerShell):
download routre_windows_amd64.zip from Releases, expand to $HOME\routre, add to user PATH, then run routre setup and routre serve. Verify with curl http://127.0.0.1:20128/healthz.

Tip: after setup, open http://127.0.0.1:20128/ui — keys + config without JSON.

LVL 07 · Bestiary

Why not X?

RAM idle Install 90% claim
routre 10 MiB curl one-liner / zip, 6 platforms · AI prompt bench-gated, build fails on regress
9router 80 MiB, leak to 4.8 GB Node/Next.js unbenchmarked, walked back
LiteLLM / Portkey GBs (Python/Postgres/Redis) full stack price discount / input-only
LVL 08 · Quick Start

Quick start

you@gateway: ~ bash
routre setup              # wizard: providers, URLs, keys, prices
routre check              # validate config + keys
routre serve              # gateway on 127.0.0.1:20128
routre start --autostart  # daemon + boot auto-start
routre list               # providers + token/cost ledger
routre doctor             # probe every provider
routre models sync        # one-shot sync (serve persists new models itself)
routre logs -f            # tail request log
routre bench -target 90   # gated metric, fails build on regress

Endpoints: /v1/chat/completions · /v1/responses · /v1/messages · /v1/models · /v1/status · /v1/usage · /healthz · /metrics · /ui (dashboard)

No CLI needed: open http://127.0.0.1:20128/ui to set keys and edit the full config in the browser (loopback-only).

Need every model at once? Copy config.all.json over config.json — 506 models through one endpoint.

LVL 09 · Changelog

Latest

v0.4.8Blueprint UI + dashboard — portfolio redesigned in Flat Blueprint style; /ui dashboard now matches the same navy/gold theme.
v0.4.4Opencode session header — every opencode.ai request carries x-opencode-session. Ends the missing-header error for Go/curl clients.
v0.4.3Native Responses passthrough — /v1/responses proxied natively for opencode upstreams; agent guide so the 500 never recurs.
v0.3.4Models sync — routre serve persists newly discovered provider models to config.json on its own; routre models sync does the same one-shot, and --prune drops retired ones.

Full history in CHANGELOG.md — bench-gated ≥90% tool-token savings, 10.6 MiB binary, ~10 MiB idle.