feat: unify provider reaction tools

This commit is contained in:
Peter Steinberger
2026-01-07 04:10:13 +01:00
parent 551a8d5683
commit 3afef2d504
41 changed files with 1169 additions and 82 deletions

View File

@@ -232,6 +232,10 @@ export type HooksConfig = {
gmail?: HooksGmailConfig;
};
export type TelegramActionConfig = {
reactions?: boolean;
};
export type TelegramConfig = {
/**
* Controls how Telegram direct chats (DMs) are handled:
@@ -271,6 +275,8 @@ export type TelegramConfig = {
webhookUrl?: string;
webhookSecret?: string;
webhookPath?: string;
/** Per-action tool gating (default: true for all). */
actions?: TelegramActionConfig;
};
export type DiscordDmConfig = {

View File

@@ -793,6 +793,11 @@ export const ClawdbotSchema = z.object({
webhookUrl: z.string().optional(),
webhookSecret: z.string().optional(),
webhookPath: z.string().optional(),
actions: z
.object({
reactions: z.boolean().optional(),
})
.optional(),
})
.superRefine((value, ctx) => {
if (value.dmPolicy !== "open") return;