Skip to main content
There is no elding login browser flow in production. Provide the token and set through two environment variables. The SDK reads them automatically, so your code does not change.
ELDING_REFRESH_TOKEN=eld_rt_...   # generate it in Dashboard → API Keys
ELDING_SET_ID=...                 # the ID of the set to load
Keep these exact names. The SDK detects them automatically, with no options required for configure(), secret(), or client(). The same code works in development and production.

An HTTP API key with configure()

Use exactly the same code as in development:
import OpenAI from "openai";
import { configure } from "@elding/sdk";

const openai = new OpenAI(
  await configure("OPENAI_API_KEY", "https://api.openai.com")
);

A secret with secret()

import { secret } from "@elding/sdk";

const dbUrl = await secret("DATABASE_URL");
const db = new Pool({ connectionString: dbUrl });

Multiple secrets with client()

import { client } from "@elding/sdk";

const elding = await client();

const dbUrl = elding.secret("DATABASE_URL");
const jwt = elding.secret("JWT_SECRET");

Where to find the two values

VariableWhere to find it
ELDING_REFRESH_TOKENDashboard → API Keys → New key. It is displayed only once.
ELDING_SET_IDOpen the set in the dashboard. Its ID appears in the URL.
Your secrets remain in the vault and are retrieved at runtime through one token. Rotation, revocation, and audit logs remain centralized.