Developer Manual

Quickstart

Install the SDK, give it an API key, and run an agent in three lines. The eClips Workforce API is JSON over HTTPS with one bearer key. The key carries your organization and its scopes, so there is no org header to send.

Install the SDK

The client is @eclips/sdk. It is fully typed and has no runtime dependencies. It works in Node.js 18+ and any runtime that has fetch.

bash
npm install @eclips/sdk
Note:The SDK is not on the public npm registry yet. Ask us for access. The REST API works without it.
Tip:The base URL defaults to https://api.eclips.tech. You never pass an organization id. The server works it out from your API key.

Get an API key

API keys begin with eck_live_. Create one in the dashboard under Settings → API Keys and choose the scopes it needs. The key is shown once. Copy it and store it as a secret, for example in ECLIPS_API_KEY.

Run an agent in three lines

runAndWait() starts an agent run and polls until it ends as completed, failed or pending_triage.

typescript
import { EClipsClient } from "@eclips/sdk";

const client = new EClipsClient({ apiKey: process.env.ECLIPS_API_KEY! });
const result = await client.runAndWait("rfq_generator", "Draft an RFQ for 500 laptops");

The same call, expanded with logging:

typescript
import { EClipsClient } from "@eclips/sdk";

// Your organization comes from the API key, so you never pass an org id.
const client = new EClipsClient({ apiKey: process.env.ECLIPS_API_KEY! });

// runAndWait starts the run and polls until it finishes.
const result = await client.runAndWait(
  "rfq_generator",
  "Draft an RFQ for 500 laptops, delivery to Amman within 30 days",
);

console.log(result.status);   // "completed", or "pending_triage" if a person must look
console.log(result.result);   // the agent's structured output

Prefer raw HTTP? The same request returns a run_id straight away, and the run carries on in the background.

bash
curl https://api.eclips.tech/v1/run \
  -H "Authorization: Bearer $ECLIPS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "agent_type": "rfq_generator", "task": "Draft an RFQ for 500 laptops" }'

End to end

Example · From install to result

  1. •

    Create a key

    Dashboard → Settings → API Keys → create a key with the agents:run and agents:read scopes. Copy the eck_live_… value.
  2. •

    Install and configure

    npm install @eclips/sdk, then export your key: export ECLIPS_API_KEY=eck_live_….
  3. •

    Run

    Call runAndWait(agentType, task). It resolves with the final { status, result, confidence_score }.
  4. •

    Go deeper

    Stream live status, register webhooks, or run up to 500 rows at once with batches.