Docs
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
Neon
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
Neon
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
Class References
Function References
Interface References
Type Alias References
Variable References

RunFinishedEvent

Interface: RunFinishedEvent

Defined in: types.ts:780

Emitted when a run completes successfully.

Extends

Properties

finishReason

ts
finishReason: "length" | "stop" | "content_filter" | "tool_calls" | null;

Defined in: types.ts:785

Why the generation stopped


model?

ts
optional model: string;

Defined in: types.ts:756

Model identifier for multi-model support

Inherited from

BaseAGUIEvent.model


rawEvent?

ts
optional rawEvent: unknown;

Defined in: types.ts:758

Original provider event for debugging/advanced use cases

Inherited from

BaseAGUIEvent.rawEvent


runId

ts
runId: string;

Defined in: types.ts:783

Run identifier


timestamp

ts
timestamp: number;

Defined in: types.ts:754

Inherited from

BaseAGUIEvent.timestamp


type

ts
type: "RUN_FINISHED";

Defined in: types.ts:781

Overrides

BaseAGUIEvent.type


usage?

ts
optional usage: object;

Defined in: types.ts:787

Token usage statistics

completionTokens

ts
completionTokens: number;

promptTokens

ts
promptTokens: number;

totalTokens

ts
totalTokens: number;