LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
LangGraph
  • Web
  • Channels
  • Pregel
  • Prebuilt
  • Remote
  • Stream
LangGraph SDK
  • Ui
  • Client
  • Auth
  • React
  • Logging
  • React Ui
  • Utils
  • Server
  • Stream
LangGraph Checkpoint
LangGraph Checkpoint MongoDB
LangGraph Checkpoint Postgres
  • Store
LangGraph Checkpoint Redis
  • Shallow
  • Store
LangGraph Checkpoint SQLite
LangGraph Checkpoint Validation
  • Cli
LangGraph API
LangGraph CLI
LangGraph CUA
  • Utils
LangGraph Supervisor
LangGraph Swarm
⌘I

LangChain Assistant

Ask a question to get started

Enter to send•Shift+Enter new line

Menu

LangGraph
WebChannelsPregelPrebuiltRemoteStream
LangGraph SDK
UiClientAuthReactLoggingReact UiUtilsServerStream
LangGraph Checkpoint
LangGraph Checkpoint MongoDB
LangGraph Checkpoint Postgres
Store
LangGraph Checkpoint Redis
ShallowStore
LangGraph Checkpoint SQLite
LangGraph Checkpoint Validation
Cli
LangGraph API
LangGraph CLI
LangGraph CUA
Utils
LangGraph Supervisor
LangGraph Swarm
Language
Theme
JavaScript@langchain/langgraph-sdkuiPendingRunsTracker
Classā—Since v1.7

PendingRunsTracker

Tracks pending server-side runs created via multitaskStrategy: "enqueue".

Uses the same subscribe/getSnapshot pattern as StreamManager to integrate with framework-specific reactivity systems.

Copy
class PendingRunsTracker

Constructors

constructor
constructor

Properties

property
entries: readonly QueueEntry<StateType, OptionsType>[]
property
size: number

Methods

method
add→ string | null
method
getSnapshot→ T
method
remove→ boolean

Remove a specific entry by ID.

method
removeAll→ QueueEntry<StateType, OptionsType>[]

Remove all entries from the tracker.

method
shift→ QueueEntry<StateType, OptionsType> | undefined

Remove and return the next pending entry (FIFO).

method
subscribe→ Promise<SubscriptionHandle<EventForChannel<TChannel>, YieldForChannel<TChannel>>>

Subscribe to raw wire channels and receive protocol events.

For assembled projections, use the lazy getters instead: thread.messages, thread.values, thread.toolCalls, thread.subgraphs, thread.subagents, thread.output.

View source on GitHub