Class: TelegramConfig
- Inherits:
-
Object
- Object
- TelegramConfig
- Defined in:
- lib/telerb/telegram_config.rb
Overview
Telegram config
Instance Attribute Summary collapse
-
#offset ⇒ Object
Returns the value of attribute offset.
Instance Method Summary collapse
- #base_uri(method) ⇒ Object
-
#initialize(token) ⇒ TelegramConfig
constructor
A new instance of TelegramConfig.
Constructor Details
#initialize(token) ⇒ TelegramConfig
Returns a new instance of TelegramConfig.
7 8 9 10 |
# File 'lib/telerb/telegram_config.rb', line 7 def initialize(token) @offset = nil @token = token end |
Instance Attribute Details
#offset ⇒ Object
Returns the value of attribute offset.
5 6 7 |
# File 'lib/telerb/telegram_config.rb', line 5 def offset @offset end |
Instance Method Details
#base_uri(method) ⇒ Object
12 13 14 |
# File 'lib/telerb/telegram_config.rb', line 12 def base_uri(method) "https://api.telegram.org/bot#{@token}/#{method}" end |