tclient

package
v0.1.25 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2025 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AppBuiltin = "builtin"
	AppDesktop = "desktop"
)

Variables

View Source
var Apps = map[string]App{

	AppBuiltin: {AppID: viper.GetInt(consts.FlagAppID), AppHash: viper.GetString(consts.FlagAppHash)},

	AppDesktop: {AppID: 2040, AppHash: "b18441a1ff607e10a989891a5462e627"},
}

Functions

func New

func New(ctx context.Context, o Options, login bool, middlewares ...telegram.Middleware) (*telegram.Client, error)

Types

type App

type App struct {
	AppID   int
	AppHash string
}

func GetApp

func GetApp(kv storage.Storage) (App, error)

type Options

type Options struct {
	KV               storage.Storage
	Proxy            string
	NTP              string
	ReconnectTimeout time.Duration
	UpdateHandler    telegram.UpdateHandler
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL