Skip to content

Your first request.
Your next idea.

From a workspace to a working model call. A practical starting point for building with Nirmos, with the detailed docs one click away.

Your serverKeep your key here
NirmosRoute + observe
MYour modelYour provider credentials

One request path. Your application stays in control.

1

Create a workspace.

Nirmos brings Gateway, Prompts, Knowledge, Evaluations, and Memory into one platform. Create an account and choose the organization your application will use.

Create your account
2

Connect a provider.

Add your provider credentials in your authenticated workspace, then choose an enabled chat model. Nirmos uses your organization’s configured credentials to call the provider.

Your provider. Your model.

A catalog entry alone doesn’t grant upstream model access. Your credentials need permission and available quota.

Provider configuration
3

Create a server API key.

In the dashboard, create a personal key for your scripts or a service key for your application with gateway execution permission. Bind the key to the organization you configured. Store its one-time secret in your server environment as NIRMOS_API_KEY.

Keep secrets on your server. Never put an API key in browser code, public environment variables, or source control.

API key lifecycle
4

Make your first request.

Use a trusted Node.js application and install the SDK. This example comes directly from the current SDK quickstart. It checks authentication and makes a gateway call using the model you select. Replace the provider and model placeholders before running it.

Install the SDK
pnpm add @nirmos/sdk
quickstart.mjs
import { Nirmos, NirmosError } from "@nirmos/sdk";

    const key = process.env.NIRMOS_API_KEY;
    if (!key) throw new Error("Missing NIRMOS_API_KEY");
    const nirmos = new Nirmos({
      auth: { type: "api-key", key },
      apiBaseUrl: process.env.NIRMOS_API_URL,
      runtimeBaseUrl: process.env.NIRMOS_RUNTIME_URL,
    });

    try {
      const context = await nirmos.auth.getContext();
      console.log("Organization:", context.organizationId);

      const completion = await nirmos.gateway.chat.create({
        model: "<provider-slug>/<model-slug>",
        messages: [{ role: "user", content: "Explain an AI gateway in two sentences." }],
        maxOutputTokens: 200,
      });
      console.log(completion.outputText);
      console.log("Request:", completion.metadata.requestId);
    } catch (error) {
      if (error instanceof NirmosError) {
        console.error({ code: error.code, status: error.status, requestId: error.requestId });
      }
      throw error;
    }
Ready to run?

Set NIRMOS_API_KEY in your server environment, replace <provider-slug>/<model-slug>, save the example as quickstart.mjs, then run node quickstart.mjs. Self-hosting? Configure the API and runtime origins as described in the quickstart.

Understand chat completions
5

Make the request yours.

Start with a model call. Add the instructions, evidence, feedback, and context your application needs.

Go a little deeper.

Practical reading for the requests that come next.

Explore the SDK docs