我想用python代码来管理我的群组呼叫。首先,我必须自动加入群组呼叫,但我应该在InputGroupCall中放入什么作为参数?
from telethon.sync import TelegramClient
from telethon import functions, types
with TelegramClient(name, api_id, api_hash) as client:
result = client.invoke(functions.phone.JoinGroupCallRequest(
call=types.InputGroupCall(
id=0, # What should I put here?
access_hash=0, # What should I put here?
),
join_as='My_name',
params=types.DataJSON(
data='What should I put here?'
),
muted=True,
video_stopped=True,
))发布于 2021-08-31 08:36:52
Params是WebRTC部件的有效负载。所以你可以试着伪造它,但你会因为不活动而断开连接(因为你需要发送音频/视频数据)。另一种方式是使用WebRTC客户端进行电报组呼叫的加入。加入后,您可以使用与群组调用相关的其他MTProto方法。
你可以在这里找到电报的WebRTC客户端:https://github.com/MarshalX/tgcalls。它适用于Telethon和Pyrogram。
https://stackoverflow.com/questions/68994733
复制相似问题