@oystehr/sdk 3.0.0 → 3.0.1
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/client.d.ts +2 -2
- package/dist/cjs/index.cjs +5 -3
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/index.min.cjs +1 -1
- package/dist/cjs/index.min.cjs.map +1 -1
- package/dist/cjs/resources/classes/fhir-ext.d.ts +9 -33
- package/dist/cjs/resources/classes/index.d.ts +1 -0
- package/dist/cjs/resources/types/AccessPolicy.d.ts +1 -1
- package/dist/cjs/resources/types/ClaimCMS1500.d.ts +5 -5
- package/dist/cjs/resources/types/ConversationAddParticipantParams.d.ts +1 -1
- package/dist/cjs/resources/types/ErxMedicationSearchResponse.d.ts +3 -3
- package/dist/cjs/resources/types/Project.d.ts +1 -1
- package/dist/cjs/resources/types/VersionGetResponse.d.ts +2 -2
- package/dist/cjs/resources/types/Z3GetPresignedUrlParams.d.ts +1 -1
- package/dist/cjs/resources/types/ZambdaCreateParams.d.ts +1 -1
- package/dist/cjs/resources/types/ZambdaFunction.d.ts +2 -2
- package/dist/cjs/resources/types/ZambdaUpdateParams.d.ts +2 -2
- package/dist/cjs/resources/types/fhir.d.ts +34 -1
- package/dist/esm/client/client.d.ts +2 -2
- package/dist/esm/client/client.js.map +1 -1
- package/dist/esm/index.min.js +1 -1
- package/dist/esm/index.min.js.map +1 -1
- package/dist/esm/resources/classes/fhir-ext.d.ts +9 -33
- package/dist/esm/resources/classes/fhir-ext.js +4 -3
- package/dist/esm/resources/classes/fhir-ext.js.map +1 -1
- package/dist/esm/resources/classes/index.d.ts +1 -0
- package/dist/esm/resources/classes/index.js +1 -0
- package/dist/esm/resources/classes/index.js.map +1 -1
- package/dist/esm/resources/types/AccessPolicy.d.ts +1 -1
- package/dist/esm/resources/types/ClaimCMS1500.d.ts +5 -5
- package/dist/esm/resources/types/ConversationAddParticipantParams.d.ts +1 -1
- package/dist/esm/resources/types/ErxMedicationSearchResponse.d.ts +3 -3
- package/dist/esm/resources/types/Project.d.ts +1 -1
- package/dist/esm/resources/types/VersionGetResponse.d.ts +2 -2
- package/dist/esm/resources/types/Z3GetPresignedUrlParams.d.ts +1 -1
- package/dist/esm/resources/types/ZambdaCreateParams.d.ts +1 -1
- package/dist/esm/resources/types/ZambdaFunction.d.ts +2 -2
- package/dist/esm/resources/types/ZambdaUpdateParams.d.ts +2 -2
- package/dist/esm/resources/types/fhir.d.ts +34 -1
- package/package.json +1 -1
- package/src/client/client.ts +2 -2
- package/src/resources/classes/fhir-ext.ts +28 -12
- package/src/resources/classes/index.ts +2 -0
- package/src/resources/types/AccessPolicy.ts +1 -1
- package/src/resources/types/ClaimCMS1500.ts +12 -5
- package/src/resources/types/ConversationAddParticipantParams.ts +1 -1
- package/src/resources/types/ErxMedicationSearchResponse.ts +3 -3
- package/src/resources/types/Project.ts +1 -1
- package/src/resources/types/VersionGetResponse.ts +2 -2
- package/src/resources/types/Z3GetPresignedUrlParams.ts +1 -1
- package/src/resources/types/ZambdaCreateParams.ts +1 -1
- package/src/resources/types/ZambdaFunction.ts +2 -2
- package/src/resources/types/ZambdaUpdateParams.ts +2 -2
- package/src/resources/types/fhir.ts +56 -2
|
@@ -15,11 +15,11 @@ export interface ZambdaFunction {
|
|
|
15
15
|
/**
|
|
16
16
|
* The Zambda Function status provides information about the Functions state including whether it is ready to be invoked.
|
|
17
17
|
*/
|
|
18
|
-
status:
|
|
18
|
+
status: 'Draft' | 'Pending' | 'Active' | 'Failed' | 'Inactive' | 'Validating';
|
|
19
19
|
/**
|
|
20
20
|
* The trigger method for the Zambda Function determines how the Function is invoked. Learn more about the different types here, https://docs.oystehr.com/services/zambda/#types-of-zambdas.
|
|
21
21
|
*/
|
|
22
|
-
triggerMethod:
|
|
22
|
+
triggerMethod: 'http_auth' | 'http_open' | 'subscription' | 'cron';
|
|
23
23
|
schedule?: ZambdaSchedule;
|
|
24
24
|
/**
|
|
25
25
|
* Info about the zip file that was uploaded for the Zambda Function.
|
|
@@ -10,11 +10,11 @@ export interface ZambdaUpdateParams {
|
|
|
10
10
|
/**
|
|
11
11
|
* The trigger method for the Zambda Function determines how the Function is invoked. Learn more about the different types here, https://docs.oystehr.com/services/zambda/#types-of-zambdas.
|
|
12
12
|
*/
|
|
13
|
-
triggerMethod?:
|
|
13
|
+
triggerMethod?: 'http_auth' | 'http_open' | 'subscription' | 'cron';
|
|
14
14
|
schedule?: ZambdaSchedule;
|
|
15
15
|
/**
|
|
16
16
|
* The runtime to use for the Zambda Function. This property is optional and defaults to "nodejs20.x".
|
|
17
17
|
*/
|
|
18
|
-
runtime?:
|
|
18
|
+
runtime?: 'nodejs18.x' | 'nodejs20.x';
|
|
19
19
|
id: string;
|
|
20
20
|
}
|
|
@@ -15,12 +15,66 @@ import type {
|
|
|
15
15
|
} from 'fhir/r5';
|
|
16
16
|
|
|
17
17
|
export type FhirResource = FhirResourceR4B | FhirResourceR5;
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
// We're doing this "Omit dance" with the Bundle types because TypeScript
|
|
19
|
+
// produces incorrect BundleEntry<F> types when F is a union of multiple FHIR
|
|
20
|
+
// types. The guess is it's something about the conditional generic typing, but
|
|
21
|
+
// we haven't found a different way to resolve it.
|
|
22
|
+
//
|
|
23
|
+
// No "omit dance":
|
|
24
|
+
// entry: BundleEntry<Patient>[] | BundleEntry<Practitioner>[] | undefined
|
|
25
|
+
// With "omit dance":
|
|
26
|
+
// entry: (BundleEntry<Patient> | BundleEntry<Practitioner>)[] | undefined
|
|
27
|
+
//
|
|
28
|
+
// The latter can be used with array functions like `.find()`.
|
|
29
|
+
export type FhirBundle<F extends FhirResource> = F extends FhirResourceR4B
|
|
30
|
+
? Omit<BundleR4B<F>, 'entry'>
|
|
31
|
+
: Omit<BundleR5<F>, 'entry'>;
|
|
32
|
+
export type Bundle<F extends FhirResource> = FhirBundle<F> & {
|
|
33
|
+
entry?: Array<BundleEntry<F>> | undefined;
|
|
34
|
+
unbundle: (this: Bundle<F>) => F[];
|
|
35
|
+
};
|
|
20
36
|
export type BundleEntry<F extends FhirResource> = F extends FhirResourceR4B ? BundleEntryR4B<F> : BundleEntryR5<F>;
|
|
21
37
|
export type Binary<F extends FhirResource> = F extends FhirResourceR4B ? BinaryR4B : BinaryR5;
|
|
22
38
|
export type OperationOutcome = OperationOutcomeR4B | OperationOutcomeR5;
|
|
23
39
|
|
|
40
|
+
export type SearchParam = { name: string; value: string | number };
|
|
41
|
+
|
|
42
|
+
export interface FhirSearchParams {
|
|
43
|
+
resourceType: string;
|
|
44
|
+
params?: SearchParam[];
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export interface FhirGetParams {
|
|
48
|
+
resourceType: string;
|
|
49
|
+
id: string;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export type FhirCreateParams<T extends FhirResource> = T;
|
|
53
|
+
|
|
54
|
+
export type FhirUpdateParams<T extends FhirResource> = T;
|
|
55
|
+
|
|
56
|
+
export interface FhirPatchParams {
|
|
57
|
+
resourceType: string;
|
|
58
|
+
id: string;
|
|
59
|
+
operations: Operation[];
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export interface FhirDeleteParams {
|
|
63
|
+
resourceType: string;
|
|
64
|
+
id: string;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export interface FhirHistorySearchParams {
|
|
68
|
+
resourceType: string;
|
|
69
|
+
id: string;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export interface FhirHistoryGetParams {
|
|
73
|
+
resourceType: string;
|
|
74
|
+
id: string;
|
|
75
|
+
versionId: string;
|
|
76
|
+
}
|
|
77
|
+
|
|
24
78
|
interface BatchInputBaseRequest {
|
|
25
79
|
url: string;
|
|
26
80
|
}
|