openehr-cdr-query
v0.0.3
Published
ES6 module for querying openEHR CDRs
Readme
openehr-cdr-query
API
Table of Contents
CDR
A connection to a single Clinical Data Repository
Parameters
configObject CDR configuration
query
Runs an AQL query against the CDR
Parameters
aqlString The AQL query to run
Returns Promise<Object> A promise resolving with the parsed JSON result of the query from the CDR, or rejecting with a CDRError
CDRs
A connection to multiple Clinical Data Repositories
Parameters
query
Runs an AQL query against the CDRs
Parameters
aqlString The AQL query to run
Returns CDRsResponse<Array<Promise>> Object representing responses from the CDRs
CDRsResponse
Class which combines responses from multiple CDRs
Parameters
promisesArray<Promises> Array of promises from calling the API
all
Wait for all API calls to succeed before resolving. If one fails, they all fail.
Returns CDRsFormatter<Promise>
CDRsFormatter
Class which formats responses from multiple CDRs
Parameters
promisePromise Promise which resolves with the result of an API call
concat
Concatenate results of multiple API calls
Returns Promise Promise which resolves with concatenated results
CDRError
Extends Error
Represents an error when communicating with a Clinical Data Repository
Parameters
resObject node-fetch response object
