class Methods::Translate

Public Class Methods

run(api_key, text, from, to) click to toggle source
# File lib/methods/translate.rb, line 4
def self.run(api_key, text, from, to)
 Api.post(path,{key: api_key, lang: "#{from}-#{to}", text: text, format: 'json'})
end

Private Class Methods

path() click to toggle source
# File lib/methods/translate.rb, line 10
def self.path
 '/api/v1.5/tr.json/translate'
end