v-key

A v-key is a disposable, budget-capped key (sk-...) you put in the browser. Your management key stays on the server and creates them. A group of v-keys created by the same management key is called a team. Team and user account are the same thing — one management key and a pool of v-keys.

The two key types

KeyWhat it can do
Management keyCreate, list, inspect, update and delete your v-keys; read your usage and spend
v-keyPOST /v1/chat/completions, GET /v1/models — inference only

The management key is securely available to see from the dashboard for authenticated users. v-keys are not stored like the management key — after creating one, store it securely, you will not be able to retrieve it again.

Keep the management key secret on your server. Never put it in data-api-key. Only v-keys go to the browser.

Disposable by design

A v-key is created using your management key. It can then be updated and deleted, and each key can be used for inference — it is capped and page-locked.

  • Create with caps (max_budget, budget_duration, models, rpm_limit) and a key_alias for individual tracking — make the alias correspond to the user, page, default anonymous user, or other abstraction that defines a budget strategy
  • Revoke via POST /key/delete {"keys":["sk-…"]} — next GET /key/info?key=sk-…404
  • Rotate by deleting + generating a fresh key_alias

You can issue hundreds of v-keys in your team.

Lifecycle example

# Use your management key to mint a disposable v-key
curl -X POST "$PROXY_URL/key/generate" \
  -H "Authorization: Bearer $TEAM_MGMT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"key_alias":"vkey-landing","max_budget":5,"budget_duration":"30d","models":["gemma4"]}'
# → { "key": "sk-…", "max_budget": 5.0 }

The v-key draws from both budgets (see Budgets) and is locked to the page (see Watermarking).

Tip: Give each surface its own key_alias (landing, docs, checkout). Revoking one does not affect others.

Help improve these docs

Found a gap? The widget is open source — open an issue or PR in the widget repo.