opta_sd 1.0.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.
Files changed (49) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +1 -0
  3. data/.rspec +3 -0
  4. data/Gemfile +22 -0
  5. data/Gemfile.lock +63 -0
  6. data/MIT-LICENSE +20 -0
  7. data/README.md +400 -0
  8. data/Rakefile +1 -0
  9. data/config/opta_sd.yml +2 -0
  10. data/config/parameters.yml +74 -0
  11. data/errors.yml +21 -0
  12. data/lib/opta_sd.rb +42 -0
  13. data/lib/opta_sd/core.rb +119 -0
  14. data/lib/opta_sd/error.rb +31 -0
  15. data/lib/opta_sd/soccer/commentary.rb +21 -0
  16. data/lib/opta_sd/soccer/match.rb +20 -0
  17. data/lib/opta_sd/soccer/match_event.rb +13 -0
  18. data/lib/opta_sd/soccer/match_facts.rb +14 -0
  19. data/lib/opta_sd/soccer/match_preview.rb +14 -0
  20. data/lib/opta_sd/soccer/match_statistics.rb +14 -0
  21. data/lib/opta_sd/soccer/pass_matrix.rb +14 -0
  22. data/lib/opta_sd/soccer/player_career.rb +15 -0
  23. data/lib/opta_sd/soccer/possession.rb +13 -0
  24. data/lib/opta_sd/soccer/rankings.rb +14 -0
  25. data/lib/opta_sd/soccer/seasonal_stats.rb +14 -0
  26. data/lib/opta_sd/soccer/soccer.rb +19 -0
  27. data/lib/opta_sd/soccer/squads.rb +14 -0
  28. data/lib/opta_sd/soccer/team_standings.rb +22 -0
  29. data/lib/opta_sd/soccer/tournament_calendar.rb +24 -0
  30. data/lib/opta_sd/soccer/tournament_schedule.rb +14 -0
  31. data/lib/opta_sd/version.rb +3 -0
  32. data/opta_sd.gemspec +27 -0
  33. data/spec/commentary_spec.rb +39 -0
  34. data/spec/match_event_spec.rb +26 -0
  35. data/spec/match_facts_spec.rb +14 -0
  36. data/spec/match_preview_spec.rb +15 -0
  37. data/spec/match_spec.rb +32 -0
  38. data/spec/match_statistics_spec.rb +43 -0
  39. data/spec/pass_matrix_spec.rb +27 -0
  40. data/spec/player_career_spec.rb +38 -0
  41. data/spec/possession_spec.rb +23 -0
  42. data/spec/rankings_spec.rb +14 -0
  43. data/spec/seasonal_stats_spec.rb +26 -0
  44. data/spec/spec_helper.rb +15 -0
  45. data/spec/squads.rb +40 -0
  46. data/spec/team_standings_spec.rb +61 -0
  47. data/spec/tournament_schedule_spec.rb +13 -0
  48. data/spec/tournament_spec.rb +48 -0
  49. metadata +169 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 847ce22203095424651f83675de69d9ffb5fa385
4
+ data.tar.gz: 8f039445d073795f3c53aa6220b97b7b88935cfa
5
+ SHA512:
6
+ metadata.gz: 587284cea05cece9d49e277f6cad246ad1e3f89ae7e992e4cd0f3e52404dcd0cf7bf042b9b74093378c96a64d32bca686af88934408798b9fda68dcc4f6ca73b
7
+ data.tar.gz: 87753fa9c9992f71b40834e9ffa6c54bdc85cad378adb10c938245768ebad68ae81f2a81467ad90b9d8fa6fba1cc6d036a153c382eee2f35e75a20e01da5f1fc
@@ -0,0 +1 @@
1
+ .byebug_history
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --color
2
+ --require spec_helper
3
+ --format documentation
data/Gemfile ADDED
@@ -0,0 +1,22 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Declare your gem's dependencies in opta_sd_api.gemspec.
4
+ # Bundler will treat runtime dependencies like base dependencies, and
5
+ # development dependencies will be added by default to the :development group.
6
+ gemspec
7
+
8
+ # Declare any dependencies that are still in development here instead of in
9
+ # your gemspec. These might include edge Rails or gems from your path or
10
+ # Git. Remember to move these dependencies to your gemspec before releasing
11
+ # your gem to rubygems.org.
12
+
13
+ gem 'activesupport'
14
+
15
+ gem 'nokogiri', '~> 1.7', '>= 1.7.0.1'
16
+
17
+ group :development, :test do
18
+ # To use a debugger
19
+ gem 'byebug'
20
+ gem 'pry'
21
+ gem 'rspec'
22
+ end
@@ -0,0 +1,63 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ opta_sd (1.0.0)
5
+ bundler
6
+ json
7
+ nokogiri (~> 1.7, >= 1.7.0.1)
8
+ rspec (~> 3.5)
9
+
10
+ GEM
11
+ remote: https://rubygems.org/
12
+ specs:
13
+ activesupport (5.0.1)
14
+ concurrent-ruby (~> 1.0, >= 1.0.2)
15
+ i18n (~> 0.7)
16
+ minitest (~> 5.1)
17
+ tzinfo (~> 1.1)
18
+ byebug (9.0.6)
19
+ coderay (1.1.1)
20
+ concurrent-ruby (1.0.4)
21
+ diff-lcs (1.3)
22
+ i18n (0.8.0)
23
+ json (2.0.3)
24
+ method_source (0.8.2)
25
+ mini_portile2 (2.1.0)
26
+ minitest (5.10.1)
27
+ nokogiri (1.7.0.1)
28
+ mini_portile2 (~> 2.1.0)
29
+ pry (0.10.4)
30
+ coderay (~> 1.1.0)
31
+ method_source (~> 0.8.1)
32
+ slop (~> 3.4)
33
+ rspec (3.5.0)
34
+ rspec-core (~> 3.5.0)
35
+ rspec-expectations (~> 3.5.0)
36
+ rspec-mocks (~> 3.5.0)
37
+ rspec-core (3.5.4)
38
+ rspec-support (~> 3.5.0)
39
+ rspec-expectations (3.5.0)
40
+ diff-lcs (>= 1.2.0, < 2.0)
41
+ rspec-support (~> 3.5.0)
42
+ rspec-mocks (3.5.0)
43
+ diff-lcs (>= 1.2.0, < 2.0)
44
+ rspec-support (~> 3.5.0)
45
+ rspec-support (3.5.0)
46
+ slop (3.6.0)
47
+ thread_safe (0.3.5)
48
+ tzinfo (1.2.2)
49
+ thread_safe (~> 0.1)
50
+
51
+ PLATFORMS
52
+ ruby
53
+
54
+ DEPENDENCIES
55
+ activesupport
56
+ byebug
57
+ nokogiri (~> 1.7, >= 1.7.0.1)
58
+ opta_sd!
59
+ pry
60
+ rspec
61
+
62
+ BUNDLED WITH
63
+ 1.13.7
@@ -0,0 +1,20 @@
1
+ Copyright 2017 Ali Al-Sheiba
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,400 @@
1
+ # OPTA Sports Data Soccer API
2
+
3
+ OPTA SD is a library to Integrate and Utilize Opta Sports Data Apis.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ ```ruby
10
+ gem 'opta_sd'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ ```bash
16
+ $ bundle install
17
+ ```
18
+
19
+ Or install it yourself as:
20
+
21
+ ```bash
22
+ $ gem install opta_sd
23
+ ```
24
+
25
+ --------------------------------------------------------------------------------
26
+
27
+ ## Using Guide
28
+
29
+ This Gem is just a class builder for the APIs, every api have a Class for it, and for every api's parameters there are methods to build them, and those parameter methods are explained down below for each Class.
30
+
31
+ ### Available Classes :
32
+
33
+ Available Feeds | Class | API End Point
34
+ --------------------------------- | :-----------------------------------------------: | ------------------------------------
35
+ Fixtures and Results | [Match](#1-fixtures-and-results) | `/soccerdata/match/...`
36
+ Match Statistics | [MatchStatistics](#2-match-statistics) | `/soccerdata/matchstats/...`
37
+ Match Events | [MatchEvent](#3-match-events) | `/soccerdata/matchevent/...`
38
+ Pass Matrix and Average Formation | [PassMatrix](4-pass-matrix-and-average-formation) | `/soccerdata/passmatrix/...`
39
+ Possession | [Possession](#5-possession) | `/soccerdata/possession/...`
40
+ Commentary | [Commentary](#6-commentary) | `/soccerdata/Commentary/...`
41
+ Match Facts | [MatchFacts](#7-match-facts) | `/soccerdata/matchfacts/...`
42
+ Seasonal Stats | [SeasonalStats](#8-seasonal-stats) | `/soccerdata/seasonstats/...`
43
+ Squads | [Squads](#9-squads) | `/soccerdata/squads/...`
44
+ Team Standings | [TeamStandings](#10-team-standings) | `/soccerdata/standings/...`
45
+ Player Career | [PlayerCareer](#11-player-career) | `/soccerdata/playercareer/...`
46
+ Tournament Calendars | [TournamentCalendar](#12-tournament-calendars) | `/soccerdata/tournamentcalendar/...`
47
+ Match Preview | [MatchPreview](#13-match-preview) | `/soccerdata/matchpreview/...`
48
+ Rankings | [Rankings](#14-rankings) | `/soccerdata/rankings/...`
49
+ Tournament Schedule | [TournamentSchedule](#15-tournament-schedule) | `/soccerdata/tournamentschedule/...`
50
+
51
+ ### Parameter Methods :
52
+
53
+ Parameters are changed in this gem to be more readable, and will be transulated to Opta keys in the backend.
54
+
55
+ There are two types of parameters, _core_ parameters that can be used in all apis, and _api parameters_ those are specific for each api.
56
+
57
+ Core Parameters are have `_` prefix, and they are:
58
+
59
+ Method | Actual Parameter
60
+ -------------- | ----------------
61
+ `_rt` | `_rt`
62
+ `_format` | `_fmt`
63
+ `_locale` | `_lcl`
64
+ `_callback` | `_clbk`
65
+ `_sort` | `_ordSrt`
66
+ `_page_size` | `_pgSz`
67
+ `_page_number` | `_pgNm`
68
+
69
+ ### Example of using core parameters
70
+
71
+ ```ruby
72
+ OptaSD::Soccer::Match.new.competition('722fdbecxzcq9788l6jqclzlw').time_range(Time.now - 86400, Time.now + 86400)
73
+ ```
74
+
75
+ ### Response Format
76
+
77
+ OPTA SD provides the response in `json` and `xml` format, you can use `_format` method to define the required response format, `json` is the default.
78
+
79
+ JSON response will be Parsed by `JSON.parse` and XML will be parsed by `nokogiri` gem. you can override `parse_xml` method from Core Class in case you need to change the behaviour.
80
+
81
+ ### The Final Call
82
+
83
+ After building the required parameters, you will call `get` method at the end of the chain to build the request and pull the data. after that you can retrieve the response by calling `data`.
84
+
85
+ Example:
86
+
87
+ ```ruby
88
+ # Build the request hit the api
89
+ match = OptaSD::Soccer::Match.new.resource('bsu6pjne1eqz2hs8r3685vbhl').live.lineups.get
90
+
91
+ # retrieve the response data
92
+ match.data['match']
93
+ ```
94
+
95
+ ### Use this Gem with Rails
96
+
97
+ To be able to use this gem with your own key, you need to create a `opta_sd.yml` in config dir and override `config_file` method from Core Class to read the `opta_sd.yml` from your app directory.
98
+
99
+ ```yaml
100
+ # config/opta_sd.yml
101
+ opta_domain: 'http://api.performfeeds.com'
102
+ opta_auth_token: 'YOUR-OWN-KEY'
103
+ ```
104
+
105
+ ```ruby
106
+ # config/initializers/opta_sd.rb
107
+ class OptaSD::Core
108
+ def config_file
109
+ YAML::load(File.open(Rails.root.join('config/opta_sd.yml')))
110
+ end
111
+ end
112
+ ```
113
+
114
+ --------------------------------------------------------------------------------
115
+
116
+ ## APIS
117
+
118
+ Sports Data Soccer API guide
119
+
120
+ <http://api.performfeeds.com/soccerdata/match/sdapidocumentation?_docu>
121
+
122
+ ### 1\. Fixtures and Results
123
+
124
+ Examples:
125
+
126
+ ```ruby
127
+ # Get Match details with live and lineups
128
+ OptaSD::Soccer::Match.new.resource('bsu6pjne1eqz2hs8r3685vbhl').live.lineups.get
129
+
130
+ # Using Old OPTA Core Match ID
131
+ OptaSD::Soccer::Match.new.fixture('urn:perform:optacore:fixture:2366080').live.lineups.get
132
+
133
+ # Get competition matches between two time stamps
134
+ OptaSD::Soccer::Match.new.competition('722fdbecxzcq9788l6jqclzlw').time_range(Time.now - 86400, Time.now + 86400).get
135
+ ```
136
+
137
+ Available Parameters:
138
+
139
+ - `resource(match_id)`
140
+ - `fixture(match_id)`
141
+ - `tournament(tournament_id)`
142
+ - `stage(stage_id)`
143
+ - `competition(competition_id)`
144
+ - `contestant(contestant_id)`
145
+ - `live(ture/false)` by default will pass true
146
+ - `lineups(ture/false)` by default will pass true
147
+ - `status(status)` statuses : (`all` - `fixture` - `played` - `playing` - `cancelled` - `postponed` - `suspended`)
148
+ - `time_range(from, to)` from and to should be a valid Time, like `Time.now`
149
+
150
+ ### 2\. Match Statistics
151
+
152
+ ```ruby
153
+ # Get Statistics Of Match
154
+ OptaSD::Soccer::MatchStatistics.new.resource('bsu6pjne1eqz2hs8r3685vbhl').get
155
+
156
+ # Get Statistics Of Match with more details
157
+ OptaSD::Soccer::MatchStatistics.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').detailed.get
158
+ ```
159
+
160
+ Available Parameters:
161
+
162
+ - `resource(match_id)`
163
+ - `fixture(match_id)`
164
+ - `detailed(ture/false)` by default will pass true
165
+
166
+ ### 3\. Match Events
167
+
168
+ ```ruby
169
+ # Get Match Events
170
+ OptaSD::Soccer::MatchEvent.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').get
171
+ ```
172
+
173
+ Available Parameters:
174
+
175
+ - `resource(match_id)`
176
+ - `fixture(match_id)`
177
+
178
+ ### 4\. Pass Matrix and Average Formation
179
+
180
+ ```ruby
181
+ # Get Match Matrix
182
+ OptaSD::Soccer::PassMatrix.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').get
183
+ ```
184
+
185
+ Available Parameters:
186
+
187
+ - `resource(match_id)`
188
+ - `fixture(match_id)`
189
+
190
+ ### 5\. Possession
191
+
192
+ ```ruby
193
+ # Get Possession Throughout A Match
194
+ OptaSD::Soccer::Possession.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').get
195
+ ```
196
+
197
+ Available Parameters:
198
+
199
+ - `resource(match_id)`
200
+ - `fixture(match_id)`
201
+
202
+ ### 6\. Commentary
203
+
204
+ ```ruby
205
+ # Get Match Commentary
206
+ OptaSD::Soccer::Commentary.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').get
207
+
208
+ # Get Match Commentary with type
209
+ OptaSD::Soccer::Commentary.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').type('auto').get
210
+ # Or
211
+ OptaSD::Soccer::Commentary.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').auto.get
212
+ ```
213
+
214
+ Available Parameters:
215
+
216
+ - `resource(match_id)`
217
+ - `fixture(match_id)`
218
+ - `type(type)` types are : `auto` - `fallback` - `manual`
219
+ - `auto`
220
+ - `fallback`
221
+ - `manual`
222
+
223
+ ### 7\. Match Facts
224
+
225
+ ```ruby
226
+ # Get Match Facts
227
+ OptaSD::Soccer::MatchFacts.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').get
228
+ ```
229
+
230
+ Available Parameters:
231
+
232
+ - `resource(match_id)`
233
+ - `fixture(match_id)`
234
+
235
+ ### 8\. Seasonal Stats
236
+
237
+ ```ruby
238
+ # Get Seasonal Stats by Competition Contestants
239
+ OptaSD::Soccer::SeasonalStats.new.competition('722fdbecxzcq9788l6jqclzlw').contestant('884uzyf1wosc7ykji6e18gifp').get
240
+
241
+ # Get Seasonal Stats by Tournament Contestants
242
+ OptaSD::Soccer::SeasonalStats.new.tournament('408bfjw6uz5k19zk4am50ykmh').contestant('884uzyf1wosc7ykji6e18gifp').get
243
+ ```
244
+
245
+ Available Parameters:
246
+
247
+ - `competition(competition_id)`
248
+ - `tournament(tournament_id)`
249
+ - `contestant(contestant_id)`
250
+
251
+ ### 9\. Squads
252
+
253
+ ```ruby
254
+ # Get Squads By Tournament
255
+ OptaSD::Soccer::Squads.new.tournament('408bfjw6uz5k19zk4am50ykmh').get
256
+
257
+ # Get Squads By Contestant
258
+ OptaSD::Soccer::Squads.new.contestant('884uzyf1wosc7ykji6e18gifp').get
259
+
260
+ # Get Detailed Squads
261
+ OptaSD::Soccer::Squads.new.tournament('408bfjw6uz5k19zk4am50ykmh').detailed.get
262
+
263
+ # Get People Squads
264
+ OptaSD::Soccer::Squads.new.tournament('408bfjw6uz5k19zk4am50ykmh').people.get
265
+ ```
266
+
267
+ Available Parameters:
268
+
269
+ - `tournament(tournament_id)`
270
+ - `contestant(contestant_id)`
271
+ - `detailed(ture/false)`
272
+ - `people(ture/false)`
273
+
274
+ ### 10\. Team Standings
275
+
276
+ ```ruby
277
+ # Get Team Standings By Tournament
278
+ OptaSD::Soccer::TeamStandings.new.tournament('408bfjw6uz5k19zk4am50ykmh').get
279
+
280
+ # Get Team Standings By Tournament And Stage
281
+ OptaSD::Soccer::TeamStandings.new.tournament('408bfjw6uz5k19zk4am50ykmh').stage('123').get
282
+
283
+ # Get Team Standings With Live Data
284
+ OptaSD::Soccer::TeamStandings.new.tournament('408bfjw6uz5k19zk4am50ykmh').live.get
285
+
286
+ # Get Team Standings By Type
287
+ OptaSD::Soccer::TeamStandings.new.tournament('408bfjw6uz5k19zk4am50ykmh').type('total').get
288
+ OptaSD::Soccer::TeamStandings.new.tournament('408bfjw6uz5k19zk4am50ykmh').total.get
289
+ ```
290
+
291
+ Available Parameters:
292
+
293
+ - `stage(stage_id)`
294
+ - `tournament(tournament_id)`
295
+ - `type(type)` types are : `total` - `home` - `away` - `form-total` - `form-home` - `form-away`
296
+ - `live(ture/false)`
297
+ - `total`
298
+ - `home`
299
+ - `away`
300
+ - `form_total`
301
+ - `form_home`
302
+ - `form_away`
303
+
304
+ ### 11\. Player Career
305
+
306
+ ```ruby
307
+ # Get Player Career By Person ID
308
+ OptaSD::Soccer::PlayerCareer.new.resource('1c4gmhsc0mfjl2or3oxggg6hh').get
309
+ OptaSD::Soccer::PlayerCareer.new.person('1c4gmhsc0mfjl2or3oxggg6hh').get
310
+
311
+ # Get Players Career By Contestant ID
312
+ OptaSD::Soccer::PlayerCareer.new.contestant('apoawtpvac4zqlancmvw4nk4o').get
313
+
314
+ # Get Players Career By Contestant ID and Active on In-Active
315
+ OptaSD::Soccer::PlayerCareer.new.contestant('apoawtpvac4zqlancmvw4nk4o').active.get
316
+ OptaSD::Soccer::PlayerCareer.new.contestant('apoawtpvac4zqlancmvw4nk4o').active(false).get
317
+ ```
318
+
319
+ Available Parameters:
320
+
321
+ - `resource(person_id)`
322
+ - `person(person_id)`
323
+ - `contestant(contestant_id)`
324
+ - `active(ture/false)`
325
+
326
+ ### 12\. Tournament Calendars
327
+
328
+ ```ruby
329
+ # Get All Competitions With All Tournaments
330
+ OptaSD::Soccer::TournamentCalendar.new.get
331
+
332
+ # Get Tournaments Of Competitions
333
+ OptaSD::Soccer::TournamentCalendar.new.competition('722fdbecxzcq9788l6jqclzlw').get
334
+
335
+ # Get All Competitions With Only Active Tournaments
336
+ OptaSD::Soccer::TournamentCalendar.new.active.get
337
+
338
+ # Get Only Authorized Competitions With Only Active Tournaments
339
+ OptaSD::Soccer::TournamentCalendar.new.active.authorized.get
340
+ ```
341
+
342
+ Available Parameters:
343
+
344
+ - `competition(competition_id)`
345
+ - `active`
346
+ - `authorized`
347
+
348
+ ### 13\. Match Preview
349
+
350
+ ```ruby
351
+ # Get Preview of Match
352
+ OptaSD::Soccer::MatchPreview.new.fixture('bsu6pjne1eqz2hs8r3685vbhl').get
353
+ ```
354
+
355
+ Available Parameters:
356
+
357
+ - `resource(match_id)`
358
+ - `fixture(match_id)`
359
+
360
+ ### 14\. Rankings
361
+
362
+ ```ruby
363
+ # Get Tournament Rankings
364
+ OptaSD::Soccer::Rankings.new.resource('408bfjw6uz5k19zk4am50ykmh').get
365
+ OptaSD::Soccer::Rankings.new.tournament('408bfjw6uz5k19zk4am50ykmh').get
366
+ ```
367
+
368
+ Available Parameters:
369
+
370
+ - `resource(tournament_id)`
371
+ - `tournament(tournament_id)`
372
+
373
+ ### 15\. Tournament Schedule
374
+
375
+ ```ruby
376
+ # Get Tournament Schedule
377
+ OptaSD::Soccer::TournamentSchedule.new.resource('408bfjw6uz5k19zk4am50ykmh').get
378
+ OptaSD::Soccer::TournamentSchedule.new.tournament('408bfjw6uz5k19zk4am50ykmh').get
379
+ ```
380
+
381
+ Available Parameters:
382
+
383
+ - `resource(tournament_id)`
384
+ - `tournament(tournament_id)`
385
+
386
+ --------------------------------------------------------------------------------
387
+
388
+ ## Contributing
389
+
390
+ 1. Fork it
391
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
392
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
393
+ 4. Push to the branch (`git push origin my-new-feature`)
394
+ 5. Create new Pull Request
395
+
396
+ --------------------------------------------------------------------------------
397
+
398
+ ## License
399
+
400
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).