refactor: migrate extensions to plugin sdk

This commit is contained in:
Peter Steinberger
2026-01-18 02:51:42 +00:00
parent 5b4651d9ed
commit 1420d113d8
95 changed files with 380 additions and 208 deletions

View File

@@ -1,10 +1,11 @@
import { chunkMarkdownText } from "../../../src/auto-reply/chunk.js";
import type { ChannelOutboundAdapter } from "../../../src/channels/plugins/types.js";
import type { ChannelOutboundAdapter } from "clawdbot/plugin-sdk";
import { getMatrixRuntime } from "./runtime.js";
import { sendMessageMatrix, sendPollMatrix } from "./matrix/send.js";
export const matrixOutbound: ChannelOutboundAdapter = {
deliveryMode: "direct",
chunker: chunkMarkdownText,
chunker: (text, limit) => getMatrixRuntime().channel.text.chunkMarkdownText(text, limit),
textChunkLimit: 4000,
sendText: async ({ to, text, deps, replyToId, threadId }) => {
const send = deps?.sendMatrix ?? sendMessageMatrix;