https://github.com/gotd/getdoc
Telegram documentation parser
https://github.com/gotd/getdoc
Last synced: 5 months ago
JSON representation
Telegram documentation parser
- Host: GitHub
- URL: https://github.com/gotd/getdoc
- Owner: gotd
- License: mit
- Created: 2020-12-04T22:03:27.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2025-12-04T04:03:06.000Z (7 months ago)
- Last Synced: 2025-12-07T10:15:08.825Z (7 months ago)
- Language: HTML
- Size: 16.7 MB
- Stars: 8
- Watchers: 1
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Security: .github/SECURITY.md
- Support: .github/SUPPORT.md
Awesome Lists containing this project
README
# getdoc
Documentation extract utilities for Telegram schema using [goquery](https://github.com/PuerkitoBio/goquery).
Used by [gotd/td](https://github.com/gotd/td) for embedding documentation to generated code.
## Parsed documentation
Parsed documentation for 133 layer is available as [133.json](./_schema/133.json) with [schema](./_schema/schema.json).
## Example
Latest schema is embedded to package, so you can just use it:
```go
doc, err := getdoc.Load(133)
if err != nil {
panic(err)
}
fmt.Printf("Layer %d, constructors: %d\n", doc.Index.Layer, len(doc.Constructors))
// Output:
// Layer 133, constructors: 926
```
## Reference
Please use [official documentation](https://core.telegram.org/schema), it is for humans,
this package is not.