Terminal or Vercel runtime logs
AI_APICallError: 401 invalid_api_key — Incorrect or revoked Tokentide API key
- What it means
- Tokentide rejected `TOKENTIDE_API_KEY` because the key is incomplete, revoked, or missing its `tt_live_` prefix.
- Likely causes
- The key pasted into
.env.localor Vercel was cut off or includes extra quotes/spaces. - The key was revoked on tokentide.app/app/keys and the environment still holds the old one.
- The key pasted into
- Prevention
- Save new
tt_live_keys in your password manager when created, and test with the read-onlytokentide.py checkscript.
Copy for your agent
AI calls return `401 invalid_api_key`. Ensure our AI helper falls back to the Vercel AI Gateway and logs an alert on 401, and run the read-only Tokentide check after I update my key in `.env.local` and Vercel.
Was this page helpful?