Documentation
¶
Overview ¶
Package telegram implements the Telegram channel plugin for the forge channel system.
Index ¶
- type Plugin
- func (p *Plugin) Init(cfg channels.ChannelConfig) error
- func (p *Plugin) Name() string
- func (p *Plugin) NormalizeEvent(raw []byte) (*channels.ChannelEvent, error)
- func (p *Plugin) SendResponse(event *channels.ChannelEvent, response *a2a.Message) error
- func (p *Plugin) Start(ctx context.Context, handler channels.EventHandler) error
- func (p *Plugin) Stop() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Plugin ¶
type Plugin struct {
// contains filtered or unexported fields
}
Plugin implements channels.ChannelPlugin for Telegram.
func (*Plugin) NormalizeEvent ¶
func (p *Plugin) NormalizeEvent(raw []byte) (*channels.ChannelEvent, error)
NormalizeEvent parses a Telegram Update JSON into a ChannelEvent.
func (*Plugin) SendResponse ¶
SendResponse sends a text message back to the Telegram chat. If the runtime attached file parts (large tool outputs), those are used for the document upload since the LLM text may be truncated. For large responses (>4096 chars), sends a summary message and uploads the full report as a document.
Click to show internal directories.
Click to hide internal directories.