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
|
}
|
|
@@ -26,7 +29,7 @@ export declare class V1 {
|
|
|
26
29
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
27
30
|
*
|
|
28
31
|
* @example
|
|
29
|
-
* await
|
|
32
|
+
* await client.guarantor.v1.create(CandidApi.EncounterId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), {
|
|
30
33
|
* phoneNumbers: [{
|
|
31
34
|
* number: "1234567890",
|
|
32
35
|
* type: CandidApi.PhoneNumberType.Home
|
|
@@ -56,7 +59,7 @@ export declare class V1 {
|
|
|
56
59
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
57
60
|
*
|
|
58
61
|
* @example
|
|
59
|
-
* await
|
|
62
|
+
* await client.guarantor.v1.get(CandidApi.guarantor.v1.GuarantorId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
60
63
|
*/
|
|
61
64
|
get(guarantorId: CandidApi.guarantor.v1.GuarantorId, requestOptions?: V1.RequestOptions): Promise<core.APIResponse<CandidApi.guarantor.v1.Guarantor, CandidApi.guarantor.v1.get.Error>>;
|
|
62
65
|
/**
|
|
@@ -67,7 +70,7 @@ export declare class V1 {
|
|
|
67
70
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
68
71
|
*
|
|
69
72
|
* @example
|
|
70
|
-
* await
|
|
73
|
+
* await client.guarantor.v1.update(CandidApi.guarantor.v1.GuarantorId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), {
|
|
71
74
|
* firstName: "string",
|
|
72
75
|
* lastName: "string",
|
|
73
76
|
* externalId: "string",
|
|
@@ -56,7 +56,7 @@ class V1 {
|
|
|
56
56
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
57
57
|
*
|
|
58
58
|
* @example
|
|
59
|
-
* await
|
|
59
|
+
* await client.guarantor.v1.create(CandidApi.EncounterId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), {
|
|
60
60
|
* phoneNumbers: [{
|
|
61
61
|
* number: "1234567890",
|
|
62
62
|
* type: CandidApi.PhoneNumberType.Home
|
|
@@ -83,20 +83,19 @@ class V1 {
|
|
|
83
83
|
return __awaiter(this, void 0, void 0, function* () {
|
|
84
84
|
const _response = yield core.fetcher({
|
|
85
85
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
86
|
-
.candidApi, `/api/guarantors/v1/${encodeURIComponent(
|
|
86
|
+
.candidApi, `/api/guarantors/v1/${encodeURIComponent(serializers.EncounterId.jsonOrThrow(encounterId))}`),
|
|
87
87
|
method: "POST",
|
|
88
88
|
headers: {
|
|
89
89
|
Authorization: yield this._getAuthorizationHeader(),
|
|
90
90
|
"X-Fern-Language": "JavaScript",
|
|
91
91
|
"X-Fern-SDK-Name": "candidhealth",
|
|
92
|
-
"X-Fern-SDK-Version": "0.24.
|
|
92
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
93
93
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
94
94
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
95
95
|
},
|
|
96
96
|
contentType: "application/json",
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
}),
|
|
97
|
+
requestType: "json",
|
|
98
|
+
body: serializers.guarantor.v1.GuarantorCreate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
100
99
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
101
100
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
102
101
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -104,7 +103,7 @@ class V1 {
|
|
|
104
103
|
if (_response.ok) {
|
|
105
104
|
return {
|
|
106
105
|
ok: true,
|
|
107
|
-
body:
|
|
106
|
+
body: serializers.guarantor.v1.Guarantor.parseOrThrow(_response.body, {
|
|
108
107
|
unrecognizedObjectKeys: "passthrough",
|
|
109
108
|
allowUnrecognizedUnionMembers: true,
|
|
110
109
|
allowUnrecognizedEnumValues: true,
|
|
@@ -118,7 +117,7 @@ class V1 {
|
|
|
118
117
|
case "HttpRequestValidationsError":
|
|
119
118
|
return {
|
|
120
119
|
ok: false,
|
|
121
|
-
error:
|
|
120
|
+
error: serializers.guarantor.v1.create.Error.parseOrThrow(_response.error.body, {
|
|
122
121
|
unrecognizedObjectKeys: "passthrough",
|
|
123
122
|
allowUnrecognizedUnionMembers: true,
|
|
124
123
|
allowUnrecognizedEnumValues: true,
|
|
@@ -140,24 +139,25 @@ class V1 {
|
|
|
140
139
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
141
140
|
*
|
|
142
141
|
* @example
|
|
143
|
-
* await
|
|
142
|
+
* await client.guarantor.v1.get(CandidApi.guarantor.v1.GuarantorId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
144
143
|
*/
|
|
145
144
|
get(guarantorId, requestOptions) {
|
|
146
145
|
var _a;
|
|
147
146
|
return __awaiter(this, void 0, void 0, function* () {
|
|
148
147
|
const _response = yield core.fetcher({
|
|
149
148
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
150
|
-
.candidApi, `/api/guarantors/v1/${encodeURIComponent(
|
|
149
|
+
.candidApi, `/api/guarantors/v1/${encodeURIComponent(serializers.guarantor.v1.GuarantorId.jsonOrThrow(guarantorId))}`),
|
|
151
150
|
method: "GET",
|
|
152
151
|
headers: {
|
|
153
152
|
Authorization: yield this._getAuthorizationHeader(),
|
|
154
153
|
"X-Fern-Language": "JavaScript",
|
|
155
154
|
"X-Fern-SDK-Name": "candidhealth",
|
|
156
|
-
"X-Fern-SDK-Version": "0.24.
|
|
155
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
157
156
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
158
157
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
159
158
|
},
|
|
160
159
|
contentType: "application/json",
|
|
160
|
+
requestType: "json",
|
|
161
161
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
162
162
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
163
163
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -165,7 +165,7 @@ class V1 {
|
|
|
165
165
|
if (_response.ok) {
|
|
166
166
|
return {
|
|
167
167
|
ok: true,
|
|
168
|
-
body:
|
|
168
|
+
body: serializers.guarantor.v1.Guarantor.parseOrThrow(_response.body, {
|
|
169
169
|
unrecognizedObjectKeys: "passthrough",
|
|
170
170
|
allowUnrecognizedUnionMembers: true,
|
|
171
171
|
allowUnrecognizedEnumValues: true,
|
|
@@ -187,7 +187,7 @@ class V1 {
|
|
|
187
187
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
188
188
|
*
|
|
189
189
|
* @example
|
|
190
|
-
* await
|
|
190
|
+
* await client.guarantor.v1.update(CandidApi.guarantor.v1.GuarantorId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), {
|
|
191
191
|
* firstName: "string",
|
|
192
192
|
* lastName: "string",
|
|
193
193
|
* externalId: "string",
|
|
@@ -214,20 +214,19 @@ class V1 {
|
|
|
214
214
|
return __awaiter(this, void 0, void 0, function* () {
|
|
215
215
|
const _response = yield core.fetcher({
|
|
216
216
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
217
|
-
.candidApi, `/api/guarantors/v1/${encodeURIComponent(
|
|
217
|
+
.candidApi, `/api/guarantors/v1/${encodeURIComponent(serializers.guarantor.v1.GuarantorId.jsonOrThrow(guarantorId))}`),
|
|
218
218
|
method: "PATCH",
|
|
219
219
|
headers: {
|
|
220
220
|
Authorization: yield this._getAuthorizationHeader(),
|
|
221
221
|
"X-Fern-Language": "JavaScript",
|
|
222
222
|
"X-Fern-SDK-Name": "candidhealth",
|
|
223
|
-
"X-Fern-SDK-Version": "0.24.
|
|
223
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
224
224
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
225
225
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
226
226
|
},
|
|
227
227
|
contentType: "application/json",
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
}),
|
|
228
|
+
requestType: "json",
|
|
229
|
+
body: serializers.guarantor.v1.GuarantorUpdate.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
231
230
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
232
231
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
233
232
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -235,7 +234,7 @@ class V1 {
|
|
|
235
234
|
if (_response.ok) {
|
|
236
235
|
return {
|
|
237
236
|
ok: true,
|
|
238
|
-
body:
|
|
237
|
+
body: serializers.guarantor.v1.Guarantor.parseOrThrow(_response.body, {
|
|
239
238
|
unrecognizedObjectKeys: "passthrough",
|
|
240
239
|
allowUnrecognizedUnionMembers: true,
|
|
241
240
|
allowUnrecognizedEnumValues: true,
|
|
@@ -10,8 +10,11 @@ export declare namespace ImportInvoice {
|
|
|
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
|
}
|
|
@@ -25,7 +28,7 @@ export declare class V1 {
|
|
|
25
28
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
26
29
|
*
|
|
27
30
|
* @example
|
|
28
|
-
* await
|
|
31
|
+
* await client.importInvoice.v1.importInvoice({
|
|
29
32
|
* externalPaymentAccountConfigId: CandidApi.PaymentAccountConfigId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"),
|
|
30
33
|
* patientExternalId: CandidApi.PatientExternalId("string"),
|
|
31
34
|
* externalCustomerIdentifier: "string",
|
|
@@ -45,7 +48,7 @@ export declare class V1 {
|
|
|
45
48
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
46
49
|
*
|
|
47
50
|
* @example
|
|
48
|
-
* await
|
|
51
|
+
* await client.importInvoice.v1.getMulti({
|
|
49
52
|
* patientExternalId: CandidApi.PatientExternalId("string"),
|
|
50
53
|
* encounterExternalId: CandidApi.EncounterExternalId("string"),
|
|
51
54
|
* note: "string",
|
|
@@ -66,7 +69,7 @@ export declare class V1 {
|
|
|
66
69
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
67
70
|
*
|
|
68
71
|
* @example
|
|
69
|
-
* await
|
|
72
|
+
* await client.importInvoice.v1.get(CandidApi.InvoiceId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
70
73
|
*/
|
|
71
74
|
get(invoiceId: CandidApi.InvoiceId, requestOptions?: V1.RequestOptions): Promise<core.APIResponse<CandidApi.importInvoice.v1.ImportInvoice, CandidApi.importInvoice.v1.get.Error>>;
|
|
72
75
|
/**
|
|
@@ -77,7 +80,7 @@ export declare class V1 {
|
|
|
77
80
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
78
81
|
*
|
|
79
82
|
* @example
|
|
80
|
-
* await
|
|
83
|
+
* await client.importInvoice.v1.update(CandidApi.InvoiceId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), {
|
|
81
84
|
* customerInvoiceUrl: "string",
|
|
82
85
|
* status: CandidApi.invoices.v2.InvoiceStatus.Draft,
|
|
83
86
|
* note: "string",
|
|
@@ -55,7 +55,7 @@ class V1 {
|
|
|
55
55
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
56
56
|
*
|
|
57
57
|
* @example
|
|
58
|
-
* await
|
|
58
|
+
* await client.importInvoice.v1.importInvoice({
|
|
59
59
|
* externalPaymentAccountConfigId: CandidApi.PaymentAccountConfigId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"),
|
|
60
60
|
* patientExternalId: CandidApi.PatientExternalId("string"),
|
|
61
61
|
* externalCustomerIdentifier: "string",
|
|
@@ -78,12 +78,13 @@ class V1 {
|
|
|
78
78
|
Authorization: yield this._getAuthorizationHeader(),
|
|
79
79
|
"X-Fern-Language": "JavaScript",
|
|
80
80
|
"X-Fern-SDK-Name": "candidhealth",
|
|
81
|
-
"X-Fern-SDK-Version": "0.24.
|
|
81
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
82
82
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
83
83
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
84
84
|
},
|
|
85
85
|
contentType: "application/json",
|
|
86
|
-
|
|
86
|
+
requestType: "json",
|
|
87
|
+
body: serializers.importInvoice.v1.CreateImportInvoiceRequest.jsonOrThrow(request, {
|
|
87
88
|
unrecognizedObjectKeys: "strip",
|
|
88
89
|
}),
|
|
89
90
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -93,7 +94,7 @@ class V1 {
|
|
|
93
94
|
if (_response.ok) {
|
|
94
95
|
return {
|
|
95
96
|
ok: true,
|
|
96
|
-
body:
|
|
97
|
+
body: serializers.importInvoice.v1.ImportInvoice.parseOrThrow(_response.body, {
|
|
97
98
|
unrecognizedObjectKeys: "passthrough",
|
|
98
99
|
allowUnrecognizedUnionMembers: true,
|
|
99
100
|
allowUnrecognizedEnumValues: true,
|
|
@@ -114,7 +115,7 @@ class V1 {
|
|
|
114
115
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
115
116
|
*
|
|
116
117
|
* @example
|
|
117
|
-
* await
|
|
118
|
+
* await client.importInvoice.v1.getMulti({
|
|
118
119
|
* patientExternalId: CandidApi.PatientExternalId("string"),
|
|
119
120
|
* encounterExternalId: CandidApi.EncounterExternalId("string"),
|
|
120
121
|
* note: "string",
|
|
@@ -175,12 +176,13 @@ class V1 {
|
|
|
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
|
queryParameters: _queryParams,
|
|
185
|
+
requestType: "json",
|
|
184
186
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
185
187
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
186
188
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -188,7 +190,7 @@ class V1 {
|
|
|
188
190
|
if (_response.ok) {
|
|
189
191
|
return {
|
|
190
192
|
ok: true,
|
|
191
|
-
body:
|
|
193
|
+
body: serializers.importInvoice.v1.ImportInvoicesPage.parseOrThrow(_response.body, {
|
|
192
194
|
unrecognizedObjectKeys: "passthrough",
|
|
193
195
|
allowUnrecognizedUnionMembers: true,
|
|
194
196
|
allowUnrecognizedEnumValues: true,
|
|
@@ -209,24 +211,25 @@ class V1 {
|
|
|
209
211
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
210
212
|
*
|
|
211
213
|
* @example
|
|
212
|
-
* await
|
|
214
|
+
* await client.importInvoice.v1.get(CandidApi.InvoiceId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
213
215
|
*/
|
|
214
216
|
get(invoiceId, requestOptions) {
|
|
215
217
|
var _a, _b;
|
|
216
218
|
return __awaiter(this, void 0, void 0, function* () {
|
|
217
219
|
const _response = yield core.fetcher({
|
|
218
220
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
219
|
-
.candidApi, `/api/import-invoice/v1/${encodeURIComponent(
|
|
221
|
+
.candidApi, `/api/import-invoice/v1/${encodeURIComponent(serializers.InvoiceId.jsonOrThrow(invoiceId))}`),
|
|
220
222
|
method: "GET",
|
|
221
223
|
headers: {
|
|
222
224
|
Authorization: yield this._getAuthorizationHeader(),
|
|
223
225
|
"X-Fern-Language": "JavaScript",
|
|
224
226
|
"X-Fern-SDK-Name": "candidhealth",
|
|
225
|
-
"X-Fern-SDK-Version": "0.24.
|
|
227
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
226
228
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
227
229
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
228
230
|
},
|
|
229
231
|
contentType: "application/json",
|
|
232
|
+
requestType: "json",
|
|
230
233
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
231
234
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
232
235
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -234,7 +237,7 @@ class V1 {
|
|
|
234
237
|
if (_response.ok) {
|
|
235
238
|
return {
|
|
236
239
|
ok: true,
|
|
237
|
-
body:
|
|
240
|
+
body: serializers.importInvoice.v1.ImportInvoice.parseOrThrow(_response.body, {
|
|
238
241
|
unrecognizedObjectKeys: "passthrough",
|
|
239
242
|
allowUnrecognizedUnionMembers: true,
|
|
240
243
|
allowUnrecognizedEnumValues: true,
|
|
@@ -247,7 +250,7 @@ class V1 {
|
|
|
247
250
|
case "EntityNotFoundError":
|
|
248
251
|
return {
|
|
249
252
|
ok: false,
|
|
250
|
-
error:
|
|
253
|
+
error: serializers.importInvoice.v1.get.Error.parseOrThrow(_response.error.body, {
|
|
251
254
|
unrecognizedObjectKeys: "passthrough",
|
|
252
255
|
allowUnrecognizedUnionMembers: true,
|
|
253
256
|
allowUnrecognizedEnumValues: true,
|
|
@@ -270,7 +273,7 @@ class V1 {
|
|
|
270
273
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
271
274
|
*
|
|
272
275
|
* @example
|
|
273
|
-
* await
|
|
276
|
+
* await client.importInvoice.v1.update(CandidApi.InvoiceId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), {
|
|
274
277
|
* customerInvoiceUrl: "string",
|
|
275
278
|
* status: CandidApi.invoices.v2.InvoiceStatus.Draft,
|
|
276
279
|
* note: "string",
|
|
@@ -286,18 +289,19 @@ class V1 {
|
|
|
286
289
|
return __awaiter(this, void 0, void 0, function* () {
|
|
287
290
|
const _response = yield core.fetcher({
|
|
288
291
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
289
|
-
.candidApi, `/api/import-invoice/v1/${encodeURIComponent(
|
|
292
|
+
.candidApi, `/api/import-invoice/v1/${encodeURIComponent(serializers.InvoiceId.jsonOrThrow(invoiceId))}`),
|
|
290
293
|
method: "PATCH",
|
|
291
294
|
headers: {
|
|
292
295
|
Authorization: yield this._getAuthorizationHeader(),
|
|
293
296
|
"X-Fern-Language": "JavaScript",
|
|
294
297
|
"X-Fern-SDK-Name": "candidhealth",
|
|
295
|
-
"X-Fern-SDK-Version": "0.24.
|
|
298
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
296
299
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
297
300
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
298
301
|
},
|
|
299
302
|
contentType: "application/json",
|
|
300
|
-
|
|
303
|
+
requestType: "json",
|
|
304
|
+
body: serializers.importInvoice.v1.ImportInvoiceUpdateRequest.jsonOrThrow(request, {
|
|
301
305
|
unrecognizedObjectKeys: "strip",
|
|
302
306
|
}),
|
|
303
307
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -307,7 +311,7 @@ class V1 {
|
|
|
307
311
|
if (_response.ok) {
|
|
308
312
|
return {
|
|
309
313
|
ok: true,
|
|
310
|
-
body:
|
|
314
|
+
body: serializers.importInvoice.v1.ImportInvoice.parseOrThrow(_response.body, {
|
|
311
315
|
unrecognizedObjectKeys: "passthrough",
|
|
312
316
|
allowUnrecognizedUnionMembers: true,
|
|
313
317
|
allowUnrecognizedEnumValues: true,
|
|
@@ -320,7 +324,7 @@ class V1 {
|
|
|
320
324
|
case "EntityNotFoundError":
|
|
321
325
|
return {
|
|
322
326
|
ok: false,
|
|
323
|
-
error:
|
|
327
|
+
error: serializers.importInvoice.v1.update.Error.parseOrThrow(_response.error.body, {
|
|
324
328
|
unrecognizedObjectKeys: "passthrough",
|
|
325
329
|
allowUnrecognizedUnionMembers: true,
|
|
326
330
|
allowUnrecognizedEnumValues: true,
|
|
@@ -10,8 +10,11 @@ export declare namespace InsuranceAdjudications {
|
|
|
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
|
}
|
|
@@ -25,7 +28,7 @@ export declare class V1 {
|
|
|
25
28
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
26
29
|
*
|
|
27
30
|
* @example
|
|
28
|
-
* await
|
|
31
|
+
* await client.insuranceAdjudications.v1.get(CandidApi.insuranceAdjudications.v1.InsuranceAdjudicationId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
29
32
|
*/
|
|
30
33
|
get(insuranceAdjudicationId: CandidApi.insuranceAdjudications.v1.InsuranceAdjudicationId, requestOptions?: V1.RequestOptions): Promise<core.APIResponse<CandidApi.insuranceAdjudications.v1.InsuranceAdjudication, CandidApi.insuranceAdjudications.v1.get.Error>>;
|
|
31
34
|
/**
|
|
@@ -35,7 +38,7 @@ export declare class V1 {
|
|
|
35
38
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
36
39
|
*
|
|
37
40
|
* @example
|
|
38
|
-
* await
|
|
41
|
+
* await client.insuranceAdjudications.v1.create({
|
|
39
42
|
* payerIdentifier: {
|
|
40
43
|
* type: "payer_info"
|
|
41
44
|
* },
|
|
@@ -57,7 +60,7 @@ export declare class V1 {
|
|
|
57
60
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
58
61
|
*
|
|
59
62
|
* @example
|
|
60
|
-
* await
|
|
63
|
+
* await client.insuranceAdjudications.v1.delete(CandidApi.insuranceAdjudications.v1.InsuranceAdjudicationId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
61
64
|
*/
|
|
62
65
|
delete(insuranceAdjudicationId: CandidApi.insuranceAdjudications.v1.InsuranceAdjudicationId, requestOptions?: V1.RequestOptions): Promise<core.APIResponse<void, CandidApi.insuranceAdjudications.v1.delete.Error>>;
|
|
63
66
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
@@ -55,24 +55,25 @@ class V1 {
|
|
|
55
55
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
56
56
|
*
|
|
57
57
|
* @example
|
|
58
|
-
* await
|
|
58
|
+
* await client.insuranceAdjudications.v1.get(CandidApi.insuranceAdjudications.v1.InsuranceAdjudicationId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
59
59
|
*/
|
|
60
60
|
get(insuranceAdjudicationId, requestOptions) {
|
|
61
61
|
var _a;
|
|
62
62
|
return __awaiter(this, void 0, void 0, function* () {
|
|
63
63
|
const _response = yield core.fetcher({
|
|
64
64
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
65
|
-
.candidApi, `/api/insurance-adjudications/v1/${encodeURIComponent(
|
|
65
|
+
.candidApi, `/api/insurance-adjudications/v1/${encodeURIComponent(serializers.insuranceAdjudications.v1.InsuranceAdjudicationId.jsonOrThrow(insuranceAdjudicationId))}`),
|
|
66
66
|
method: "GET",
|
|
67
67
|
headers: {
|
|
68
68
|
Authorization: yield this._getAuthorizationHeader(),
|
|
69
69
|
"X-Fern-Language": "JavaScript",
|
|
70
70
|
"X-Fern-SDK-Name": "candidhealth",
|
|
71
|
-
"X-Fern-SDK-Version": "0.24.
|
|
71
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
72
72
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
73
73
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
74
74
|
},
|
|
75
75
|
contentType: "application/json",
|
|
76
|
+
requestType: "json",
|
|
76
77
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
77
78
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
78
79
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -80,7 +81,7 @@ class V1 {
|
|
|
80
81
|
if (_response.ok) {
|
|
81
82
|
return {
|
|
82
83
|
ok: true,
|
|
83
|
-
body:
|
|
84
|
+
body: serializers.insuranceAdjudications.v1.InsuranceAdjudication.parseOrThrow(_response.body, {
|
|
84
85
|
unrecognizedObjectKeys: "passthrough",
|
|
85
86
|
allowUnrecognizedUnionMembers: true,
|
|
86
87
|
allowUnrecognizedEnumValues: true,
|
|
@@ -101,7 +102,7 @@ class V1 {
|
|
|
101
102
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
102
103
|
*
|
|
103
104
|
* @example
|
|
104
|
-
* await
|
|
105
|
+
* await client.insuranceAdjudications.v1.create({
|
|
105
106
|
* payerIdentifier: {
|
|
106
107
|
* type: "payer_info"
|
|
107
108
|
* },
|
|
@@ -126,12 +127,13 @@ class V1 {
|
|
|
126
127
|
Authorization: yield this._getAuthorizationHeader(),
|
|
127
128
|
"X-Fern-Language": "JavaScript",
|
|
128
129
|
"X-Fern-SDK-Name": "candidhealth",
|
|
129
|
-
"X-Fern-SDK-Version": "0.24.
|
|
130
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
130
131
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
131
132
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
132
133
|
},
|
|
133
134
|
contentType: "application/json",
|
|
134
|
-
|
|
135
|
+
requestType: "json",
|
|
136
|
+
body: serializers.insuranceAdjudications.v1.InsuranceAdjudicationCreate.jsonOrThrow(request, {
|
|
135
137
|
unrecognizedObjectKeys: "strip",
|
|
136
138
|
}),
|
|
137
139
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -141,7 +143,7 @@ class V1 {
|
|
|
141
143
|
if (_response.ok) {
|
|
142
144
|
return {
|
|
143
145
|
ok: true,
|
|
144
|
-
body:
|
|
146
|
+
body: serializers.insuranceAdjudications.v1.InsuranceAdjudication.parseOrThrow(_response.body, {
|
|
145
147
|
unrecognizedObjectKeys: "passthrough",
|
|
146
148
|
allowUnrecognizedUnionMembers: true,
|
|
147
149
|
allowUnrecognizedEnumValues: true,
|
|
@@ -154,7 +156,7 @@ class V1 {
|
|
|
154
156
|
case "EraNotFullyProcessedError":
|
|
155
157
|
return {
|
|
156
158
|
ok: false,
|
|
157
|
-
error:
|
|
159
|
+
error: serializers.insuranceAdjudications.v1.create.Error.parseOrThrow(_response.error.body, {
|
|
158
160
|
unrecognizedObjectKeys: "passthrough",
|
|
159
161
|
allowUnrecognizedUnionMembers: true,
|
|
160
162
|
allowUnrecognizedEnumValues: true,
|
|
@@ -176,24 +178,25 @@ class V1 {
|
|
|
176
178
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
177
179
|
*
|
|
178
180
|
* @example
|
|
179
|
-
* await
|
|
181
|
+
* await client.insuranceAdjudications.v1.delete(CandidApi.insuranceAdjudications.v1.InsuranceAdjudicationId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
180
182
|
*/
|
|
181
183
|
delete(insuranceAdjudicationId, requestOptions) {
|
|
182
184
|
var _a;
|
|
183
185
|
return __awaiter(this, void 0, void 0, function* () {
|
|
184
186
|
const _response = yield core.fetcher({
|
|
185
187
|
url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
|
|
186
|
-
.candidApi, `/api/insurance-adjudications/v1/${encodeURIComponent(
|
|
188
|
+
.candidApi, `/api/insurance-adjudications/v1/${encodeURIComponent(serializers.insuranceAdjudications.v1.InsuranceAdjudicationId.jsonOrThrow(insuranceAdjudicationId))}`),
|
|
187
189
|
method: "DELETE",
|
|
188
190
|
headers: {
|
|
189
191
|
Authorization: yield this._getAuthorizationHeader(),
|
|
190
192
|
"X-Fern-Language": "JavaScript",
|
|
191
193
|
"X-Fern-SDK-Name": "candidhealth",
|
|
192
|
-
"X-Fern-SDK-Version": "0.24.
|
|
194
|
+
"X-Fern-SDK-Version": "0.24.1",
|
|
193
195
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
194
196
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
195
197
|
},
|
|
196
198
|
contentType: "application/json",
|
|
199
|
+
requestType: "json",
|
|
197
200
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
198
201
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
199
202
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -10,8 +10,11 @@ export declare namespace InsurancePayments {
|
|
|
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
|
}
|
|
@@ -25,7 +28,7 @@ export declare class V1 {
|
|
|
25
28
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
26
29
|
*
|
|
27
30
|
* @example
|
|
28
|
-
* await
|
|
31
|
+
* await client.insurancePayments.v1.getMulti({
|
|
29
32
|
* limit: 1,
|
|
30
33
|
* payerUuid: CandidApi.payers.v3.PayerUuid("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"),
|
|
31
34
|
* claimId: CandidApi.ClaimId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"),
|
|
@@ -45,7 +48,7 @@ export declare class V1 {
|
|
|
45
48
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
46
49
|
*
|
|
47
50
|
* @example
|
|
48
|
-
* await
|
|
51
|
+
* await client.insurancePayments.v1.get(CandidApi.insurancePayments.v1.InsurancePaymentId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
49
52
|
*/
|
|
50
53
|
get(insurancePaymentId: CandidApi.insurancePayments.v1.InsurancePaymentId, requestOptions?: V1.RequestOptions): Promise<core.APIResponse<CandidApi.insurancePayments.v1.InsurancePayment, CandidApi.insurancePayments.v1.get.Error>>;
|
|
51
54
|
/**
|
|
@@ -57,7 +60,7 @@ export declare class V1 {
|
|
|
57
60
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
58
61
|
*
|
|
59
62
|
* @example
|
|
60
|
-
* await
|
|
63
|
+
* await client.insurancePayments.v1.create({
|
|
61
64
|
* payerIdentifier: {
|
|
62
65
|
* type: "payer_info"
|
|
63
66
|
* },
|
|
@@ -77,7 +80,7 @@ export declare class V1 {
|
|
|
77
80
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
78
81
|
*
|
|
79
82
|
* @example
|
|
80
|
-
* await
|
|
83
|
+
* await client.insurancePayments.v1.update(CandidApi.insurancePayments.v1.InsurancePaymentId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"), {
|
|
81
84
|
* paymentTimestamp: new Date("2024-01-15T09:30:00.000Z"),
|
|
82
85
|
* paymentNote: {
|
|
83
86
|
* type: "set",
|
|
@@ -95,7 +98,7 @@ export declare class V1 {
|
|
|
95
98
|
* @param {V1.RequestOptions} requestOptions - Request-specific configuration.
|
|
96
99
|
*
|
|
97
100
|
* @example
|
|
98
|
-
* await
|
|
101
|
+
* await client.insurancePayments.v1.delete(CandidApi.insurancePayments.v1.InsurancePaymentId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"))
|
|
99
102
|
*/
|
|
100
103
|
delete(insurancePaymentId: CandidApi.insurancePayments.v1.InsurancePaymentId, requestOptions?: V1.RequestOptions): Promise<core.APIResponse<void, CandidApi.insurancePayments.v1.delete.Error>>;
|
|
101
104
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|