Skip to main content
Setup

Getting Started with Vibgrate Relay

Sign in, mint a Relay token, and point vg code at Vibgrate Relay in under a minute.

Prerequisites

  • The Vibgrate CLI installed (vg on your PATH).
  • A Vibgrate account (vg login) — Relay is billed per workspace, not per machine.
  • Prepaid credit on the workspace, or a BYOK provider key (see BYOK passthrough) if you'd rather not spend Relay credit yet.

1. Sign in

vg login

This opens a browser flow and stores a DSN credential locally. Relay authenticates with the same credential — there is no separate Relay-only login.

2. Add credit (skip this if you're using BYOK)

Open dash.vibgrate.com → Settings → Billing → Relay and buy a top-up ($25 minimum). Credits are prepaid — nothing is served on Vibgrate's key unless the balance can already cover it, so there's never a surprise invoice. See Pricing & credits for the full fee schedule.

3. Set your Relay token

export VIBGRATE_RELAY_TOKEN="<your-dsn-key>:<your-dsn-secret>"

Put this in your shell profile or CI secret store — never commit it. When VIBGRATE_RELAY_TOKEN is set, VG Code prefers Vibgrate Relay automatically over other hosted providers, with local models as fallback if Relay is unreachable.

4. Run VG Code

vg code "extract the pagination logic in UserList.tsx into a hook" --provider vibgrate-relay

The --provider flag is optional once VIBGRATE_RELAY_TOKEN is set — Relay is picked automatically. Pick a specific model with --model or VG_CODE_MODEL; see Supported models for the current catalog.

vg code "..." --provider vibgrate-relay --model anthropic/claude-sonnet-5

Verifying it's working

vg doctor

vg doctor reports which model backend VG Code would currently select and why (the same routing reason string VG Code itself uses, e.g. "VIBGRATE_RELAY_TOKEN is set → Vibgrate Relay (with local fallback)").

What happens if you have no credit and no BYOK key

VG Code fails with an actionable message rather than a silent local fallback substitution of a different paid backend:

no model backend configured. Do one of: sign in to Vibgrate Relay (VIBGRATE_RELAY_TOKEN),
set OPENROUTER_API_KEY for the hosted router, run `vg models install spark` for the
Vibgrate manager, run Ollama locally, or use --local with a local model.

A request against an empty Relay balance returns HTTP 402 with an insufficient_credit error carrying a top-up link and a correlation id — see Troubleshooting & FAQ.

Related Documentation

Related Help Articles