From 207d3c4b5fdbf5bd0295e913fa724c97ba641787 Mon Sep 17 00:00:00 2001 From: Shawn Pana Date: Wed, 17 Jun 2026 21:24:29 -0700 Subject: [PATCH] docs: flag that the default model needs paid AI Gateway credits A fresh deploy builds and runs, but the default anthropic/claude-opus-4.8 routes through the Vercel AI Gateway, which returns "Free tier users do not have access to this model" without paid credits. Document the gateway-credits requirement and the no-gateway direct-provider path (ANTHROPIC_API_KEY) in ENVIRONMENT.md and the README Deploy step. Co-Authored-By: Claude Opus 4.8 (1M context) --- README.md | 2 ++ docs/ENVIRONMENT.md | 20 +++++++++++++++----- 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 8602727..bb3828f 100644 --- a/README.md +++ b/README.md @@ -62,6 +62,8 @@ It's a single Next.js service: `withEve()` in [`next.config.ts`](next.config.ts) You'll be asked for a `BROWSER_USE_API_KEY` (from [browser-use.com](https://browser-use.com)) and a model credential (link the Vercel project for the AI Gateway, or set `AI_GATEWAY_API_KEY`). +> **Note:** the default model runs through the Vercel AI Gateway, which **requires paid credits** — without them you'll see _"Free tier users do not have access to this model"_ when the agent tries to browse. To run without the gateway, use a direct provider key (e.g. `ANTHROPIC_API_KEY`) instead — see [ENVIRONMENT.md](./docs/ENVIRONMENT.md#a-model-credential). + ### Self-hosting **Requirements:** Node.js 24+ diff --git a/docs/ENVIRONMENT.md b/docs/ENVIRONMENT.md index 3b72070..858dcc1 100644 --- a/docs/ENVIRONMENT.md +++ b/docs/ENVIRONMENT.md @@ -13,17 +13,27 @@ Get one at [browser-use.com](https://browser-use.com). ### A model credential -The agent's model (`anthropic/claude-opus-4.8`) routes through the -[Vercel AI Gateway](https://vercel.com/docs/ai-gateway). Provide **one** of: +The default model `anthropic/claude-opus-4.8` is served through the +[Vercel AI Gateway](https://vercel.com/docs/ai-gateway). Pick one path: + +**Option A — AI Gateway (the default).** Provide one of: - **Link a Vercel project** — the gateway authenticates via OIDC, no key to manage (easiest on Vercel; run `vercel link` locally). - **`AI_GATEWAY_API_KEY`** — a gateway key from [vercel.com/dashboard/ai/api-keys](https://vercel.com/dashboard/ai/api-keys). -To call a provider directly instead of the gateway, set that provider's key and use -a provider-authored model in `agent/agent.ts` (see -[CUSTOMIZATION.md](./CUSTOMIZATION.md#change-the-model)). +> ⚠️ **The AI Gateway needs paid credits.** A gateway account with no paid balance +> returns _"Free tier users do not have access to this model"_ at request time — the +> app deploys fine but can't browse until you +> [add credits](https://vercel.com/docs/ai-gateway/pricing). If you'd rather not use +> the gateway, use Option B. + +**Option B — call a provider directly (no gateway).** Set the provider's key (e.g. +`ANTHROPIC_API_KEY`) and use a provider-authored model in `agent/agent.ts` — a +one-line change shown in +[CUSTOMIZATION.md → Change the model](./CUSTOMIZATION.md#change-the-model). This skips +the gateway entirely, so no gateway credits are required. ## Example `.env.local`