@@ -93,8 +93,21 @@ where:
9393 currently supported %terminologies APIs.
9494 * options.fhirServerUrl - a URL pointing to a FHIR RESTful API server that
9595 is used to ` resolve() ` resources.
96- * options.signal - an AbortSignal object that allows you to abort the
97- asynchronous FHIRPath expression evaluation.
96+ * options.signal - an AbortSignal object that allows you to [ abort the
97+ asynchronous FHIRPath expression evaluation] ( docs/abort.md ) .
98+ * options.httpHeaders - an object with HTTP headers that will be used
99+ when making requests to FHIR servers (e.g. for terminology servers).
100+ The object has the following structure:
101+ ```
102+ {
103+ <server base url>: {
104+ <header name>: <header value>,
105+ ...
106+ },
107+ ...
108+ }
109+ ```
110+ See [authentication to FHIR servers](docs/auth.md).
98111
99112Note: The resource will be modified by this function to add type information.
100113
@@ -186,22 +199,6 @@ const path = fhirpath.compile(
186199);
187200` ` `
188201
189- But passing the ` signal` option to compile() whose result is used more than once
190- will cause abortion problems. If you need to abort the evaluation of the compiled
191- expression, you should pass the signal option to the function that is returned
192- by compile():
193-
194- ` ` ` js
195- const path = fhirpath .compile (
196- expression, model, {async: true }
197- );
198- const abortController = new AbortController ();
199- const signal = abortController .signal ;
200- let res = path (resource, environment, {signal});
201- // Abort the evaluation of the compiled expression
202- abortController .abort ();
203- ` ` `
204-
205202If at some point you decide to convert all values which have internal types to
206203standard JavaScript types you can use the special function "resolveInternalTypes":
207204
0 commit comments