duoshuo.com apis
duoshuo.com apis for node.js
How to install
$ npm install duoshuo
Sample code
var Duoshuo = ; var duoshuo = short_name: 'abc' // 站点申请的多说二级域名。 secret: 'xxx' // 站点密钥; // fetch tokenduoshuo; var access_token = 'xxxxxxxxxxxxxxxxxx'; // 通过duoshuo.auth获得的access_tokenvar duoshuoClient = duoshuo; // join local user to duoshuo.comduoshuoClient; // fetch top articlesduoshuoClient; // push comments to duoshuo.comduoshuoClient;
Run Unit-test (Mocha)
$ git clone https://github.com/turingou/duoshuo.git
$ cd duoshuo
$ npm install
$ npm test