mirror of
https://github.com/vercel/chat.git
synced 2026-09-14 18:32:29 +08:00
b1940d2374
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @chat-adapter/github@4.33.0 ### Minor Changes -6750d59: Add Vercel Connect support to the GitHub adapter. A new `installationToken` config option (string or resolver) supplies installation access tokens directly, skipping the GitHub App private-key JWT exchange, and an optional `webhookVerifier` verifies inbound webhooks (e.g. Connect trigger-forwarded requests via a Vercel OIDC token) in place of the GitHub webhook secret. Pair with `connectGitHubAdapter()` from `@vercel/connect/chat`. `botUserId` now also auto-detects from the `GITHUB_BOT_USER_ID` env var, and the adapter learns its bot user id from the first comment it posts. In Connect mode (where the bot user id can't be auto-detected from an installation token) set `botUserId` / `GITHUB_BOT_USER_ID` to enable self-message detection and avoid the adapter replying to its own comments. Note: the `connectGitHubAdapter()` helper ships in `@vercel/connect` — release this adapter together with (or after) the `@vercel/connect` version that adds the `@vercel/connect/chat` subpath so the documented helper resolves. ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/linear@4.33.0 ### Minor Changes -4115c94: Add Vercel Connect support to the Linear adapter. The `accessToken` config option now accepts a resolver (`() => string | Promise<string>`) in addition to a string, so tokens can be sourced from Vercel Connect at runtime, and a new optional `webhookVerifier` verifies inbound webhooks (e.g. Connect trigger-forwarded requests via a Vercel OIDC token) in place of the Linear webhook secret. Pair with `connectLinearAdapter()` from `@vercel/connect/chat`. Connect-mode outbound calls outside webhook handling are supported via `withInstallation(organizationId, fn)`. Note: the `connectLinearAdapter()` helper ships in `@vercel/connect` — release this adapter together with (or after) the `@vercel/connect` version that adds the `@vercel/connect/chat` subpath so the documented helper resolves. ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/shared@4.33.0 ### Minor Changes -d4c52ca: add `replaceBareMentions`, a context-aware bare-`@mention` resolver that skips code spans, URLs, schemeless hosts, and existing angle-bracket tokens before handing each real `@name` to a platform-specific replacer ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [076fe5d] - chat@4.33.0 ## @chat-adapter/x@4.33.0 ### Minor Changes -ef2542c: add X (Twitter) adapter: reply to public mentions, send and receive direct messages, post and edit from the bot account, and like posts, using the X API v2 with OAuth 2.0 and managed token refresh ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## chat@4.33.0 ### Minor Changes -ef2542c: add X (Twitter) adapter: reply to public mentions, send and receive direct messages, post and edit from the bot account, and like posts, using the X API v2 with OAuth 2.0 and managed token refresh ### Patch Changes -3abdc69: docs(adapters): add Cloudflare Agents as a vendor-official state adapter (`agents/chat-sdk`) to the catalog and docs listing. It is hidden from the create-chat-sdk CLI (Worker/Durable Objects runtime), and the interactive state picker now filters out CLI-incompatible state adapters. -0b63791: Raise the default message dedupe TTL from 5 to 10 minutes so it outlives the longest platform redelivery window. Slack's Events API retries up to ~5 minutes after the original delivery — exactly at the old TTL boundary, where a retried event could miss the expired dedupe entry from its first processing and be handled twice. Configurable behavior is unchanged (`dedupeTtlMs` still overrides). -0c761f1: docs(adapters): add Dial as a vendor-official adapter (`@getdial/chat-sdk-adapter`) to the catalog, docs listing, and CLI scaffold spec -24a04d5: docs(adapters): add Photon as a vendor-official adapter (`@photon-ai/chat-adapter-imessage`) to the catalog, docs listing, and CLI scaffold spec -076fe5d: preserve skipped mention routing for debounce and message patterns ## create-chat-sdk@0.2.0 ### Minor Changes -ba375ce: Add Vercel Connect support to the scaffolder. Pass `--connect` (or choose **Vercel Connect** at the new interactive auth-mode prompt) to authenticate the Slack, GitHub, and Linear adapters with a Vercel Connect connector instead of stored provider secrets. The generated `src/lib/bot.ts` spreads the matching helper from `@vercel/connect/chat` into the adapter factory, `@vercel/connect` is added to dependencies, and `.env.example` lists each connector UID (for example `SLACK_CONNECTOR`) plus the recommended `GITHUB_BOT_USER_ID` for GitHub, in place of native secrets. -ef2542c: add X (Twitter) adapter: reply to public mentions, send and receive direct messages, post and edit from the bot account, and like posts, using the X API v2 with OAuth 2.0 and managed token refresh ### Patch Changes -3abdc69: docs(adapters): add Cloudflare Agents as a vendor-official state adapter (`agents/chat-sdk`) to the catalog and docs listing. It is hidden from the create-chat-sdk CLI (Worker/Durable Objects runtime), and the interactive state picker now filters out CLI-incompatible state adapters. -0c761f1: docs(adapters): add Dial as a vendor-official adapter (`@getdial/chat-sdk-adapter`) to the catalog, docs listing, and CLI scaffold spec -24a04d5: docs(adapters): add Photon as a vendor-official adapter (`@photon-ai/chat-adapter-imessage`) to the catalog, docs listing, and CLI scaffold spec ## @chat-adapter/tests@4.33.0 ### Minor Changes -e7a396a: Add two shared behavioral test contracts for adapter authors: - `threadIdContract` — verifies an adapter's thread-id codec round-trips (`decode(encode(x))`), prefixes ids with the adapter name, matches any pinned encoded strings, and (optionally) distinguishes DM from non-DM threads. - `selfMessageContract` — verifies an adapter dispatches inbound messages from other users (to `processMessage` by default) but ignores messages the bot authored itself, so it never replies to itself. Requires the matchers to be registered via `setupFiles: ["@chat-adapter/tests/setup"]`. -a7fb1bc: Add `connectWebhookContract`, a shared Vitest suite for verifying an adapter's Vercel Connect webhook verification. Given a small per-adapter descriptor (how to build the adapter in Connect mode and craft an inbound webhook), it asserts the behavior every Connect-capable adapter shares: a `webhookVerifier` replaces the native signature/secret check and gates inbound requests — accept (`200`) on a truthy result, reject (`401`) on a thrown error or falsy result — and is invoked with the request and raw body. Connect-capable adapters can opt in with ~10 lines. ## @chat-adapter/discord@4.33.0 ### Patch Changes -d4c52ca: use the shared `replaceBareMentions` scanner for `@mention` conversion so email addresses, `@handles` inside URLs, and mentions inside code spans are no longer mangled into Discord mentions, and already-formatted `<@id>` tokens are not double-wrapped -6de4572: Implement `rehydrateAttachment` on the Discord adapter. Serialization strips an attachment's `fetchData` closure (queue/debounce strategies), and consumers rebuild it via `adapter.rehydrateAttachment`. The Discord adapter did not implement the method, so downstream consumers could not download inbound Discord attachments after deserialization. The Discord CDN `url` survives serialization, so `fetchData` is now rebuilt to fetch that url (preserving its signed query params), matching how the other adapters implement the method. - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/gchat@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/messenger@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/slack@4.33.0 ### Patch Changes -0b63791: Process Slack Socket Mode retry envelopes instead of discarding them. Slack redelivers an event (immediately, +1 min, +5 min) when a prior delivery wasn't acknowledged — including events sent while the app had no open socket, e.g. during a restart or a routine connection refresh. The adapter previously acked and dropped every envelope with `retry_num > 0`, so such events were permanently lost even though Slack redelivered them. Retries are now routed like first deliveries (logged at info with `retry_num`/`retry_reason`); `Chat.processMessage`'s message-id dedupe drops true duplicates. - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/teams@4.33.0 ### Patch Changes -d4c52ca: use the shared `replaceBareMentions` scanner for `@mention` conversion so email addresses, `@handles` inside URLs, and mentions inside code spans are no longer mangled into `<at>` mention tags - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/telegram@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/twilio@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/web@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/whatsapp@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [d4c52ca] - Updated dependencies [076fe5d] - chat@4.33.0 - @chat-adapter/shared@4.33.0 ## @chat-adapter/state-ioredis@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [076fe5d] - chat@4.33.0 ## @chat-adapter/state-memory@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [076fe5d] - chat@4.33.0 ## @chat-adapter/state-pg@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [076fe5d] - chat@4.33.0 ## @chat-adapter/state-redis@4.33.0 ### Patch Changes - Updated dependencies [3abdc69] - Updated dependencies [0b63791] - Updated dependencies [0c761f1] - Updated dependencies [ef2542c] - Updated dependencies [24a04d5] - Updated dependencies [076fe5d] - chat@4.33.0 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
7.0 KiB
7.0 KiB
@chat-adapter/shared
4.33.0
Minor Changes
d4c52ca: addreplaceBareMentions, a context-aware bare-@mentionresolver that skips code spans, URLs, schemeless hosts, and existing angle-bracket tokens before handing each real@nameto a platform-specific replacer
Patch Changes
- Updated dependencies [
3abdc69] - Updated dependencies [
0b63791] - Updated dependencies [
0c761f1] - Updated dependencies [
ef2542c] - Updated dependencies [
24a04d5] - Updated dependencies [
076fe5d]
4.32.0
Patch Changes
- Updated dependencies [
eccc6b9] - Updated dependencies [
438f551] - Updated dependencies [
d034b8b] - Updated dependencies [
06af3e1] - Updated dependencies [
2e47351] - Updated dependencies [
efa9610]
4.31.0
Patch Changes
4.30.0
Patch Changes
4.29.0
Minor Changes
add2730: support typed Telegram attachment uploads
Patch Changes
e60bc8c: chore: set supported Node versions in engines- Updated dependencies [
ac8a207] - Updated dependencies [
e60bc8c] - Updated dependencies [
b75eedb]
4.28.1
Patch Changes
4.28.0
Minor Changes
-
9824d33: Security fixes for HIGH-severity findings:- adapter-slack: Replace timing-unsafe
!==withcrypto.timingSafeEqualwhen validating thex-slack-socket-tokenheader on forwarded socket-mode events. - adapter-github: In multi-tenant App mode, eagerly auto-detect the bot user ID on the first installation client / first webhook so
isMechecks work and self-reply loops are prevented. Falls back toapps.getAuthenticated+users.getByUsernamewhenusers.getAuthenticatedis unavailable for installation tokens. - adapter-linear: Add optional
encryptionKeyconfig (orLINEAR_ENCRYPTION_KEYenv var) that AES-256-GCM-encryptsaccessTokenandrefreshTokenat rest in the state store. Tolerates plaintext records for zero-downtime rollout. - adapter-gchat: Fail-closed by default — the constructor now throws
ValidationErrorif neithergoogleChatProjectNumbernorpubsubAudienceis configured. To accept unverified webhooks (development only), set the newdisableSignatureVerification: trueflag (orGOOGLE_CHAT_DISABLE_SIGNATURE_VERIFICATION=true). Mirrors the Slack adapter's signing-secret requirement. - adapter-shared: New
decodeKey/encryptToken/decryptToken/isEncryptedTokenDatautilities (AES-256-GCM, hex or base64 32-byte keys), shared by Slack and Linear.
- adapter-slack: Replace timing-unsafe
Patch Changes
- Updated dependencies [
eb5f94a] - Updated dependencies [
c1cd9b5] - Updated dependencies [
9824d33] - Updated dependencies [
46d183b] - Updated dependencies [
46d183b] - Updated dependencies [
3490a8c]
4.27.0
Patch Changes
- Updated dependencies [
8a0c7b3] - Updated dependencies [
1e7c551] - Updated dependencies [
b0ab804] - Updated dependencies [
d630e6c] - Updated dependencies [
b9a1961] - Updated dependencies [
a520797] - Updated dependencies [
70281dc] - Updated dependencies [
9093292] - Updated dependencies [
7e90d9c] - Updated dependencies [
bca4792] - Updated dependencies [
37dbb4a] - Updated dependencies [
608d5f0] - Updated dependencies [
a179b29] - Updated dependencies [
a8f2aab]
4.26.0
Patch Changes
4.25.0
Patch Changes
4.24.0
Patch Changes
8d89274: fix: disable source maps in published packages- Updated dependencies [
8d89274] - Updated dependencies [
4f5d200] - Updated dependencies [
27b34e1]
4.23.0
Patch Changes
4.22.0
Patch Changes
4.21.0
Patch Changes
4.20.2
Patch Changes
4.20.1
Patch Changes
4.20.0
Patch Changes
4.19.0
Patch Changes
4.18.0
Patch Changes
4.17.0
Patch Changes
4.16.1
Patch Changes
4.16.0
Minor Changes
02e7ef6: Implements table markdown rendering, and fully streaming markdown rendering including for Slack which has native streaming. Overhauls adapters to have better fallback-render behavior
Patch Changes
- Updated dependencies [
02e7ef6] - Updated dependencies [
9522b04] - Updated dependencies [
f5a75c9] - Updated dependencies [
f0c7050] - Updated dependencies [
73de82d]
4.15.0
Minor Changes
5b3090a: Add CardLink element
Patch Changes
4.14.0
Patch Changes
4.13.4
Patch Changes
4.13.3
Patch Changes
4.13.2
Patch Changes
4.13.1
Patch Changes
4.13.0
Patch Changes
4.12.0
Patch Changes
4.11.0
Patch Changes
4.10.1
Patch Changes
4.10.0
Patch Changes
4.9.1
Patch Changes
18ce1d0: Exclude action buttons from card fallback text so they no longer appear in Slack notification previews- chat@4.9.1
4.9.0
Patch Changes
- chat@4.9.0
4.8.0
Patch Changes
- Updated dependencies [
cca9867]- chat@4.8.0
4.7.2
Patch Changes
- chat@4.7.2
4.7.1
Patch Changes
- Updated dependencies [
160f1f7]- chat@4.7.1
4.7.0
Patch Changes
- Updated dependencies [
a13f43e]- chat@4.7.0
4.6.0
Patch Changes
- Updated dependencies [
68e3f74]- chat@4.6.0
4.5.0
Patch Changes
- Updated dependencies [
efa6b36]- chat@4.5.0
4.4.1
Patch Changes
9e8f9e7: Serde support- Updated dependencies [
1882732] - Updated dependencies [
b5826c2] - Updated dependencies [
9e8f9e7]- chat@4.4.1
4.4.0
Patch Changes
- Updated dependencies [
8ca6371]- chat@4.4.0
4.3.0
Minor Changes
498eb04: Discord support