/** * Base Gateway abstract class * * Extracts common logic shared across Discord, Slack, and Telegram gateways. * Platform-specific behavior is implemented via abstract methods and properties. */ import type { Gateway, GatewayEvent, GatewayEventHandler, GatewayConfig, MessageSource } from './types.js'; import { MessageRouter } from './message-router.js'; export interface BaseGatewayOptions { messageRouter: MessageRouter; config?: Partial; } export declare abstract class BaseGateway implements Gateway { abstract readonly source: MessageSource; protected messageRouter: MessageRouter; protected eventHandlers: GatewayEventHandler[]; protected connected: boolean; constructor(options: BaseGatewayOptions); abstract start(): Promise; abstract stop(): Promise; abstract sendMessage(channelId: string, text: string): Promise; abstract sendFile(channelId: string, filePath: string, caption?: string): Promise; /** Regex to strip bot mentions from message text. null = no stripping. */ protected abstract get mentionPattern(): RegExp | null; isConnected(): boolean; onEvent(handler: GatewayEventHandler): void; protected emitEvent(event: GatewayEvent): void; protected cleanMessageContent(content: string): string; } //# sourceMappingURL=base-gateway.d.ts.map