Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

disqus-node

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

disqus-node - npm Package Compare versions

Comparing version 0.7.0 to 0.8.0

5

CHANGELOG.md

@@ -0,1 +1,6 @@

##### 0.8.0 - 13 June 2014
###### Backwards compatible API changes
- #7 - Implemented Imports
##### 0.7.0 - 13 June 2014

@@ -2,0 +7,0 @@

22

lib/api/imports.js

@@ -14,3 +14,4 @@ /**

method: 'GET',
availableOptions: ['api_secret', 'api_key', 'access_token', 'group', 'forum']
requiredOptions: ['api_secret', 'access_token', 'forum', 'group'],
availableOptions: []
},

@@ -21,3 +22,4 @@ list: {

method: 'GET',
availableOptions: ['api_secret', 'api_key', 'access_token', 'forum', 'cursor']
requiredOptions: ['api_secret', 'access_token', 'forum'],
availableOptions: ['cursor']
}

@@ -40,4 +42,6 @@ };

* disqus.imports.details({
* forum: 'forumId',
* group: 'groupId'
* forum: '',
* group: '',
* api_secret: 'asdfghkj', // can be set globally
* access_token: '12345678' // can be set globally
* }, function (err, result) {...})

@@ -47,4 +51,4 @@ *

* disqus.imports.details({
* forum: 'forumId',
* group: 'groupId'
* forum: '',
* group: ''
* })

@@ -74,2 +78,3 @@ * .then(function (result) {...})

* forum: 'forumId',
* // defaults shown
* cursor: null

@@ -80,3 +85,6 @@ * }, function (err, result) {...})

* disqus.imports.list({
* forum: 'forumId',
* forum: '',
* api_secret: 'asdfghkj', // can be set globally
* access_token: '12345678', // can be set globally
* // defaults shown
* cursor: null

@@ -83,0 +91,0 @@ * })

@@ -8,4 +8,6 @@ /**

*/
var Disqus = require('../');
var commander = require('commander');
var imports = new commander.Command('disqus imports');
var util = require('../util');

@@ -25,8 +27,9 @@ imports

-h, --help output usage information
-A, --api_key <string> Your application's public api_key.
-f, --forum <string> Looks up a forum by ID (aka short name).
-g, --group <string> Looks up a group by ID.
-H, --https [boolean] Whether to use https. Defaults to true.
-L, --logLevel [string] Output log level. Choices: debug, info, notice, warning, error, critical, alert, emergency.
-h, --help output usage information
-A, --access_token <string> Your access token.
-f, --forum <string> Looks up a forum by ID (aka short name).
-g, --group <string> Looks up a group by ID.
-H, --https [boolean] Whether to use https. Defaults to true.
-L, --logLevel [string] Output log level. Choices: debug, info, notice, warning, error, critical, alert, emergency.
-S, --api_secret <string> Your applications's api_secret.
* ```

@@ -37,3 +40,3 @@ */

.description('Returns the details for an import.')
.option('-A, --api_key <string>', 'Your applications\'s public api_key.')
.option('-A, --access_token <string>', 'Your access token.')
.option('-f, --forum <string>', 'Looks up a forum by ID (aka short name).')

@@ -43,21 +46,5 @@ .option('-g, --group <string>', 'Looks up a group by ID.')

.option('-L, --logLevel [string]', 'Output log level. Choices: debug, info, notice, warning, error, critical, alert, emergency.', 'info')
.option('-S, --api_secret <string>', 'Your applications\'s api_secret.')
.action(function (options) {
var Disqus = require('../');
var disqus = new Disqus({
logLevel: options.logLevel,
api_key: options.api_key,
https: options.https
});
disqus.imports.details({
forum: options.forum,
group: options.group
}, function (err, result) {
if (err) {
console.error(err);
process.exit(1);
} else {
console.log(JSON.stringify(result, null, 2));
}
});
new Disqus(options).imports.details(options, util.printCliResult);
});

@@ -75,8 +62,9 @@

-h, --help output usage information
-A, --api_key <string> Your application's public api_key.
-c, --cursor [string] Defaults to null.
-f, --forum <string> Looks up a forum by ID (aka short name).
-H, --https [boolean] Whether to use https. Defaults to true.
-L, --logLevel [string] Output log level. Choices: debug, info, notice, warning, error, critical, alert, emergency.
-h, --help output usage information
-A, --access_token <string> Your access token.
-f, --forum <string> Looks up a forum by ID (aka short name).
-c, --cursor [string] Defaults to null.
-H, --https [boolean] Whether to use https. Defaults to true.
-L, --logLevel [string] Output log level. Choices: debug, info, notice, warning, error, critical, alert, emergency.
-S, --api_secret <string> Your applications's api_secret.
* ```

@@ -87,28 +75,12 @@ */

.description('Returns a list of all imports.')
.option('-A, --api_key <string>', 'Your applications\'s public api_key.')
.option('-A, --access_token <string>', 'Your access token.')
.option('-f, --forum <string>', 'Looks up a forum by ID (aka short name).')
.option('-c, --cursor [string]', 'Defaults to null.', null)
.option('-f, --forum <string>', 'Looks up a forum by ID (aka short name).')
.option('-H, --https [boolean]', 'Whether to use https. Defaults to true.', true)
.option('-L, --logLevel [string]', 'Output log level. Choices: debug, info, notice, warning, error, critical, alert, emergency.', 'info')
.option('-S, --api_secret <string>', 'Your applications\'s api_secret.')
.action(function (options) {
var Disqus = require('../');
var disqus = new Disqus({
logLevel: options.logLevel,
api_key: options.api_key,
https: options.https
});
disqus.imports.list({
forum: options.forum,
cursor: options.cursor
}, function (err, result) {
if (err) {
console.error(err);
process.exit(1);
} else {
console.log(JSON.stringify(result, null, 2));
}
});
new Disqus(options).imports.list(options, util.printCliResult);
});
module.exports = imports;

@@ -35,2 +35,9 @@ var commander = require('commander');

.description('Execute command for the Exports resource.');
/**
* ###### Imports
* [API](/lib/api/imports.html) | [CLI](/lib/cli/imports.html) | [Disqus](https://disqus.com/api/docs/imports/)
*/
disqus
.command('imports <cmd> [options]')
.description('Execute command for the Imports resource.');

@@ -45,2 +52,3 @@ exports.parse = function (primaryArgs, secondaryArgs) {

case 'exports':
case 'imports':
if (!secondaryArgs.length) {

@@ -47,0 +55,0 @@ primaryArgs.push('--help');

@@ -10,2 +10,3 @@ /**

var Exports = require('./api/exports');
var Imports = require('./api/imports');

@@ -109,2 +110,7 @@ /**

this.exports = new Exports(this.config, this.logger);
/**
* ###### Imports
* [API](/lib/api/imports.html) | [CLI](/lib/cli/imports.html) | [Disqus](https://disqus.com/api/docs/imports/)
*/
this.imports = new Imports(this.config, this.logger);

@@ -111,0 +117,0 @@ this.logger.debug('Instantiated Disqus', JSON.stringify(this.config));

{
"name": "disqus-node",
"version": "0.7.0",
"version": "0.8.0",
"description": "Disqus API bindings and CLI for NodeJS http://disqus.com/api/",
"main": "lib/index.js",
"main": "./lib/index.js",
"bin": {

@@ -31,3 +31,3 @@ "disqus": "./bin/disqus"

},
"homepage": "https://github.com/jmdobry/disqus-node",
"homepage": "http://disqus-node.pseudobry.com",
"dependencies": {

@@ -34,0 +34,0 @@ "bluebird": "^2.1.1",

@@ -16,6 +16,6 @@ disqus-node

- Exports
- Imports
## Not Yet Implemented
- Forums
- Imports
- Posts

@@ -22,0 +22,0 @@ - Threads

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc