TanStack

UIResourceEvent

Interface: UIResourceEvent

Defined in: packages/ai/src/types.ts:1505

Emitted when an MCP tool returns a ui:// resource (MCP Apps). Reconciled into a UIResourcePart on the assistant UIMessage. Never enters model input.

Extends

Properties

model?

ts
optional model?: string;

Defined in: packages/ai/src/types.ts:1414

Model identifier for multi-model support

Inherited from

CustomEvent.model


name

ts
name: "ui-resource";

Defined in: packages/ai/src/types.ts:1506

Overrides

ts
CustomEvent.name

runId?

ts
optional runId?: string;

Defined in: packages/ai/src/types.ts:1422

Inherited from

CustomEvent.runId


threadId?

ts
optional threadId?: string;

Defined in: packages/ai/src/types.ts:1421

Routing metadata the TanStack engine attaches when emitting CUSTOM events that need to be correlated with a specific thread/run. Stripped by strip-to-spec-middleware before going on the wire so the AG-UI consumer never sees them (when that middleware is enabled).

Inherited from

CustomEvent.threadId


type

ts
type: "CUSTOM";

Defined in: packages/ai/src/types.ts:1412

Inherited from

CustomEvent.type


value

ts
value: object;

Defined in: packages/ai/src/types.ts:1507

meta?

ts
optional meta?: Record<string, unknown>;

resource

ts
resource: object;
resource.blob?
ts
optional blob?: string;
resource.mimeType
ts
mimeType: string;
resource.text?
ts
optional text?: string;
resource.uri
ts
uri: string;

serverId?

ts
optional serverId?: string;

toolCallId

ts
toolCallId: string;

toolName

ts
toolName: string;

Overrides

ts
CustomEvent.value