sportradar-api 0.13.24 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/Gemfile.lock +6 -6
- data/lib/sportradar/api/images.rb +11 -7
- data/lib/sportradar/api/soccer/player.rb +8 -0
- data/lib/sportradar/api/soccer/team.rb +3 -0
- data/lib/sportradar/api/version.rb +1 -1
- data/lib/sportradar/api.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
|
-
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 33784418fb807e49dedec710bc4d07e22165615929f5b379e5b75da16f7a474c
|
|
4
|
+
data.tar.gz: '09071e245846662f1f9f60297fdfac12690746040d8e93705be21bba543f583c'
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b6aa4fc6699921922fc84be63de15569e658baac30506093fe7e250844f51908657e859e70404b55cfe0c8362d945ec19cc5b2c1df3a74711ded681efefea994
|
|
7
|
+
data.tar.gz: d882cba949755f62c7e3885ca8683866e19f59c3fc9c6fd4bf34e95cdd205f1323130f4b6c0d203c96e43ac3e74bf3b44bd2b439ba6753a431712ef151e9a1dd
|
data/Gemfile.lock
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
sportradar-api (0.
|
|
4
|
+
sportradar-api (0.14.0)
|
|
5
5
|
activesupport
|
|
6
6
|
httparty (>= 0.14.0)
|
|
7
7
|
|
|
8
8
|
GEM
|
|
9
9
|
remote: https://rubygems.org/
|
|
10
10
|
specs:
|
|
11
|
-
activesupport (5.1
|
|
11
|
+
activesupport (5.2.1)
|
|
12
12
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
13
|
-
i18n (
|
|
13
|
+
i18n (>= 0.7, < 2)
|
|
14
14
|
minitest (~> 5.1)
|
|
15
15
|
tzinfo (~> 1.1)
|
|
16
16
|
addressable (2.5.1)
|
|
@@ -45,9 +45,9 @@ GEM
|
|
|
45
45
|
guard-compat (~> 1.2)
|
|
46
46
|
minitest (>= 3.0)
|
|
47
47
|
hashdiff (0.3.4)
|
|
48
|
-
httparty (0.
|
|
48
|
+
httparty (0.16.2)
|
|
49
49
|
multi_xml (>= 0.5.2)
|
|
50
|
-
i18n (
|
|
50
|
+
i18n (1.1.0)
|
|
51
51
|
concurrent-ruby (~> 1.0)
|
|
52
52
|
json (2.1.0)
|
|
53
53
|
listen (3.1.5)
|
|
@@ -115,4 +115,4 @@ DEPENDENCIES
|
|
|
115
115
|
webmock
|
|
116
116
|
|
|
117
117
|
BUNDLED WITH
|
|
118
|
-
1.
|
|
118
|
+
1.16.3
|
|
@@ -23,7 +23,8 @@ module Sportradar
|
|
|
23
23
|
else
|
|
24
24
|
response = get request_url("#{league}/#{image_type}/players/manifest")
|
|
25
25
|
end
|
|
26
|
-
elsif nfl_premium || usat_premium || sport == 'ncaafb'
|
|
26
|
+
elsif nfl_premium || usat_premium || sport == 'ncaafb' || sport == 'nba'
|
|
27
|
+
year = Date.today.month < 8 ? Date.today.year - 1 : Date.today
|
|
27
28
|
response = get request_url("#{image_type}/players/#{year}/manifest")
|
|
28
29
|
else
|
|
29
30
|
response = get request_url("players/#{image_type}/manifests/all_assets")
|
|
@@ -136,6 +137,8 @@ module Sportradar
|
|
|
136
137
|
'ap_premium'
|
|
137
138
|
elsif usat_premium
|
|
138
139
|
'usat_premium'
|
|
140
|
+
elsif sport == 'nba'
|
|
141
|
+
'getty_premium'
|
|
139
142
|
else
|
|
140
143
|
'usat'
|
|
141
144
|
# REUTERS IS JUST FOR SOCCER sport == 'mlb' ? 'usat' : 'reuters'
|
|
@@ -143,11 +146,12 @@ module Sportradar
|
|
|
143
146
|
end
|
|
144
147
|
|
|
145
148
|
def version
|
|
146
|
-
if uses_v3_api? || nfl_premium || usat_premium
|
|
147
|
-
|
|
148
|
-
elsif uses_v2_api?
|
|
149
|
-
|
|
150
|
-
end
|
|
149
|
+
# if uses_v3_api? || nfl_premium || usat_premium || sport == 'nba'
|
|
150
|
+
# 3
|
|
151
|
+
# elsif uses_v2_api?
|
|
152
|
+
# Sportradar::Api.version('images')
|
|
153
|
+
# end
|
|
154
|
+
3
|
|
151
155
|
end
|
|
152
156
|
|
|
153
157
|
def image_type
|
|
@@ -175,7 +179,7 @@ module Sportradar
|
|
|
175
179
|
end
|
|
176
180
|
|
|
177
181
|
def v3_api_sports
|
|
178
|
-
['mlb', 'soccer', 'cricket', 'f1', 'rugby', 'tennis', 'ncaafb',
|
|
182
|
+
['mlb', 'soccer', 'cricket', 'f1', 'rugby', 'tennis', 'ncaafb', 'nba' ]
|
|
179
183
|
end
|
|
180
184
|
|
|
181
185
|
def soccer_leagues
|
data/lib/sportradar/api.rb
CHANGED
|
@@ -60,7 +60,7 @@ module Sportradar
|
|
|
60
60
|
{api: :nascar, version: 3},
|
|
61
61
|
{api: :odds, version: 1},
|
|
62
62
|
{api: :content, version: 3},
|
|
63
|
-
{api: :images, version:
|
|
63
|
+
{api: :images, version: 3},
|
|
64
64
|
{api: :live_images, version: 1},
|
|
65
65
|
{api: :olympics, version: 2},
|
|
66
66
|
{api: :soccer, version: 3},
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: sportradar-api
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.14.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ben Eggett
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-
|
|
11
|
+
date: 2018-08-23 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|
|
@@ -471,7 +471,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
471
471
|
version: '0'
|
|
472
472
|
requirements: []
|
|
473
473
|
rubyforge_project:
|
|
474
|
-
rubygems_version: 2.6
|
|
474
|
+
rubygems_version: 2.7.6
|
|
475
475
|
signing_key:
|
|
476
476
|
specification_version: 4
|
|
477
477
|
summary: Sportradar API client
|