Module: TeleRb::MediaMethods
- Included in:
- TelegramBot
- Defined in:
- lib/telerb/methods/media_methods.rb
Overview
Message Methods
Instance Method Summary collapse
- #send_audio(chat_id, audio_path, caption = nil, reply_to_message_id = nil) ⇒ Object
- #send_document(chat_id, document_path, caption = nil, reply_to_message_id = nil) ⇒ Object
- #send_photo(chat_id, photo_path, caption = nil, reply_to_message_id = nil) ⇒ Object
- #send_sticker(chat_id, sticker_path, reply_to_message_id = nil) ⇒ Object
- #send_video(chat_id, video_path, caption = nil, reply_to_message_id = nil) ⇒ Object
Instance Method Details
#send_audio(chat_id, audio_path, caption = nil, reply_to_message_id = nil) ⇒ Object
10 11 12 |
# File 'lib/telerb/methods/media_methods.rb', line 10 def send_audio(chat_id, audio_path, caption = nil, = nil) send_media(chat_id, audio_path, caption, , "sendAudio", :audio) end |
#send_document(chat_id, document_path, caption = nil, reply_to_message_id = nil) ⇒ Object
18 19 20 |
# File 'lib/telerb/methods/media_methods.rb', line 18 def send_document(chat_id, document_path, caption = nil, = nil) send_media(chat_id, document_path, caption, , "sendDocument", :document) end |
#send_photo(chat_id, photo_path, caption = nil, reply_to_message_id = nil) ⇒ Object
6 7 8 |
# File 'lib/telerb/methods/media_methods.rb', line 6 def send_photo(chat_id, photo_path, caption = nil, = nil) send_media(chat_id, photo_path, caption, , "sendPhoto", :photo) end |
#send_sticker(chat_id, sticker_path, reply_to_message_id = nil) ⇒ Object
22 23 24 |
# File 'lib/telerb/methods/media_methods.rb', line 22 def send_sticker(chat_id, sticker_path, = nil) send_media(chat_id, sticker_path, , "sendSticker", :sticker) end |
#send_video(chat_id, video_path, caption = nil, reply_to_message_id = nil) ⇒ Object
14 15 16 |
# File 'lib/telerb/methods/media_methods.rb', line 14 def send_video(chat_id, video_path, caption = nil, = nil) send_media(chat_id, video_path, caption, , "sendVideo", :video) end |