url - Json api to set varibale -
i tries use api json , output :
can't read "title": no such variable
, , when announce $toke : <testbot> tok ::http::2
testid tt3896198, !id tt3896198
form imdb url: http://api.rest7.com/v1/movie_info.php?imdb=tt3896198&title
bind pub "-|-" !id pub:id proc pub:id { nick uhost hand channel arg } { set id [lindex $arg 0] set tok [http::geturl "http://api.rest7.com/v1/movie_info.php?imdb=$id&title"] set data [json::json2dict [http::data $tok]] http::cleanup $tok dict data putnow "privmsg $channel :$title $year $runtime $director $writer $score $genre" } }
Comments
Post a Comment