telegram-bot-ruby 0.5.3 → 0.6.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4f7c6e57a1156c438d89b0854198070f9f41c25e
4
- data.tar.gz: 50b5d4f341ccd2615483dd3148cfb3a745639666
3
+ metadata.gz: 668a55980427b870e1b3d632d7b1a97dad6f3943
4
+ data.tar.gz: a71056d94620753d77fba50f6944a7c3d090d5a2
5
5
  SHA512:
6
- metadata.gz: 961f32bdc285f7dab980a317e44fa74f840d6174023caca66fe6b419dc0405ffad402d000f18d2ae273de3419655aba207afdfef7bb7f7d61239afb1ad598b87
7
- data.tar.gz: 8c04a6dd381cb72c30bad09e66233e87c6ed959e05f0df0cdc45a86805d0b7def20f7a7587cca2475ad427e8a0e4dd7c1df3a0d5162e9b0d2822e7cf2c18d316
6
+ metadata.gz: 361cb8a4145448625cb3b4b6aaeba1aa108d41e79710e48972c14bc640ec92ea9ca4cd66b5c1672c467a4f316acd4bb187ce07f82ff8d74de150f5318259a61f
7
+ data.tar.gz: bba7d2ba16b9c29c4d3364e3a6d474de9ea25a7b20e2ae8807ed1ff4eeffab356ee9c10ffdb5c8a48ad57607773f1018848cdce53f3ea70ccc6c3ba66ae3c3e7
data/.travis.yml CHANGED
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  language: ruby
3
3
  rvm:
4
- - 1.9.3
5
4
  - 2.3.0
6
5
  before_install:
7
6
  - gem install bundler
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.6.0
4
+
5
+ - Implement Bot API changes (October 3, 2016 API update)
6
+
3
7
  ## 0.5.2
4
8
 
5
9
  - Implement Bot API 2.1 changes
@@ -8,6 +8,7 @@ module Telegram
8
8
  kickChatMember unbanChatMember answerCallbackQuery editMessageText
9
9
  editMessageCaption editMessageReplyMarkup answerInlineQuery getChat
10
10
  leaveChat getChatAdministrators getChatMember getChatMembersCount
11
+ sendGame setGameScore getGameHighScores getWebhookInfo
11
12
  ).freeze
12
13
  REPLY_MARKUP_TYPES = [
13
14
  Telegram::Bot::Types::ReplyKeyboardMarkup,
@@ -11,6 +11,10 @@ require 'telegram/bot/types/location'
11
11
  require 'telegram/bot/types/chat'
12
12
  require 'telegram/bot/types/message_entity'
13
13
  require 'telegram/bot/types/venue'
14
+ require 'telegram/bot/types/animation'
15
+ require 'telegram/bot/types/game'
16
+ require 'telegram/bot/types/callback_game'
17
+ require 'telegram/bot/types/game_high_score'
14
18
  require 'telegram/bot/types/message'
15
19
  require 'telegram/bot/types/input_message_content'
16
20
  require 'telegram/bot/types/input_contact_message_content'
@@ -31,6 +35,7 @@ require 'telegram/bot/types/inline_query_result_cached_sticker'
31
35
  require 'telegram/bot/types/inline_query_result_cached_video'
32
36
  require 'telegram/bot/types/inline_query_result_cached_voice'
33
37
  require 'telegram/bot/types/inline_query_result_contact'
38
+ require 'telegram/bot/types/inline_query_result_game'
34
39
  require 'telegram/bot/types/inline_query_result_document'
35
40
  require 'telegram/bot/types/inline_query_result_gif'
36
41
  require 'telegram/bot/types/inline_query_result_location'
@@ -0,0 +1,13 @@
1
+ module Telegram
2
+ module Bot
3
+ module Types
4
+ class Animation < Base
5
+ attribute :file_id, String
6
+ attribute :thumb, PhotoSize
7
+ attribute :file_name, String
8
+ attribute :mime_type, String
9
+ attribute :file_size, Integer
10
+ end
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,8 @@
1
+ module Telegram
2
+ module Bot
3
+ module Types
4
+ class CallbackGame < Base
5
+ end
6
+ end
7
+ end
8
+ end
@@ -6,7 +6,9 @@ module Telegram
6
6
  attribute :from, User
7
7
  attribute :message, Message
8
8
  attribute :inline_message_id, String
9
+ attribute :chat_instance, String
9
10
  attribute :data, String
11
+ attribute :game_short_name, String
10
12
  end
11
13
  end
12
14
  end
@@ -8,6 +8,7 @@ module Telegram
8
8
  attribute :username, String
9
9
  attribute :first_name, String
10
10
  attribute :last_name, String
11
+ attribute :all_members_are_admins, Boolean
11
12
  end
12
13
  end
13
14
  end
@@ -0,0 +1,14 @@
1
+ module Telegram
2
+ module Bot
3
+ module Types
4
+ class Game < Base
5
+ attribute :title, String
6
+ attribute :description, String
7
+ attribute :photo, Array[PhotoSize]
8
+ attribute :text, String
9
+ attribute :text_entities, Array[MessageEntity]
10
+ attribute :animation, Animation
11
+ end
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,11 @@
1
+ module Telegram
2
+ module Bot
3
+ module Types
4
+ class GameHighScore < Base
5
+ attribute :position, Integer
6
+ attribute :user, User
7
+ attribute :score, Integer
8
+ end
9
+ end
10
+ end
11
+ end
@@ -6,6 +6,8 @@ module Telegram
6
6
  attribute :url, String
7
7
  attribute :callback_data, String
8
8
  attribute :switch_inline_query, String
9
+ attribute :switch_inline_query_current_chat, String
10
+ attribute :callback_game, CallbackGame
9
11
  end
10
12
  end
11
13
  end
@@ -6,6 +6,7 @@ module Telegram
6
6
  attribute :id, String
7
7
  attribute :audio_url, String
8
8
  attribute :title, String
9
+ attribute :caption, String
9
10
  attribute :performer, String
10
11
  attribute :audio_duration, Integer
11
12
  attribute :reply_markup, InlineKeyboardMarkup
@@ -5,6 +5,7 @@ module Telegram
5
5
  attribute :type, String, default: 'audio'
6
6
  attribute :id, String
7
7
  attribute :audio_file_id, String
8
+ attribute :caption, String
8
9
  attribute :reply_markup, InlineKeyboardMarkup
9
10
  attribute :input_message_content, InputMessageContent
10
11
  end
@@ -6,6 +6,7 @@ module Telegram
6
6
  attribute :id, String
7
7
  attribute :voice_file_id, String
8
8
  attribute :title, String
9
+ attribute :caption, String
9
10
  attribute :reply_markup, InlineKeyboardMarkup
10
11
  attribute :input_message_content, InputMessageContent
11
12
  end
@@ -0,0 +1,12 @@
1
+ module Telegram
2
+ module Bot
3
+ module Types
4
+ class InlineQueryResultGame < Base
5
+ attribute :type, String, default: 'game'
6
+ attribute :id, String
7
+ attribute :game_short_name, String
8
+ attribute :reply_markup, InlineKeyboardMarkup
9
+ end
10
+ end
11
+ end
12
+ end
@@ -6,6 +6,7 @@ module Telegram
6
6
  attribute :id, String
7
7
  attribute :voice_url, String
8
8
  attribute :title, String
9
+ attribute :caption, String
9
10
  attribute :voice_duration, Integer
10
11
  attribute :reply_markup, InlineKeyboardMarkup
11
12
  attribute :input_message_content, InputMessageContent
@@ -15,6 +15,7 @@ module Telegram
15
15
  attribute :entities, Array[MessageEntity]
16
16
  attribute :audio, Audio
17
17
  attribute :document, Document
18
+ attribute :game, Game
18
19
  attribute :photo, Array[PhotoSize]
19
20
  attribute :sticker, Sticker
20
21
  attribute :video, Video
@@ -1,5 +1,5 @@
1
1
  module Telegram
2
2
  module Bot
3
- VERSION = '0.5.3'.freeze
3
+ VERSION = '0.6.0.1'.freeze
4
4
  end
5
5
  end
@@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
23
23
  spec.add_development_dependency 'bundler', '~> 1.9'
24
24
  spec.add_development_dependency 'rake', '~> 10.0'
25
25
  spec.add_development_dependency 'pry'
26
- spec.add_development_dependency 'rubocop'
26
+ spec.add_development_dependency 'rubocop', '~> 0.42.0'
27
27
  spec.add_development_dependency 'rspec', '~> 3.4'
28
28
  spec.add_development_dependency 'rubocop-rspec', '~> 1.4'
29
29
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: telegram-bot-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.3
4
+ version: 0.6.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexander Tipugin
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-15 00:00:00.000000000 Z
11
+ date: 2016-10-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -84,16 +84,16 @@ dependencies:
84
84
  name: rubocop
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - ">="
87
+ - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: '0'
89
+ version: 0.42.0
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - ">="
94
+ - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: '0'
96
+ version: 0.42.0
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: rspec
99
99
  requirement: !ruby/object:Gem::Requirement
@@ -152,8 +152,10 @@ files:
152
152
  - lib/telegram/bot/exceptions/response_error.rb
153
153
  - lib/telegram/bot/null_logger.rb
154
154
  - lib/telegram/bot/types.rb
155
+ - lib/telegram/bot/types/animation.rb
155
156
  - lib/telegram/bot/types/audio.rb
156
157
  - lib/telegram/bot/types/base.rb
158
+ - lib/telegram/bot/types/callback_game.rb
157
159
  - lib/telegram/bot/types/callback_query.rb
158
160
  - lib/telegram/bot/types/chat.rb
159
161
  - lib/telegram/bot/types/chosen_inline_result.rb
@@ -161,6 +163,8 @@ files:
161
163
  - lib/telegram/bot/types/document.rb
162
164
  - lib/telegram/bot/types/file.rb
163
165
  - lib/telegram/bot/types/force_reply.rb
166
+ - lib/telegram/bot/types/game.rb
167
+ - lib/telegram/bot/types/game_high_score.rb
164
168
  - lib/telegram/bot/types/inline_keyboard_button.rb
165
169
  - lib/telegram/bot/types/inline_keyboard_markup.rb
166
170
  - lib/telegram/bot/types/inline_query.rb
@@ -176,6 +180,7 @@ files:
176
180
  - lib/telegram/bot/types/inline_query_result_cached_voice.rb
177
181
  - lib/telegram/bot/types/inline_query_result_contact.rb
178
182
  - lib/telegram/bot/types/inline_query_result_document.rb
183
+ - lib/telegram/bot/types/inline_query_result_game.rb
179
184
  - lib/telegram/bot/types/inline_query_result_gif.rb
180
185
  - lib/telegram/bot/types/inline_query_result_location.rb
181
186
  - lib/telegram/bot/types/inline_query_result_mpeg4_gif.rb