# AIRunResult

class

Container returned by any per-root AI run. Wraps one [`AIRunSingleRootResult`](module_ai_aicore_model_airunsinglerootresult-AIRunSingleRootResult.md) (or feature-specific subclass) per root when the run completes successfully; on whole-run failures (transport / parse errors or abort) the `results` array stays empty and the outcome is described by `status` and `error`.

<a id="type-parameters">

## Type parameters

### `SubResultType: extends AIRunSingleRootResult`

<a id="properties">

## Properties

<a id="member-error">

### `error: Error | undefined`

The error that caused the whole run to fail. Undefined when the run completed successfully or was aborted.

When the failure originated in the AI service backend, its structured response (for example, an `issues` list describing which fields failed validation) is available under `error.data.backendData`.

#### Parameters

* `value: CKEditorError`

<a id="member-results">

### `results: Array<SubResultType>` _(readonly)_

<a id="member-status">

### `status: AIRunStatus`

Outcome of the whole run — driven explicitly by the runner. Per-root sub-results carry their own `status` / `error`; consult [`results`](#member-results) for per-root outcomes.

#### Parameters

* `value: AIRunStatus`

<a id="methods">

## Methods

<a id="function-constructor">

### `constructor( results )`

#### Type parameters

* `SubResultType: extends AIRunSingleRootResult`

#### Parameters

* `results: Array<SubResultType>`

  Defaults to `[]`

<a id="function-abort">

### `abort() → void`

Marks the run as aborted. Reflected via [`status`](#member-status). No-op when the run has already errored — a concrete error is more informative to the integrator than a subsequent abort.

#### Returns

* `void`

<a id="function-addResult">

### `addResult( results ) → void`

Appends one or more per-root sub-results to the multi.

#### Parameters

* `results: Array<SubResultType>`

#### Returns

* `void`

---

Full index of the CKEditor 5 API reference: [llms.txt](llms.txt)
