API reference

Programmatic access to every model, with the same privacy posture as the app.
Your API key
0:37
A key created on camera, and the two ways to send it.

What the API is

The Local Keep AI API gives your own software the same inference the app uses — every cloud model in the catalogue, with the same privacy posture: requests are anonymized before they reach any upstream provider, and your prompts are never used for training. Authentication is by API key, and usage is pay-as-you-go from a prepaid credit balance. The API is its own plan: it does not draw on a personal subscription's allowance, and a personal subscription is not required.

Keys

Create keys on the API page (localkeep.ai/developers). A key looks like lk_live_… and is shown once, at creation — we store only its SHA-256 digest, so it can never be recovered, only revoked and replaced. Keys are inference-only by design: a key cannot create keys, see the account's other keys, change billing, or touch account settings, so a leaked key's blast radius is bounded to spending the credit balance — and revocation is immediate.
Treat keys like passwords: environment variables, never source code.
One key per service, so one leak revokes one integration.
Up to 20 active keys per account.
Revoked keys fail with a distinct 'revoked' error, so theft is visible in your logs.

Authentication

Send the key in the Authorization header as a bearer token, or in X-API-Key — both are equivalent:
Authorization: Bearer lk_live_your_key_here
X-API-Key: lk_live_your_key_here

Chat completions

POST https://localkeep.ai/chat with a JSON body. `messages` is the OpenAI-style array of {role, content}; `model_id` is any id from the model catalogue (GET https://localkeep.ai/catalog/all lists them, with per-model capability flags).
curl https://localkeep.ai/chat -H "X-API-Key: $LK_API_KEY" -H "Content-Type: application/json" -d '{"model_id": "cloud:qwen3-coder", "messages": [{"role": "user", "content": "Write a haiku about local AI."}]}'

Models

Every cloud model the platform serves is available through the API under the same ids the app shows — the Llama, Gemma, Qwen, Mistral, Phi and DeepSeek families and the rest of the 1,000+ catalogue. Requests are anonymized before any upstream provider sees them: identifiers stripped, emails and phone numbers scrubbed, and the provider receives a request not linked to a person or a key.

Pricing

$5.00 per 1,000,000 output tokens, billed from a prepaid credit balance. Credits are sold in packs of $10, $25, $100 and $500 from the API page, never expire, and the balance gates before a request is served — the API cannot run up a surprise bill. When the balance is empty the API answers 402 with error text beginning API_CREDIT_EXHAUSTED.

Errors

401 — the key is missing, malformed, unknown, or revoked.
402 API_CREDIT_EXHAUSTED — the prepaid balance is empty; buy credits on the API page.
403 — the key tried something keys cannot do (key management, billing, account changes).
429 — provider capacity is saturated; retry with backoff.

Security model, stated plainly

Keys are 256-bit random secrets; the server stores a one-way digest only.
Key management requires a signed-in dashboard session — never a key.
Enabling two-factor on your account never breaks API integrations: the key itself is the possession factor on this rail.
Every key shows its last-used time on the API page, so a dormant compromised key is findable.
Last updated: 25 August 2026

All documentation

Installation
Install the CLI on macOS, Linux or Windows, and sign in.
Setup, start to finish
The whole path on one page: install, sign in, pick local or hosted, get an answer.
Connecting accounts
One account everywhere, registering devices for the SMS bridge, and OAuth integrations.
Models
Pull open-weight models, switch between them, and run fully local.
Using models on every client
What runs locally in a terminal, a browser tab, a phone and the desktop app.
Commands
Every terminal command and every slash command, each with its own page.
Editor integrations
VS Code, Cursor, JetBrains, Neovim, Sublime, Zed, Godot, Unity, gh and git hooks.
The SMS bridge
Send a task to your own machine from your phone, and get the answer back.
The apps
One React Native codebase behind iPhone, Android, web and desktop — and how to run it.
Automation Studio
Idea to production: flows, per-step models, your machines or ours, live editing.
Enterprise seats
Licensed team seats under one owner account — invites, billing, and how seats resolve.
Notifications
Four channels, all opt-in, how to change them, and the limits on re-engagement.
Privacy
What leaves your machine, what never does, and how anonymisation works.
Troubleshooting
When a model will not load, a command hangs, or the CLI cannot be found.