Versions in this module Expand all Collapse all v1 v1.1.3 Jul 20, 2026 v1.1.2 Jul 20, 2026 v1.1.1 Jul 19, 2026 v1.1.0 Jul 16, 2026 v1.0.0 Jul 14, 2026 Changes in this version + var ErrLocalStorageIsNotAvailable = errors.New("localStorage is not available") — js/wasm + var ErrNotFound = errors.New("session storage: not found") + type Config struct + BlockedMode bool + DCOptions []tg.DCOption + DCTxtDomainName string + Date int + Expires int + ForceTryIpv6 bool + TestMode bool + ThisDC int + TmpSessions int + WebfileDCID int + func ConfigFromTG(c tg.Config) Config + func (c Config) TG() tg.Config + type Data struct + Addr string + AuthKey []byte + AuthKeyID []byte + Config Config + DC int + Salt int64 + func TDesktopSession(account tdesktop.Account) (*Data, error) + func TelethonSession(hx string) (*Data, error) + type FileStorage struct + Path string + func (f *FileStorage) LoadSession(_ context.Context) ([]byte, error) + func (f *FileStorage) StoreSession(_ context.Context, data []byte) error + type Loader struct + Storage Storage + func (l *Loader) Load(ctx context.Context) (*Data, error) + func (l *Loader) Save(ctx context.Context, data *Data) error + type Storage interface + LoadSession func(ctx context.Context) ([]byte, error) + StoreSession func(ctx context.Context, data []byte) error + type StorageMemory struct + func (s *StorageMemory) Bytes(to []byte) ([]byte, error) + func (s *StorageMemory) Clone() *StorageMemory + func (s *StorageMemory) Dump(w io.Writer) error + func (s *StorageMemory) LoadSession(context.Context) ([]byte, error) + func (s *StorageMemory) StoreSession(ctx context.Context, data []byte) error + func (s *StorageMemory) WriteFile(name string, perm os.FileMode) error + type WebLocalStorage struct — js/wasm + Key string + func (w WebLocalStorage) LoadSession(_ context.Context) (_ []byte, rerr error) + func (w WebLocalStorage) StoreSession(_ context.Context, data []byte) (rerr error) v0 v0.159.1-multilayer.1 Jul 14, 2026