Skip to content
providerkit
GitHub

RunSnapshot

Defined in: agents/src/types.ts:1034

JSON-serializable execution journal. Contains private prompts, arguments and results; the host owns storage, access and retention. Never accept it as proof of permission, and never send it to a browser.

agentId: string;

Defined in: agents/src/types.ts:1037


attemptId: string;

Defined in: agents/src/types.ts:1040


compactions: CompactionExecution[];

Defined in: agents/src/types.ts:1060

Completed model-view cuts and any in-flight paid summary. Never session edits.


definition: RunDefinition;

Defined in: agents/src/types.ts:1043

Resolved once before the first checkpoint. Resume never reruns definition callbacks.


delegations: DelegationExecution[];

Defined in: agents/src/types.ts:1068


format: 3;

Defined in: agents/src/types.ts:1036


guards: GuardRecord[];

Defined in: agents/src/types.ts:1058

Guard checks are journaled before callbacks and before releasing their checked output.


history: AgentMessage[];

Defined in: agents/src/types.ts:1050

The conversation before the new turn, repaired once when the run starts. A tool image may give way to its media type under toolHistory. Never a system message.


optional historyHash?: string;

Defined in: agents/src/types.ts:1052

Original child history identity when later tool images can displace its bytes.


input: UserContent;

Defined in: agents/src/types.ts:1054

The new user turn.


inputs: RunInput[];

Defined in: agents/src/types.ts:1056

Accepted user messages, in order at safe model boundaries. Never replaces frozen input.


kind: "agent";

Defined in: agents/src/types.ts:1035


limits: RunLimits;

Defined in: agents/src/types.ts:1066


models: ModelExecution[];

Defined in: agents/src/types.ts:1067


optional recall?: MemoryRecall;

Defined in: agents/src/types.ts:1047

Private model-input data, recorded once. Never part of the session transcript.


runId: string;

Defined in: agents/src/types.ts:1039


optional session?: object;

Defined in: agents/src/types.ts:1065

The session the history came from, and the revision a settled run appends after.

id: string;
revision: string | null;

startedAt: number;

Defined in: agents/src/types.ts:1041


state: RunState;

Defined in: agents/src/types.ts:1071


optional subagent?: SubagentRecord;

Defined in: agents/src/types.ts:1045

Present only for model-created helpers. Private definition and frozen host capabilities.


optional toolCosts?: ToolCost[];

Defined in: agents/src/types.ts:1063

What tools reported spending through context.reportCost, one entry per call attempt, in the order they first reported. Absent until a tool reports.


tree: object;

Defined in: agents/src/types.ts:1070

Identical in every node. Admissions are counted from the journals, including running work.

limits: TreeLimits;
optional memory?: MemoryScopes;
runId: string;
startedAt: number;

version: string;

Defined in: agents/src/types.ts:1038