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

# Run Terminal • AI Agent SDK

> RunTerminal: One authoritative way a run ended — a closed discriminated union.

# RunTerminal

> Defined in the [**Run Outcome**](../modules/run_outcome) module.

<Badge color="blue">AI Agent</Badge>

One authoritative way a run ended — a closed discriminated union.

`kind` is the collapsed terminal category; `source` records which
observer produced it (used to decide stickiness). `RunTerminal` is frozen
so a recorded outcome is immutable — refinement happens by producing a new
instance via :func:`merge_run_terminal`, never by mutation.

## Properties

<ResponseField name="kind" type="TerminalKind">
  No description available.
</ResponseField>

<ResponseField name="source" type="TerminalSource">
  No description available.
</ResponseField>

<ResponseField name="detail" type="Optional[str]">
  No description available.
</ResponseField>

<Accordion title="Internal & Generic Methods">
  * **from\_dict**: Rehydrate from a plain dict produced by :meth:`to_dict`.
  * **to\_dict**: Serialise to a plain dict (JSON/SQLite friendly, round-trippable).
</Accordion>

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/run_outcome.py#L371">
  `praisonaiagents/run_outcome.py` at line 371
</Card>
