Skip to content

Function: snapshotRequestContext()

snapshotRequestContext<TValues>(source): MastraRequestContextSnapshot | undefined

Materialize and validate one run’s application context. Infrastructure keys remain server-owned; this only snapshots caller-provided JSON values.

TValues extends Record<string, unknown>

MastraRequestContextSource<TValues> | undefined

MastraRequestContextSnapshot | undefined