This repository has been archived by the owner on Dec 27, 2018. It is now read-only.
Releases: sphereio/sphere-node-connect
Releases · sphereio/sphere-node-connect
v0.5.8
v0.5.7
v0.5.6
v0.5.5
v0.5.4
v0.5.3
v0.5.2
v0.5.1
Fixes:
- use correct version
v0.3.1
ofsphere-node-utils
which requiresbunyan
dependency for Logger
v0.5.0
@deprecated: use version 0.5.1
Logger
is no longer exposed in this module, instead it's available in thesphere-node-utils
packageNote that the
sphere-node-connect
still uses internally the logger- introduce
PAGED
request with progress subscriptionA
PAGED
request is an HTTP GET to one of the API query endpoints. It should be used to retrieve all results of the specified resource. It uses internally a recursive function to accumulate results in chunks.
rest = new Rest options
rest.PAGED '/products', (error, response, body) ->
# do something
You can subscribe to progress notification by specifying a second callback
rest = new Rest options
rest.PAGED '/products', (error, response, body) ->
# do something
, (progress) ->
# progress is an object containing the current progress percentage
# and the value of the current results (array)
# {percentage: 20, value: [r1, r2, r3, ...]}