Skip to content
This repository has been archived by the owner on Dec 27, 2018. It is now read-only.

Releases: sphereio/sphere-node-connect

v0.2.0

29 Nov 13:23
Compare
Choose a tag to compare

Improvements:

  • simplified internal logic
  • extended options for OAuth and Rest
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) 
});

v0.1.3 - Support DELETE

25 Nov 12:41
Compare
Choose a tag to compare
  • add support for DELETE request
rest.DELETE("/resource/path", function(error, response, body) {
  // do something
}

Auto-retry to get access token

14 Nov 16:55
Compare
Choose a tag to compare
  • when using rest object to communicate with the API without providing an access_token, it will automatically re-try for max 10 attempts

Also automatically publish to npm after releasing

08 Nov 18:13
Compare
Choose a tag to compare
nicola: ~/dev/src/sphere-node-connect (master *) $ grunt release
Running "release" task

Running "bump-only:patch" (bump-only) task

Running "bump:patch:bump-only" (bump) task
>> Version bumped to 0.0.8
>> pkg's version updated

Running "clean:default" (clean) task
Cleaning lib...OK

Running "clean:test" (clean) task
Cleaning test...OK

Running "coffeelint:default" (coffeelint) task
>> 6 files lint free.

Running "coffee:default" (coffee) task
File lib/oauth2.js created.
File lib/rest.js created.

Running "coffee:test" (coffee) task
File test/integration.spec.js created.
File test/oauth2.spec.js created.
File test/rest.spec.js created.

Running "concat:default" (concat) task
File "lib/oauth2.js" created.
File "lib/rest.js" created.

Running "bump::commit-only" (bump) task
>> Committed as "Bump version to 0.0.8"
>> Tagged as "v0.0.8"
>> Pushed to origin

Running "shell:publish" (shell) task
npm http PUT https://registry.npmjs.org/sphere-node-connect
npm http 409 https://registry.npmjs.org/sphere-node-connect
npm http GET https://registry.npmjs.org/sphere-node-connect
npm http 200 https://registry.npmjs.org/sphere-node-connect
npm http PUT https://registry.npmjs.org/sphere-node-connect/-/sphere-node-connect-0.0.8.tgz/-rev/7-e48da04c54941c0a7d9b90c6ec85651d
npm http 201 https://registry.npmjs.org/sphere-node-connect/-/sphere-node-connect-0.0.8.tgz/-rev/7-e48da04c54941c0a7d9b90c6ec85651d
npm http PUT https://registry.npmjs.org/sphere-node-connect/0.0.8/-tag/latest
npm http 201 https://registry.npmjs.org/sphere-node-connect/0.0.8/-tag/latest
+ [email protected]

Done, without errors.

Use Grunt task to automatically release

08 Nov 18:10
Compare
Choose a tag to compare

grunt release

Example:

nicola: ~/dev/src/sphere-node-connect (master) $ grunt release
Running "release" task

Running "bump-only:patch" (bump-only) task

Running "bump:patch:bump-only" (bump) task
>> Version bumped to 0.0.7
>> pkg's version updated

Running "clean:default" (clean) task
Cleaning lib...OK

Running "clean:test" (clean) task
Cleaning test...OK

Running "coffeelint:default" (coffeelint) task
>> 6 files lint free.

Running "coffee:default" (coffee) task
File lib/oauth2.js created.
File lib/rest.js created.

Running "coffee:test" (coffee) task
File test/integration.spec.js created.
File test/oauth2.spec.js created.
File test/rest.spec.js created.

Running "concat:default" (concat) task
File "lib/oauth2.js" created.
File "lib/rest.js" created.

Running "bump::commit-only" (bump) task
>> Committed as "Bump version to 0.0.7"
>> Tagged as "v0.0.7"
>> Pushed to origin

Commit generated sources

31 Oct 16:06
Compare
Choose a tag to compare

Support OAuth2 and GET/POST

31 Oct 15:46
Compare
Choose a tag to compare

Add basic support for retrieving an access_token from a SPHERE.IO project as well as performing GET and POST HTTP requests to the SPHERE.IO API.