d2l-insights-data-providers v0.11.0
d2l-insights-data-providers
Data provider for Metron and Valence APIs
API Docs
valence.retrieveAllObjectListPagesPromise(path)
Retrieve all pages from Valence path
and returns a ES6 promise with the result. This method handles Valence routes that return an ObjectListPage. This method will fetch all pages and concatenate them together before returning. When you use this one, be aware of the performance hit, as the API doesn't usually do pagination for no reason.
valence.retrieveAllPagedResultSetsPromise(path)
Retrieve all pages from Valence path
and returns a ES6 promise with the result. This method handles Valence routes that return a PagedResultSet. This method will fetch all pages and concatenate them together before returning. When you use this one, be aware of the performance hit, as the API doesn't usually do pagination for no reason.
valence.retrieveAllPagesPromise(path)
(deprecated)
valence.retrieveAllPagesPromise(path)
This points to valence.retrieveAllPagedResultSetsPromise(path)
but will be removed in a future release. Do not use this method.
valence.retrieveResponsePromise(path)
Retrieve response from valence path
and returns a ES6 promise with the result. This returns the http response object to you as a promise.
valence.retrieveDataPromise(path)
Retrieve data from valence path
and returns a ES6 promise with the result. This returns the body
property of the http response object to you as a promise, so it does a little more than retrieveResponsePromise()
so that you don't need to say res.body
.
metron.retrieveDataPromise(path)
Retrieve data from metron path
and returns a ES6 promise with the result. This is merely the body
property of the http response object wrapped in a promise.