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

auth0

Package Overview
Dependencies
Maintainers
1
Versions
156
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

auth0 - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

43

lib/index.js

@@ -82,2 +82,24 @@ var request = require('request');

Client.prototype.getConnectionByName = function(name, done) {
var self = this;
this._getAccessToken(function (err, accessToken) {
if (err) return done(err);
request.get({
url: self.apiUrl + '/connections',
qs: { access_token: accessToken, name: name }
}, function (err, r, body) {
if (err) return done(err);
if (r.statusCode === 404) return done( null, null);
if (r.statusCode.toString().substr(0, 1) !== '2') return done(new Error(body));
try {
var json = JSON.parse(body);
done(null, json);
} catch(e) {
done(e);
}
});
});
};
Client.prototype.createConnection = function (connection, done) {

@@ -95,3 +117,3 @@ var self = this;

if(r.statusCode === 400) {
return done(new Error(body.detail));
return done(new Error(body.detail || body));
}

@@ -103,2 +125,21 @@ done(null, body);

Client.prototype.updateConnection = function (connection, done) {
var self = this;
this._getAccessToken(function (err, accessToken) {
if (err) return done(err);
request.put({
url: self.apiUrl + '/connections/' + connection._id,
qs: { access_token: accessToken },
json: connection
}, function (err, r, body) {
if (err) { return done(err); }
if(r.statusCode === 400) {
return done(new Error(body.detail || body));
}
done(null, body);
});
});
};
module.exports = Client;

2

package.json
{
"name": "auth0",
"version": "0.0.3",
"version": "0.0.4",
"description": "Client library for the Auth0 platform",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -35,32 +35,7 @@ Node.js client library for the Auth0 platform.

"client_secret": "aadsadsadsa",
"email": true,
"profile": true,
"contacts": false,
"blogger": false,
"calendar": false,
"gmail": false,
"google_plus": false,
"orkut": false,
"picasa_web": false,
"tasks": false,
"youtube": false,
"adsense_management": false,
"google_affiliate_network": false,
"analytics": false,
"google_books": false,
"google_cloud_storage": false,
"content_api_for_shopping": false,
"chrome_web_store": false,
"document_list": false,
"google_drive": false,
"google_drive_files": false,
"latitude_best": false,
"latitude_city": false,
"moderator": false,
"sites": false,
"spreadsheets": false,
"url_shortener": false,
"webmaster_tools": false
},
"status": 0
"sites": true,
"spreadsheets": true,
"url_shortener": true,
"webmaster_tools": true
}
};

@@ -67,0 +42,0 @@

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