npm / @chat-adapter/linear
@chat-adapter/linear
What changed in @chat-adapter/linear 4, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-19.
1 breaking2 security5 new APIs and options9 behavior and defaults4 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli init@chat-adapter/linear 421 changes
Breaking changes 1
Adapter and StateAdapter now require channelIdFromThreadId, so implementations must provide it.
Security 2
Validates agent session issue ownership before fetching history to prevent cross-issue reads.
Validates comment ownership before fetching Linear thread replies to prevent cross-issue content exposure.
New APIs and options 5
A new optional webhookVerifier verifies inbound webhooks in place of the Linear webhook secret.
Connect-mode outbound calls outside webhook handling are supported via withInstallation(organizationId, fn).
The Linear adapter exposes its native client as linearClient, returning LinearClient; the previous client getter remains available as a deprecated alias.
EphemeralMessage is now generic over TRawMessage, allowing its raw message type to be specified.
Adds the CardLink element.
Behavior and default changes 9
Generated Linear Connect bots use explicit agent-session mode and setup guidance; initialization recommends agent sessions when a token resolver and webhook verifier are configured without a mode, while preserving the adapter's comments default.
The accessToken config option accepts a string or a resolver returning a string or Promise<string>, allowing tokens to be sourced from Vercel Connect at runtime.
Adapter internals are protected rather than private, allowing consumers to subclass an adapter to override or extend its behavior.
The adapter now declares chat as a full dependency instead of an optional dependency, so it is installed as a required package dependency.
Adapters have improved fallback-render behavior.
Markdown rendering is fully streaming, including for Slack, which has native streaming.
Markdown rendering now supports tables.
The Slack adapter adds typing indicators using the Slack assistants API.
Configuration is now automatically loaded from environment variables.
Fixes and other changes 4
The Linear adapter checks that a comment belongs to the supplied thread before edits, deletions, and reactions.
Linear ordinary comments leave isMention undetermined, allowing SDK text detection to apply; a definitive false from an adapter now suppresses mention detection based on message text.
Linear agent-session events stay on one stable thread, including sessions created by automation or without a root comment.
Expanded npm keywords to improve discoverability of adapter and state packages.