candidhealth 0.24.0-2a6d412 → 0.24.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/Client.d.ts +3 -0
- package/README.md +134 -6
- package/api/resources/auth/client/Client.d.ts +3 -0
- package/api/resources/auth/resources/v2/client/Client.d.ts +4 -1
- package/api/resources/auth/resources/v2/client/Client.js +6 -7
- package/api/resources/billingNotes/client/Client.d.ts +3 -0
- package/api/resources/billingNotes/resources/v2/client/Client.d.ts +4 -1
- package/api/resources/billingNotes/resources/v2/client/Client.js +5 -4
- package/api/resources/contracts/client/Client.d.ts +3 -0
- package/api/resources/contracts/resources/v2/client/Client.d.ts +8 -5
- package/api/resources/contracts/resources/v2/client/Client.js +27 -26
- package/api/resources/eligibility/client/Client.d.ts +3 -0
- package/api/resources/eligibility/resources/v2/client/Client.d.ts +6 -3
- package/api/resources/eligibility/resources/v2/client/Client.js +12 -9
- package/api/resources/encounters/client/Client.d.ts +3 -0
- package/api/resources/encounters/resources/v4/client/Client.d.ts +7 -19
- package/api/resources/encounters/resources/v4/client/Client.js +22 -37
- package/api/resources/encounters/resources/v4/client/requests/EncounterCreate.d.ts +0 -21
- package/api/resources/encounters/resources/v4/types/Encounter.d.ts +0 -1
- package/api/resources/expectedNetworkStatus/client/Client.d.ts +3 -0
- package/api/resources/expectedNetworkStatus/resources/v1/client/Client.d.ts +4 -1
- package/api/resources/expectedNetworkStatus/resources/v1/client/Client.js +5 -4
- package/api/resources/expectedNetworkStatus/resources/v2/client/Client.d.ts +5 -2
- package/api/resources/expectedNetworkStatus/resources/v2/client/Client.js +13 -11
- package/api/resources/exports/client/Client.d.ts +3 -0
- package/api/resources/exports/resources/v3/client/Client.d.ts +4 -1
- package/api/resources/exports/resources/v3/client/Client.js +5 -4
- package/api/resources/externalPaymentAccountConfig/client/Client.d.ts +3 -0
- package/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.d.ts +4 -1
- package/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.js +4 -3
- package/api/resources/feeSchedules/client/Client.d.ts +3 -0
- package/api/resources/feeSchedules/resources/v3/client/Client.d.ts +13 -10
- package/api/resources/feeSchedules/resources/v3/client/Client.js +52 -44
- package/api/resources/guarantor/client/Client.d.ts +3 -0
- package/api/resources/guarantor/resources/v1/client/Client.d.ts +6 -3
- package/api/resources/guarantor/resources/v1/client/Client.js +18 -19
- package/api/resources/importInvoice/client/Client.d.ts +3 -0
- package/api/resources/importInvoice/resources/v1/client/Client.d.ts +7 -4
- package/api/resources/importInvoice/resources/v1/client/Client.js +22 -18
- package/api/resources/insuranceAdjudications/client/Client.d.ts +3 -0
- package/api/resources/insuranceAdjudications/resources/v1/client/Client.d.ts +6 -3
- package/api/resources/insuranceAdjudications/resources/v1/client/Client.js +15 -12
- package/api/resources/insurancePayments/client/Client.d.ts +3 -0
- package/api/resources/insurancePayments/resources/v1/client/Client.d.ts +8 -5
- package/api/resources/insurancePayments/resources/v1/client/Client.js +29 -24
- package/api/resources/insuranceRefunds/client/Client.d.ts +3 -0
- package/api/resources/insuranceRefunds/resources/v1/client/Client.d.ts +8 -5
- package/api/resources/insuranceRefunds/resources/v1/client/Client.js +29 -24
- package/api/resources/organizationProviders/client/Client.d.ts +3 -0
- package/api/resources/organizationProviders/resources/v3/client/Client.d.ts +7 -4
- package/api/resources/organizationProviders/resources/v3/client/Client.js +23 -19
- package/api/resources/organizationServiceFacilities/client/Client.d.ts +3 -0
- package/api/resources/organizationServiceFacilities/resources/v2/client/Client.d.ts +8 -5
- package/api/resources/organizationServiceFacilities/resources/v2/client/Client.js +32 -23
- package/api/resources/patientPayments/client/Client.d.ts +3 -0
- package/api/resources/patientPayments/resources/v4/client/Client.d.ts +8 -5
- package/api/resources/patientPayments/resources/v4/client/Client.js +29 -24
- package/api/resources/patientRefunds/client/Client.d.ts +3 -0
- package/api/resources/patientRefunds/resources/v1/client/Client.d.ts +8 -5
- package/api/resources/patientRefunds/resources/v1/client/Client.js +29 -24
- package/api/resources/payers/client/Client.d.ts +3 -0
- package/api/resources/payers/resources/v3/client/Client.d.ts +5 -2
- package/api/resources/payers/resources/v3/client/Client.js +9 -7
- package/api/resources/preEncounter/client/Client.d.ts +3 -0
- package/api/resources/preEncounter/resources/coverages/client/Client.d.ts +3 -0
- package/api/resources/preEncounter/resources/coverages/resources/v1/client/Client.d.ts +3 -0
- package/api/resources/preEncounter/resources/coverages/resources/v1/resources/coverages/client/Client.d.ts +9 -6
- package/api/resources/preEncounter/resources/coverages/resources/v1/resources/coverages/client/Client.js +31 -25
- package/api/resources/preEncounter/resources/patients/client/Client.d.ts +3 -0
- package/api/resources/preEncounter/resources/patients/resources/v1/client/Client.d.ts +3 -0
- package/api/resources/preEncounter/resources/patients/resources/v1/resources/patients/client/Client.d.ts +10 -7
- package/api/resources/preEncounter/resources/patients/resources/v1/resources/patients/client/Client.js +38 -31
- package/api/resources/serviceFacility/client/Client.d.ts +4 -1
- package/api/resources/serviceFacility/client/Client.js +6 -7
- package/api/resources/tasks/client/Client.d.ts +3 -0
- package/api/resources/tasks/resources/v3/client/Client.d.ts +8 -5
- package/api/resources/tasks/resources/v3/client/Client.js +28 -23
- package/api/resources/writeOffs/client/Client.d.ts +3 -0
- package/api/resources/writeOffs/resources/v1/client/Client.d.ts +7 -4
- package/api/resources/writeOffs/resources/v1/client/Client.js +19 -15
- package/core/fetcher/Fetcher.d.ts +3 -0
- package/core/fetcher/Fetcher.js +22 -153
- package/core/fetcher/createRequestUrl.d.ts +1 -0
- package/core/fetcher/createRequestUrl.js +13 -0
- package/core/fetcher/getFetchFn.d.ts +4 -0
- package/core/fetcher/getFetchFn.js +59 -0
- package/core/fetcher/getRequestBody.d.ts +7 -0
- package/core/fetcher/getRequestBody.js +23 -0
- package/core/fetcher/getResponseBody.d.ts +1 -0
- package/core/fetcher/getResponseBody.js +48 -0
- package/core/fetcher/makeRequest.d.ts +1 -0
- package/core/fetcher/makeRequest.js +42 -0
- package/core/fetcher/requestWithRetries.d.ts +1 -0
- package/core/fetcher/requestWithRetries.js +32 -0
- package/core/fetcher/signals.d.ts +12 -0
- package/core/fetcher/signals.js +37 -0
- package/core/runtime/runtime.d.ts +2 -1
- package/core/runtime/runtime.js +12 -1
- package/core/schemas/Schema.d.ts +7 -4
- package/core/schemas/builders/lazy/lazy.d.ts +2 -2
- package/core/schemas/builders/lazy/lazy.js +8 -19
- package/core/schemas/builders/lazy/lazyObject.js +1 -10
- package/core/schemas/builders/list/list.js +31 -44
- package/core/schemas/builders/object/object.js +90 -111
- package/core/schemas/builders/object/types.d.ts +2 -2
- package/core/schemas/builders/object-like/getObjectLikeUtils.js +3 -12
- package/core/schemas/builders/record/record.js +49 -60
- package/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +2 -2
- package/core/schemas/builders/schema-utils/getSchemaUtils.js +18 -21
- package/core/schemas/builders/set/set.js +6 -15
- package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +21 -32
- package/core/schemas/builders/union/union.js +51 -62
- package/core/schemas/utils/maybeSkipValidation.js +3 -12
- package/dist/Client.d.ts +3 -0
- package/dist/api/resources/auth/client/Client.d.ts +3 -0
- package/dist/api/resources/auth/resources/v2/client/Client.d.ts +4 -1
- package/dist/api/resources/auth/resources/v2/client/Client.js +6 -7
- package/dist/api/resources/billingNotes/client/Client.d.ts +3 -0
- package/dist/api/resources/billingNotes/resources/v2/client/Client.d.ts +4 -1
- package/dist/api/resources/billingNotes/resources/v2/client/Client.js +5 -4
- package/dist/api/resources/contracts/client/Client.d.ts +3 -0
- package/dist/api/resources/contracts/resources/v2/client/Client.d.ts +8 -5
- package/dist/api/resources/contracts/resources/v2/client/Client.js +27 -26
- package/dist/api/resources/eligibility/client/Client.d.ts +3 -0
- package/dist/api/resources/eligibility/resources/v2/client/Client.d.ts +6 -3
- package/dist/api/resources/eligibility/resources/v2/client/Client.js +12 -9
- package/dist/api/resources/encounters/client/Client.d.ts +3 -0
- package/dist/api/resources/encounters/resources/v4/client/Client.d.ts +7 -19
- package/dist/api/resources/encounters/resources/v4/client/Client.js +22 -37
- package/dist/api/resources/encounters/resources/v4/client/requests/EncounterCreate.d.ts +0 -21
- package/dist/api/resources/encounters/resources/v4/types/Encounter.d.ts +0 -1
- package/dist/api/resources/expectedNetworkStatus/client/Client.d.ts +3 -0
- package/dist/api/resources/expectedNetworkStatus/resources/v1/client/Client.d.ts +4 -1
- package/dist/api/resources/expectedNetworkStatus/resources/v1/client/Client.js +5 -4
- package/dist/api/resources/expectedNetworkStatus/resources/v2/client/Client.d.ts +5 -2
- package/dist/api/resources/expectedNetworkStatus/resources/v2/client/Client.js +13 -11
- package/dist/api/resources/exports/client/Client.d.ts +3 -0
- package/dist/api/resources/exports/resources/v3/client/Client.d.ts +4 -1
- package/dist/api/resources/exports/resources/v3/client/Client.js +5 -4
- package/dist/api/resources/externalPaymentAccountConfig/client/Client.d.ts +3 -0
- package/dist/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.d.ts +4 -1
- package/dist/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.js +4 -3
- package/dist/api/resources/feeSchedules/client/Client.d.ts +3 -0
- package/dist/api/resources/feeSchedules/resources/v3/client/Client.d.ts +13 -10
- package/dist/api/resources/feeSchedules/resources/v3/client/Client.js +52 -44
- package/dist/api/resources/guarantor/client/Client.d.ts +3 -0
- package/dist/api/resources/guarantor/resources/v1/client/Client.d.ts +6 -3
- package/dist/api/resources/guarantor/resources/v1/client/Client.js +18 -19
- package/dist/api/resources/importInvoice/client/Client.d.ts +3 -0
- package/dist/api/resources/importInvoice/resources/v1/client/Client.d.ts +7 -4
- package/dist/api/resources/importInvoice/resources/v1/client/Client.js +22 -18
- package/dist/api/resources/insuranceAdjudications/client/Client.d.ts +3 -0
- package/dist/api/resources/insuranceAdjudications/resources/v1/client/Client.d.ts +6 -3
- package/dist/api/resources/insuranceAdjudications/resources/v1/client/Client.js +15 -12
- package/dist/api/resources/insurancePayments/client/Client.d.ts +3 -0
- package/dist/api/resources/insurancePayments/resources/v1/client/Client.d.ts +8 -5
- package/dist/api/resources/insurancePayments/resources/v1/client/Client.js +29 -24
- package/dist/api/resources/insuranceRefunds/client/Client.d.ts +3 -0
- package/dist/api/resources/insuranceRefunds/resources/v1/client/Client.d.ts +8 -5
- package/dist/api/resources/insuranceRefunds/resources/v1/client/Client.js +29 -24
- package/dist/api/resources/organizationProviders/client/Client.d.ts +3 -0
- package/dist/api/resources/organizationProviders/resources/v3/client/Client.d.ts +7 -4
- package/dist/api/resources/organizationProviders/resources/v3/client/Client.js +23 -19
- package/dist/api/resources/organizationServiceFacilities/client/Client.d.ts +3 -0
- package/dist/api/resources/organizationServiceFacilities/resources/v2/client/Client.d.ts +8 -5
- package/dist/api/resources/organizationServiceFacilities/resources/v2/client/Client.js +32 -23
- package/dist/api/resources/patientPayments/client/Client.d.ts +3 -0
- package/dist/api/resources/patientPayments/resources/v4/client/Client.d.ts +8 -5
- package/dist/api/resources/patientPayments/resources/v4/client/Client.js +29 -24
- package/dist/api/resources/patientRefunds/client/Client.d.ts +3 -0
- package/dist/api/resources/patientRefunds/resources/v1/client/Client.d.ts +8 -5
- package/dist/api/resources/patientRefunds/resources/v1/client/Client.js +29 -24
- package/dist/api/resources/payers/client/Client.d.ts +3 -0
- package/dist/api/resources/payers/resources/v3/client/Client.d.ts +5 -2
- package/dist/api/resources/payers/resources/v3/client/Client.js +9 -7
- package/dist/api/resources/preEncounter/client/Client.d.ts +3 -0
- package/dist/api/resources/preEncounter/resources/coverages/client/Client.d.ts +3 -0
- package/dist/api/resources/preEncounter/resources/coverages/resources/v1/client/Client.d.ts +3 -0
- package/dist/api/resources/preEncounter/resources/coverages/resources/v1/resources/coverages/client/Client.d.ts +9 -6
- package/dist/api/resources/preEncounter/resources/coverages/resources/v1/resources/coverages/client/Client.js +31 -25
- package/dist/api/resources/preEncounter/resources/patients/client/Client.d.ts +3 -0
- package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/Client.d.ts +3 -0
- package/dist/api/resources/preEncounter/resources/patients/resources/v1/resources/patients/client/Client.d.ts +10 -7
- package/dist/api/resources/preEncounter/resources/patients/resources/v1/resources/patients/client/Client.js +38 -31
- package/dist/api/resources/serviceFacility/client/Client.d.ts +4 -1
- package/dist/api/resources/serviceFacility/client/Client.js +6 -7
- package/dist/api/resources/tasks/client/Client.d.ts +3 -0
- package/dist/api/resources/tasks/resources/v3/client/Client.d.ts +8 -5
- package/dist/api/resources/tasks/resources/v3/client/Client.js +28 -23
- package/dist/api/resources/writeOffs/client/Client.d.ts +3 -0
- package/dist/api/resources/writeOffs/resources/v1/client/Client.d.ts +7 -4
- package/dist/api/resources/writeOffs/resources/v1/client/Client.js +19 -15
- package/dist/core/fetcher/Fetcher.d.ts +3 -0
- package/dist/core/fetcher/Fetcher.js +22 -153
- package/dist/core/fetcher/createRequestUrl.d.ts +1 -0
- package/dist/core/fetcher/createRequestUrl.js +13 -0
- package/dist/core/fetcher/getFetchFn.d.ts +4 -0
- package/dist/core/fetcher/getFetchFn.js +59 -0
- package/dist/core/fetcher/getRequestBody.d.ts +7 -0
- package/dist/core/fetcher/getRequestBody.js +23 -0
- package/dist/core/fetcher/getResponseBody.d.ts +1 -0
- package/dist/core/fetcher/getResponseBody.js +48 -0
- package/dist/core/fetcher/makeRequest.d.ts +1 -0
- package/dist/core/fetcher/makeRequest.js +42 -0
- package/dist/core/fetcher/requestWithRetries.d.ts +1 -0
- package/dist/core/fetcher/requestWithRetries.js +32 -0
- package/dist/core/fetcher/signals.d.ts +12 -0
- package/dist/core/fetcher/signals.js +37 -0
- package/dist/core/runtime/runtime.d.ts +2 -1
- package/dist/core/runtime/runtime.js +12 -1
- package/dist/core/schemas/Schema.d.ts +7 -4
- package/dist/core/schemas/builders/lazy/lazy.d.ts +2 -2
- package/dist/core/schemas/builders/lazy/lazy.js +8 -19
- package/dist/core/schemas/builders/lazy/lazyObject.js +1 -10
- package/dist/core/schemas/builders/list/list.js +31 -44
- package/dist/core/schemas/builders/object/object.js +90 -111
- package/dist/core/schemas/builders/object/types.d.ts +2 -2
- package/dist/core/schemas/builders/object-like/getObjectLikeUtils.js +3 -12
- package/dist/core/schemas/builders/record/record.js +49 -60
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +2 -2
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.js +18 -21
- package/dist/core/schemas/builders/set/set.js +6 -15
- package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +21 -32
- package/dist/core/schemas/builders/union/union.js +51 -62
- package/dist/core/schemas/utils/maybeSkipValidation.js +3 -12
- package/dist/serialization/resources/encounters/resources/v4/client/requests/EncounterCreate.d.ts +0 -2
- package/dist/serialization/resources/encounters/resources/v4/client/requests/EncounterCreate.js +0 -2
- package/dist/serialization/resources/encounters/resources/v4/types/Encounter.d.ts +0 -1
- package/dist/serialization/resources/encounters/resources/v4/types/Encounter.js +0 -1
- package/package.json +7 -2
- package/reference.md +7177 -0
- package/serialization/resources/encounters/resources/v4/client/requests/EncounterCreate.d.ts +0 -2
- package/serialization/resources/encounters/resources/v4/client/requests/EncounterCreate.js +0 -2
- package/serialization/resources/encounters/resources/v4/types/Encounter.d.ts +0 -1
- package/serialization/resources/encounters/resources/v4/types/Encounter.js +0 -1
|
@@ -10,8 +10,11 @@ export declare namespace V1 {
|
|
|
10
10
|
token?: core.Supplier<core.BearerToken | undefined>;
|
|
11
11
|
}
|
|
12
12
|
interface RequestOptions {
|
|
13
|
+
/** The maximum time to wait for a response in seconds. */
|
|
13
14
|
timeoutInSeconds?: number;
|
|
15
|
+
/** The number of times to retry the request. Defaults to 2. */
|
|
14
16
|
maxRetries?: number;
|
|
17
|
+
/** A hook to abort the request. */
|
|
15
18
|
abortSignal?: AbortSignal;
|
|
16
19
|
}
|
|
17
20
|
}
|
|
@@ -10,8 +10,11 @@ export declare namespace Coverages {
|
|
|
10
10
|
token?: core.Supplier<core.BearerToken | undefined>;
|
|
11
11
|
}
|
|
12
12
|
interface RequestOptions {
|
|
13
|
+
/** The maximum time to wait for a response in seconds. */
|
|
13
14
|
timeoutInSeconds?: number;
|
|
15
|
+
/** The number of times to retry the request. Defaults to 2. */
|
|
14
16
|
maxRetries?: number;
|
|
17
|
+
/** A hook to abort the request. */
|
|
15
18
|
abortSignal?: AbortSignal;
|
|
16
19
|
}
|
|
17
20
|
}
|
|
@@ -25,7 +28,7 @@ export declare class Coverages {
|
|
|
25
28
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
26
29
|
*
|
|
27
30
|
* @example
|
|
28
|
-
* await
|
|
31
|
+
* await client.preEncounter.coverages.v1.coverages.create({
|
|
29
32
|
* status: CandidApi.preEncounter.coverages.v1.CoverageStatus.Active,
|
|
30
33
|
* subscriber: {
|
|
31
34
|
* name: {
|
|
@@ -65,7 +68,7 @@ export declare class Coverages {
|
|
|
65
68
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
66
69
|
*
|
|
67
70
|
* @example
|
|
68
|
-
* await
|
|
71
|
+
* await client.preEncounter.coverages.v1.coverages.update(CandidApi.preEncounter.coverages.v1.CoverageId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), 1, {
|
|
69
72
|
* status: CandidApi.preEncounter.coverages.v1.CoverageStatus.Active,
|
|
70
73
|
* subscriber: {
|
|
71
74
|
* name: {
|
|
@@ -103,7 +106,7 @@ export declare class Coverages {
|
|
|
103
106
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
104
107
|
*
|
|
105
108
|
* @example
|
|
106
|
-
* await
|
|
109
|
+
* await client.preEncounter.coverages.v1.coverages.get(CandidApi.preEncounter.coverages.v1.CoverageId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
107
110
|
*/
|
|
108
111
|
get(id: CandidApi.preEncounter.coverages.v1.CoverageId, requestOptions?: Coverages.RequestOptions): Promise<core.APIResponse<CandidApi.preEncounter.coverages.v1.Coverage, CandidApi.preEncounter.coverages.v1.coverages.get.Error>>;
|
|
109
112
|
/**
|
|
@@ -113,7 +116,7 @@ export declare class Coverages {
|
|
|
113
116
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
114
117
|
*
|
|
115
118
|
* @example
|
|
116
|
-
* await
|
|
119
|
+
* await client.preEncounter.coverages.v1.coverages.getHistory(CandidApi.preEncounter.coverages.v1.CoverageId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
117
120
|
*/
|
|
118
121
|
getHistory(id: CandidApi.preEncounter.coverages.v1.CoverageId, requestOptions?: Coverages.RequestOptions): Promise<core.APIResponse<CandidApi.preEncounter.coverages.v1.Coverage[], CandidApi.preEncounter.coverages.v1.coverages.getHistory.Error>>;
|
|
119
122
|
/**
|
|
@@ -123,7 +126,7 @@ export declare class Coverages {
|
|
|
123
126
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
124
127
|
*
|
|
125
128
|
* @example
|
|
126
|
-
* await
|
|
129
|
+
* await client.preEncounter.coverages.v1.coverages.getMulti({
|
|
127
130
|
* patientId: "string"
|
|
128
131
|
* })
|
|
129
132
|
*/
|
|
@@ -135,7 +138,7 @@ export declare class Coverages {
|
|
|
135
138
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
136
139
|
*
|
|
137
140
|
* @example
|
|
138
|
-
* await
|
|
141
|
+
* await client.preEncounter.coverages.v1.coverages.scan({
|
|
139
142
|
* since: new Date("2024-01-15T09:30:00.000Z")
|
|
140
143
|
* })
|
|
141
144
|
*/
|
|
@@ -55,7 +55,7 @@ class Coverages {
|
|
|
55
55
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
56
56
|
*
|
|
57
57
|
* @example
|
|
58
|
-
* await
|
|
58
|
+
* await client.preEncounter.coverages.v1.coverages.create({
|
|
59
59
|
* status: CandidApi.preEncounter.coverages.v1.CoverageStatus.Active,
|
|
60
60
|
* subscriber: {
|
|
61
61
|
* name: {
|
|
@@ -96,12 +96,13 @@ class Coverages {
|
|
|
96
96
|
Authorization: yield this._getAuthorizationHeader(),
|
|
97
97
|
"X-Fern-Language": "JavaScript",
|
|
98
98
|
"X-Fern-SDK-Name": "candidhealth",
|
|
99
|
-
"X-Fern-SDK-Version": "0.24.
|
|
99
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
100
100
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
101
101
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
102
102
|
},
|
|
103
103
|
contentType: "application/json",
|
|
104
|
-
|
|
104
|
+
requestType: "json",
|
|
105
|
+
body: serializers.preEncounter.coverages.v1.MutableCoverage.jsonOrThrow(request, {
|
|
105
106
|
unrecognizedObjectKeys: "strip",
|
|
106
107
|
}),
|
|
107
108
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -111,7 +112,7 @@ class Coverages {
|
|
|
111
112
|
if (_response.ok) {
|
|
112
113
|
return {
|
|
113
114
|
ok: true,
|
|
114
|
-
body:
|
|
115
|
+
body: serializers.preEncounter.coverages.v1.Coverage.parseOrThrow(_response.body, {
|
|
115
116
|
unrecognizedObjectKeys: "passthrough",
|
|
116
117
|
allowUnrecognizedUnionMembers: true,
|
|
117
118
|
allowUnrecognizedEnumValues: true,
|
|
@@ -134,7 +135,7 @@ class Coverages {
|
|
|
134
135
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
135
136
|
*
|
|
136
137
|
* @example
|
|
137
|
-
* await
|
|
138
|
+
* await client.preEncounter.coverages.v1.coverages.update(CandidApi.preEncounter.coverages.v1.CoverageId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), 1, {
|
|
138
139
|
* status: CandidApi.preEncounter.coverages.v1.CoverageStatus.Active,
|
|
139
140
|
* subscriber: {
|
|
140
141
|
* name: {
|
|
@@ -169,18 +170,19 @@ class Coverages {
|
|
|
169
170
|
return __awaiter(this, void 0, void 0, function* () {
|
|
170
171
|
const _response = yield core.fetcher({
|
|
171
172
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
172
|
-
.preEncounter, `/coverages/v1/${encodeURIComponent(
|
|
173
|
+
.preEncounter, `/coverages/v1/${encodeURIComponent(serializers.preEncounter.coverages.v1.CoverageId.jsonOrThrow(id))}/${encodeURIComponent(version)}`),
|
|
173
174
|
method: "PUT",
|
|
174
175
|
headers: {
|
|
175
176
|
Authorization: yield this._getAuthorizationHeader(),
|
|
176
177
|
"X-Fern-Language": "JavaScript",
|
|
177
178
|
"X-Fern-SDK-Name": "candidhealth",
|
|
178
|
-
"X-Fern-SDK-Version": "0.24.
|
|
179
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
179
180
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
180
181
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
181
182
|
},
|
|
182
183
|
contentType: "application/json",
|
|
183
|
-
|
|
184
|
+
requestType: "json",
|
|
185
|
+
body: serializers.preEncounter.coverages.v1.MutableCoverage.jsonOrThrow(request, {
|
|
184
186
|
unrecognizedObjectKeys: "strip",
|
|
185
187
|
}),
|
|
186
188
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -190,7 +192,7 @@ class Coverages {
|
|
|
190
192
|
if (_response.ok) {
|
|
191
193
|
return {
|
|
192
194
|
ok: true,
|
|
193
|
-
body:
|
|
195
|
+
body: serializers.preEncounter.coverages.v1.Coverage.parseOrThrow(_response.body, {
|
|
194
196
|
unrecognizedObjectKeys: "passthrough",
|
|
195
197
|
allowUnrecognizedUnionMembers: true,
|
|
196
198
|
allowUnrecognizedEnumValues: true,
|
|
@@ -204,7 +206,7 @@ class Coverages {
|
|
|
204
206
|
case "VersionConflictError":
|
|
205
207
|
return {
|
|
206
208
|
ok: false,
|
|
207
|
-
error:
|
|
209
|
+
error: serializers.preEncounter.coverages.v1.coverages.update.Error.parseOrThrow(_response.error.body, {
|
|
208
210
|
unrecognizedObjectKeys: "passthrough",
|
|
209
211
|
allowUnrecognizedUnionMembers: true,
|
|
210
212
|
allowUnrecognizedEnumValues: true,
|
|
@@ -226,24 +228,25 @@ class Coverages {
|
|
|
226
228
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
227
229
|
*
|
|
228
230
|
* @example
|
|
229
|
-
* await
|
|
231
|
+
* await client.preEncounter.coverages.v1.coverages.get(CandidApi.preEncounter.coverages.v1.CoverageId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
230
232
|
*/
|
|
231
233
|
get(id, requestOptions) {
|
|
232
234
|
var _a;
|
|
233
235
|
return __awaiter(this, void 0, void 0, function* () {
|
|
234
236
|
const _response = yield core.fetcher({
|
|
235
237
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
236
|
-
.preEncounter, `/coverages/v1/${encodeURIComponent(
|
|
238
|
+
.preEncounter, `/coverages/v1/${encodeURIComponent(serializers.preEncounter.coverages.v1.CoverageId.jsonOrThrow(id))}`),
|
|
237
239
|
method: "GET",
|
|
238
240
|
headers: {
|
|
239
241
|
Authorization: yield this._getAuthorizationHeader(),
|
|
240
242
|
"X-Fern-Language": "JavaScript",
|
|
241
243
|
"X-Fern-SDK-Name": "candidhealth",
|
|
242
|
-
"X-Fern-SDK-Version": "0.24.
|
|
244
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
243
245
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
244
246
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
245
247
|
},
|
|
246
248
|
contentType: "application/json",
|
|
249
|
+
requestType: "json",
|
|
247
250
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
248
251
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
249
252
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -251,7 +254,7 @@ class Coverages {
|
|
|
251
254
|
if (_response.ok) {
|
|
252
255
|
return {
|
|
253
256
|
ok: true,
|
|
254
|
-
body:
|
|
257
|
+
body: serializers.preEncounter.coverages.v1.Coverage.parseOrThrow(_response.body, {
|
|
255
258
|
unrecognizedObjectKeys: "passthrough",
|
|
256
259
|
allowUnrecognizedUnionMembers: true,
|
|
257
260
|
allowUnrecognizedEnumValues: true,
|
|
@@ -272,24 +275,25 @@ class Coverages {
|
|
|
272
275
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
273
276
|
*
|
|
274
277
|
* @example
|
|
275
|
-
* await
|
|
278
|
+
* await client.preEncounter.coverages.v1.coverages.getHistory(CandidApi.preEncounter.coverages.v1.CoverageId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
276
279
|
*/
|
|
277
280
|
getHistory(id, requestOptions) {
|
|
278
281
|
var _a, _b;
|
|
279
282
|
return __awaiter(this, void 0, void 0, function* () {
|
|
280
283
|
const _response = yield core.fetcher({
|
|
281
284
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
282
|
-
.preEncounter, `/coverages/v1/${encodeURIComponent(
|
|
285
|
+
.preEncounter, `/coverages/v1/${encodeURIComponent(serializers.preEncounter.coverages.v1.CoverageId.jsonOrThrow(id))}/history`),
|
|
283
286
|
method: "GET",
|
|
284
287
|
headers: {
|
|
285
288
|
Authorization: yield this._getAuthorizationHeader(),
|
|
286
289
|
"X-Fern-Language": "JavaScript",
|
|
287
290
|
"X-Fern-SDK-Name": "candidhealth",
|
|
288
|
-
"X-Fern-SDK-Version": "0.24.
|
|
291
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
289
292
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
290
293
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
291
294
|
},
|
|
292
295
|
contentType: "application/json",
|
|
296
|
+
requestType: "json",
|
|
293
297
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
294
298
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
295
299
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -297,7 +301,7 @@ class Coverages {
|
|
|
297
301
|
if (_response.ok) {
|
|
298
302
|
return {
|
|
299
303
|
ok: true,
|
|
300
|
-
body:
|
|
304
|
+
body: serializers.preEncounter.coverages.v1.coverages.getHistory.Response.parseOrThrow(_response.body, {
|
|
301
305
|
unrecognizedObjectKeys: "passthrough",
|
|
302
306
|
allowUnrecognizedUnionMembers: true,
|
|
303
307
|
allowUnrecognizedEnumValues: true,
|
|
@@ -310,7 +314,7 @@ class Coverages {
|
|
|
310
314
|
case "NotFoundError":
|
|
311
315
|
return {
|
|
312
316
|
ok: false,
|
|
313
|
-
error:
|
|
317
|
+
error: serializers.preEncounter.coverages.v1.coverages.getHistory.Error.parseOrThrow(_response.error
|
|
314
318
|
.body, {
|
|
315
319
|
unrecognizedObjectKeys: "passthrough",
|
|
316
320
|
allowUnrecognizedUnionMembers: true,
|
|
@@ -333,7 +337,7 @@ class Coverages {
|
|
|
333
337
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
334
338
|
*
|
|
335
339
|
* @example
|
|
336
|
-
* await
|
|
340
|
+
* await client.preEncounter.coverages.v1.coverages.getMulti({
|
|
337
341
|
* patientId: "string"
|
|
338
342
|
* })
|
|
339
343
|
*/
|
|
@@ -353,12 +357,13 @@ class Coverages {
|
|
|
353
357
|
Authorization: yield this._getAuthorizationHeader(),
|
|
354
358
|
"X-Fern-Language": "JavaScript",
|
|
355
359
|
"X-Fern-SDK-Name": "candidhealth",
|
|
356
|
-
"X-Fern-SDK-Version": "0.24.
|
|
360
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
357
361
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
358
362
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
359
363
|
},
|
|
360
364
|
contentType: "application/json",
|
|
361
365
|
queryParameters: _queryParams,
|
|
366
|
+
requestType: "json",
|
|
362
367
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
363
368
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
364
369
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -366,7 +371,7 @@ class Coverages {
|
|
|
366
371
|
if (_response.ok) {
|
|
367
372
|
return {
|
|
368
373
|
ok: true,
|
|
369
|
-
body:
|
|
374
|
+
body: serializers.preEncounter.coverages.v1.coverages.getMulti.Response.parseOrThrow(_response.body, {
|
|
370
375
|
unrecognizedObjectKeys: "passthrough",
|
|
371
376
|
allowUnrecognizedUnionMembers: true,
|
|
372
377
|
allowUnrecognizedEnumValues: true,
|
|
@@ -387,7 +392,7 @@ class Coverages {
|
|
|
387
392
|
* @param {Coverages.RequestOptions} requestOptions - Request-specific configuration.
|
|
388
393
|
*
|
|
389
394
|
* @example
|
|
390
|
-
* await
|
|
395
|
+
* await client.preEncounter.coverages.v1.coverages.scan({
|
|
391
396
|
* since: new Date("2024-01-15T09:30:00.000Z")
|
|
392
397
|
* })
|
|
393
398
|
*/
|
|
@@ -405,12 +410,13 @@ class Coverages {
|
|
|
405
410
|
Authorization: yield this._getAuthorizationHeader(),
|
|
406
411
|
"X-Fern-Language": "JavaScript",
|
|
407
412
|
"X-Fern-SDK-Name": "candidhealth",
|
|
408
|
-
"X-Fern-SDK-Version": "0.24.
|
|
413
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
409
414
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
410
415
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
411
416
|
},
|
|
412
417
|
contentType: "application/json",
|
|
413
418
|
queryParameters: _queryParams,
|
|
419
|
+
requestType: "json",
|
|
414
420
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
415
421
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
416
422
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -418,7 +424,7 @@ class Coverages {
|
|
|
418
424
|
if (_response.ok) {
|
|
419
425
|
return {
|
|
420
426
|
ok: true,
|
|
421
|
-
body:
|
|
427
|
+
body: serializers.preEncounter.coverages.v1.coverages.scan.Response.parseOrThrow(_response.body, {
|
|
422
428
|
unrecognizedObjectKeys: "passthrough",
|
|
423
429
|
allowUnrecognizedUnionMembers: true,
|
|
424
430
|
allowUnrecognizedEnumValues: true,
|
|
@@ -10,8 +10,11 @@ export declare namespace Patients {
|
|
|
10
10
|
token?: core.Supplier<core.BearerToken | undefined>;
|
|
11
11
|
}
|
|
12
12
|
interface RequestOptions {
|
|
13
|
+
/** The maximum time to wait for a response in seconds. */
|
|
13
14
|
timeoutInSeconds?: number;
|
|
15
|
+
/** The number of times to retry the request. Defaults to 2. */
|
|
14
16
|
maxRetries?: number;
|
|
17
|
+
/** A hook to abort the request. */
|
|
15
18
|
abortSignal?: AbortSignal;
|
|
16
19
|
}
|
|
17
20
|
}
|
|
@@ -10,8 +10,11 @@ export declare namespace V1 {
|
|
|
10
10
|
token?: core.Supplier<core.BearerToken | undefined>;
|
|
11
11
|
}
|
|
12
12
|
interface RequestOptions {
|
|
13
|
+
/** The maximum time to wait for a response in seconds. */
|
|
13
14
|
timeoutInSeconds?: number;
|
|
15
|
+
/** The number of times to retry the request. Defaults to 2. */
|
|
14
16
|
maxRetries?: number;
|
|
17
|
+
/** A hook to abort the request. */
|
|
15
18
|
abortSignal?: AbortSignal;
|
|
16
19
|
}
|
|
17
20
|
}
|
|
@@ -10,8 +10,11 @@ export declare namespace Patients {
|
|
|
10
10
|
token?: core.Supplier<core.BearerToken | undefined>;
|
|
11
11
|
}
|
|
12
12
|
interface RequestOptions {
|
|
13
|
+
/** The maximum time to wait for a response in seconds. */
|
|
13
14
|
timeoutInSeconds?: number;
|
|
15
|
+
/** The number of times to retry the request. Defaults to 2. */
|
|
14
16
|
maxRetries?: number;
|
|
17
|
+
/** A hook to abort the request. */
|
|
15
18
|
abortSignal?: AbortSignal;
|
|
16
19
|
}
|
|
17
20
|
}
|
|
@@ -25,7 +28,7 @@ export declare class Patients {
|
|
|
25
28
|
* @param {Patients.RequestOptions} requestOptions - Request-specific configuration.
|
|
26
29
|
*
|
|
27
30
|
* @example
|
|
28
|
-
* await
|
|
31
|
+
* await client.preEncounter.patients.v1.patients.create({
|
|
29
32
|
* name: {
|
|
30
33
|
* family: "string",
|
|
31
34
|
* given: ["string"],
|
|
@@ -153,7 +156,7 @@ export declare class Patients {
|
|
|
153
156
|
* @param {Patients.RequestOptions} requestOptions - Request-specific configuration.
|
|
154
157
|
*
|
|
155
158
|
* @example
|
|
156
|
-
* await
|
|
159
|
+
* await client.preEncounter.patients.v1.patients.get(CandidApi.preEncounter.patients.v1.PatientId("string"))
|
|
157
160
|
*/
|
|
158
161
|
get(id: CandidApi.preEncounter.patients.v1.PatientId, requestOptions?: Patients.RequestOptions): Promise<core.APIResponse<CandidApi.preEncounter.patients.v1.Patient, CandidApi.preEncounter.patients.v1.patients.get.Error>>;
|
|
159
162
|
/**
|
|
@@ -163,7 +166,7 @@ export declare class Patients {
|
|
|
163
166
|
* @param {Patients.RequestOptions} requestOptions - Request-specific configuration.
|
|
164
167
|
*
|
|
165
168
|
* @example
|
|
166
|
-
* await
|
|
169
|
+
* await client.preEncounter.patients.v1.patients.getHistory(CandidApi.preEncounter.patients.v1.PatientId("string"))
|
|
167
170
|
*/
|
|
168
171
|
getHistory(id: CandidApi.preEncounter.patients.v1.PatientId, requestOptions?: Patients.RequestOptions): Promise<core.APIResponse<CandidApi.preEncounter.patients.v1.Patient[], CandidApi.preEncounter.patients.v1.patients.getHistory.Error>>;
|
|
169
172
|
/**
|
|
@@ -175,7 +178,7 @@ export declare class Patients {
|
|
|
175
178
|
* @param {Patients.RequestOptions} requestOptions - Request-specific configuration.
|
|
176
179
|
*
|
|
177
180
|
* @example
|
|
178
|
-
* await
|
|
181
|
+
* await client.preEncounter.patients.v1.patients.update(CandidApi.preEncounter.patients.v1.PatientId("string"), 1, {
|
|
179
182
|
* name: {
|
|
180
183
|
* family: "string",
|
|
181
184
|
* given: ["string"],
|
|
@@ -304,7 +307,7 @@ export declare class Patients {
|
|
|
304
307
|
* @param {Patients.RequestOptions} requestOptions - Request-specific configuration.
|
|
305
308
|
*
|
|
306
309
|
* @example
|
|
307
|
-
* await
|
|
310
|
+
* await client.preEncounter.patients.v1.patients.deactivate(CandidApi.preEncounter.patients.v1.PatientId("string"), 1)
|
|
308
311
|
*/
|
|
309
312
|
deactivate(id: CandidApi.preEncounter.patients.v1.PatientId, version: number, requestOptions?: Patients.RequestOptions): Promise<core.APIResponse<void, CandidApi.preEncounter.patients.v1.patients.deactivate.Error>>;
|
|
310
313
|
/**
|
|
@@ -314,7 +317,7 @@ export declare class Patients {
|
|
|
314
317
|
* @param {Patients.RequestOptions} requestOptions - Request-specific configuration.
|
|
315
318
|
*
|
|
316
319
|
* @example
|
|
317
|
-
* await
|
|
320
|
+
* await client.preEncounter.patients.v1.patients.search({
|
|
318
321
|
* nameContains: "string"
|
|
319
322
|
* })
|
|
320
323
|
*/
|
|
@@ -326,7 +329,7 @@ export declare class Patients {
|
|
|
326
329
|
* @param {Patients.RequestOptions} requestOptions - Request-specific configuration.
|
|
327
330
|
*
|
|
328
331
|
* @example
|
|
329
|
-
* await
|
|
332
|
+
* await client.preEncounter.patients.v1.patients.scan({
|
|
330
333
|
* since: new Date("2024-01-15T09:30:00.000Z")
|
|
331
334
|
* })
|
|
332
335
|
*/
|