Project

splapi

0.0
No commit activity in last 3 years
No release in over 3 years
splapi Client for ruby.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.11
>= 0
~> 10.0
~> 3.0

Runtime

 Project Readme

splapi - スプラトゥーンのステージ情報がとれるやつのRuby実装のClient gem。 各APIのパラメーターは上記の公式リファレンスを参照してください。

Installation

Add this line to your application's Gemfile:

gem 'splapi'

And then execute:

$ bundle

Or install it yourself as:

$ gem install splapi

Usage

require 'splapi'

client = SplAPI::Client.new


res = client.gachi_now
res.body
# => {"result"=>
#   [{"maps"=>["マサバ海峡大橋", "マヒマヒリゾート&スパ"],
#     "rule"=>"ガチエリア",
#     "end"=>"2016-03-04T23:00:00",
#     "start"=>"2016-03-04T19:00:00"}]}

res = client.gachi_rules
res.body['rules']
# => ["ガチエリア", "ガチホコ", "ガチヤグラ"]

res = client.weapons
res.body['weapons']
# => [".52ガロン",
#  ".52ガロンデコ",
#  ".96ガロン",
#  ".96ガロンデコ",
#  "14式竹筒銃・乙",
#  .
#  .
#  .
#  ]

# Other examples
client.gachi(date: '2015-08-31T03:00:00', to: '2015-09-03T19:00:00', rule: 'ガチヤグラ,ガチホコ', map: 'シオノメ油田,ハコフグ倉庫')
client.fes(team: 'ボケ')

License

The gem is available as open source under the terms of the MIT License.