Documentation
¶
Index ¶
- Variables
- type Session
- func (s Session) AddContact(teamUid string, phone string) (tdproto.Contact, error)
- func (s Session) AuthByPasswordGetToken(login, password string) (tdapi.Auth, error)
- func (s Session) AuthBySmsGetToken(phone, code string) (tdapi.Auth, error)
- func (s Session) AuthBySmsSendCode(phone string) (tdapi.SmsCode, error)
- func (s Session) Contacts(teamUid string) ([]tdproto.Contact, error)
- func (s *Session) Features() (*tdproto.Features, error)
- func (s Session) Me(teamUid string) (tdproto.Contact, error)
- func (s Session) Ping() error
- func (s *Session) SetCookie(v string)
- func (s *Session) SetToken(v string)
- func (s *Session) SetVerbose(v bool)
- func (s *Session) Ws(team string, onfail func(error)) (*WsSession, error)
- type WsSession
- func (w *WsSession) Close() error
- func (w *WsSession) DeleteMessage(uid string) string
- func (w *WsSession) Ping() string
- func (w *WsSession) Send(event tdproto.Event) string
- func (w *WsSession) SendPlainMessage(to tdproto.JID, text string) string
- func (w *WsSession) WaitFor(name string, v interface{}) error
- func (w *WsSession) WaitForConfirm() (string, error)
- func (w *WsSession) WaitForMessage() (tdproto.Message, bool, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var Timeout = errors.New("Timeout")
Functions ¶
This section is empty.
Types ¶
type Session ¶
func NewSession ¶
func (Session) AddContact ¶ added in v0.2.2
func (Session) AuthByPasswordGetToken ¶ added in v0.2.0
func (Session) AuthBySmsGetToken ¶ added in v0.2.0
func (Session) AuthBySmsSendCode ¶ added in v0.2.0
func (*Session) SetVerbose ¶ added in v0.1.8
type WsSession ¶ added in v0.1.4
type WsSession struct {
*Session
// contains filtered or unexported fields
}
func (*WsSession) DeleteMessage ¶ added in v0.1.4
func (*WsSession) SendPlainMessage ¶ added in v0.1.4
func (*WsSession) WaitForConfirm ¶ added in v0.1.4
Directories
¶
| Path | Synopsis |
|---|---|
|
contacts
command
|
|
|
echobot
command
|
|
|
message
command
|
|
|
passwordauth
command
|
|
|
serverinfo
command
|
|
|
smsauth
command
|
Click to show internal directories.
Click to hide internal directories.