@medplum/core 0.9.29 → 0.9.32
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/client.d.ts +13 -11
- package/dist/cjs/index.js +7 -8
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/index.min.js +1 -1
- package/dist/cjs/index.min.js.map +1 -1
- package/dist/cjs/utils.d.ts +6 -0
- package/dist/esm/client.d.ts +13 -11
- package/dist/esm/client.js +4 -6
- package/dist/esm/client.js.map +1 -1
- package/dist/esm/fhirpath/utils.js +3 -3
- package/dist/esm/fhirpath/utils.js.map +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.min.js +1 -1
- package/dist/esm/index.min.js.map +1 -1
- package/dist/esm/utils.d.ts +6 -0
- package/dist/esm/utils.js +1 -1
- package/dist/esm/utils.js.map +1 -1
- package/package.json +3 -3
- package/stats.html +0 -4034
package/dist/cjs/client.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Binary, Bundle, Communication, ExtractResource, OperationOutcome, Project, ProjectMembership, Reference, Resource, ResourceType, UserConfiguration, ValueSet } from '@medplum/fhirtypes';
|
|
1
|
+
import { Binary, Bundle, Communication, ExtractResource, OperationOutcome, Project, ProjectMembership, ProjectSecret, Reference, Resource, ResourceType, UserConfiguration, ValueSet } from '@medplum/fhirtypes';
|
|
2
2
|
/** @ts-ignore */
|
|
3
3
|
import type { CustomTableLayout, TDocumentDefinitions, TFontDictionary } from 'pdfmake/interfaces';
|
|
4
4
|
import { EventTarget } from './eventtarget';
|
|
@@ -145,21 +145,22 @@ export interface LoginRequest {
|
|
|
145
145
|
readonly nonce?: string;
|
|
146
146
|
}
|
|
147
147
|
export interface NewUserRequest {
|
|
148
|
+
readonly firstName: string;
|
|
149
|
+
readonly lastName: string;
|
|
148
150
|
readonly email: string;
|
|
149
151
|
readonly password: string;
|
|
150
152
|
readonly recaptchaToken: string;
|
|
151
153
|
readonly recaptchaSiteKey?: string;
|
|
152
154
|
readonly remember?: boolean;
|
|
155
|
+
readonly projectId?: string;
|
|
153
156
|
}
|
|
154
157
|
export interface NewProjectRequest {
|
|
158
|
+
readonly login: string;
|
|
155
159
|
readonly projectName: string;
|
|
156
|
-
readonly firstName: string;
|
|
157
|
-
readonly lastName: string;
|
|
158
160
|
}
|
|
159
161
|
export interface NewPatientRequest {
|
|
162
|
+
readonly login: string;
|
|
160
163
|
readonly projectId: string;
|
|
161
|
-
readonly firstName: string;
|
|
162
|
-
readonly lastName: string;
|
|
163
164
|
}
|
|
164
165
|
export interface GoogleCredentialResponse {
|
|
165
166
|
readonly clientId: string;
|
|
@@ -168,9 +169,11 @@ export interface GoogleCredentialResponse {
|
|
|
168
169
|
export interface GoogleLoginRequest {
|
|
169
170
|
readonly googleClientId: string;
|
|
170
171
|
readonly googleCredential: string;
|
|
172
|
+
readonly projectId?: string;
|
|
171
173
|
readonly clientId?: string;
|
|
172
174
|
readonly scope?: string;
|
|
173
175
|
readonly nonce?: string;
|
|
176
|
+
readonly createUser?: boolean;
|
|
174
177
|
}
|
|
175
178
|
export interface LoginAuthenticationResponse {
|
|
176
179
|
readonly login: string;
|
|
@@ -200,9 +203,10 @@ export interface TokenResponse {
|
|
|
200
203
|
readonly project: Reference<Project>;
|
|
201
204
|
readonly profile: Reference<ProfileResource>;
|
|
202
205
|
}
|
|
203
|
-
export interface BotEvent {
|
|
206
|
+
export interface BotEvent<T = Resource | Hl7Message | string> {
|
|
204
207
|
readonly contentType: string;
|
|
205
|
-
readonly input:
|
|
208
|
+
readonly input: T;
|
|
209
|
+
readonly secrets: Record<string, ProjectSecret>;
|
|
206
210
|
}
|
|
207
211
|
/**
|
|
208
212
|
* JSONPatch patch operation.
|
|
@@ -425,20 +429,18 @@ export declare class MedplumClient extends EventTarget {
|
|
|
425
429
|
* This requires a partial login from `startNewUser` or `startNewGoogleUser`.
|
|
426
430
|
*
|
|
427
431
|
* @param newProjectRequest Register request including email and password.
|
|
428
|
-
* @param login The partial login to complete. This should come from the `startNewUser` method.
|
|
429
432
|
* @returns Promise to the authentication response.
|
|
430
433
|
*/
|
|
431
|
-
startNewProject(newProjectRequest: NewProjectRequest
|
|
434
|
+
startNewProject(newProjectRequest: NewProjectRequest): Promise<LoginAuthenticationResponse>;
|
|
432
435
|
/**
|
|
433
436
|
* Initiates a new patient flow.
|
|
434
437
|
*
|
|
435
438
|
* This requires a partial login from `startNewUser` or `startNewGoogleUser`.
|
|
436
439
|
*
|
|
437
440
|
* @param newPatientRequest Register request including email and password.
|
|
438
|
-
* @param login The partial login to complete. This should come from the `startNewUser` method.
|
|
439
441
|
* @returns Promise to the authentication response.
|
|
440
442
|
*/
|
|
441
|
-
startNewPatient(newPatientRequest: NewPatientRequest
|
|
443
|
+
startNewPatient(newPatientRequest: NewPatientRequest): Promise<LoginAuthenticationResponse>;
|
|
442
444
|
/**
|
|
443
445
|
* Initiates a user login flow.
|
|
444
446
|
* @category Authentication
|
package/dist/cjs/index.js
CHANGED
|
@@ -6494,12 +6494,11 @@
|
|
|
6494
6494
|
* This requires a partial login from `startNewUser` or `startNewGoogleUser`.
|
|
6495
6495
|
*
|
|
6496
6496
|
* @param newProjectRequest Register request including email and password.
|
|
6497
|
-
* @param login The partial login to complete. This should come from the `startNewUser` method.
|
|
6498
6497
|
* @returns Promise to the authentication response.
|
|
6499
6498
|
*/
|
|
6500
|
-
startNewProject(newProjectRequest
|
|
6499
|
+
startNewProject(newProjectRequest) {
|
|
6501
6500
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6502
|
-
return this.post('auth/newproject',
|
|
6501
|
+
return this.post('auth/newproject', newProjectRequest);
|
|
6503
6502
|
});
|
|
6504
6503
|
}
|
|
6505
6504
|
/**
|
|
@@ -6508,12 +6507,11 @@
|
|
|
6508
6507
|
* This requires a partial login from `startNewUser` or `startNewGoogleUser`.
|
|
6509
6508
|
*
|
|
6510
6509
|
* @param newPatientRequest Register request including email and password.
|
|
6511
|
-
* @param login The partial login to complete. This should come from the `startNewUser` method.
|
|
6512
6510
|
* @returns Promise to the authentication response.
|
|
6513
6511
|
*/
|
|
6514
|
-
startNewPatient(newPatientRequest
|
|
6512
|
+
startNewPatient(newPatientRequest) {
|
|
6515
6513
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6516
|
-
return this.post('auth/newpatient',
|
|
6514
|
+
return this.post('auth/newpatient', newPatientRequest);
|
|
6517
6515
|
});
|
|
6518
6516
|
}
|
|
6519
6517
|
/**
|
|
@@ -7771,7 +7769,7 @@
|
|
|
7771
7769
|
}
|
|
7772
7770
|
}
|
|
7773
7771
|
}
|
|
7774
|
-
if (resultValue
|
|
7772
|
+
if (isEmpty(resultValue)) {
|
|
7775
7773
|
return undefined;
|
|
7776
7774
|
}
|
|
7777
7775
|
if (resultType === 'BackboneElement') {
|
|
@@ -7816,7 +7814,7 @@
|
|
|
7816
7814
|
}
|
|
7817
7815
|
}
|
|
7818
7816
|
}
|
|
7819
|
-
if (result
|
|
7817
|
+
if (isEmpty(result)) {
|
|
7820
7818
|
return undefined;
|
|
7821
7819
|
}
|
|
7822
7820
|
if (Array.isArray(result)) {
|
|
@@ -11053,6 +11051,7 @@
|
|
|
11053
11051
|
exports.indexSearchParameter = indexSearchParameter;
|
|
11054
11052
|
exports.indexStructureDefinition = indexStructureDefinition;
|
|
11055
11053
|
exports.indexStructureDefinitionBundle = indexStructureDefinitionBundle;
|
|
11054
|
+
exports.isEmpty = isEmpty;
|
|
11056
11055
|
exports.isGone = isGone;
|
|
11057
11056
|
exports.isLowerCase = isLowerCase;
|
|
11058
11057
|
exports.isNotFound = isNotFound;
|