This repository has been archived by the owner on Dec 27, 2018. It is now read-only.
v0.2.0
Improvements:
- simplified internal logic
- extended options for
OAuth
andRest
var oa = new OAuth2({
config: {
client_id: "",
client_secret: "",
project_key: ""
},
host: "auth.sphere.io", // optional
accessTokenUrl: "/oauth/token" // optional,
timeout: 20000, // optional
rejectUnauthorized: true // optional
});
var rest = new Rest({
config: {
client_id: "",
client_secret: "",
project_key: ""
},
host: "api.sphere.io", // optional
access_token: "", // optional (if not provided it will automatically retrieve an access_token)
timeout: 20000, // optional
rejectUnauthorized: true, // optional
oauth_host: "auth.sphere.io" // optional (used when retrieving the access_token internally)
});