candidhealth 0.39.4 → 0.39.5
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/api/resources/auth/resources/v2/client/Client.js +1 -1
- package/api/resources/billingNotes/resources/v2/client/Client.js +3 -3
- package/api/resources/chargeCapture/resources/v1/client/Client.js +5 -5
- package/api/resources/chargeCaptureBundles/resources/v1/client/Client.js +3 -3
- package/api/resources/contracts/resources/v2/client/Client.js +5 -5
- package/api/resources/credentialing/resources/v2/client/Client.js +5 -5
- package/api/resources/customSchemas/resources/v1/client/Client.js +4 -4
- package/api/resources/diagnoses/client/Client.js +3 -3
- package/api/resources/eligibility/resources/v2/client/Client.js +3 -3
- package/api/resources/encounterProviders/resources/v2/client/Client.js +12 -12
- package/api/resources/encounters/resources/v4/client/Client.d.ts +0 -223
- package/api/resources/encounters/resources/v4/client/Client.js +5 -288
- package/api/resources/encounters/resources/v4/client/index.d.ts +0 -1
- package/api/resources/encounters/resources/v4/client/index.js +1 -2
- package/api/resources/expectedNetworkStatus/resources/v1/client/Client.js +1 -1
- package/api/resources/expectedNetworkStatus/resources/v2/client/Client.js +2 -2
- package/api/resources/exports/resources/v3/client/Client.js +1 -1
- package/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.js +1 -1
- package/api/resources/feeSchedules/resources/v3/client/Client.js +10 -10
- package/api/resources/guarantor/resources/v1/client/Client.js +3 -3
- package/api/resources/importInvoice/resources/v1/client/Client.js +4 -4
- package/api/resources/insuranceAdjudications/resources/v1/client/Client.js +3 -3
- package/api/resources/insurancePayments/resources/v1/client/Client.js +5 -5
- package/api/resources/insuranceRefunds/resources/v1/client/Client.js +5 -5
- package/api/resources/medicationDispense/resources/v1/client/Client.js +1 -1
- package/api/resources/nonInsurancePayerPayments/resources/v1/client/Client.js +5 -5
- package/api/resources/nonInsurancePayerRefunds/resources/v1/client/Client.js +5 -5
- package/api/resources/nonInsurancePayers/resources/v1/client/Client.js +6 -6
- package/api/resources/organizationProviders/resources/v3/client/Client.js +4 -4
- package/api/resources/organizationServiceFacilities/resources/v2/client/Client.js +5 -5
- package/api/resources/patientPayments/resources/v4/client/Client.js +5 -5
- package/api/resources/patientRefunds/resources/v1/client/Client.js +5 -5
- package/api/resources/payers/resources/v3/client/Client.js +2 -2
- package/api/resources/preEncounter/resources/appointments/resources/v1/client/Client.js +6 -6
- package/api/resources/preEncounter/resources/coverages/resources/v1/client/Client.js +8 -8
- package/api/resources/preEncounter/resources/lists/resources/v1/client/Client.js +2 -2
- package/api/resources/preEncounter/resources/notes/resources/v1/client/Client.js +4 -4
- package/api/resources/preEncounter/resources/patients/resources/v1/client/Client.js +9 -9
- package/api/resources/preEncounter/resources/tags/resources/v1/client/Client.js +5 -5
- package/api/resources/serviceFacility/client/Client.js +1 -1
- package/api/resources/serviceLines/resources/v2/client/Client.js +3 -3
- package/api/resources/tasks/resources/v3/client/Client.js +5 -5
- package/api/resources/writeOffs/resources/v1/client/Client.js +4 -4
- package/dist/api/resources/auth/resources/v2/client/Client.js +1 -1
- package/dist/api/resources/billingNotes/resources/v2/client/Client.js +3 -3
- package/dist/api/resources/chargeCapture/resources/v1/client/Client.js +5 -5
- package/dist/api/resources/chargeCaptureBundles/resources/v1/client/Client.js +3 -3
- package/dist/api/resources/contracts/resources/v2/client/Client.js +5 -5
- package/dist/api/resources/credentialing/resources/v2/client/Client.js +5 -5
- package/dist/api/resources/customSchemas/resources/v1/client/Client.js +4 -4
- package/dist/api/resources/diagnoses/client/Client.js +3 -3
- package/dist/api/resources/eligibility/resources/v2/client/Client.js +3 -3
- package/dist/api/resources/encounterProviders/resources/v2/client/Client.js +12 -12
- package/dist/api/resources/encounters/resources/v4/client/Client.d.ts +0 -223
- package/dist/api/resources/encounters/resources/v4/client/Client.js +5 -288
- package/dist/api/resources/encounters/resources/v4/client/index.d.ts +0 -1
- package/dist/api/resources/encounters/resources/v4/client/index.js +1 -2
- package/dist/api/resources/expectedNetworkStatus/resources/v1/client/Client.js +1 -1
- package/dist/api/resources/expectedNetworkStatus/resources/v2/client/Client.js +2 -2
- package/dist/api/resources/exports/resources/v3/client/Client.js +1 -1
- package/dist/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.js +1 -1
- package/dist/api/resources/feeSchedules/resources/v3/client/Client.js +10 -10
- package/dist/api/resources/guarantor/resources/v1/client/Client.js +3 -3
- package/dist/api/resources/importInvoice/resources/v1/client/Client.js +4 -4
- package/dist/api/resources/insuranceAdjudications/resources/v1/client/Client.js +3 -3
- package/dist/api/resources/insurancePayments/resources/v1/client/Client.js +5 -5
- package/dist/api/resources/insuranceRefunds/resources/v1/client/Client.js +5 -5
- package/dist/api/resources/medicationDispense/resources/v1/client/Client.js +1 -1
- package/dist/api/resources/nonInsurancePayerPayments/resources/v1/client/Client.js +5 -5
- package/dist/api/resources/nonInsurancePayerRefunds/resources/v1/client/Client.js +5 -5
- package/dist/api/resources/nonInsurancePayers/resources/v1/client/Client.js +6 -6
- package/dist/api/resources/organizationProviders/resources/v3/client/Client.js +4 -4
- package/dist/api/resources/organizationServiceFacilities/resources/v2/client/Client.js +5 -5
- package/dist/api/resources/patientPayments/resources/v4/client/Client.js +5 -5
- package/dist/api/resources/patientRefunds/resources/v1/client/Client.js +5 -5
- package/dist/api/resources/payers/resources/v3/client/Client.js +2 -2
- package/dist/api/resources/preEncounter/resources/appointments/resources/v1/client/Client.js +6 -6
- package/dist/api/resources/preEncounter/resources/coverages/resources/v1/client/Client.js +8 -8
- package/dist/api/resources/preEncounter/resources/lists/resources/v1/client/Client.js +2 -2
- package/dist/api/resources/preEncounter/resources/notes/resources/v1/client/Client.js +4 -4
- package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/Client.js +9 -9
- package/dist/api/resources/preEncounter/resources/tags/resources/v1/client/Client.js +5 -5
- package/dist/api/resources/serviceFacility/client/Client.js +1 -1
- package/dist/api/resources/serviceLines/resources/v2/client/Client.js +3 -3
- package/dist/api/resources/tasks/resources/v3/client/Client.js +5 -5
- package/dist/api/resources/writeOffs/resources/v1/client/Client.js +4 -4
- package/dist/serialization/resources/encounters/resources/v4/client/index.d.ts +0 -1
- package/dist/serialization/resources/encounters/resources/v4/client/index.js +1 -2
- package/package.json +1 -1
- package/reference.md +0 -304
- package/serialization/resources/encounters/resources/v4/client/index.d.ts +0 -1
- package/serialization/resources/encounters/resources/v4/client/index.js +1 -2
- package/api/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.d.ts +0 -58
- package/api/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.js +0 -113
- package/dist/api/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.d.ts +0 -58
- package/dist/api/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.js +0 -113
- package/dist/serialization/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.d.ts +0 -39
- package/dist/serialization/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.js +0 -90
- package/serialization/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.d.ts +0 -39
- package/serialization/resources/encounters/resources/v4/client/createFromPreEncounterPatientInternal.js +0 -90
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
-
*/
|
|
4
|
-
import * as serializers from "../../../../../index";
|
|
5
|
-
import * as CandidApi from "../../../../../../api/index";
|
|
6
|
-
import * as core from "../../../../../../core";
|
|
7
|
-
import { EncounterExternalIdUniquenessErrorType } from "../types/EncounterExternalIdUniquenessErrorType";
|
|
8
|
-
import { EncounterPatientControlNumberUniquenessErrorType } from "../types/EncounterPatientControlNumberUniquenessErrorType";
|
|
9
|
-
import { EntityNotFoundErrorMessage } from "../../../../commons/types/EntityNotFoundErrorMessage";
|
|
10
|
-
import { RequestValidationError } from "../../../../commons/types/RequestValidationError";
|
|
11
|
-
import { SchemaInstanceValidationFailure } from "../types/SchemaInstanceValidationFailure";
|
|
12
|
-
export declare const Error: core.serialization.Schema<serializers.encounters.v4.createFromPreEncounterPatientInternal.Error.Raw, CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error>;
|
|
13
|
-
export declare namespace Error {
|
|
14
|
-
type Raw = Error.EncounterExternalIdUniquenessError | Error.EncounterPatientControlNumberUniquenessError | Error.EntityNotFoundError | Error.HttpRequestValidationsError | Error.SchemaInstanceValidationHttpFailure | Error.HttpRequestValidationError;
|
|
15
|
-
interface EncounterExternalIdUniquenessError {
|
|
16
|
-
errorName: "EncounterExternalIdUniquenessError";
|
|
17
|
-
content: EncounterExternalIdUniquenessErrorType.Raw;
|
|
18
|
-
}
|
|
19
|
-
interface EncounterPatientControlNumberUniquenessError {
|
|
20
|
-
errorName: "EncounterPatientControlNumberUniquenessError";
|
|
21
|
-
content: EncounterPatientControlNumberUniquenessErrorType.Raw;
|
|
22
|
-
}
|
|
23
|
-
interface EntityNotFoundError {
|
|
24
|
-
errorName: "EntityNotFoundError";
|
|
25
|
-
content: EntityNotFoundErrorMessage.Raw;
|
|
26
|
-
}
|
|
27
|
-
interface HttpRequestValidationsError {
|
|
28
|
-
errorName: "HttpRequestValidationsError";
|
|
29
|
-
content: RequestValidationError.Raw[];
|
|
30
|
-
}
|
|
31
|
-
interface SchemaInstanceValidationHttpFailure {
|
|
32
|
-
errorName: "SchemaInstanceValidationHttpFailure";
|
|
33
|
-
content: SchemaInstanceValidationFailure.Raw;
|
|
34
|
-
}
|
|
35
|
-
interface HttpRequestValidationError {
|
|
36
|
-
errorName: "HttpRequestValidationError";
|
|
37
|
-
content: RequestValidationError.Raw;
|
|
38
|
-
}
|
|
39
|
-
}
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
-
*/
|
|
5
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
-
}
|
|
11
|
-
Object.defineProperty(o, k2, desc);
|
|
12
|
-
}) : (function(o, m, k, k2) {
|
|
13
|
-
if (k2 === undefined) k2 = k;
|
|
14
|
-
o[k2] = m[k];
|
|
15
|
-
}));
|
|
16
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
-
}) : function(o, v) {
|
|
19
|
-
o["default"] = v;
|
|
20
|
-
});
|
|
21
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
-
if (mod && mod.__esModule) return mod;
|
|
23
|
-
var result = {};
|
|
24
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
-
__setModuleDefault(result, mod);
|
|
26
|
-
return result;
|
|
27
|
-
};
|
|
28
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
29
|
-
var t = {};
|
|
30
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
31
|
-
t[p] = s[p];
|
|
32
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
33
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
34
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
35
|
-
t[p[i]] = s[p[i]];
|
|
36
|
-
}
|
|
37
|
-
return t;
|
|
38
|
-
};
|
|
39
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
-
exports.Error = void 0;
|
|
41
|
-
const CandidApi = __importStar(require("../../../../../../api/index"));
|
|
42
|
-
const core = __importStar(require("../../../../../../core"));
|
|
43
|
-
const EncounterExternalIdUniquenessErrorType_1 = require("../types/EncounterExternalIdUniquenessErrorType");
|
|
44
|
-
const EncounterPatientControlNumberUniquenessErrorType_1 = require("../types/EncounterPatientControlNumberUniquenessErrorType");
|
|
45
|
-
const EntityNotFoundErrorMessage_1 = require("../../../../commons/types/EntityNotFoundErrorMessage");
|
|
46
|
-
const RequestValidationError_1 = require("../../../../commons/types/RequestValidationError");
|
|
47
|
-
const SchemaInstanceValidationFailure_1 = require("../types/SchemaInstanceValidationFailure");
|
|
48
|
-
exports.Error = core.serialization
|
|
49
|
-
.union("errorName", {
|
|
50
|
-
EncounterExternalIdUniquenessError: core.serialization.object({
|
|
51
|
-
content: EncounterExternalIdUniquenessErrorType_1.EncounterExternalIdUniquenessErrorType,
|
|
52
|
-
}),
|
|
53
|
-
EncounterPatientControlNumberUniquenessError: core.serialization.object({
|
|
54
|
-
content: EncounterPatientControlNumberUniquenessErrorType_1.EncounterPatientControlNumberUniquenessErrorType,
|
|
55
|
-
}),
|
|
56
|
-
EntityNotFoundError: core.serialization.object({
|
|
57
|
-
content: EntityNotFoundErrorMessage_1.EntityNotFoundErrorMessage,
|
|
58
|
-
}),
|
|
59
|
-
HttpRequestValidationsError: core.serialization.object({
|
|
60
|
-
content: core.serialization.list(RequestValidationError_1.RequestValidationError),
|
|
61
|
-
}),
|
|
62
|
-
SchemaInstanceValidationHttpFailure: core.serialization.object({
|
|
63
|
-
content: SchemaInstanceValidationFailure_1.SchemaInstanceValidationFailure,
|
|
64
|
-
}),
|
|
65
|
-
HttpRequestValidationError: core.serialization.object({
|
|
66
|
-
content: RequestValidationError_1.RequestValidationError,
|
|
67
|
-
}),
|
|
68
|
-
})
|
|
69
|
-
.transform({
|
|
70
|
-
transform: (value) => {
|
|
71
|
-
switch (value.errorName) {
|
|
72
|
-
case "EncounterExternalIdUniquenessError":
|
|
73
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.encounterExternalIdUniquenessError(value.content);
|
|
74
|
-
case "EncounterPatientControlNumberUniquenessError":
|
|
75
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.encounterPatientControlNumberUniquenessError(value.content);
|
|
76
|
-
case "EntityNotFoundError":
|
|
77
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.entityNotFoundError(value.content);
|
|
78
|
-
case "HttpRequestValidationsError":
|
|
79
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.httpRequestValidationsError(value.content);
|
|
80
|
-
case "SchemaInstanceValidationHttpFailure":
|
|
81
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.schemaInstanceValidationHttpFailure(value.content);
|
|
82
|
-
case "HttpRequestValidationError":
|
|
83
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.httpRequestValidationError(value.content);
|
|
84
|
-
}
|
|
85
|
-
},
|
|
86
|
-
untransform: (_a) => {
|
|
87
|
-
var { _visit } = _a, value = __rest(_a, ["_visit"]);
|
|
88
|
-
return value;
|
|
89
|
-
},
|
|
90
|
-
});
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
-
*/
|
|
4
|
-
import * as serializers from "../../../../../index";
|
|
5
|
-
import * as CandidApi from "../../../../../../api/index";
|
|
6
|
-
import * as core from "../../../../../../core";
|
|
7
|
-
import { EncounterExternalIdUniquenessErrorType } from "../types/EncounterExternalIdUniquenessErrorType";
|
|
8
|
-
import { EncounterPatientControlNumberUniquenessErrorType } from "../types/EncounterPatientControlNumberUniquenessErrorType";
|
|
9
|
-
import { EntityNotFoundErrorMessage } from "../../../../commons/types/EntityNotFoundErrorMessage";
|
|
10
|
-
import { RequestValidationError } from "../../../../commons/types/RequestValidationError";
|
|
11
|
-
import { SchemaInstanceValidationFailure } from "../types/SchemaInstanceValidationFailure";
|
|
12
|
-
export declare const Error: core.serialization.Schema<serializers.encounters.v4.createFromPreEncounterPatientInternal.Error.Raw, CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error>;
|
|
13
|
-
export declare namespace Error {
|
|
14
|
-
type Raw = Error.EncounterExternalIdUniquenessError | Error.EncounterPatientControlNumberUniquenessError | Error.EntityNotFoundError | Error.HttpRequestValidationsError | Error.SchemaInstanceValidationHttpFailure | Error.HttpRequestValidationError;
|
|
15
|
-
interface EncounterExternalIdUniquenessError {
|
|
16
|
-
errorName: "EncounterExternalIdUniquenessError";
|
|
17
|
-
content: EncounterExternalIdUniquenessErrorType.Raw;
|
|
18
|
-
}
|
|
19
|
-
interface EncounterPatientControlNumberUniquenessError {
|
|
20
|
-
errorName: "EncounterPatientControlNumberUniquenessError";
|
|
21
|
-
content: EncounterPatientControlNumberUniquenessErrorType.Raw;
|
|
22
|
-
}
|
|
23
|
-
interface EntityNotFoundError {
|
|
24
|
-
errorName: "EntityNotFoundError";
|
|
25
|
-
content: EntityNotFoundErrorMessage.Raw;
|
|
26
|
-
}
|
|
27
|
-
interface HttpRequestValidationsError {
|
|
28
|
-
errorName: "HttpRequestValidationsError";
|
|
29
|
-
content: RequestValidationError.Raw[];
|
|
30
|
-
}
|
|
31
|
-
interface SchemaInstanceValidationHttpFailure {
|
|
32
|
-
errorName: "SchemaInstanceValidationHttpFailure";
|
|
33
|
-
content: SchemaInstanceValidationFailure.Raw;
|
|
34
|
-
}
|
|
35
|
-
interface HttpRequestValidationError {
|
|
36
|
-
errorName: "HttpRequestValidationError";
|
|
37
|
-
content: RequestValidationError.Raw;
|
|
38
|
-
}
|
|
39
|
-
}
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
-
*/
|
|
5
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
-
}
|
|
11
|
-
Object.defineProperty(o, k2, desc);
|
|
12
|
-
}) : (function(o, m, k, k2) {
|
|
13
|
-
if (k2 === undefined) k2 = k;
|
|
14
|
-
o[k2] = m[k];
|
|
15
|
-
}));
|
|
16
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
-
}) : function(o, v) {
|
|
19
|
-
o["default"] = v;
|
|
20
|
-
});
|
|
21
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
-
if (mod && mod.__esModule) return mod;
|
|
23
|
-
var result = {};
|
|
24
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
-
__setModuleDefault(result, mod);
|
|
26
|
-
return result;
|
|
27
|
-
};
|
|
28
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
29
|
-
var t = {};
|
|
30
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
31
|
-
t[p] = s[p];
|
|
32
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
33
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
34
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
35
|
-
t[p[i]] = s[p[i]];
|
|
36
|
-
}
|
|
37
|
-
return t;
|
|
38
|
-
};
|
|
39
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
-
exports.Error = void 0;
|
|
41
|
-
const CandidApi = __importStar(require("../../../../../../api/index"));
|
|
42
|
-
const core = __importStar(require("../../../../../../core"));
|
|
43
|
-
const EncounterExternalIdUniquenessErrorType_1 = require("../types/EncounterExternalIdUniquenessErrorType");
|
|
44
|
-
const EncounterPatientControlNumberUniquenessErrorType_1 = require("../types/EncounterPatientControlNumberUniquenessErrorType");
|
|
45
|
-
const EntityNotFoundErrorMessage_1 = require("../../../../commons/types/EntityNotFoundErrorMessage");
|
|
46
|
-
const RequestValidationError_1 = require("../../../../commons/types/RequestValidationError");
|
|
47
|
-
const SchemaInstanceValidationFailure_1 = require("../types/SchemaInstanceValidationFailure");
|
|
48
|
-
exports.Error = core.serialization
|
|
49
|
-
.union("errorName", {
|
|
50
|
-
EncounterExternalIdUniquenessError: core.serialization.object({
|
|
51
|
-
content: EncounterExternalIdUniquenessErrorType_1.EncounterExternalIdUniquenessErrorType,
|
|
52
|
-
}),
|
|
53
|
-
EncounterPatientControlNumberUniquenessError: core.serialization.object({
|
|
54
|
-
content: EncounterPatientControlNumberUniquenessErrorType_1.EncounterPatientControlNumberUniquenessErrorType,
|
|
55
|
-
}),
|
|
56
|
-
EntityNotFoundError: core.serialization.object({
|
|
57
|
-
content: EntityNotFoundErrorMessage_1.EntityNotFoundErrorMessage,
|
|
58
|
-
}),
|
|
59
|
-
HttpRequestValidationsError: core.serialization.object({
|
|
60
|
-
content: core.serialization.list(RequestValidationError_1.RequestValidationError),
|
|
61
|
-
}),
|
|
62
|
-
SchemaInstanceValidationHttpFailure: core.serialization.object({
|
|
63
|
-
content: SchemaInstanceValidationFailure_1.SchemaInstanceValidationFailure,
|
|
64
|
-
}),
|
|
65
|
-
HttpRequestValidationError: core.serialization.object({
|
|
66
|
-
content: RequestValidationError_1.RequestValidationError,
|
|
67
|
-
}),
|
|
68
|
-
})
|
|
69
|
-
.transform({
|
|
70
|
-
transform: (value) => {
|
|
71
|
-
switch (value.errorName) {
|
|
72
|
-
case "EncounterExternalIdUniquenessError":
|
|
73
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.encounterExternalIdUniquenessError(value.content);
|
|
74
|
-
case "EncounterPatientControlNumberUniquenessError":
|
|
75
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.encounterPatientControlNumberUniquenessError(value.content);
|
|
76
|
-
case "EntityNotFoundError":
|
|
77
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.entityNotFoundError(value.content);
|
|
78
|
-
case "HttpRequestValidationsError":
|
|
79
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.httpRequestValidationsError(value.content);
|
|
80
|
-
case "SchemaInstanceValidationHttpFailure":
|
|
81
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.schemaInstanceValidationHttpFailure(value.content);
|
|
82
|
-
case "HttpRequestValidationError":
|
|
83
|
-
return CandidApi.encounters.v4.createFromPreEncounterPatientInternal.Error.httpRequestValidationError(value.content);
|
|
84
|
-
}
|
|
85
|
-
},
|
|
86
|
-
untransform: (_a) => {
|
|
87
|
-
var { _visit } = _a, value = __rest(_a, ["_visit"]);
|
|
88
|
-
return value;
|
|
89
|
-
},
|
|
90
|
-
});
|