Documentation
¶
Index ¶
- Constants
- func NewUploading(file io.Reader, opts ...UploadingOptions) http.MultipartFile
- type AuthToken
- type Client
- func (c Client) CommandGetList(ctx context.Context) (CommandList, error)
- func (c Client) CommandUpdate(ctx context.Context, command ...Command) error
- func (c Client) FileGetURL(ctx context.Context) (*FileNode, error)
- func (c Client) FileUpload(ctx context.Context, file http.MultipartFile) (fileID string, _ error)
- func (c Client) Group(id string) Group
- func (c Client) GroupGetList(ctx context.Context, request Pagination) (GroupList, error)
- func (c Client) Message(id string) Message
- func (c Client) User(id int64) User
- func (c Client) UserGetList(ctx context.Context, request Pagination) (UserList, error)
- func (c Client) WebhookGetVersion(ctx context.Context) (version int, _ error)
- func (c Client) WebhookSetVersion(ctx context.Context, version int) error
- type Command
- type CommandList
- type ErrorResponse
- type FileNode
- type Fmt
- type Group
- type GroupList
- type Message
- func (m Message) AddReaction(ctx context.Context, reaction string) error
- func (m Message) RemoveReaction(ctx context.Context, reaction string) error
- func (m Message) ReplyFile(ctx context.Context, fileID string) (messageID string, err error)
- func (m Message) ReplyText(ctx context.Context, text string) (messageID string, err error)
- type Options
- type Pagination
- type Tag
- type UploadingOptions
- type User
- type UserList
Constants ¶
const ( ProcessingReaction = "🤖" DoneReaction = "✅" FailedReaction = "❌" QuestionReaction = "❓" )
Variables ¶
This section is empty.
Functions ¶
func NewUploading ¶
func NewUploading( file io.Reader, opts ...UploadingOptions, ) http.MultipartFile
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (Client) CommandGetList ¶
func (c Client) CommandGetList( ctx context.Context, ) (CommandList, error)
CommandGetList invokes POST /command/getList operation.
Получить список команд бота.
POST /command/getList
func (Client) CommandUpdate ¶
CommandUpdate invokes POST /command/update operation.
Обновить список команд бота.
POST /command/update
func (Client) FileGetURL ¶
FileGetURL invokes POST /file/getUrl operation.
Получить URL для загрузки файлов.
POST /file/getUrl
func (Client) FileUpload ¶
func (c Client) FileUpload( ctx context.Context, file http.MultipartFile, ) (fileID string, _ error)
FileUpload invokes POST {node_url} operation.
Загрузка файла.
POST {node_url}
func (Client) GroupGetList ¶
GroupGetList invokes POST /group/getList operation.
Получить данные групп, в которых состоит бот.
POST /group/getList
func (Client) UserGetList ¶
UserGetList invokes POST /user/getList operation.
Получить данные об участниках команды.
POST /user/getList
func (Client) WebhookGetVersion ¶
WebhookGetVersion invokes POST /webhook/getVersion operation.
Получить текущую версию webhook бота.
POST /webhook/getVersion
type CommandList ¶
type CommandList = []Command
type ErrorResponse ¶
type ErrorResponse api.ErrorResponseResponse
func (*ErrorResponse) Error ¶
func (e *ErrorResponse) Error() string
type FileNode ¶
type FileNode = api.FileGetURLResponseResponse
type Group ¶
type Group struct {
// contains filtered or unexported fields
}
type GroupList ¶
type GroupList = []api.GroupGetListResponseResponseGroupListItem
type Message ¶
type Message struct {
// contains filtered or unexported fields
}
func (Message) AddReaction ¶
AddReaction invokes POST /message/addReaction operation.
Добавить реакцию на сообщение от лица бота.
POST /message/addReaction
func (Message) RemoveReaction ¶
RemoveReaction invokes POST /message/removeReaction operation.
Удалить реакцию бота с сообщения.
POST /message/removeReaction
type Pagination ¶
type Pagination = api.GetListRequest
type UploadingOptions ¶
type User ¶
type User struct {
// contains filtered or unexported fields
}
type UserList ¶
type UserList = []api.UserGetListResponseResponseUserListItem