1.0.0 • Published 9 years ago

yandex-search v1.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
9 years ago

node-yandex-search

Simple interface for Yandex XML search.

##Installation## $ npm install yandex-search

##Usage## yandex(options, function)

##Example##

var yandex = require('yandex');
var myXmlUrl = 'http://xmlsearch.yandex.com/xmlsearch?user=YOU&key=YOURKEY';
yandex({url: myXmlUrl, query: 'Node.js'}, function(err, xmlResults) {
  // do cool stuff
})

##Options### Options and defaults mostly follow the format specified here.

{
  url: '',           // required. get this from yandex.
  query: '',         // required. will be xml encoded for you.
  sortby: 'rlv',     // [rlv, tm]
  maxpassages: 4,    // [1..5]
  page: 0,           // Int
  groupby: {
    mode: 'deep'     // [deep, flat], attr is set for you.
    groupsOnPage: 10 // [1..100]
    docsInGroup: 1   // [1..3]
  }
  proxy: {}          // object is passed directly to the request module to control proxy behaviour.
}
1.0.0

9 years ago

0.0.1

11 years ago