The Open Framework for Building Agents
feat(docs): add Liveblocks integration (#1078)
Colton Padden331711bf97d9
diff --git a/apps/docs/lib/integrations/data.ts b/apps/docs/lib/integrations/data.tsindex 82e114326..d3618ba18 100644--- a/apps/docs/lib/integrations/data.ts+++ b/apps/docs/lib/integrations/data.ts@@ -697,6 +697,62 @@ export default channel;See the [Novu adapter documentation](https://chat-sdk.dev/adapters/vendor-official/novu) for supported events, capabilities, and credentials.`,configure: `Run \`npx novu connect --runtime chat-sdk\` to authenticate Novu, choose a channel, and create the required environment variables. Novu manages provider credentials, identity, delivery, and conversation history across its supported channels. See the [Chat SDK channel docs](/docs/channels/chat-sdk) for eve session dispatch, state, streaming, and human-in-the-loop behavior.`,},+ "chat-sdk-liveblocks": {+ logo: "liveblocks",+ docsHref: "/docs/channels/chat-sdk",+ badge: "Provider official",+ keywords: [+ "chat sdk",+ "liveblocks",+ "comments",+ "collaboration",+ "threads",+ "mentions",+ "reactions",+ ],+ install: `Install eve, Chat SDK, the Liveblocks adapter, and a state adapter:++\`\`\`bash+npm install eve@latest chat @liveblocks/chat-sdk-adapter @chat-adapter/state-memory+\`\`\`++The in-memory state store is for local development. Use Redis or PostgreSQL in production. This adapter is built and maintained by Liveblocks.`,+ quickStart: `Create \`agent/channels/liveblocks.ts\`:++\`\`\`ts+// agent/channels/liveblocks.ts+import { createLiveblocksAdapter } from "@liveblocks/chat-sdk-adapter";+import { createMemoryState } from "@chat-adapter/state-memory";+import { chatSdkChannel } from "eve/channels/chat-sdk";++export const { bot, channel, send } = chatSdkChannel({+ userName: "My Agent",+ adapters: {+ liveblocks: createLiveblocksAdapter({+ apiKey: process.env.LIVEBLOCKS_SECRET_KEY!,+ webhookSecret: process.env.LIVEBLOCKS_WEBHOOK_SECRET!,+ botUserId: "my-agent",+ botUserName: "My Agent",+ }),+ },+ state: createMemoryState(),+});++bot.onNewMention(async (thread, message) => {+ await thread.subscribe();+ await send(message.text, { thread });+});++bot.onSubscribedMessage(async (thread, message) => {+ await send(message.text, { thread });+});++export default channel;+\`\`\`++See the [Liveblocks adapter documentation](https://chat-sdk.dev/adapters/vendor-official/liveblocks) for supported events, capabilities, and credentials.`,+ configure: `Create a Liveblocks webhook, set \`LIVEBLOCKS_SECRET_KEY\` and \`LIVEBLOCKS_WEBHOOK_SECRET\`, and send comment events to \`/eve/v1/liveblocks\`. The adapter maps rooms to channels, comment threads to threads, and comments to messages. See the [Chat SDK channel docs](/docs/channels/chat-sdk) for eve session dispatch, state, streaming, and human-in-the-loop behavior.`,+ },};const extensionPresentations: Record<string, ExtensionPresentation> = {diff --git a/apps/docs/lib/integrations/logos.tsx b/apps/docs/lib/integrations/logos.tsxindex 1a2a00d18..307b8bb36 100644--- a/apps/docs/lib/integrations/logos.tsx+++ b/apps/docs/lib/integrations/logos.tsx@@ -357,6 +357,12 @@ export const novuLogo = (props: LogoProps) => (</svg>);+export const liveblocksLogo = (props: LogoProps) => (+ <svg fill="none" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" {...props}>+ <path d="M14.5 5H3l3 3.8v4.5L14.5 5ZM9 19h12l-3-3.2v-5L9 19Z" fill="currentColor" />+ </svg>+);+export const googlechatLogo = (props: LogoProps) => <SiGooglechat color="default" {...props} />;export const whatsappLogo = (props: LogoProps) => <SiWhatsapp color="default" {...props} />;@@ -497,6 +503,7 @@ export const logos = {velt: veltLogo,sendblue: sendblueLogo,novu: novuLogo,+ liveblocks: liveblocksLogo,googlechat: googlechatLogo,whatsapp: whatsappLogo,messenger: messengerLogo,diff --git a/packages/eve-catalog/src/index.ts b/packages/eve-catalog/src/index.tsindex 702981db8..c8bf233da 100644--- a/packages/eve-catalog/src/index.ts+++ b/packages/eve-catalog/src/index.ts@@ -199,6 +199,13 @@ export const INTEGRATIONS: readonly IntegrationEntry[] = [tagline: "Reach Slack, Teams, WhatsApp, Telegram, and email through Novu.",surfaces: { scaffoldable: false, gallery: true },},+ {+ slug: "chat-sdk-liveblocks",+ name: "Liveblocks",+ kind: "channel",+ tagline: "Bring your agent into Liveblocks comment threads, mentions, and reactions.",+ surfaces: { scaffoldable: false, gallery: true },+ },{slug: "agent-browser",name: "agent-browser",