Skip to main content
Use @brello/sdk in a server-side Node.js application. You need Node.js 18 or newer, a Brello project ingestion key, and credentials for your AI provider. Follow your provider SDK’s Node.js requirements as well.

Install the SDK

Install the Brello SDK in your application directory:
To test from source, run pnpm install and pnpm pack in the SDK’s typescript directory. From your application directory, run npm install with the tarball path printed by pnpm pack. Keep your existing provider SDK dependency. For Google AI Studio or Vertex AI, install @google/genai if your application doesn’t already use it.

Set your Brello environment

The SDK uses https://api.brello.app/v1 by default. If you run Brello yourself, set your self-hosted API URL. Configure your provider credentials separately in your application.

Wrap your client

Choose the client you already use. Create one Brello instance per application runtime so calls share a buffer.
Keep your existing provider calls. For setup and request examples, see the OpenAI, Anthropic, or Google AI Studio and Vertex AI guide.

Verify the connection

Complete a provider call or finish consuming its stream. In Brello, open your project’s Settings and look for Connected under SDK activity. That status appears after the worker stores an event. For a short-lived test script, call await brello.flush() before it exits. If the status stays pending, check your project key and set BRELLO_DEBUG=1 to inspect event delivery. See configuration and delivery for context, retries, and serverless examples.