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

Chat LangChain

What can I help with?

Enter to send·Shift+Enter new line

Menu

LangGraph
WebChannelsPregelPrebuiltRemoteStream
LangGraph SDK
ClientAuthReactLoggingReact UiServer
LangGraph Checkpoint
LangGraph Checkpoint MongoDB
LangGraph Checkpoint Postgres
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/langgraphstreaminferChannel
Function●Since v1.5

inferChannel

Maps a protocol event method to its subscription Channel.

Returns undefined for unrecognized methods so that new server-side channels (e.g. from extension transformers) don't break existing subscribers. The custom method resolves to the named custom:<name> channel when the payload carries a name, otherwise the bare custom channel. Both "input" and the wire-level "input.requested" map to the input channel.

Copy
inferChannel(event: MatchableEvent): Channel | undefined

Parameters

NameTypeDescription
event*MatchableEvent

Event whose method should be mapped to a channel.

View source on GitHub