MCPcopy Create free account
hub / github.com/eternnoir/pyTelegramBotAPI / chatting

Function chatting

examples/anonymous_bot.py:111–115  ·  view source on GitHub ↗
(message: types.Message)

Source from the content-addressed store, hash-verified

109# 2. Is there any way to register this message handler only when i found the opponent?
110@bot.message_handler(content_types=['animation', 'audio', 'contact', 'dice', 'document', 'location', 'photo', 'poll', 'sticker', 'text', 'venue', 'video', 'video_note', 'voice'])
111def chatting(message: types.Message):
112 if message.chat.id in users:
113 bot.copy_message(users[message.chat.id], users[users[message.chat.id]], message.id)
114 else:
115 bot.send_message(message.chat.id, 'No one can hear you...')
116
117bot.infinity_polling(skip_pending=True)

Callers

nothing calls this directly

Calls 2

copy_messageMethod · 0.45
send_messageMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…