Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .sdk-source.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"schemaVersion": 1,
"sourceCommit": "60be0cdcc0ccb8cbc28c3840c0a3980370b41f5b",
"contract": "contracts/2026.07/public-sdk-contract.json",
"sourceCommit": "bd9e63c32f78a4a65929cece9ed128e4e2a67ae6",
"contract": "contracts/2026.11/public-sdk-contract.json",
"packages": [
"typescript"
]
Expand Down
11 changes: 5 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
[![npm](https://img.shields.io/npm/v/@ignitionai/sdk.svg)](https://www.npmjs.com/package/@ignitionai/sdk)
[![license](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)

Official open-source SDKs and signed public API contracts for IgnitionRAG deployments.
Official open-source TypeScript SDK and signed public API contracts for IgnitionRAG deployments.

IgnitionRAG itself is licensed software. This repository contains client libraries only; it does not contain the product server, administration CLI, widgets, deployment tooling, customer configuration, or private MCP implementations.

Expand All @@ -15,9 +15,10 @@ bun add @ignitionai/sdk@next
# or npm install @ignitionai/sdk@next
```

The current public release is `0.3.0-rc.3` under the npm `next` tag. The
unqualified install command remains on the stable `0.2.x` line until `0.3.0` is
promoted to `latest`.
This source tree prepares `1.0.0` for public contract `2026.11`; publication
requires the reviewed release workflow. `ingest.file` is a breaking change from
`0.3.0-rc.4`. The unqualified install command remains on the stable `0.2.x` line
until `1.0.0` is promoted to `latest`.

```ts
import { IgnitionAI } from "@ignitionai/sdk";
Expand All @@ -39,8 +40,6 @@ See the [TypeScript SDK guide](./typescript/README.md) for server, browser, stre
- `examples/` — minimal runtime smoke examples.
- `docs/` — compatibility and release documentation.

The Python SDK may be added later. It is not part of the current support commitment.

## Security

API keys are server-side credentials. Browser applications must use `@ignitionai/sdk/browser` with a delegated token provider. See [SECURITY.md](./SECURITY.md) to report a vulnerability privately.
Expand Down
1 change: 1 addition & 0 deletions contracts/2026.11/public-sdk-contract.json

Large diffs are not rendered by default.

52 changes: 50 additions & 2 deletions docs/compatibility.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,58 @@
# Compatibility policy

IgnitionRAG exposes a signed public contract through `/api/meta`. The SDK verifies the contract version and digest before relying on deployment capabilities.
IgnitionRAG exposes a contract identity through `/api/meta`. Signed archives are
verified separately before SDK generation and public synchronization. Metadata
identifies a deployment; it is not itself a signed archive.

- The current SDK supports the current public contract and the immediately previous contract version.
- A changed digest under an unchanged version is rejected as a protocol error.
- A changed digest under the current version is rejected as a protocol error.
- The previous revision is admitted by version and advertised capabilities; its
digest is not compared with the current revision digest.
- Missing or disabled capabilities are reported explicitly; they are not silently redirected to another service.
- Contract artifacts are verified with the public keys in `contracts/trusted-keys.json`.

Upgrade the deployment or SDK when the compatibility check reports an unsupported contract version.

## Live SDK diagnostic

From `typescript/`, run `bun run test:live` with `IGNITION_BASE_URL` and
`IGNITION_API_KEY` supplied through the environment. Keep credentials out of
shell history and committed files. The command uses the checked-out SDK and
only sends GET requests, with retries disabled and a 15-second request timeout.

It checks deployment compatibility, collection details and documents,
evaluation details, agents, skills, research status, workflows and execution
details. Output contains check labels and outcomes, never resource contents,
identifiers or API credentials. Any failed compatibility, HTTP or response
shape check produces a nonzero exit status, while the remaining checks continue.
Missing fixtures and unavailable insights are reported as `NOT PROVEN`.

Run again with a group-bound key for group coverage. To probe collection
isolation, set `IGNITION_FORBIDDEN_COLLECTION_IDS` to comma-separated IDs of
known private collections in the other space. Only 403 or 404 counts as a
successful denial. Shared/public collections are unsuitable fixtures. Without
these fixtures, isolation is explicitly `NOT PROVEN`; successful resource
reads alone do not prove tenancy isolation.

A zero exit status covers only the checks exercised. This diagnostic does not
validate chat/streaming, ingestion, writes, workflow execution or cancellation.
Contract identities must still come from the official signed synchronization;
do not change the accepted version or digest merely to make a live check pass.

## Migration to 2026.11

The prepared TypeScript candidate is `1.0.0`. Its current contract is
`2026.11`; `2026.10` and `2026.09` remain accepted older revisions. `ingest.file` now returns
`AsyncIngestResult` — wait with `getJob` / `streamJob`. The sync HTTP route
`POST /api/ingest/file` is license-only. Deployment-specific crawler limits
remain enforced, but no longer change the versioned schema identity.
Upgrade the SDK before deploying `2026.11`. This source preparation is neither
a signed release nor an npm publication. The official workflow must sign and
verify the archive, regenerate the TypeScript identity and wire types and pass public synchronization
before release. Personal evaluation reads also require the server workspace
scope correction; upgrading the client alone does not fix the deployed 400.

Revision `2026.11` regenerates the integrated public schemas, including optional
ingestion chunking configuration. The current digest remains strict; older
revision admission does not assert equivalent digests or qualify every operation.
No deprecated revision is removed and no existing signed archive is rewritten.
91 changes: 91 additions & 0 deletions docs/typescript-contract-2026-10.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
# TypeScript contract 2026.10 operation mapping

The canonical allow-list contains 65 operations. The table maps each operation
to the ergonomic client. Inputs and wire responses are generated in
`src/generated/public-api.ts`; the package root exposes ergonomic types.
This inventory is not runtime proof for every operation. Existing focused tests
cover the resource families, multipart transport, asynchronous jobs, cancellation,
managed admission, streaming and errors; live coverage must be assessed separately.

Legacy synchronous ingestion, discovery/crawling, skill mutations and agent SSE
remain deployment-dependent. Ordinary SaaS users must use durably admitted file
ingestion and managed agent execution. Availability on licensed deployments does
not imply SaaS availability. No private widgets/MCP routes enter this contract.

| Operation | HTTP | Client method |
| --- | --- | --- |
| `chat.send` | `POST /api/chat` | `chat.send` |
| `chat.stream` | `POST /api/chat/stream` | `chat.stream` |
| `chat.streamProgressive` | `POST /api/chat/stream/progressive` | `chat.streamProgressive` |
| `collections.listPublic` | `GET /api/public-collections` | `collections.listPublic` |
| `collections.getPublic` | `GET /api/public-collections/{slug}` | `collections.getPublic` |
| `collections.list` | `GET /api/collections` | `collections.list` |
| `collections.create` | `POST /api/collections` | `collections.create` |
| `collections.get` | `GET /api/collections/:id` | `collections.get` |
| `collections.update` | `PATCH /api/collections/:id` | `collections.update` |
| `collections.delete` | `DELETE /api/collections/:id` | `collections.delete` |
| `collections.insights` | `GET /api/collections/:id/insights` | `collections.insights` |
| `collections.regenerateInsights` | `POST /api/collections/:id/insights/regenerate` | `collections.regenerateInsights` |
| `collections.chunks` | `GET /api/collections/:id/chunks` | `collections.chunks` |
| `collections.search` | `GET /api/collections/:id/search` | `collections.search` |
| `collections.stats` | `GET /api/collections/:id/stats` | `collections.stats` |
| `collections.qualityReport` | `GET /api/collections/:id/quality-report` | `collections.qualityReport` |
| `collections.documents` | `GET /api/collections/:id/documents` | `collections.documents` |
| `collections.setRagConfig` | `PUT /api/collections/:collectionId/rag-config` | `collections.applyRagPreset` |
| `ingestion.url` | `POST /api/ingest/url` | `ingest.url` |
| `ingestion.document` | `POST /api/ingest/document` | `ingest.document` |
| `ingestion.file` | `POST /api/ingest/file/async` | `ingest.file` (alias of `ingest.fileAsync`; SaaS rejects sync `/ingest/file`) |
| `ingestion.crawl` | `POST /api/ingest/crawl` | `ingest.crawl` |
| `ingestion.dataset` | `POST /api/ingest/dataset` | `ingest.dataset` |
| `ingestion.fileAsync` | `POST /api/ingest/file/async` | `ingest.fileAsync` |
| `ingestion.crawlAsync` | `POST /api/ingest/crawl/async` | `ingest.crawlAsync` |
| `ingestion.datasetAsync` | `POST /api/ingest/dataset/async` | `ingest.datasetAsync` |
| `ingestion.discover` | `POST /api/ingest/discover` | `ingest.discover` |
| `ingestion.crawlSelectedAsync` | `POST /api/ingest/crawl-selected/async` | `ingest.crawlSelectedAsync` |
| `ingestion.getJob` | `GET /api/ingest/jobs/{jobId}` | `ingest.getJob` |
| `ingestion.listJobs` | `GET /api/ingest/jobs` | `ingest.listJobs` |
| `ingestion.streamJob` | `GET /api/ingest/jobs/{jobId}/stream` | `ingest.streamJob` |
| `ingestion.cancelJob` | `POST /api/ingest/jobs/{jobId}/cancel` | `ingest.cancelJob` |
| `agents.listSkills` | `GET /api/agents/skills` | `agents.listSkills` |
| `agents.createSkill` | `POST /api/agents/skills` | `agents.createSkill` |
| `agents.updateSkill` | `PATCH /api/agents/skills/:id` | `agents.updateSkill` |
| `agents.deleteSkill` | `DELETE /api/agents/skills/:id` | `agents.deleteSkill` |
| `agents.list` | `GET /api/agents` | `agents.list` |
| `agents.create` | `POST /api/agents` | `agents.create` |
| `agents.get` | `GET /api/agents/:id` | `agents.get` |
| `agents.update` | `PATCH /api/agents/:id` | `agents.update` |
| `agents.delete` | `DELETE /api/agents/:id` | `agents.delete` |
| `agents.generate` | `POST /api/agents/generate` | `agents.generate` |
| `agents.chatStream` | `POST /api/agents/:id/chat/stream` | `agentChat.stream` |
| `deepResearch.cancel` | `POST /api/agents/:agentId/chat/cancel-deep` | `deepResearch.cancel` |
| `deepResearch.status` | `GET /api/agents/:agentId/chat/deep-status` | `deepResearch.status` |
| `deepResearch.stream` | `GET /api/agents/:agentId/chat/deep-stream` | `deepResearch.stream` |
| `workflows.list` | `GET /api/workflows` | `workflows.list` |
| `workflows.create` | `POST /api/workflows` | `workflows.create` |
| `workflows.get` | `GET /api/workflows/:id` | `workflows.get` |
| `workflows.update` | `PATCH /api/workflows/:id` | `workflows.update` |
| `workflows.delete` | `DELETE /api/workflows/:id` | `workflows.delete` |
| `workflows.validate` | `POST /api/workflows/:id/validate` | `workflows.validate` |
| `workflows.execute` | `POST /api/workflows/:id/execute` | `workflows.execute` |
| `workflows.listExecutions` | `GET /api/workflows/:id/executions` | `workflows.listExecutions` |
| `workflows.getExecution` | `GET /api/workflows/executions/:executionId` | `workflows.getExecution` |
| `workflows.cancelExecution` | `DELETE /api/workflows/executions/:executionId` | `workflows.cancelExecution` |
| `evaluations.create` | `POST /api/collections/:id/evaluations` | `evaluations.create` |
| `evaluations.list` | `GET /api/collections/:id/evaluations` | `evaluations.list` |
| `evaluations.get` | `GET /api/evaluations/:evaluationId` | `evaluations.get` |
| `ragExperiments.runAbTest` | `POST /api/collections/:collectionId/rag-config/test` | `ragAbTests.run` |
| `observability.listTraces` | `GET /api/traces` | `traces.list` |
| `observability.getTrace` | `GET /api/traces/{id}` | `traces.get` |
| `observability.getTraceMetrics` | `GET /api/traces/metrics` | `traces.metrics` |
| `observability.exportTraces` | `GET /api/traces/export` | `traces.export` |
| `feedback.submit` | `POST /api/feedback` | `feedback.submit` |

`collections.applyRagPreset` accepts a preset or its inline retrieval config;
it deliberately does not expose arbitrary platform provider/model configuration.
`workflows.cancelExecution` returns `{ cancelled: boolean }`. It is a remote
cancellation request, distinct from aborting an HTTP request. SaaS durable
workflow/agent execution has separate managed helpers and admission rules.

Full per-operation input/result conformance and both-space live completion
remain release gates. Empty lists, accepted submissions and skipped scenarios
do not establish completed execution or successful ingestion.
2 changes: 1 addition & 1 deletion scripts/validate-release.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ const packageJson = JSON.parse(await readFile("typescript/package.json", "utf8")
if (tag !== `v${packageJson.version}`) {
throw new Error(`Tag ${tag} does not match package version ${packageJson.version}`);
}
process.argv.push("--built");
if (!process.argv.includes("--metadata-only")) process.argv.push("--built");
await import("./validate-public-surface.ts");
console.log(`Validated release ${tag}`);
47 changes: 47 additions & 0 deletions typescript/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# Changelog

## 1.0.0

### Fixed

- Collection creation exposes the canonical `embeddingConfigId` input so callers
can select an owned configuration without changing the workspace default.
- File ingestion forwards the canonical `ocrMode` selection, and workflow
creation accepts an explicit `isActive` flag.
- Licensed agent creation and updates expose the canonical `llmConfigId`,
`fallbackLlmConfigId`, and `runtimeKind: "byok_api"` inputs in TypeScript.
Nullable provider selections remain supported; managed agent inputs stay restricted.

### Breaking

- `ingest.file` now calls `POST /api/ingest/file/async` and returns `AsyncIngestResult`
(`success`, `jobId`, `message`) instead of a completed `IngestResult`.
`ingest.fileAsync` is unchanged.
- `ingest.url` now calls `POST /api/ingest/url/async` (single page) and returns
`AsyncIngestResult` (`success`, `jobId`, `message`) instead of a completed
`IngestResult` (`chunksCount`, `documentId`, …). Callers that read
`chunksCount` from `ingest.url` must wait on `getJob` / `streamJob`.
`ingest.document` also returns `AsyncIngestResult` (raw text uploaded through
`/file/async`). SaaS members no longer hit the closed synchronous routes.

### Migration

Wait for the durable job instead of treating `ingest.file` or `ingest.url` as a
synchronous ingest:

```ts
const started = await client.ingest.file({ collectionId, file });
const job = await client.ingest.getJob(started.jobId);
// or: for await (const event of client.ingest.streamJob(started.jobId)) { ... }

const fromUrl = await client.ingest.url({ collectionId, url });
await client.ingest.getJob(fromUrl.jobId);
```

`POST /api/ingest/file` and `POST /api/ingest/url` remain published for
**license** deployments only. SaaS rejects those sync routes; the SDK uses the
metered async paths (`ingest.file`, `ingest.url`, `ingest.document`).
Synchronous `ingest.crawl`, `ingest.dataset`, and `ingest.discover` stay on the
license routes and raise `OfferingUnavailableError` when SaaS returns 503
`AI_TEMPORARILY_UNAVAILABLE`. Members should call `ingest.crawlAsync` or
`ingest.datasetAsync` instead.
Loading
Loading