> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nika.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# SDK method index

> Every method of @supernovae-st/nika 0.124.1, what it returns, and which transport serves it.

> [!NOTE]
>
> These pages describe the published `@supernovae-st/nika@0.124.1`
> [SDK release](https://github.com/supernovae-st/nika-client/tree/v0.124.1) and its matching
> [bundled engine](https://github.com/supernovae-st/nika/releases/tag/v0.124.1). A newer engine
> release or SDK main commit does not change an installed package. Use Node.js
> 22 or newer, on macOS (arm64, x64) or Linux with glibc (x64, arm64); no
> global Nika installation is required for local mode.

| Method | Returns | Local | HTTP |
| - | - | :-: | :-: |
| `check(workflow, options?)` | `Promise<NikaCheckResult>` | yes | yes |
| `compile(request, options?)` | `Promise<NikaCompileOutcome>` | yes | yes ([Compile](https://docs.nika.sh/sdk/local/compile.md)) |
| `run(workflow, options?)` | `Promise<NikaRun>` | yes | yes |
| `run.events(options?)` | `AsyncIterable<NikaRunEvent>` | yes | yes |
| `run.result()` | `Promise<NikaRunResult>` | yes | yes |
| `run.cancel()` | `Promise<NikaCancelResult>` | yes | yes |
| `run.status()` | `Promise<NikaRunStatus>` | no | yes |
| `run.artifacts(options?)` | `Promise<NikaArtifactManifest>` | no | yes: a settled job's manifest ([Outputs and artifacts](https://docs.nika.sh/sdk/remote/artifacts.md)) |
| `run.downloadArtifact(artifact, options?)` | `Promise<NikaArtifactDownload>` | no | yes: a stream that closes once its bytes are proven |
| `run.readArtifact(artifact, options?)` | `Promise<Uint8Array>` | no | yes: the proven bytes, up to `maxBytes` (16 MiB by default) |
| `traceVerify(receipt, options?)` | `Promise<NikaTraceVerifyResult>` | yes | yes: the server's verdict on its journal (`ok`, `sealed`…; `unavailable` when it holds none) |
| `attachRun(id, options?)` | `Promise<NikaRun>` | no | yes |
| `listWorkflows()` | `Promise<readonly string[]>` | no | yes |
| `workflow(name)` | `Promise<NikaWorkflowMetadata>` | no | yes |
| `schedule(workflow, options)` | `Promise<NikaScheduleApplyResult>` | no | yes ([Schedules](https://docs.nika.sh/sdk/remote/schedules.md)) |
| `scheduleStatus(id)` | `Promise<NikaScheduleStatus>` | no | yes |

`run.result()` resolves once with how the run ended, including a pause.
`check()` returns the engine's local findings report, or the server's typed
acknowledgement or refusal for a served name. `run.cancel()` may acknowledge a
pending request; it never replaces `run.result()`. Methods that need a server
throw `NikaCompatibilityError` on the local transport. The three artifact
methods reject the same way, before any request, on a server whose `/health`
does not list `artifacts`; `attachRun()` handles have them too, and `artifact`
is a manifest `name` or the entry itself. The run-handle methods
are bound to their run; only the deprecated facade wrappers
(`nika.events(run)`, `nika.cancel(run)`, `nika.status(run)`) check that a run
belongs to this client, with `NikaRunOwnershipError`.

`compile()` asks the engine for a candidate workflow and runs nothing:
`ready`, `incomplete` and `refused` all resolve as data. A ready `candidate`
is ordinary `.nika` source; write it to a file and `run(path)` admits it
again. Over HTTP it calls `POST /v1/compile` when the server's `/health`
lists `compile`. A provider round is opt-in: `cognition: 'explicitProvider'`
on a server that lists `compileNativeV2`, or `authoringModel` on a local
engine. `nextCompileRequest(request, outcome, answers)` builds the next round
from the outcome's questions, and `isNikaCompileHeld(outcome)` tells a
candidate the verifier held, a preview never to run. The package's
[compile guide](https://github.com/supernovae-st/nika-client/blob/v0.124.1/docs/compile.md)
covers both doors.

> [accordion] Compatibility aliases
>
> `nika.events(run)`, `nika.cancel(run)`, `nika.status(run)` and `run.done`
> remain as deprecated aliases through the compatibility window. `run.done`
> is the same promise as `run.result()`; the facade wrappers forward to the
> handle methods unchanged.

The facade intentionally has no version, plan, buffered-run, golden-test,
health, webhook or environment-constructor convenience methods. A run's
artifacts are read through its handle, never by a URL your code builds.

> [card] [Configuration](https://docs.nika.sh/sdk/reference/configuration.md)
>
> Constructor and operation options.

> [card] [Types](https://docs.nika.sh/sdk/reference/types.md)
>
> Expand the public projections.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.