1
0
mirror of https://github.com/eternnoir/pyTelegramBotAPI.git synced 2023-08-10 21:12:57 +03:00

Update readme.

This commit is contained in:
eternnoir 2015-08-21 23:09:35 +08:00
parent ee4061561e
commit 645270861c

View File

@ -108,11 +108,19 @@ file_id = 'AAAaaaZZZzzz'
tb.send_photo(chat_id, file_id) tb.send_photo(chat_id, file_id)
# sendAudio # sendAudio
audio = open('/tmp/audio.ogg', 'rb') audio = open('/tmp/audio.mp3', 'rb')
tb.send_audio(chat_id, audio) tb.send_audio(chat_id, audio)
## sendAudio with duration, performer and title.
tb.send_audio(CHAT_ID, file_data, 1, 'eternnoir', 'pyTelegram')
file_id = 'AAAaaaZZZzzz' file_id = 'AAAaaaZZZzzz'
tb.send_audio(chat_id, file_id) tb.send_audio(chat_id, file_id)
# sendVoice
voice = open('/tmp/voice.ogg', 'rb')
tb.send_voice(chat_id, voice)
file_id = 'AAAaaaZZZzzz'
tb.send_voice(chat_id, file_id)
# sendDocument # sendDocument
doc = open('/tmp/file.txt', 'rb') doc = open('/tmp/file.txt', 'rb')
tb.send_document(chat_id, doc) tb.send_document(chat_id, doc)