Installation

Rivano ships three installable packages: the TypeScript SDK for programmatic access, the CLI for terminal-based operations, and the gateway for proxying LLM traffic.

SDK

Install @rivano/sdk into your project:

// npm
// npm install @rivano/sdk

// yarn
// yarn add @rivano/sdk

// pnpm
// pnpm add @rivano/sdk

import Rivano from '@rivano/sdk';

const rivano = new Rivano({ apiKey: 'rv_...' });

The SDK requires Node.js 18 or later. It ships with full TypeScript types — no @types package needed.

CLI

Install the CLI globally:

npm install -g @rivano/cli

Verify the installation:

rivano --version
# @rivano/cli 1.0.0

Log in with your API key:

rivano login
# Rivano API key: rv_...
# ✔ Logged in as [email protected]

CLI config file

The CLI stores credentials at ~/.rivano/config.json:

{
  "apiKey": "rv_...",
  "baseUrl": "https://api.rivano.ai"
}

You can edit this file directly or use rivano login to regenerate it. Run rivano logout to delete it.

Gateway

Install the gateway globally:

npm install -g @rivano/gateway

Verify the installation:

rivano-gateway --version
# @rivano/gateway 1.0.0

The gateway reads its configuration from a rivano.yaml file. Run rivano init in any directory to create one.

Environment variables

Both the CLI and SDK respect these environment variables, which take precedence over config files but are overridden by explicit flags or constructor options:

VariableDescriptionDefault
RIVANO_API_KEYYour Rivano API key
RIVANO_BASE_URLOverride the API base URLhttps://api.rivano.ai

Set them in your shell or .env file:

export RIVANO_API_KEY=rv_...
export RIVANO_BASE_URL=https://api.rivano.ai

SDK configuration options

The Rivano constructor accepts the following options:

OptionTypeDescriptionDefault
apiKeystringYour Rivano API keyRequired
baseUrlstringAPI base URLhttps://api.rivano.ai
timeoutnumberRequest timeout in milliseconds30000
retriesnumberNumber of retry attempts on transient errors2
import Rivano from '@rivano/sdk';

const rivano = new Rivano({
  apiKey: process.env.RIVANO_API_KEY!,
  baseUrl: 'https://api.rivano.ai',
  timeout: 10000,
  retries: 3,
});

Config priority

For the CLI, configuration is resolved in this order (highest to lowest priority):

  1. Flags--api-key rv_... passed directly to a command
  2. Environment variablesRIVANO_API_KEY, RIVANO_BASE_URL
  3. Config file~/.rivano/config.json

Never commit your API key to source control. Use environment variables in CI/CD environments and secret managers in production.

Next steps