bff.bff 是 Telegram RPC 的主要实现层。它本质上是一个 go-zero zrpc gRPC server,注册了多个 mtproto.RegisterRPCxxxServer。
modulehandlers说明account8账户TTL/换手机号/删除账户authorization29登录/注册/二步验证/邮箱验证autodownload2自动下载设置chatinvites14聊天邀请链接/加群请求chats23群组管理/创建/迁移/管理员configuration11帮助/配置/国家列表/更新检查contacts23联系人管理/搜索/屏蔽/导入dialogs15对话列表/置顶/标记未读/输入状态drafts3消息草稿files12文件上传/下载/CDNmessages33消息发送/编辑/删除/搜索/转发/置顶miscellaneous2测试/日志notification7通知设置/设备注册nsfw2内容设置passkey6Passkey 认证passport11Telegram Passportpremium5Premium/支付privacysettings8隐私设置/全局隐私qrcode3QR 码登录savedmessagedialogs9保存的消息对话sponsoredmessages11赞助消息tos2服务条款updates3获取状态/差异/频道差异userchannelprofiles18用户资料/头像/频道资料usernames5用户名管理users4用户查询
auth.sendCode 的 handler 展示 BFF 的典型模式:
常见错误(TL/协议层):
app/bff/<module>/internal/core/*_handler.goapp/bff/bff/internal/server/server.goteamgramd/etc/bff.yaml