Every gateway asks you to read docs to change one line. We built a wizard that makes the change for you:
npx @inferall/cli init
That's the whole integration. Here's what it actually does — and what it deliberately doesn't.
What init does
- Detects your project. Node or Python, and whether you already use the
openai,@anthropic-ai/sdk, or Google Gemini SDKs. - Sets up your key. Writes
INFERALL_API_KEYto.env, adds a placeholder to.env.example, and makes sure.envis gitignored — the hygiene step most quickstarts skip. - Migrates your code. Simple client constructors are rewritten
deterministically — the OpenAI SDK gets
baseURL: "https://api.inferall.ai/v1", the Anthropic SDK gets the host root (it appends/v1/messagesitself). Anything ambiguous gets an AI-suggested patch that you review before it's applied. The patches are generated by InferAll's own $0 NVIDIA NIM models — the wizard runs on the product it installs. - Verifies with a live call. If your account isn't activated yet, it says exactly that — the $5 starter pack becomes spendable balance, not a fee — with the link, instead of failing with an opaque 402.
What it deliberately doesn't do
Using the Google Gemini SDK? That SDK speaks its own wire protocol, so no base
URL can re-point it. Instead of a risky cross-protocol rewrite, the wizard
prints the exact OpenAI-compat snippet (model: "gemini/gemini-2.5-flash")
and leaves your code alone. Honest guidance beats broken automation.
doctor — keep it wired
npx @inferall/cli doctor
Checks key presence and validity, .env gitignore hygiene, whether every
client call site actually points at the gateway, and your live account state.
Exit code 0 only when everything passes — so it drops straight into CI:
- name: Check InferAll wiring
run: npx @inferall/cli doctor
env:
INFERALL_API_KEY: ${{ secrets.INFERALL_API_KEY }}
models — see what you get
npx @inferall/cli models --free
The live catalog with real prices from the gateway — 120+ models, 80+ of them at $0 input/output on NVIDIA NIM within free-plan daily limits.
Zero runtime dependencies, Node 18+, and the whole thing is one file. Get a
key at inferall.ai/keys and run
npx @inferall/cli init in your project.