@medplum/core 3.2.25 → 3.2.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.cjs +14 -5
- package/dist/cjs/index.cjs.map +4 -4
- package/dist/cjs/index.d.ts +42 -2
- package/dist/esm/index.d.ts +42 -2
- package/dist/esm/index.mjs +14 -5
- package/dist/esm/index.mjs.map +4 -4
- package/package.json +3 -3
package/dist/cjs/index.d.ts
CHANGED
|
@@ -1342,6 +1342,17 @@ export declare const fhirTypeToJsType: {
|
|
|
1342
1342
|
readonly 'http://hl7.org/fhirpath/System.String': "string";
|
|
1343
1343
|
};
|
|
1344
1344
|
|
|
1345
|
+
export declare class FileBuilder {
|
|
1346
|
+
private readonly indent;
|
|
1347
|
+
private readonly b;
|
|
1348
|
+
indentCount: number;
|
|
1349
|
+
constructor(indent?: string, header?: boolean);
|
|
1350
|
+
newLine(): void;
|
|
1351
|
+
appendNoWrap(line: string): void;
|
|
1352
|
+
append(line: string): void;
|
|
1353
|
+
toString(): string;
|
|
1354
|
+
}
|
|
1355
|
+
|
|
1345
1356
|
export declare interface Filter {
|
|
1346
1357
|
code: string;
|
|
1347
1358
|
operator: Operator;
|
|
@@ -1487,6 +1498,13 @@ export declare function formatQuantity(quantity: Quantity | undefined, precision
|
|
|
1487
1498
|
*/
|
|
1488
1499
|
export declare function formatRange(range: Range_2 | undefined, precision?: number, exclusive?: boolean): string;
|
|
1489
1500
|
|
|
1501
|
+
/**
|
|
1502
|
+
* Formats a FHIR Reference as a string.
|
|
1503
|
+
* @param value - The reference to format.
|
|
1504
|
+
* @returns The formatted reference string.
|
|
1505
|
+
*/
|
|
1506
|
+
export declare function formatReferenceString(value: Reference | undefined): string;
|
|
1507
|
+
|
|
1490
1508
|
/**
|
|
1491
1509
|
* Formats a search definition object into a query string.
|
|
1492
1510
|
* Note: The return value does not include the resource type.
|
|
@@ -3850,6 +3868,14 @@ export declare class MedplumClient extends TypedEventTarget<MedplumClientEventMa
|
|
|
3850
3868
|
* @category Authentication
|
|
3851
3869
|
*/
|
|
3852
3870
|
getAccessToken(): string | undefined;
|
|
3871
|
+
/**
|
|
3872
|
+
* Returns whether the client has a valid access token or not.
|
|
3873
|
+
* @param gracePeriod - Optional grace period in milliseconds. If not specified, uses the client configured grace period (default 5 minutes).
|
|
3874
|
+
* @returns Boolean indicating whether or not the client is authenticated.
|
|
3875
|
+
*
|
|
3876
|
+
* **NOTE: Does not check whether the auth token has been revoked server-side.**
|
|
3877
|
+
*/
|
|
3878
|
+
isAuthenticated(gracePeriod?: number): boolean;
|
|
3853
3879
|
/**
|
|
3854
3880
|
* Sets the current access token.
|
|
3855
3881
|
* @param accessToken - The new access token.
|
|
@@ -4524,7 +4550,6 @@ export declare interface MedplumClientOptions {
|
|
|
4524
4550
|
/**
|
|
4525
4551
|
* Default headers to include in all requests.
|
|
4526
4552
|
* This can be used to set custom headers such as Cookies or Authorization headers.
|
|
4527
|
-
* @default {}
|
|
4528
4553
|
*/
|
|
4529
4554
|
defaultHeaders?: Record<string, string>;
|
|
4530
4555
|
}
|
|
@@ -5591,7 +5616,6 @@ export declare const RXNORM = "http://www.nlm.nih.gov/research/umls/rxnorm";
|
|
|
5591
5616
|
export declare function satisfiedAccessPolicy(resource: Resource, interaction: AccessPolicyInteraction, accessPolicy: AccessPolicy | undefined): AccessPolicyResource | undefined;
|
|
5592
5617
|
|
|
5593
5618
|
export declare interface SearchParameterDetails {
|
|
5594
|
-
readonly columnName: string;
|
|
5595
5619
|
readonly type: SearchParameterType;
|
|
5596
5620
|
readonly elementDefinitions?: InternalSchemaElement[];
|
|
5597
5621
|
readonly array?: boolean;
|
|
@@ -6043,6 +6067,13 @@ export declare interface TypedValue {
|
|
|
6043
6067
|
readonly value: any;
|
|
6044
6068
|
}
|
|
6045
6069
|
|
|
6070
|
+
/**
|
|
6071
|
+
* Converts a typed value to a string.
|
|
6072
|
+
* @param typedValue - The typed value to convert to a string.
|
|
6073
|
+
* @returns The string representation of the typed value.
|
|
6074
|
+
*/
|
|
6075
|
+
export declare function typedValueToString(typedValue: TypedValue | undefined): string;
|
|
6076
|
+
|
|
6046
6077
|
export declare type TypedValueWithPath = TypedValue & {
|
|
6047
6078
|
path: string;
|
|
6048
6079
|
};
|
|
@@ -6166,6 +6197,15 @@ declare type WebSocketEventMap_2 = {
|
|
|
6166
6197
|
};
|
|
6167
6198
|
export { WebSocketEventMap_2 as WebSocketEventMap }
|
|
6168
6199
|
|
|
6200
|
+
/**
|
|
6201
|
+
* Returns a word-wrapped string.
|
|
6202
|
+
* Based on: https://stackoverflow.com/a/38709683
|
|
6203
|
+
* @param text - Original input string.
|
|
6204
|
+
* @param maxLength - Width in number of characters.
|
|
6205
|
+
* @returns Array of lines.
|
|
6206
|
+
*/
|
|
6207
|
+
export declare function wordWrap(text: string, maxLength: number): string[];
|
|
6208
|
+
|
|
6169
6209
|
/**
|
|
6170
6210
|
* 6.5.4. xor
|
|
6171
6211
|
* Returns true if exactly one of the operands evaluates to true,
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -1342,6 +1342,17 @@ export declare const fhirTypeToJsType: {
|
|
|
1342
1342
|
readonly 'http://hl7.org/fhirpath/System.String': "string";
|
|
1343
1343
|
};
|
|
1344
1344
|
|
|
1345
|
+
export declare class FileBuilder {
|
|
1346
|
+
private readonly indent;
|
|
1347
|
+
private readonly b;
|
|
1348
|
+
indentCount: number;
|
|
1349
|
+
constructor(indent?: string, header?: boolean);
|
|
1350
|
+
newLine(): void;
|
|
1351
|
+
appendNoWrap(line: string): void;
|
|
1352
|
+
append(line: string): void;
|
|
1353
|
+
toString(): string;
|
|
1354
|
+
}
|
|
1355
|
+
|
|
1345
1356
|
export declare interface Filter {
|
|
1346
1357
|
code: string;
|
|
1347
1358
|
operator: Operator;
|
|
@@ -1487,6 +1498,13 @@ export declare function formatQuantity(quantity: Quantity | undefined, precision
|
|
|
1487
1498
|
*/
|
|
1488
1499
|
export declare function formatRange(range: Range_2 | undefined, precision?: number, exclusive?: boolean): string;
|
|
1489
1500
|
|
|
1501
|
+
/**
|
|
1502
|
+
* Formats a FHIR Reference as a string.
|
|
1503
|
+
* @param value - The reference to format.
|
|
1504
|
+
* @returns The formatted reference string.
|
|
1505
|
+
*/
|
|
1506
|
+
export declare function formatReferenceString(value: Reference | undefined): string;
|
|
1507
|
+
|
|
1490
1508
|
/**
|
|
1491
1509
|
* Formats a search definition object into a query string.
|
|
1492
1510
|
* Note: The return value does not include the resource type.
|
|
@@ -3850,6 +3868,14 @@ export declare class MedplumClient extends TypedEventTarget<MedplumClientEventMa
|
|
|
3850
3868
|
* @category Authentication
|
|
3851
3869
|
*/
|
|
3852
3870
|
getAccessToken(): string | undefined;
|
|
3871
|
+
/**
|
|
3872
|
+
* Returns whether the client has a valid access token or not.
|
|
3873
|
+
* @param gracePeriod - Optional grace period in milliseconds. If not specified, uses the client configured grace period (default 5 minutes).
|
|
3874
|
+
* @returns Boolean indicating whether or not the client is authenticated.
|
|
3875
|
+
*
|
|
3876
|
+
* **NOTE: Does not check whether the auth token has been revoked server-side.**
|
|
3877
|
+
*/
|
|
3878
|
+
isAuthenticated(gracePeriod?: number): boolean;
|
|
3853
3879
|
/**
|
|
3854
3880
|
* Sets the current access token.
|
|
3855
3881
|
* @param accessToken - The new access token.
|
|
@@ -4524,7 +4550,6 @@ export declare interface MedplumClientOptions {
|
|
|
4524
4550
|
/**
|
|
4525
4551
|
* Default headers to include in all requests.
|
|
4526
4552
|
* This can be used to set custom headers such as Cookies or Authorization headers.
|
|
4527
|
-
* @default {}
|
|
4528
4553
|
*/
|
|
4529
4554
|
defaultHeaders?: Record<string, string>;
|
|
4530
4555
|
}
|
|
@@ -5591,7 +5616,6 @@ export declare const RXNORM = "http://www.nlm.nih.gov/research/umls/rxnorm";
|
|
|
5591
5616
|
export declare function satisfiedAccessPolicy(resource: Resource, interaction: AccessPolicyInteraction, accessPolicy: AccessPolicy | undefined): AccessPolicyResource | undefined;
|
|
5592
5617
|
|
|
5593
5618
|
export declare interface SearchParameterDetails {
|
|
5594
|
-
readonly columnName: string;
|
|
5595
5619
|
readonly type: SearchParameterType;
|
|
5596
5620
|
readonly elementDefinitions?: InternalSchemaElement[];
|
|
5597
5621
|
readonly array?: boolean;
|
|
@@ -6043,6 +6067,13 @@ export declare interface TypedValue {
|
|
|
6043
6067
|
readonly value: any;
|
|
6044
6068
|
}
|
|
6045
6069
|
|
|
6070
|
+
/**
|
|
6071
|
+
* Converts a typed value to a string.
|
|
6072
|
+
* @param typedValue - The typed value to convert to a string.
|
|
6073
|
+
* @returns The string representation of the typed value.
|
|
6074
|
+
*/
|
|
6075
|
+
export declare function typedValueToString(typedValue: TypedValue | undefined): string;
|
|
6076
|
+
|
|
6046
6077
|
export declare type TypedValueWithPath = TypedValue & {
|
|
6047
6078
|
path: string;
|
|
6048
6079
|
};
|
|
@@ -6166,6 +6197,15 @@ declare type WebSocketEventMap_2 = {
|
|
|
6166
6197
|
};
|
|
6167
6198
|
export { WebSocketEventMap_2 as WebSocketEventMap }
|
|
6168
6199
|
|
|
6200
|
+
/**
|
|
6201
|
+
* Returns a word-wrapped string.
|
|
6202
|
+
* Based on: https://stackoverflow.com/a/38709683
|
|
6203
|
+
* @param text - Original input string.
|
|
6204
|
+
* @param maxLength - Width in number of characters.
|
|
6205
|
+
* @returns Array of lines.
|
|
6206
|
+
*/
|
|
6207
|
+
export declare function wordWrap(text: string, maxLength: number): string[];
|
|
6208
|
+
|
|
6169
6209
|
/**
|
|
6170
6210
|
* 6.5.4. xor
|
|
6171
6211
|
* Returns true if exactly one of the operands evaluates to true,
|