Laptop with code on a bright desk, coffee mug and headphones
Developers

CLI and MCP: setup Scalattice from the terminal

Get an API key without clicking through the dashboard. Optionally let Cursor or Claude Desktop check credits and models for you.

Most people still discover inference APIs by opening a browser, copying a key, and pasting env vars. That works. It is also a bad fit for coding agents and anyone who lives in a terminal.

Today we are shipping the open-source Scalattice CLI (scalattice-cli on npm) plus an optional MCP mode so AI apps can call a few read-only tools after you are set up.

What you get

  • CLI: magic-code login, developer profile, create an slt_ API key, print OPENAI_BASE_URL / OPENAI_API_KEY, check wallet and model grants.
  • MCP (optional): the same binary, run as scalattice mcp, exposes scalattice_credits, scalattice_models, and scalattice_env to Cursor or Claude Desktop.
  • Same API: inference stays OpenAI-compatible at https://api.scalattice.cloud/v1. You can also call GET /v1/credits with your key.

MCP does not create accounts. The CLI does. Install once, then wire MCP if you want the agent to ask “what is my balance?” without pasting curls.

Install

curl -fsSL https://scalattice.cloud/install/cli | sh
# or
npm install -g scalattice-cli

Both paths install the same package. Command name: scalattice.

Setup

scalattice setup
eval "$(scalattice init)"
scalattice credits

setup emails a magic code, marks the account as a developer if needed, creates an API key, and prints the exports. init is safe to re-run whenever you open a new shell.

Optional: MCP in Cursor

After setup, add:

{
  "mcpServers": {
    "scalattice": {
      "command": "scalattice",
      "args": ["mcp"]
    }
  }
}

The agent can then list live catalog models (with pricing) and read your prepaid balance plus any model-specific grants.

Links