Browse documentation

Start here

Connect an AI model API key safely

Get an API key from Anthropic, OpenAI, OpenRouter, Google Gemini or another supported provider and connect it to the Basis agent.

8 min readUpdated 2026-08-224 sections

Choose a provider and a tool-capable model

Basis is bring-your-own-key. The platform itself is free; your selected AI provider bills model usage directly. OpenRouter is convenient when you want one key for many model families. Direct Anthropic, OpenAI and Gemini keys are suitable when you already use those providers.

ProviderBest fitKey portal
AnthropicStrong multi-step tool use and visionconsole.anthropic.com
OpenAIReasoning, tool use and visionplatform.openai.com
OpenRouterOne key across many vendors with reported request costopenrouter.ai
Google GeminiLarge context and fast modelsaistudio.google.com
LocalNo provider bill; model runs on your computerOllama or LM Studio

Connect the key in Basis

  1. 01

    Open Assistant

    Open the Assistant panel from the right dock or the mobile AI button.

  2. 02

    Select the provider

    Choose the company that issued the key. A key works only with its matching provider.

  3. 03

    Paste the key

    Paste it into the masked API key field. Basis checks obvious copy errors but the provider performs final authentication.

  4. 04

    Choose storage

    Leave Remember off to keep the key only for the current browser session. Turn it on only on a trusted personal device.

  5. 05

    Select a model

    Choose a model marked for tool use. Tool-less models cannot read market data and are blocked from acting as an agent.

Where the key goes — and where it never goes

By default, the key lives in session storage and disappears when the tab closes. Remembering it moves it to local browser storage. Requests travel from your browser directly to the provider you selected; the key is not proxied through Basis servers, synchronized to the Basis database, written into conversation history or passed to sandbox code.

  • Provider errors are redacted before they reach the interface.
  • Chart screenshots exclude account panels and keys.
  • Custom model endpoints are limited to your machine or local network.
  • Clearing the provider key removes both session and remembered copies.

Important

Any browser extension or malicious script with access to the site can be a risk to browser-stored secrets. Use a trusted browser profile, keep extensions minimal and do not remember keys on shared devices.

Fix common connection errors

SymptomLikely causeFix
Unauthorized / 401Wrong provider, revoked key or copy errorRecreate the key and verify the provider selector
Insufficient credits / quotaProvider account has no usable balanceAdd provider credit or select another key
Model cannot use toolsSelected model does not support function callingPick a tool-capable model
Browser network errorProvider CORS, extension or local endpoint configurationDisable interfering extensions; for Ollama set OLLAMA_ORIGINS=*
Very high costFrontier model plus many agent roundsUse a cheaper tool-capable model and narrow the task