Class: ChatbotHelper::Telegram::Update
- Inherits:
-
BaseResource
- Object
- BaseResource
- ChatbotHelper::Telegram::Update
- Defined in:
- lib/chatbot_helper/telegram/update.rb
Overview
The update resource which represents a Telegram bot API update
Instance Attribute Summary
Attributes inherited from BaseResource
Class Method Summary collapse
Methods inherited from BaseResource
#==, #initialize, optional_arrays, optional_fields, required_arrays, required_objects, #to_s, valid_resource!, valid_resource?
Constructor Details
This class inherits a constructor from ChatbotHelper::Telegram::BaseResource
Class Method Details
.optional_objects ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/chatbot_helper/telegram/update.rb', line 10 def optional_objects [ { name: 'message', type: ChatbotHelper::Telegram::Message }, { name: 'edited_message', type: ChatbotHelper::Telegram::Message }, { name: 'channel_post', type: ChatbotHelper::Telegram::Message }, { name: 'edited_channel_post', type: ChatbotHelper::Telegram::Message }, { name: 'inline_query', type: ChatbotHelper::Telegram::InlineQuery }, { name: 'chosen_inline_result', type: ChatbotHelper::Telegram::ChosenInlineResult }, { name: 'callback_query', type: ChatbotHelper::Telegram::CallbackQuery } ] end |
.required_fields ⇒ Object
6 7 8 |
# File 'lib/chatbot_helper/telegram/update.rb', line 6 def required_fields %w[update_id] end |