
Security News
pnpm 11.5 Adds Support for Recognizing npm Staged Publishes
pnpm 11.5 now recognizes npm staged publish approvals in release metadata, preventing those releases from being mistaken for lower-trust package publishes.
@langchain/protocol
Advanced tools
@langchain/protocolTypeScript bindings for the LangChain agent streaming protocol.
This package publishes the generated TypeScript schema bindings from
protocol.cddl so TypeScript applications can type protocol commands, events,
results, and content blocks consistently.
protocol.tsCommand, Message, and protocol eventsThis package does not currently ship a runtime client, transport, or helper APIs
such as createSession(). It is intended for typing protocol payloads and
generated bindings only.
npm install @langchain/protocol
Use type-only imports when consuming the protocol schema:
import type {
Command,
Message,
SessionOpenParams,
SubscribeParams,
MessagesEvent,
} from "@langchain/protocol";
You can then use the exported types to model protocol payloads in your own transport or client implementation:
import type { Command, SessionOpenParams } from "@langchain/protocol";
const params: SessionOpenParams = {
protocolVersion: "0.3.0",
};
const openCommand: Command = {
id: 1,
method: "session.open",
params,
};
The package version is aligned with the draft protocol schema version published
from this repository. The current generated bindings target protocol 0.3.0.
The canonical protocol definition lives in the repository root at
protocol.cddl. The TypeScript bindings in this package are generated from that
schema.
FAQs
TypeScript bindings for the LangChain agent streaming protocol
The npm package @langchain/protocol receives a total of 755,285 weekly downloads. As such, @langchain/protocol popularity was classified as popular.
We found that @langchain/protocol demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 13 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
pnpm 11.5 now recognizes npm staged publish approvals in release metadata, preventing those releases from being mistaken for lower-trust package publishes.

Security News
Federal audit finds NIST lacked a plan to clear the NVD backlog, wasted funds on duplicate work, and delayed use of CISA data.

Research
/Security News
A mini Shai-Hulud campaign compromised Red Hat Cloud Services npm packages to steal developer and CI/CD secrets during installation.