Class: Rubyfuri::YahooAPI

Inherits:
Object
  • Object
show all
Defined in:
lib/rubyfuri/yahoo_api.rb

Constant Summary collapse

BASE_URL =
'http://jlp.yahooapis.jp'
API_PATH =
'/FuriganaService/V1/furigana'

Class Method Summary collapse

Class Method Details

.request(app_id, text) ⇒ Object



9
10
11
12
13
14
15
# File 'lib/rubyfuri/yahoo_api.rb', line 9

def request(app_id, text)
  res = http_client.get do |req|
    req.url API_PATH
    req.params[:appid] = app_id
    req.params[:sentence] = text
  end
end