td
td copied to clipboard
Telegram client, in Go. (MTProto API)
### Description latest version gotd need socks5 and mtproxy. ### References no
```go // ExportedChatInviteClass represents ExportedChatInvite generic type. // // See https://core.telegram.org/type/ExportedChatInvite for reference. // // Example: // g, err := tg.DecodeExportedChatInvite(buf) // if err != nil { // panic(err) //...
For now, `gotd` have a lot badly documented features and helpers, like `uploader` package.
### What version of gotd are you using? `github.com/gotd/td v0.56.0` ### Can this issue be reproduced with the latest version? Yes I think ### What did you do? I have...
Currently 2FA password is passed as string, which is [not fully safe](https://stackoverflow.com/questions/39968084/is-it-possible-to-zero-a-golang-strings-memory-safely), because we can't reliably perform memory zeroing and ensure that it is not stored in memory more than...
Telegram API has some methods like [`channels.getMessages`](https://core.telegram.org/method/channels.getMessages) or [`users.getUsers`](https://core.telegram.org/method/users.getUsers) which is designed to request object by ID, unlike pagination methods. It would be nice to add helpers for this methods,...
go version: go version go1.17.2 darwin/amd64 td version: v0.55.2 ```go // Binary bg-run implements alternative to Run pattern. package main import ( "context" "fmt" "time" "go.uber.org/zap" "github.com/gotd/contrib/bg" "github.com/gotd/td/examples" "github.com/gotd/td/telegram" )...
My test Code ``` func main() { // Environment variables: examples.Run(func(ctx context.Context, log *zap.Logger) error { // Dispatcher handles incoming updates. dispatcher := tg.NewUpdateDispatcher() opts := telegram.Options{ Logger: log, UpdateHandler:...
We can generate resolve helpers to be able to use ```go query.NewQuery(raw).Messages().GetHistory(peer.Resolve("domain")).ForEach(ctx, cb) ``` instead of ```go peer, err := peer.Resolve(r, "domain")(ctx) if err != nil { .... } query.NewQuery(raw).Messages().GetHistory(peer).ForEach(ctx,...