Documentation ¶
Overview ¶
Package manager provides a simple way to manage multiples bots.
Index ¶
- type Manager
- func (m *Manager) AddBot(botToken string) error
- func (m *Manager) DownloadFileBuffer(identifier v1.MessageIdentifier, copyChat int64) (*v1.DownloadBufferResult, error)
- func (m *Manager) DownloadFileReader(identifier v1.MessageIdentifier, copyChat int64) (*v1.DownloadReaderResult, error)
- func (m *Manager) StartUploaderManager()
- func (m *Manager) UploadFileBuffer(chatId int64, fileName string, fileData []byte) (v1.MessageIdentifier, error)
- func (m *Manager) UploadFileReader(chatId int64, fileName string, fileReader io.Reader) (v1.MessageIdentifier, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func NewManager ¶
NewManager creates a new Manager. botsTokens is a slice of distinct bot tokens
func (*Manager) DownloadFileBuffer ¶
func (m *Manager) DownloadFileBuffer(identifier v1.MessageIdentifier, copyChat int64) (*v1.DownloadBufferResult, error)
func (*Manager) DownloadFileReader ¶
func (m *Manager) DownloadFileReader(identifier v1.MessageIdentifier, copyChat int64) (*v1.DownloadReaderResult, error)
func (*Manager) StartUploaderManager ¶
func (m *Manager) StartUploaderManager()
StartUploaderManager starts the uploader manager
This uploader manager will handle requests for getting available bots, and making them available again
func (*Manager) UploadFileBuffer ¶
func (*Manager) UploadFileReader ¶
Click to show internal directories.
Click to hide internal directories.