/lib/DDG/Spice/Dictionary/Pronunciation.pm

http://github.com/duckduckgo/zeroclickinfo-spice · Perl · 18 lines · 12 code · 5 blank · 1 comment · 1 complexity · a7d77c96fcac3f6652bb3ec34c932f24 MD5 · raw file

  1. package DDG::Spice::Dictionary::Pronunciation;
  2. # ABSTRACT: Get pronounciation information of a word
  3. use strict;
  4. use DDG::Spice;
  5. attribution web => ['http://duckduckgo.com', 'DuckDuckGo'],
  6. twitter => ['http://twitter.com/duckduckgo', 'DuckDuckGo'];
  7. spice to => 'http://api.wordnik.com/v4/word.json/$1/pronunciations?limit=1&useCanonical=false&api_key={{ENV{DDG_SPICE_WORDNIK_APIKEY}}}&callback={{callback}}';
  8. triggers any => "///***never_trigger***///";
  9. handle remainder => sub {
  10. return $_ if $_;
  11. return;
  12. };
  13. 1;