Gogram TL Reference

Complete documentation for Telegram's Type Language (TL) Schema, optimized for Gogram development.

Layer 228
1642 Constructors
768 Methods
Errors Reference → E2E Schema →

About TL Types

The Type Language (TL) is a schema language used by Telegram to define its API. It describes constructors (data types) and methods (API calls) that form the MTProto protocol.

In Gogram, each TL constructor is represented as a Go struct in the telegram package. For example, inputMediaPhoto becomes telegram.InputMediaPhoto.

Types are abstract interfaces that can be implemented by multiple constructors. For instance, InputMedia is implemented by InputMediaPhoto, InputMediaDocument, and others.