Class: TelegramBotApi::Requests::SendMessage

Inherits:
Object
  • Object
show all
Includes:
Base
Defined in:
lib/telegram_bot_api/requests/send_message.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Base

included

Constructor Details

#initialize(arguments = {}) ⇒ SendMessage

Returns a new instance of SendMessage.



5
6
7
# File 'lib/telegram_bot_api/requests/send_message.rb', line 5

def initialize(arguments = {})
  build_arguments(arguments)
end

Class Method Details

.endpoint_urlObject



18
19
20
# File 'lib/telegram_bot_api/requests/send_message.rb', line 18

def endpoint_url
  'sendMessage'
end

.mandatory_argumentsObject



10
11
12
# File 'lib/telegram_bot_api/requests/send_message.rb', line 10

def mandatory_arguments
  %i(chat_id text)
end

.optional_argumentsObject



14
15
16
# File 'lib/telegram_bot_api/requests/send_message.rb', line 14

def optional_arguments
  %i(disable_web_page_preview reply_to_message_id reply_markup)
end

.verbObject



22
23
24
# File 'lib/telegram_bot_api/requests/send_message.rb', line 22

def verb
  :post
end