r7kamura/docomoru — pull request #1 by kkosuge (2014-12-28 07:48:22+00:00)
Title: Implement 知識Q&A

```ruby
client = Docomoru::Client.new(api_key: ENV["DOCOMO_API_KEY"])
response = client.create_knowledge("Rubyの作者は誰ですか")
response.status #=> 200
response.headers #=> {
"Asyncserviceinvoke" => "false",
"Content-Type" => "application/json;charset=UTF-8",
"Date" => "Sun, 28 Dec 2014 07:45:54 GMT",
"Content-Length" => "1268",
"Connection" => "Close"
}
response.body #=> {
"code" => "S020010",
"message" => {
"textForDisplay" => "インターネットで調べたところ、一位は、まつもとゆきひろです。",
"textForSpeech" => "インターネットで調べたところ、一位は、マツモトユキヒロです。"
},
"answers" => [
[0] {
"rank" => "1",
"answerText" => "まつもとゆきひろ",
"linkText" => "田中ばびえ",
"linkUrl" => "http://d.hatena.ne.jp/keywordmobile/%93c%92%86%82%CE%82%D1%82%A6?kid=177550"
},
[1] {
"rank" => "2",
"answerText" => "まつもと",
"linkText" => "ネット時代の最前線走る3氏が“ビジネスイノベーション\"を語る 角川アスキー総研第1回シンポ開催",
"linkUrl" => "http://www.zakzak.co.jp/economy/ecn-news/news/20130913/ecn1309130732001-n1.htm"
},
[2] {
"rank" => "3",
"answerText" => "DHH",
"linkText" => "田中ばびえ",
"linkUrl" => "http://d.hatena.ne.jp/keywordmobile/%93c%92%86%82%CE%82%D1%82%A6?kid=177550"
},
[3] {
"rank" => "4",
"answerText" => "高橋征義",
"linkText" => "ついにRubyの勉強をはじめます - duck75のはてなブログ",
"linkUrl" => "http://duck75.hatenablog.com/entry/2012/11/26/134640"
},
[4] {
"rank" => "5",
"answerText" => "角征典",
"linkText" => "Amazonアソシエイトやってみようと思いまして - chikuchikugonzalezの雑記帳",
"linkUrl" => "http://chiku2gonzalez.hatenablog.com/entry/2012/10/19/000248"
}
]
}
```