Documentation
¶
Index ¶
- type TelegramChannel
- func (t *TelegramChannel) Name() string
- func (t *TelegramChannel) Send(ctx context.Context, msg domain.OutboundMessage) error
- func (t *TelegramChannel) SendApproval(ctx context.Context, recipientID string, req *domain.ApprovalRequest) error
- func (t *TelegramChannel) Start(ctx context.Context, inbox chan<- domain.InboundMessage) error
- func (t *TelegramChannel) Stop() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TelegramChannel ¶
type TelegramChannel struct {
// contains filtered or unexported fields
}
TelegramChannel implements domain.Channel for the Telegram Bot API using the go-telegram/bot SDK with long-polling.
func NewTelegramChannel ¶
func NewTelegramChannel(cfg config.TelegramChannelConfig) *TelegramChannel
NewTelegramChannel creates a new Telegram channel
func (*TelegramChannel) Name ¶
func (t *TelegramChannel) Name() string
Name returns the channel identifier
func (*TelegramChannel) Send ¶
func (t *TelegramChannel) Send(ctx context.Context, msg domain.OutboundMessage) error
Send delivers a message through the Telegram Bot API
func (*TelegramChannel) SendApproval ¶ added in v0.103.0
func (t *TelegramChannel) SendApproval(ctx context.Context, recipientID string, req *domain.ApprovalRequest) error
SendApproval sends a tool approval prompt with inline keyboard buttons. Implements domain.ApprovalChannel.
func (*TelegramChannel) Start ¶
func (t *TelegramChannel) Start(ctx context.Context, inbox chan<- domain.InboundMessage) error
Start begins long-polling for Telegram updates and sends inbound messages to the inbox
func (*TelegramChannel) Stop ¶
func (t *TelegramChannel) Stop() error
Stop gracefully shuts down the Telegram channel
Click to show internal directories.
Click to hide internal directories.