import type { GuardianAlert } from './types.js'; export interface TelegramSettings { token: string | null; chatId: string | null; } /** Read TELEGRAM_BOT_TOKEN / TELEGRAM_CHAT_ID (dotenv is loaded by core/config on import). */ export declare function loadTelegramSettings(): TelegramSettings; export declare function sendTelegramMessage(token: string, chatId: string | number, text: string): Promise; export declare function getTelegramBotInfo(token: string): Promise<{ id: number; username: string; }>; /** Same message shape as the hosted guardian's Telegram channel. */ export declare function formatTelegramAlert(alert: GuardianAlert): string; export declare function generateLinkCode(): string; /** * Long-poll getUpdates until someone sends `/start ` (or the bare code) * to the bot, then confirm in-chat and return the chat id. Returns null on * timeout. Drains the update backlog first so old messages can't match. */ export declare function waitForTelegramLink(token: string, code: string, timeoutMs?: number): Promise; /** Persist a key=value into the active openbroker config file (creates it if missing). */ export declare function saveEnvVar(key: string, value: string): string; //# sourceMappingURL=telegram.d.ts.map