@aws-sdk/client-comprehendmedical 3.35.0 → 3.38.0
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/CHANGELOG.md +47 -0
- package/dist-cjs/ComprehendMedical.js +0 -5
- package/dist-cjs/ComprehendMedicalClient.js +0 -10
- package/dist-cjs/commands/DescribeEntitiesDetectionV2JobCommand.js +0 -26
- package/dist-cjs/commands/DescribeICD10CMInferenceJobCommand.js +0 -26
- package/dist-cjs/commands/DescribePHIDetectionJobCommand.js +0 -26
- package/dist-cjs/commands/DescribeRxNormInferenceJobCommand.js +0 -26
- package/dist-cjs/commands/DetectEntitiesCommand.js +0 -30
- package/dist-cjs/commands/DetectEntitiesV2Command.js +0 -34
- package/dist-cjs/commands/DetectPHICommand.js +0 -27
- package/dist-cjs/commands/InferICD10CMCommand.js +0 -28
- package/dist-cjs/commands/InferRxNormCommand.js +0 -27
- package/dist-cjs/commands/ListEntitiesDetectionV2JobsCommand.js +0 -25
- package/dist-cjs/commands/ListICD10CMInferenceJobsCommand.js +0 -25
- package/dist-cjs/commands/ListPHIDetectionJobsCommand.js +0 -26
- package/dist-cjs/commands/ListRxNormInferenceJobsCommand.js +0 -25
- package/dist-cjs/commands/StartEntitiesDetectionV2JobCommand.js +0 -26
- package/dist-cjs/commands/StartICD10CMInferenceJobCommand.js +0 -27
- package/dist-cjs/commands/StartPHIDetectionJobCommand.js +0 -26
- package/dist-cjs/commands/StartRxNormInferenceJobCommand.js +0 -27
- package/dist-cjs/commands/StopEntitiesDetectionV2JobCommand.js +0 -25
- package/dist-cjs/commands/StopICD10CMInferenceJobCommand.js +0 -25
- package/dist-cjs/commands/StopPHIDetectionJobCommand.js +0 -25
- package/dist-cjs/commands/StopRxNormInferenceJobCommand.js +0 -25
- package/dist-cjs/commands/index.js +24 -0
- package/dist-cjs/endpoints.js +1 -2
- package/dist-cjs/index.js +3 -24
- package/dist-cjs/models/index.js +0 -1
- package/dist-cjs/models/models_0.js +0 -199
- package/dist-cjs/protocols/Aws_json1_1.js +0 -6
- package/dist-cjs/runtimeConfig.browser.js +1 -6
- package/dist-cjs/runtimeConfig.js +2 -7
- package/dist-cjs/runtimeConfig.native.js +0 -4
- package/dist-cjs/runtimeConfig.shared.js +0 -4
- package/dist-es/ComprehendMedical.js +0 -1
- package/dist-es/ComprehendMedicalClient.js +0 -1
- package/dist-es/commands/DescribeEntitiesDetectionV2JobCommand.js +0 -1
- package/dist-es/commands/DescribeICD10CMInferenceJobCommand.js +0 -1
- package/dist-es/commands/DescribePHIDetectionJobCommand.js +0 -1
- package/dist-es/commands/DescribeRxNormInferenceJobCommand.js +0 -1
- package/dist-es/commands/DetectEntitiesCommand.js +0 -1
- package/dist-es/commands/DetectEntitiesV2Command.js +0 -1
- package/dist-es/commands/DetectPHICommand.js +0 -1
- package/dist-es/commands/InferICD10CMCommand.js +0 -1
- package/dist-es/commands/InferRxNormCommand.js +0 -1
- package/dist-es/commands/ListEntitiesDetectionV2JobsCommand.js +0 -1
- package/dist-es/commands/ListICD10CMInferenceJobsCommand.js +0 -1
- package/dist-es/commands/ListPHIDetectionJobsCommand.js +0 -1
- package/dist-es/commands/ListRxNormInferenceJobsCommand.js +0 -1
- package/dist-es/commands/StartEntitiesDetectionV2JobCommand.js +0 -1
- package/dist-es/commands/StartICD10CMInferenceJobCommand.js +0 -1
- package/dist-es/commands/StartPHIDetectionJobCommand.js +0 -1
- package/dist-es/commands/StartRxNormInferenceJobCommand.js +0 -1
- package/dist-es/commands/StopEntitiesDetectionV2JobCommand.js +0 -1
- package/dist-es/commands/StopICD10CMInferenceJobCommand.js +0 -1
- package/dist-es/commands/StopPHIDetectionJobCommand.js +0 -1
- package/dist-es/commands/StopRxNormInferenceJobCommand.js +0 -1
- package/dist-es/commands/index.js +21 -0
- package/dist-es/endpoints.js +1 -2
- package/dist-es/index.js +3 -24
- package/dist-es/models/index.js +0 -1
- package/dist-es/models/models_0.js +0 -1
- package/dist-es/protocols/Aws_json1_1.js +0 -1
- package/dist-es/runtimeConfig.browser.js +1 -2
- package/dist-es/runtimeConfig.js +2 -3
- package/dist-es/runtimeConfig.native.js +0 -1
- package/dist-es/runtimeConfig.shared.js +0 -1
- package/dist-types/commands/index.d.ts +21 -0
- package/dist-types/index.d.ts +3 -23
- package/dist-types/ts3.4/ComprehendMedical.d.ts +22 -99
- package/dist-types/ts3.4/ComprehendMedicalClient.d.ts +24 -90
- package/dist-types/ts3.4/commands/DescribeEntitiesDetectionV2JobCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/DescribeICD10CMInferenceJobCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/DescribePHIDetectionJobCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/DescribeRxNormInferenceJobCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/DetectEntitiesCommand.d.ts +2 -25
- package/dist-types/ts3.4/commands/DetectEntitiesV2Command.d.ts +2 -29
- package/dist-types/ts3.4/commands/DetectPHICommand.d.ts +2 -22
- package/dist-types/ts3.4/commands/InferICD10CMCommand.d.ts +2 -23
- package/dist-types/ts3.4/commands/InferRxNormCommand.d.ts +2 -22
- package/dist-types/ts3.4/commands/ListEntitiesDetectionV2JobsCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/ListICD10CMInferenceJobsCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/ListPHIDetectionJobsCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/ListRxNormInferenceJobsCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/StartEntitiesDetectionV2JobCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/StartICD10CMInferenceJobCommand.d.ts +2 -22
- package/dist-types/ts3.4/commands/StartPHIDetectionJobCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/StartRxNormInferenceJobCommand.d.ts +2 -22
- package/dist-types/ts3.4/commands/StopEntitiesDetectionV2JobCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/StopICD10CMInferenceJobCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/StopPHIDetectionJobCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/StopRxNormInferenceJobCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/index.d.ts +21 -0
- package/dist-types/ts3.4/index.d.ts +3 -23
- package/dist-types/ts3.4/models/models_0.d.ts +273 -985
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +1 -3
- package/package.json +33 -30
- package/dist-cjs/ComprehendMedical.js.map +0 -1
- package/dist-cjs/ComprehendMedicalClient.js.map +0 -1
- package/dist-cjs/commands/DescribeEntitiesDetectionV2JobCommand.js.map +0 -1
- package/dist-cjs/commands/DescribeICD10CMInferenceJobCommand.js.map +0 -1
- package/dist-cjs/commands/DescribePHIDetectionJobCommand.js.map +0 -1
- package/dist-cjs/commands/DescribeRxNormInferenceJobCommand.js.map +0 -1
- package/dist-cjs/commands/DetectEntitiesCommand.js.map +0 -1
- package/dist-cjs/commands/DetectEntitiesV2Command.js.map +0 -1
- package/dist-cjs/commands/DetectPHICommand.js.map +0 -1
- package/dist-cjs/commands/InferICD10CMCommand.js.map +0 -1
- package/dist-cjs/commands/InferRxNormCommand.js.map +0 -1
- package/dist-cjs/commands/ListEntitiesDetectionV2JobsCommand.js.map +0 -1
- package/dist-cjs/commands/ListICD10CMInferenceJobsCommand.js.map +0 -1
- package/dist-cjs/commands/ListPHIDetectionJobsCommand.js.map +0 -1
- package/dist-cjs/commands/ListRxNormInferenceJobsCommand.js.map +0 -1
- package/dist-cjs/commands/StartEntitiesDetectionV2JobCommand.js.map +0 -1
- package/dist-cjs/commands/StartICD10CMInferenceJobCommand.js.map +0 -1
- package/dist-cjs/commands/StartPHIDetectionJobCommand.js.map +0 -1
- package/dist-cjs/commands/StartRxNormInferenceJobCommand.js.map +0 -1
- package/dist-cjs/commands/StopEntitiesDetectionV2JobCommand.js.map +0 -1
- package/dist-cjs/commands/StopICD10CMInferenceJobCommand.js.map +0 -1
- package/dist-cjs/commands/StopPHIDetectionJobCommand.js.map +0 -1
- package/dist-cjs/commands/StopRxNormInferenceJobCommand.js.map +0 -1
- package/dist-cjs/endpoints.js.map +0 -1
- package/dist-cjs/index.js.map +0 -1
- package/dist-cjs/models/index.js.map +0 -1
- package/dist-cjs/models/models_0.js.map +0 -1
- package/dist-cjs/protocols/Aws_json1_1.js.map +0 -1
- package/dist-cjs/runtimeConfig.browser.js.map +0 -1
- package/dist-cjs/runtimeConfig.js.map +0 -1
- package/dist-cjs/runtimeConfig.native.js.map +0 -1
- package/dist-cjs/runtimeConfig.shared.js.map +0 -1
- package/dist-es/ComprehendMedical.js.map +0 -1
- package/dist-es/ComprehendMedicalClient.js.map +0 -1
- package/dist-es/commands/DescribeEntitiesDetectionV2JobCommand.js.map +0 -1
- package/dist-es/commands/DescribeICD10CMInferenceJobCommand.js.map +0 -1
- package/dist-es/commands/DescribePHIDetectionJobCommand.js.map +0 -1
- package/dist-es/commands/DescribeRxNormInferenceJobCommand.js.map +0 -1
- package/dist-es/commands/DetectEntitiesCommand.js.map +0 -1
- package/dist-es/commands/DetectEntitiesV2Command.js.map +0 -1
- package/dist-es/commands/DetectPHICommand.js.map +0 -1
- package/dist-es/commands/InferICD10CMCommand.js.map +0 -1
- package/dist-es/commands/InferRxNormCommand.js.map +0 -1
- package/dist-es/commands/ListEntitiesDetectionV2JobsCommand.js.map +0 -1
- package/dist-es/commands/ListICD10CMInferenceJobsCommand.js.map +0 -1
- package/dist-es/commands/ListPHIDetectionJobsCommand.js.map +0 -1
- package/dist-es/commands/ListRxNormInferenceJobsCommand.js.map +0 -1
- package/dist-es/commands/StartEntitiesDetectionV2JobCommand.js.map +0 -1
- package/dist-es/commands/StartICD10CMInferenceJobCommand.js.map +0 -1
- package/dist-es/commands/StartPHIDetectionJobCommand.js.map +0 -1
- package/dist-es/commands/StartRxNormInferenceJobCommand.js.map +0 -1
- package/dist-es/commands/StopEntitiesDetectionV2JobCommand.js.map +0 -1
- package/dist-es/commands/StopICD10CMInferenceJobCommand.js.map +0 -1
- package/dist-es/commands/StopPHIDetectionJobCommand.js.map +0 -1
- package/dist-es/commands/StopRxNormInferenceJobCommand.js.map +0 -1
- package/dist-es/endpoints.js.map +0 -1
- package/dist-es/index.js.map +0 -1
- package/dist-es/models/index.js.map +0 -1
- package/dist-es/models/models_0.js.map +0 -1
- package/dist-es/protocols/Aws_json1_1.js.map +0 -1
- package/dist-es/runtimeConfig.browser.js.map +0 -1
- package/dist-es/runtimeConfig.js.map +0 -1
- package/dist-es/runtimeConfig.native.js.map +0 -1
- package/dist-es/runtimeConfig.shared.js.map +0 -1
- package/jest.config.js +0 -4
- package/src/ComprehendMedical.ts +0 -795
- package/src/ComprehendMedicalClient.ts +0 -348
- package/src/commands/DescribeEntitiesDetectionV2JobCommand.ts +0 -108
- package/src/commands/DescribeICD10CMInferenceJobCommand.ts +0 -105
- package/src/commands/DescribePHIDetectionJobCommand.ts +0 -100
- package/src/commands/DescribeRxNormInferenceJobCommand.ts +0 -103
- package/src/commands/DetectEntitiesCommand.ts +0 -104
- package/src/commands/DetectEntitiesV2Command.ts +0 -108
- package/src/commands/DetectPHICommand.ts +0 -98
- package/src/commands/InferICD10CMCommand.ts +0 -102
- package/src/commands/InferRxNormCommand.ts +0 -101
- package/src/commands/ListEntitiesDetectionV2JobsCommand.ts +0 -104
- package/src/commands/ListICD10CMInferenceJobsCommand.ts +0 -99
- package/src/commands/ListPHIDetectionJobsCommand.ts +0 -100
- package/src/commands/ListRxNormInferenceJobsCommand.ts +0 -99
- package/src/commands/StartEntitiesDetectionV2JobCommand.ts +0 -105
- package/src/commands/StartICD10CMInferenceJobCommand.ts +0 -101
- package/src/commands/StartPHIDetectionJobCommand.ts +0 -100
- package/src/commands/StartRxNormInferenceJobCommand.ts +0 -101
- package/src/commands/StopEntitiesDetectionV2JobCommand.ts +0 -102
- package/src/commands/StopICD10CMInferenceJobCommand.ts +0 -99
- package/src/commands/StopPHIDetectionJobCommand.ts +0 -99
- package/src/commands/StopRxNormInferenceJobCommand.ts +0 -99
- package/src/endpoints.ts +0 -77
- package/src/index.ts +0 -24
- package/src/models/index.ts +0 -1
- package/src/models/models_0.ts +0 -2054
- package/src/protocols/Aws_json1_1.ts +0 -3273
- package/src/runtimeConfig.browser.ts +0 -41
- package/src/runtimeConfig.native.ts +0 -17
- package/src/runtimeConfig.shared.ts +0 -17
- package/src/runtimeConfig.ts +0 -46
- package/tsconfig.es.json +0 -10
- package/tsconfig.json +0 -33
- package/tsconfig.types.json +0 -9
|
@@ -1,3273 +0,0 @@
|
|
|
1
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
2
|
-
import {
|
|
3
|
-
expectInt32 as __expectInt32,
|
|
4
|
-
expectNonNull as __expectNonNull,
|
|
5
|
-
expectNumber as __expectNumber,
|
|
6
|
-
expectString as __expectString,
|
|
7
|
-
limitedParseFloat32 as __limitedParseFloat32,
|
|
8
|
-
parseEpochTimestamp as __parseEpochTimestamp,
|
|
9
|
-
} from "@aws-sdk/smithy-client";
|
|
10
|
-
import {
|
|
11
|
-
Endpoint as __Endpoint,
|
|
12
|
-
HeaderBag as __HeaderBag,
|
|
13
|
-
MetadataBearer as __MetadataBearer,
|
|
14
|
-
ResponseMetadata as __ResponseMetadata,
|
|
15
|
-
SerdeContext as __SerdeContext,
|
|
16
|
-
SmithyException as __SmithyException,
|
|
17
|
-
} from "@aws-sdk/types";
|
|
18
|
-
import { v4 as generateIdempotencyToken } from "uuid";
|
|
19
|
-
|
|
20
|
-
import {
|
|
21
|
-
DescribeEntitiesDetectionV2JobCommandInput,
|
|
22
|
-
DescribeEntitiesDetectionV2JobCommandOutput,
|
|
23
|
-
} from "../commands/DescribeEntitiesDetectionV2JobCommand";
|
|
24
|
-
import {
|
|
25
|
-
DescribeICD10CMInferenceJobCommandInput,
|
|
26
|
-
DescribeICD10CMInferenceJobCommandOutput,
|
|
27
|
-
} from "../commands/DescribeICD10CMInferenceJobCommand";
|
|
28
|
-
import {
|
|
29
|
-
DescribePHIDetectionJobCommandInput,
|
|
30
|
-
DescribePHIDetectionJobCommandOutput,
|
|
31
|
-
} from "../commands/DescribePHIDetectionJobCommand";
|
|
32
|
-
import {
|
|
33
|
-
DescribeRxNormInferenceJobCommandInput,
|
|
34
|
-
DescribeRxNormInferenceJobCommandOutput,
|
|
35
|
-
} from "../commands/DescribeRxNormInferenceJobCommand";
|
|
36
|
-
import { DetectEntitiesCommandInput, DetectEntitiesCommandOutput } from "../commands/DetectEntitiesCommand";
|
|
37
|
-
import { DetectEntitiesV2CommandInput, DetectEntitiesV2CommandOutput } from "../commands/DetectEntitiesV2Command";
|
|
38
|
-
import { DetectPHICommandInput, DetectPHICommandOutput } from "../commands/DetectPHICommand";
|
|
39
|
-
import { InferICD10CMCommandInput, InferICD10CMCommandOutput } from "../commands/InferICD10CMCommand";
|
|
40
|
-
import { InferRxNormCommandInput, InferRxNormCommandOutput } from "../commands/InferRxNormCommand";
|
|
41
|
-
import {
|
|
42
|
-
ListEntitiesDetectionV2JobsCommandInput,
|
|
43
|
-
ListEntitiesDetectionV2JobsCommandOutput,
|
|
44
|
-
} from "../commands/ListEntitiesDetectionV2JobsCommand";
|
|
45
|
-
import {
|
|
46
|
-
ListICD10CMInferenceJobsCommandInput,
|
|
47
|
-
ListICD10CMInferenceJobsCommandOutput,
|
|
48
|
-
} from "../commands/ListICD10CMInferenceJobsCommand";
|
|
49
|
-
import {
|
|
50
|
-
ListPHIDetectionJobsCommandInput,
|
|
51
|
-
ListPHIDetectionJobsCommandOutput,
|
|
52
|
-
} from "../commands/ListPHIDetectionJobsCommand";
|
|
53
|
-
import {
|
|
54
|
-
ListRxNormInferenceJobsCommandInput,
|
|
55
|
-
ListRxNormInferenceJobsCommandOutput,
|
|
56
|
-
} from "../commands/ListRxNormInferenceJobsCommand";
|
|
57
|
-
import {
|
|
58
|
-
StartEntitiesDetectionV2JobCommandInput,
|
|
59
|
-
StartEntitiesDetectionV2JobCommandOutput,
|
|
60
|
-
} from "../commands/StartEntitiesDetectionV2JobCommand";
|
|
61
|
-
import {
|
|
62
|
-
StartICD10CMInferenceJobCommandInput,
|
|
63
|
-
StartICD10CMInferenceJobCommandOutput,
|
|
64
|
-
} from "../commands/StartICD10CMInferenceJobCommand";
|
|
65
|
-
import {
|
|
66
|
-
StartPHIDetectionJobCommandInput,
|
|
67
|
-
StartPHIDetectionJobCommandOutput,
|
|
68
|
-
} from "../commands/StartPHIDetectionJobCommand";
|
|
69
|
-
import {
|
|
70
|
-
StartRxNormInferenceJobCommandInput,
|
|
71
|
-
StartRxNormInferenceJobCommandOutput,
|
|
72
|
-
} from "../commands/StartRxNormInferenceJobCommand";
|
|
73
|
-
import {
|
|
74
|
-
StopEntitiesDetectionV2JobCommandInput,
|
|
75
|
-
StopEntitiesDetectionV2JobCommandOutput,
|
|
76
|
-
} from "../commands/StopEntitiesDetectionV2JobCommand";
|
|
77
|
-
import {
|
|
78
|
-
StopICD10CMInferenceJobCommandInput,
|
|
79
|
-
StopICD10CMInferenceJobCommandOutput,
|
|
80
|
-
} from "../commands/StopICD10CMInferenceJobCommand";
|
|
81
|
-
import {
|
|
82
|
-
StopPHIDetectionJobCommandInput,
|
|
83
|
-
StopPHIDetectionJobCommandOutput,
|
|
84
|
-
} from "../commands/StopPHIDetectionJobCommand";
|
|
85
|
-
import {
|
|
86
|
-
StopRxNormInferenceJobCommandInput,
|
|
87
|
-
StopRxNormInferenceJobCommandOutput,
|
|
88
|
-
} from "../commands/StopRxNormInferenceJobCommand";
|
|
89
|
-
import {
|
|
90
|
-
Attribute,
|
|
91
|
-
ComprehendMedicalAsyncJobFilter,
|
|
92
|
-
ComprehendMedicalAsyncJobProperties,
|
|
93
|
-
DescribeEntitiesDetectionV2JobRequest,
|
|
94
|
-
DescribeEntitiesDetectionV2JobResponse,
|
|
95
|
-
DescribeICD10CMInferenceJobRequest,
|
|
96
|
-
DescribeICD10CMInferenceJobResponse,
|
|
97
|
-
DescribePHIDetectionJobRequest,
|
|
98
|
-
DescribePHIDetectionJobResponse,
|
|
99
|
-
DescribeRxNormInferenceJobRequest,
|
|
100
|
-
DescribeRxNormInferenceJobResponse,
|
|
101
|
-
DetectEntitiesRequest,
|
|
102
|
-
DetectEntitiesResponse,
|
|
103
|
-
DetectEntitiesV2Request,
|
|
104
|
-
DetectEntitiesV2Response,
|
|
105
|
-
DetectPHIRequest,
|
|
106
|
-
DetectPHIResponse,
|
|
107
|
-
Entity,
|
|
108
|
-
ICD10CMAttribute,
|
|
109
|
-
ICD10CMConcept,
|
|
110
|
-
ICD10CMEntity,
|
|
111
|
-
ICD10CMTrait,
|
|
112
|
-
InferICD10CMRequest,
|
|
113
|
-
InferICD10CMResponse,
|
|
114
|
-
InferRxNormRequest,
|
|
115
|
-
InferRxNormResponse,
|
|
116
|
-
InputDataConfig,
|
|
117
|
-
InternalServerException,
|
|
118
|
-
InvalidEncodingException,
|
|
119
|
-
InvalidRequestException,
|
|
120
|
-
ListEntitiesDetectionV2JobsRequest,
|
|
121
|
-
ListEntitiesDetectionV2JobsResponse,
|
|
122
|
-
ListICD10CMInferenceJobsRequest,
|
|
123
|
-
ListICD10CMInferenceJobsResponse,
|
|
124
|
-
ListPHIDetectionJobsRequest,
|
|
125
|
-
ListPHIDetectionJobsResponse,
|
|
126
|
-
ListRxNormInferenceJobsRequest,
|
|
127
|
-
ListRxNormInferenceJobsResponse,
|
|
128
|
-
OutputDataConfig,
|
|
129
|
-
ResourceNotFoundException,
|
|
130
|
-
RxNormAttribute,
|
|
131
|
-
RxNormConcept,
|
|
132
|
-
RxNormEntity,
|
|
133
|
-
RxNormTrait,
|
|
134
|
-
ServiceUnavailableException,
|
|
135
|
-
StartEntitiesDetectionV2JobRequest,
|
|
136
|
-
StartEntitiesDetectionV2JobResponse,
|
|
137
|
-
StartICD10CMInferenceJobRequest,
|
|
138
|
-
StartICD10CMInferenceJobResponse,
|
|
139
|
-
StartPHIDetectionJobRequest,
|
|
140
|
-
StartPHIDetectionJobResponse,
|
|
141
|
-
StartRxNormInferenceJobRequest,
|
|
142
|
-
StartRxNormInferenceJobResponse,
|
|
143
|
-
StopEntitiesDetectionV2JobRequest,
|
|
144
|
-
StopEntitiesDetectionV2JobResponse,
|
|
145
|
-
StopICD10CMInferenceJobRequest,
|
|
146
|
-
StopICD10CMInferenceJobResponse,
|
|
147
|
-
StopPHIDetectionJobRequest,
|
|
148
|
-
StopPHIDetectionJobResponse,
|
|
149
|
-
StopRxNormInferenceJobRequest,
|
|
150
|
-
StopRxNormInferenceJobResponse,
|
|
151
|
-
TextSizeLimitExceededException,
|
|
152
|
-
TooManyRequestsException,
|
|
153
|
-
Trait,
|
|
154
|
-
UnmappedAttribute,
|
|
155
|
-
ValidationException,
|
|
156
|
-
} from "../models/models_0";
|
|
157
|
-
|
|
158
|
-
export const serializeAws_json1_1DescribeEntitiesDetectionV2JobCommand = async (
|
|
159
|
-
input: DescribeEntitiesDetectionV2JobCommandInput,
|
|
160
|
-
context: __SerdeContext
|
|
161
|
-
): Promise<__HttpRequest> => {
|
|
162
|
-
const headers: __HeaderBag = {
|
|
163
|
-
"content-type": "application/x-amz-json-1.1",
|
|
164
|
-
"x-amz-target": "ComprehendMedical_20181030.DescribeEntitiesDetectionV2Job",
|
|
165
|
-
};
|
|
166
|
-
let body: any;
|
|
167
|
-
body = JSON.stringify(serializeAws_json1_1DescribeEntitiesDetectionV2JobRequest(input, context));
|
|
168
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
169
|
-
};
|
|
170
|
-
|
|
171
|
-
export const serializeAws_json1_1DescribeICD10CMInferenceJobCommand = async (
|
|
172
|
-
input: DescribeICD10CMInferenceJobCommandInput,
|
|
173
|
-
context: __SerdeContext
|
|
174
|
-
): Promise<__HttpRequest> => {
|
|
175
|
-
const headers: __HeaderBag = {
|
|
176
|
-
"content-type": "application/x-amz-json-1.1",
|
|
177
|
-
"x-amz-target": "ComprehendMedical_20181030.DescribeICD10CMInferenceJob",
|
|
178
|
-
};
|
|
179
|
-
let body: any;
|
|
180
|
-
body = JSON.stringify(serializeAws_json1_1DescribeICD10CMInferenceJobRequest(input, context));
|
|
181
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
182
|
-
};
|
|
183
|
-
|
|
184
|
-
export const serializeAws_json1_1DescribePHIDetectionJobCommand = async (
|
|
185
|
-
input: DescribePHIDetectionJobCommandInput,
|
|
186
|
-
context: __SerdeContext
|
|
187
|
-
): Promise<__HttpRequest> => {
|
|
188
|
-
const headers: __HeaderBag = {
|
|
189
|
-
"content-type": "application/x-amz-json-1.1",
|
|
190
|
-
"x-amz-target": "ComprehendMedical_20181030.DescribePHIDetectionJob",
|
|
191
|
-
};
|
|
192
|
-
let body: any;
|
|
193
|
-
body = JSON.stringify(serializeAws_json1_1DescribePHIDetectionJobRequest(input, context));
|
|
194
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
195
|
-
};
|
|
196
|
-
|
|
197
|
-
export const serializeAws_json1_1DescribeRxNormInferenceJobCommand = async (
|
|
198
|
-
input: DescribeRxNormInferenceJobCommandInput,
|
|
199
|
-
context: __SerdeContext
|
|
200
|
-
): Promise<__HttpRequest> => {
|
|
201
|
-
const headers: __HeaderBag = {
|
|
202
|
-
"content-type": "application/x-amz-json-1.1",
|
|
203
|
-
"x-amz-target": "ComprehendMedical_20181030.DescribeRxNormInferenceJob",
|
|
204
|
-
};
|
|
205
|
-
let body: any;
|
|
206
|
-
body = JSON.stringify(serializeAws_json1_1DescribeRxNormInferenceJobRequest(input, context));
|
|
207
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
208
|
-
};
|
|
209
|
-
|
|
210
|
-
export const serializeAws_json1_1DetectEntitiesCommand = async (
|
|
211
|
-
input: DetectEntitiesCommandInput,
|
|
212
|
-
context: __SerdeContext
|
|
213
|
-
): Promise<__HttpRequest> => {
|
|
214
|
-
const headers: __HeaderBag = {
|
|
215
|
-
"content-type": "application/x-amz-json-1.1",
|
|
216
|
-
"x-amz-target": "ComprehendMedical_20181030.DetectEntities",
|
|
217
|
-
};
|
|
218
|
-
let body: any;
|
|
219
|
-
body = JSON.stringify(serializeAws_json1_1DetectEntitiesRequest(input, context));
|
|
220
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
221
|
-
};
|
|
222
|
-
|
|
223
|
-
export const serializeAws_json1_1DetectEntitiesV2Command = async (
|
|
224
|
-
input: DetectEntitiesV2CommandInput,
|
|
225
|
-
context: __SerdeContext
|
|
226
|
-
): Promise<__HttpRequest> => {
|
|
227
|
-
const headers: __HeaderBag = {
|
|
228
|
-
"content-type": "application/x-amz-json-1.1",
|
|
229
|
-
"x-amz-target": "ComprehendMedical_20181030.DetectEntitiesV2",
|
|
230
|
-
};
|
|
231
|
-
let body: any;
|
|
232
|
-
body = JSON.stringify(serializeAws_json1_1DetectEntitiesV2Request(input, context));
|
|
233
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
234
|
-
};
|
|
235
|
-
|
|
236
|
-
export const serializeAws_json1_1DetectPHICommand = async (
|
|
237
|
-
input: DetectPHICommandInput,
|
|
238
|
-
context: __SerdeContext
|
|
239
|
-
): Promise<__HttpRequest> => {
|
|
240
|
-
const headers: __HeaderBag = {
|
|
241
|
-
"content-type": "application/x-amz-json-1.1",
|
|
242
|
-
"x-amz-target": "ComprehendMedical_20181030.DetectPHI",
|
|
243
|
-
};
|
|
244
|
-
let body: any;
|
|
245
|
-
body = JSON.stringify(serializeAws_json1_1DetectPHIRequest(input, context));
|
|
246
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
247
|
-
};
|
|
248
|
-
|
|
249
|
-
export const serializeAws_json1_1InferICD10CMCommand = async (
|
|
250
|
-
input: InferICD10CMCommandInput,
|
|
251
|
-
context: __SerdeContext
|
|
252
|
-
): Promise<__HttpRequest> => {
|
|
253
|
-
const headers: __HeaderBag = {
|
|
254
|
-
"content-type": "application/x-amz-json-1.1",
|
|
255
|
-
"x-amz-target": "ComprehendMedical_20181030.InferICD10CM",
|
|
256
|
-
};
|
|
257
|
-
let body: any;
|
|
258
|
-
body = JSON.stringify(serializeAws_json1_1InferICD10CMRequest(input, context));
|
|
259
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
260
|
-
};
|
|
261
|
-
|
|
262
|
-
export const serializeAws_json1_1InferRxNormCommand = async (
|
|
263
|
-
input: InferRxNormCommandInput,
|
|
264
|
-
context: __SerdeContext
|
|
265
|
-
): Promise<__HttpRequest> => {
|
|
266
|
-
const headers: __HeaderBag = {
|
|
267
|
-
"content-type": "application/x-amz-json-1.1",
|
|
268
|
-
"x-amz-target": "ComprehendMedical_20181030.InferRxNorm",
|
|
269
|
-
};
|
|
270
|
-
let body: any;
|
|
271
|
-
body = JSON.stringify(serializeAws_json1_1InferRxNormRequest(input, context));
|
|
272
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
273
|
-
};
|
|
274
|
-
|
|
275
|
-
export const serializeAws_json1_1ListEntitiesDetectionV2JobsCommand = async (
|
|
276
|
-
input: ListEntitiesDetectionV2JobsCommandInput,
|
|
277
|
-
context: __SerdeContext
|
|
278
|
-
): Promise<__HttpRequest> => {
|
|
279
|
-
const headers: __HeaderBag = {
|
|
280
|
-
"content-type": "application/x-amz-json-1.1",
|
|
281
|
-
"x-amz-target": "ComprehendMedical_20181030.ListEntitiesDetectionV2Jobs",
|
|
282
|
-
};
|
|
283
|
-
let body: any;
|
|
284
|
-
body = JSON.stringify(serializeAws_json1_1ListEntitiesDetectionV2JobsRequest(input, context));
|
|
285
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
286
|
-
};
|
|
287
|
-
|
|
288
|
-
export const serializeAws_json1_1ListICD10CMInferenceJobsCommand = async (
|
|
289
|
-
input: ListICD10CMInferenceJobsCommandInput,
|
|
290
|
-
context: __SerdeContext
|
|
291
|
-
): Promise<__HttpRequest> => {
|
|
292
|
-
const headers: __HeaderBag = {
|
|
293
|
-
"content-type": "application/x-amz-json-1.1",
|
|
294
|
-
"x-amz-target": "ComprehendMedical_20181030.ListICD10CMInferenceJobs",
|
|
295
|
-
};
|
|
296
|
-
let body: any;
|
|
297
|
-
body = JSON.stringify(serializeAws_json1_1ListICD10CMInferenceJobsRequest(input, context));
|
|
298
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
299
|
-
};
|
|
300
|
-
|
|
301
|
-
export const serializeAws_json1_1ListPHIDetectionJobsCommand = async (
|
|
302
|
-
input: ListPHIDetectionJobsCommandInput,
|
|
303
|
-
context: __SerdeContext
|
|
304
|
-
): Promise<__HttpRequest> => {
|
|
305
|
-
const headers: __HeaderBag = {
|
|
306
|
-
"content-type": "application/x-amz-json-1.1",
|
|
307
|
-
"x-amz-target": "ComprehendMedical_20181030.ListPHIDetectionJobs",
|
|
308
|
-
};
|
|
309
|
-
let body: any;
|
|
310
|
-
body = JSON.stringify(serializeAws_json1_1ListPHIDetectionJobsRequest(input, context));
|
|
311
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
312
|
-
};
|
|
313
|
-
|
|
314
|
-
export const serializeAws_json1_1ListRxNormInferenceJobsCommand = async (
|
|
315
|
-
input: ListRxNormInferenceJobsCommandInput,
|
|
316
|
-
context: __SerdeContext
|
|
317
|
-
): Promise<__HttpRequest> => {
|
|
318
|
-
const headers: __HeaderBag = {
|
|
319
|
-
"content-type": "application/x-amz-json-1.1",
|
|
320
|
-
"x-amz-target": "ComprehendMedical_20181030.ListRxNormInferenceJobs",
|
|
321
|
-
};
|
|
322
|
-
let body: any;
|
|
323
|
-
body = JSON.stringify(serializeAws_json1_1ListRxNormInferenceJobsRequest(input, context));
|
|
324
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
325
|
-
};
|
|
326
|
-
|
|
327
|
-
export const serializeAws_json1_1StartEntitiesDetectionV2JobCommand = async (
|
|
328
|
-
input: StartEntitiesDetectionV2JobCommandInput,
|
|
329
|
-
context: __SerdeContext
|
|
330
|
-
): Promise<__HttpRequest> => {
|
|
331
|
-
const headers: __HeaderBag = {
|
|
332
|
-
"content-type": "application/x-amz-json-1.1",
|
|
333
|
-
"x-amz-target": "ComprehendMedical_20181030.StartEntitiesDetectionV2Job",
|
|
334
|
-
};
|
|
335
|
-
let body: any;
|
|
336
|
-
body = JSON.stringify(serializeAws_json1_1StartEntitiesDetectionV2JobRequest(input, context));
|
|
337
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
338
|
-
};
|
|
339
|
-
|
|
340
|
-
export const serializeAws_json1_1StartICD10CMInferenceJobCommand = async (
|
|
341
|
-
input: StartICD10CMInferenceJobCommandInput,
|
|
342
|
-
context: __SerdeContext
|
|
343
|
-
): Promise<__HttpRequest> => {
|
|
344
|
-
const headers: __HeaderBag = {
|
|
345
|
-
"content-type": "application/x-amz-json-1.1",
|
|
346
|
-
"x-amz-target": "ComprehendMedical_20181030.StartICD10CMInferenceJob",
|
|
347
|
-
};
|
|
348
|
-
let body: any;
|
|
349
|
-
body = JSON.stringify(serializeAws_json1_1StartICD10CMInferenceJobRequest(input, context));
|
|
350
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
351
|
-
};
|
|
352
|
-
|
|
353
|
-
export const serializeAws_json1_1StartPHIDetectionJobCommand = async (
|
|
354
|
-
input: StartPHIDetectionJobCommandInput,
|
|
355
|
-
context: __SerdeContext
|
|
356
|
-
): Promise<__HttpRequest> => {
|
|
357
|
-
const headers: __HeaderBag = {
|
|
358
|
-
"content-type": "application/x-amz-json-1.1",
|
|
359
|
-
"x-amz-target": "ComprehendMedical_20181030.StartPHIDetectionJob",
|
|
360
|
-
};
|
|
361
|
-
let body: any;
|
|
362
|
-
body = JSON.stringify(serializeAws_json1_1StartPHIDetectionJobRequest(input, context));
|
|
363
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
364
|
-
};
|
|
365
|
-
|
|
366
|
-
export const serializeAws_json1_1StartRxNormInferenceJobCommand = async (
|
|
367
|
-
input: StartRxNormInferenceJobCommandInput,
|
|
368
|
-
context: __SerdeContext
|
|
369
|
-
): Promise<__HttpRequest> => {
|
|
370
|
-
const headers: __HeaderBag = {
|
|
371
|
-
"content-type": "application/x-amz-json-1.1",
|
|
372
|
-
"x-amz-target": "ComprehendMedical_20181030.StartRxNormInferenceJob",
|
|
373
|
-
};
|
|
374
|
-
let body: any;
|
|
375
|
-
body = JSON.stringify(serializeAws_json1_1StartRxNormInferenceJobRequest(input, context));
|
|
376
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
377
|
-
};
|
|
378
|
-
|
|
379
|
-
export const serializeAws_json1_1StopEntitiesDetectionV2JobCommand = async (
|
|
380
|
-
input: StopEntitiesDetectionV2JobCommandInput,
|
|
381
|
-
context: __SerdeContext
|
|
382
|
-
): Promise<__HttpRequest> => {
|
|
383
|
-
const headers: __HeaderBag = {
|
|
384
|
-
"content-type": "application/x-amz-json-1.1",
|
|
385
|
-
"x-amz-target": "ComprehendMedical_20181030.StopEntitiesDetectionV2Job",
|
|
386
|
-
};
|
|
387
|
-
let body: any;
|
|
388
|
-
body = JSON.stringify(serializeAws_json1_1StopEntitiesDetectionV2JobRequest(input, context));
|
|
389
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
390
|
-
};
|
|
391
|
-
|
|
392
|
-
export const serializeAws_json1_1StopICD10CMInferenceJobCommand = async (
|
|
393
|
-
input: StopICD10CMInferenceJobCommandInput,
|
|
394
|
-
context: __SerdeContext
|
|
395
|
-
): Promise<__HttpRequest> => {
|
|
396
|
-
const headers: __HeaderBag = {
|
|
397
|
-
"content-type": "application/x-amz-json-1.1",
|
|
398
|
-
"x-amz-target": "ComprehendMedical_20181030.StopICD10CMInferenceJob",
|
|
399
|
-
};
|
|
400
|
-
let body: any;
|
|
401
|
-
body = JSON.stringify(serializeAws_json1_1StopICD10CMInferenceJobRequest(input, context));
|
|
402
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
403
|
-
};
|
|
404
|
-
|
|
405
|
-
export const serializeAws_json1_1StopPHIDetectionJobCommand = async (
|
|
406
|
-
input: StopPHIDetectionJobCommandInput,
|
|
407
|
-
context: __SerdeContext
|
|
408
|
-
): Promise<__HttpRequest> => {
|
|
409
|
-
const headers: __HeaderBag = {
|
|
410
|
-
"content-type": "application/x-amz-json-1.1",
|
|
411
|
-
"x-amz-target": "ComprehendMedical_20181030.StopPHIDetectionJob",
|
|
412
|
-
};
|
|
413
|
-
let body: any;
|
|
414
|
-
body = JSON.stringify(serializeAws_json1_1StopPHIDetectionJobRequest(input, context));
|
|
415
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
416
|
-
};
|
|
417
|
-
|
|
418
|
-
export const serializeAws_json1_1StopRxNormInferenceJobCommand = async (
|
|
419
|
-
input: StopRxNormInferenceJobCommandInput,
|
|
420
|
-
context: __SerdeContext
|
|
421
|
-
): Promise<__HttpRequest> => {
|
|
422
|
-
const headers: __HeaderBag = {
|
|
423
|
-
"content-type": "application/x-amz-json-1.1",
|
|
424
|
-
"x-amz-target": "ComprehendMedical_20181030.StopRxNormInferenceJob",
|
|
425
|
-
};
|
|
426
|
-
let body: any;
|
|
427
|
-
body = JSON.stringify(serializeAws_json1_1StopRxNormInferenceJobRequest(input, context));
|
|
428
|
-
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
429
|
-
};
|
|
430
|
-
|
|
431
|
-
export const deserializeAws_json1_1DescribeEntitiesDetectionV2JobCommand = async (
|
|
432
|
-
output: __HttpResponse,
|
|
433
|
-
context: __SerdeContext
|
|
434
|
-
): Promise<DescribeEntitiesDetectionV2JobCommandOutput> => {
|
|
435
|
-
if (output.statusCode >= 300) {
|
|
436
|
-
return deserializeAws_json1_1DescribeEntitiesDetectionV2JobCommandError(output, context);
|
|
437
|
-
}
|
|
438
|
-
const data: any = await parseBody(output.body, context);
|
|
439
|
-
let contents: any = {};
|
|
440
|
-
contents = deserializeAws_json1_1DescribeEntitiesDetectionV2JobResponse(data, context);
|
|
441
|
-
const response: DescribeEntitiesDetectionV2JobCommandOutput = {
|
|
442
|
-
$metadata: deserializeMetadata(output),
|
|
443
|
-
...contents,
|
|
444
|
-
};
|
|
445
|
-
return Promise.resolve(response);
|
|
446
|
-
};
|
|
447
|
-
|
|
448
|
-
const deserializeAws_json1_1DescribeEntitiesDetectionV2JobCommandError = async (
|
|
449
|
-
output: __HttpResponse,
|
|
450
|
-
context: __SerdeContext
|
|
451
|
-
): Promise<DescribeEntitiesDetectionV2JobCommandOutput> => {
|
|
452
|
-
const parsedOutput: any = {
|
|
453
|
-
...output,
|
|
454
|
-
body: await parseBody(output.body, context),
|
|
455
|
-
};
|
|
456
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
457
|
-
let errorCode = "UnknownError";
|
|
458
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
459
|
-
switch (errorCode) {
|
|
460
|
-
case "InternalServerException":
|
|
461
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
462
|
-
response = {
|
|
463
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
464
|
-
name: errorCode,
|
|
465
|
-
$metadata: deserializeMetadata(output),
|
|
466
|
-
};
|
|
467
|
-
break;
|
|
468
|
-
case "InvalidRequestException":
|
|
469
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
470
|
-
response = {
|
|
471
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
472
|
-
name: errorCode,
|
|
473
|
-
$metadata: deserializeMetadata(output),
|
|
474
|
-
};
|
|
475
|
-
break;
|
|
476
|
-
case "ResourceNotFoundException":
|
|
477
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
478
|
-
response = {
|
|
479
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
480
|
-
name: errorCode,
|
|
481
|
-
$metadata: deserializeMetadata(output),
|
|
482
|
-
};
|
|
483
|
-
break;
|
|
484
|
-
case "TooManyRequestsException":
|
|
485
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
486
|
-
response = {
|
|
487
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
488
|
-
name: errorCode,
|
|
489
|
-
$metadata: deserializeMetadata(output),
|
|
490
|
-
};
|
|
491
|
-
break;
|
|
492
|
-
default:
|
|
493
|
-
const parsedBody = parsedOutput.body;
|
|
494
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
495
|
-
response = {
|
|
496
|
-
...parsedBody,
|
|
497
|
-
name: `${errorCode}`,
|
|
498
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
499
|
-
$fault: "client",
|
|
500
|
-
$metadata: deserializeMetadata(output),
|
|
501
|
-
} as any;
|
|
502
|
-
}
|
|
503
|
-
const message = response.message || response.Message || errorCode;
|
|
504
|
-
response.message = message;
|
|
505
|
-
delete response.Message;
|
|
506
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
507
|
-
};
|
|
508
|
-
|
|
509
|
-
export const deserializeAws_json1_1DescribeICD10CMInferenceJobCommand = async (
|
|
510
|
-
output: __HttpResponse,
|
|
511
|
-
context: __SerdeContext
|
|
512
|
-
): Promise<DescribeICD10CMInferenceJobCommandOutput> => {
|
|
513
|
-
if (output.statusCode >= 300) {
|
|
514
|
-
return deserializeAws_json1_1DescribeICD10CMInferenceJobCommandError(output, context);
|
|
515
|
-
}
|
|
516
|
-
const data: any = await parseBody(output.body, context);
|
|
517
|
-
let contents: any = {};
|
|
518
|
-
contents = deserializeAws_json1_1DescribeICD10CMInferenceJobResponse(data, context);
|
|
519
|
-
const response: DescribeICD10CMInferenceJobCommandOutput = {
|
|
520
|
-
$metadata: deserializeMetadata(output),
|
|
521
|
-
...contents,
|
|
522
|
-
};
|
|
523
|
-
return Promise.resolve(response);
|
|
524
|
-
};
|
|
525
|
-
|
|
526
|
-
const deserializeAws_json1_1DescribeICD10CMInferenceJobCommandError = async (
|
|
527
|
-
output: __HttpResponse,
|
|
528
|
-
context: __SerdeContext
|
|
529
|
-
): Promise<DescribeICD10CMInferenceJobCommandOutput> => {
|
|
530
|
-
const parsedOutput: any = {
|
|
531
|
-
...output,
|
|
532
|
-
body: await parseBody(output.body, context),
|
|
533
|
-
};
|
|
534
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
535
|
-
let errorCode = "UnknownError";
|
|
536
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
537
|
-
switch (errorCode) {
|
|
538
|
-
case "InternalServerException":
|
|
539
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
540
|
-
response = {
|
|
541
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
542
|
-
name: errorCode,
|
|
543
|
-
$metadata: deserializeMetadata(output),
|
|
544
|
-
};
|
|
545
|
-
break;
|
|
546
|
-
case "InvalidRequestException":
|
|
547
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
548
|
-
response = {
|
|
549
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
550
|
-
name: errorCode,
|
|
551
|
-
$metadata: deserializeMetadata(output),
|
|
552
|
-
};
|
|
553
|
-
break;
|
|
554
|
-
case "ResourceNotFoundException":
|
|
555
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
556
|
-
response = {
|
|
557
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
558
|
-
name: errorCode,
|
|
559
|
-
$metadata: deserializeMetadata(output),
|
|
560
|
-
};
|
|
561
|
-
break;
|
|
562
|
-
case "TooManyRequestsException":
|
|
563
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
564
|
-
response = {
|
|
565
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
566
|
-
name: errorCode,
|
|
567
|
-
$metadata: deserializeMetadata(output),
|
|
568
|
-
};
|
|
569
|
-
break;
|
|
570
|
-
default:
|
|
571
|
-
const parsedBody = parsedOutput.body;
|
|
572
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
573
|
-
response = {
|
|
574
|
-
...parsedBody,
|
|
575
|
-
name: `${errorCode}`,
|
|
576
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
577
|
-
$fault: "client",
|
|
578
|
-
$metadata: deserializeMetadata(output),
|
|
579
|
-
} as any;
|
|
580
|
-
}
|
|
581
|
-
const message = response.message || response.Message || errorCode;
|
|
582
|
-
response.message = message;
|
|
583
|
-
delete response.Message;
|
|
584
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
585
|
-
};
|
|
586
|
-
|
|
587
|
-
export const deserializeAws_json1_1DescribePHIDetectionJobCommand = async (
|
|
588
|
-
output: __HttpResponse,
|
|
589
|
-
context: __SerdeContext
|
|
590
|
-
): Promise<DescribePHIDetectionJobCommandOutput> => {
|
|
591
|
-
if (output.statusCode >= 300) {
|
|
592
|
-
return deserializeAws_json1_1DescribePHIDetectionJobCommandError(output, context);
|
|
593
|
-
}
|
|
594
|
-
const data: any = await parseBody(output.body, context);
|
|
595
|
-
let contents: any = {};
|
|
596
|
-
contents = deserializeAws_json1_1DescribePHIDetectionJobResponse(data, context);
|
|
597
|
-
const response: DescribePHIDetectionJobCommandOutput = {
|
|
598
|
-
$metadata: deserializeMetadata(output),
|
|
599
|
-
...contents,
|
|
600
|
-
};
|
|
601
|
-
return Promise.resolve(response);
|
|
602
|
-
};
|
|
603
|
-
|
|
604
|
-
const deserializeAws_json1_1DescribePHIDetectionJobCommandError = async (
|
|
605
|
-
output: __HttpResponse,
|
|
606
|
-
context: __SerdeContext
|
|
607
|
-
): Promise<DescribePHIDetectionJobCommandOutput> => {
|
|
608
|
-
const parsedOutput: any = {
|
|
609
|
-
...output,
|
|
610
|
-
body: await parseBody(output.body, context),
|
|
611
|
-
};
|
|
612
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
613
|
-
let errorCode = "UnknownError";
|
|
614
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
615
|
-
switch (errorCode) {
|
|
616
|
-
case "InternalServerException":
|
|
617
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
618
|
-
response = {
|
|
619
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
620
|
-
name: errorCode,
|
|
621
|
-
$metadata: deserializeMetadata(output),
|
|
622
|
-
};
|
|
623
|
-
break;
|
|
624
|
-
case "InvalidRequestException":
|
|
625
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
626
|
-
response = {
|
|
627
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
628
|
-
name: errorCode,
|
|
629
|
-
$metadata: deserializeMetadata(output),
|
|
630
|
-
};
|
|
631
|
-
break;
|
|
632
|
-
case "ResourceNotFoundException":
|
|
633
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
634
|
-
response = {
|
|
635
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
636
|
-
name: errorCode,
|
|
637
|
-
$metadata: deserializeMetadata(output),
|
|
638
|
-
};
|
|
639
|
-
break;
|
|
640
|
-
case "TooManyRequestsException":
|
|
641
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
642
|
-
response = {
|
|
643
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
644
|
-
name: errorCode,
|
|
645
|
-
$metadata: deserializeMetadata(output),
|
|
646
|
-
};
|
|
647
|
-
break;
|
|
648
|
-
default:
|
|
649
|
-
const parsedBody = parsedOutput.body;
|
|
650
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
651
|
-
response = {
|
|
652
|
-
...parsedBody,
|
|
653
|
-
name: `${errorCode}`,
|
|
654
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
655
|
-
$fault: "client",
|
|
656
|
-
$metadata: deserializeMetadata(output),
|
|
657
|
-
} as any;
|
|
658
|
-
}
|
|
659
|
-
const message = response.message || response.Message || errorCode;
|
|
660
|
-
response.message = message;
|
|
661
|
-
delete response.Message;
|
|
662
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
663
|
-
};
|
|
664
|
-
|
|
665
|
-
export const deserializeAws_json1_1DescribeRxNormInferenceJobCommand = async (
|
|
666
|
-
output: __HttpResponse,
|
|
667
|
-
context: __SerdeContext
|
|
668
|
-
): Promise<DescribeRxNormInferenceJobCommandOutput> => {
|
|
669
|
-
if (output.statusCode >= 300) {
|
|
670
|
-
return deserializeAws_json1_1DescribeRxNormInferenceJobCommandError(output, context);
|
|
671
|
-
}
|
|
672
|
-
const data: any = await parseBody(output.body, context);
|
|
673
|
-
let contents: any = {};
|
|
674
|
-
contents = deserializeAws_json1_1DescribeRxNormInferenceJobResponse(data, context);
|
|
675
|
-
const response: DescribeRxNormInferenceJobCommandOutput = {
|
|
676
|
-
$metadata: deserializeMetadata(output),
|
|
677
|
-
...contents,
|
|
678
|
-
};
|
|
679
|
-
return Promise.resolve(response);
|
|
680
|
-
};
|
|
681
|
-
|
|
682
|
-
const deserializeAws_json1_1DescribeRxNormInferenceJobCommandError = async (
|
|
683
|
-
output: __HttpResponse,
|
|
684
|
-
context: __SerdeContext
|
|
685
|
-
): Promise<DescribeRxNormInferenceJobCommandOutput> => {
|
|
686
|
-
const parsedOutput: any = {
|
|
687
|
-
...output,
|
|
688
|
-
body: await parseBody(output.body, context),
|
|
689
|
-
};
|
|
690
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
691
|
-
let errorCode = "UnknownError";
|
|
692
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
693
|
-
switch (errorCode) {
|
|
694
|
-
case "InternalServerException":
|
|
695
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
696
|
-
response = {
|
|
697
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
698
|
-
name: errorCode,
|
|
699
|
-
$metadata: deserializeMetadata(output),
|
|
700
|
-
};
|
|
701
|
-
break;
|
|
702
|
-
case "InvalidRequestException":
|
|
703
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
704
|
-
response = {
|
|
705
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
706
|
-
name: errorCode,
|
|
707
|
-
$metadata: deserializeMetadata(output),
|
|
708
|
-
};
|
|
709
|
-
break;
|
|
710
|
-
case "ResourceNotFoundException":
|
|
711
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
712
|
-
response = {
|
|
713
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
714
|
-
name: errorCode,
|
|
715
|
-
$metadata: deserializeMetadata(output),
|
|
716
|
-
};
|
|
717
|
-
break;
|
|
718
|
-
case "TooManyRequestsException":
|
|
719
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
720
|
-
response = {
|
|
721
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
722
|
-
name: errorCode,
|
|
723
|
-
$metadata: deserializeMetadata(output),
|
|
724
|
-
};
|
|
725
|
-
break;
|
|
726
|
-
default:
|
|
727
|
-
const parsedBody = parsedOutput.body;
|
|
728
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
729
|
-
response = {
|
|
730
|
-
...parsedBody,
|
|
731
|
-
name: `${errorCode}`,
|
|
732
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
733
|
-
$fault: "client",
|
|
734
|
-
$metadata: deserializeMetadata(output),
|
|
735
|
-
} as any;
|
|
736
|
-
}
|
|
737
|
-
const message = response.message || response.Message || errorCode;
|
|
738
|
-
response.message = message;
|
|
739
|
-
delete response.Message;
|
|
740
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
741
|
-
};
|
|
742
|
-
|
|
743
|
-
export const deserializeAws_json1_1DetectEntitiesCommand = async (
|
|
744
|
-
output: __HttpResponse,
|
|
745
|
-
context: __SerdeContext
|
|
746
|
-
): Promise<DetectEntitiesCommandOutput> => {
|
|
747
|
-
if (output.statusCode >= 300) {
|
|
748
|
-
return deserializeAws_json1_1DetectEntitiesCommandError(output, context);
|
|
749
|
-
}
|
|
750
|
-
const data: any = await parseBody(output.body, context);
|
|
751
|
-
let contents: any = {};
|
|
752
|
-
contents = deserializeAws_json1_1DetectEntitiesResponse(data, context);
|
|
753
|
-
const response: DetectEntitiesCommandOutput = {
|
|
754
|
-
$metadata: deserializeMetadata(output),
|
|
755
|
-
...contents,
|
|
756
|
-
};
|
|
757
|
-
return Promise.resolve(response);
|
|
758
|
-
};
|
|
759
|
-
|
|
760
|
-
const deserializeAws_json1_1DetectEntitiesCommandError = async (
|
|
761
|
-
output: __HttpResponse,
|
|
762
|
-
context: __SerdeContext
|
|
763
|
-
): Promise<DetectEntitiesCommandOutput> => {
|
|
764
|
-
const parsedOutput: any = {
|
|
765
|
-
...output,
|
|
766
|
-
body: await parseBody(output.body, context),
|
|
767
|
-
};
|
|
768
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
769
|
-
let errorCode = "UnknownError";
|
|
770
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
771
|
-
switch (errorCode) {
|
|
772
|
-
case "InternalServerException":
|
|
773
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
774
|
-
response = {
|
|
775
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
776
|
-
name: errorCode,
|
|
777
|
-
$metadata: deserializeMetadata(output),
|
|
778
|
-
};
|
|
779
|
-
break;
|
|
780
|
-
case "InvalidEncodingException":
|
|
781
|
-
case "com.amazonaws.comprehendmedical#InvalidEncodingException":
|
|
782
|
-
response = {
|
|
783
|
-
...(await deserializeAws_json1_1InvalidEncodingExceptionResponse(parsedOutput, context)),
|
|
784
|
-
name: errorCode,
|
|
785
|
-
$metadata: deserializeMetadata(output),
|
|
786
|
-
};
|
|
787
|
-
break;
|
|
788
|
-
case "InvalidRequestException":
|
|
789
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
790
|
-
response = {
|
|
791
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
792
|
-
name: errorCode,
|
|
793
|
-
$metadata: deserializeMetadata(output),
|
|
794
|
-
};
|
|
795
|
-
break;
|
|
796
|
-
case "ServiceUnavailableException":
|
|
797
|
-
case "com.amazonaws.comprehendmedical#ServiceUnavailableException":
|
|
798
|
-
response = {
|
|
799
|
-
...(await deserializeAws_json1_1ServiceUnavailableExceptionResponse(parsedOutput, context)),
|
|
800
|
-
name: errorCode,
|
|
801
|
-
$metadata: deserializeMetadata(output),
|
|
802
|
-
};
|
|
803
|
-
break;
|
|
804
|
-
case "TextSizeLimitExceededException":
|
|
805
|
-
case "com.amazonaws.comprehendmedical#TextSizeLimitExceededException":
|
|
806
|
-
response = {
|
|
807
|
-
...(await deserializeAws_json1_1TextSizeLimitExceededExceptionResponse(parsedOutput, context)),
|
|
808
|
-
name: errorCode,
|
|
809
|
-
$metadata: deserializeMetadata(output),
|
|
810
|
-
};
|
|
811
|
-
break;
|
|
812
|
-
case "TooManyRequestsException":
|
|
813
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
814
|
-
response = {
|
|
815
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
816
|
-
name: errorCode,
|
|
817
|
-
$metadata: deserializeMetadata(output),
|
|
818
|
-
};
|
|
819
|
-
break;
|
|
820
|
-
default:
|
|
821
|
-
const parsedBody = parsedOutput.body;
|
|
822
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
823
|
-
response = {
|
|
824
|
-
...parsedBody,
|
|
825
|
-
name: `${errorCode}`,
|
|
826
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
827
|
-
$fault: "client",
|
|
828
|
-
$metadata: deserializeMetadata(output),
|
|
829
|
-
} as any;
|
|
830
|
-
}
|
|
831
|
-
const message = response.message || response.Message || errorCode;
|
|
832
|
-
response.message = message;
|
|
833
|
-
delete response.Message;
|
|
834
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
835
|
-
};
|
|
836
|
-
|
|
837
|
-
export const deserializeAws_json1_1DetectEntitiesV2Command = async (
|
|
838
|
-
output: __HttpResponse,
|
|
839
|
-
context: __SerdeContext
|
|
840
|
-
): Promise<DetectEntitiesV2CommandOutput> => {
|
|
841
|
-
if (output.statusCode >= 300) {
|
|
842
|
-
return deserializeAws_json1_1DetectEntitiesV2CommandError(output, context);
|
|
843
|
-
}
|
|
844
|
-
const data: any = await parseBody(output.body, context);
|
|
845
|
-
let contents: any = {};
|
|
846
|
-
contents = deserializeAws_json1_1DetectEntitiesV2Response(data, context);
|
|
847
|
-
const response: DetectEntitiesV2CommandOutput = {
|
|
848
|
-
$metadata: deserializeMetadata(output),
|
|
849
|
-
...contents,
|
|
850
|
-
};
|
|
851
|
-
return Promise.resolve(response);
|
|
852
|
-
};
|
|
853
|
-
|
|
854
|
-
const deserializeAws_json1_1DetectEntitiesV2CommandError = async (
|
|
855
|
-
output: __HttpResponse,
|
|
856
|
-
context: __SerdeContext
|
|
857
|
-
): Promise<DetectEntitiesV2CommandOutput> => {
|
|
858
|
-
const parsedOutput: any = {
|
|
859
|
-
...output,
|
|
860
|
-
body: await parseBody(output.body, context),
|
|
861
|
-
};
|
|
862
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
863
|
-
let errorCode = "UnknownError";
|
|
864
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
865
|
-
switch (errorCode) {
|
|
866
|
-
case "InternalServerException":
|
|
867
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
868
|
-
response = {
|
|
869
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
870
|
-
name: errorCode,
|
|
871
|
-
$metadata: deserializeMetadata(output),
|
|
872
|
-
};
|
|
873
|
-
break;
|
|
874
|
-
case "InvalidEncodingException":
|
|
875
|
-
case "com.amazonaws.comprehendmedical#InvalidEncodingException":
|
|
876
|
-
response = {
|
|
877
|
-
...(await deserializeAws_json1_1InvalidEncodingExceptionResponse(parsedOutput, context)),
|
|
878
|
-
name: errorCode,
|
|
879
|
-
$metadata: deserializeMetadata(output),
|
|
880
|
-
};
|
|
881
|
-
break;
|
|
882
|
-
case "InvalidRequestException":
|
|
883
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
884
|
-
response = {
|
|
885
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
886
|
-
name: errorCode,
|
|
887
|
-
$metadata: deserializeMetadata(output),
|
|
888
|
-
};
|
|
889
|
-
break;
|
|
890
|
-
case "ServiceUnavailableException":
|
|
891
|
-
case "com.amazonaws.comprehendmedical#ServiceUnavailableException":
|
|
892
|
-
response = {
|
|
893
|
-
...(await deserializeAws_json1_1ServiceUnavailableExceptionResponse(parsedOutput, context)),
|
|
894
|
-
name: errorCode,
|
|
895
|
-
$metadata: deserializeMetadata(output),
|
|
896
|
-
};
|
|
897
|
-
break;
|
|
898
|
-
case "TextSizeLimitExceededException":
|
|
899
|
-
case "com.amazonaws.comprehendmedical#TextSizeLimitExceededException":
|
|
900
|
-
response = {
|
|
901
|
-
...(await deserializeAws_json1_1TextSizeLimitExceededExceptionResponse(parsedOutput, context)),
|
|
902
|
-
name: errorCode,
|
|
903
|
-
$metadata: deserializeMetadata(output),
|
|
904
|
-
};
|
|
905
|
-
break;
|
|
906
|
-
case "TooManyRequestsException":
|
|
907
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
908
|
-
response = {
|
|
909
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
910
|
-
name: errorCode,
|
|
911
|
-
$metadata: deserializeMetadata(output),
|
|
912
|
-
};
|
|
913
|
-
break;
|
|
914
|
-
default:
|
|
915
|
-
const parsedBody = parsedOutput.body;
|
|
916
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
917
|
-
response = {
|
|
918
|
-
...parsedBody,
|
|
919
|
-
name: `${errorCode}`,
|
|
920
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
921
|
-
$fault: "client",
|
|
922
|
-
$metadata: deserializeMetadata(output),
|
|
923
|
-
} as any;
|
|
924
|
-
}
|
|
925
|
-
const message = response.message || response.Message || errorCode;
|
|
926
|
-
response.message = message;
|
|
927
|
-
delete response.Message;
|
|
928
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
929
|
-
};
|
|
930
|
-
|
|
931
|
-
export const deserializeAws_json1_1DetectPHICommand = async (
|
|
932
|
-
output: __HttpResponse,
|
|
933
|
-
context: __SerdeContext
|
|
934
|
-
): Promise<DetectPHICommandOutput> => {
|
|
935
|
-
if (output.statusCode >= 300) {
|
|
936
|
-
return deserializeAws_json1_1DetectPHICommandError(output, context);
|
|
937
|
-
}
|
|
938
|
-
const data: any = await parseBody(output.body, context);
|
|
939
|
-
let contents: any = {};
|
|
940
|
-
contents = deserializeAws_json1_1DetectPHIResponse(data, context);
|
|
941
|
-
const response: DetectPHICommandOutput = {
|
|
942
|
-
$metadata: deserializeMetadata(output),
|
|
943
|
-
...contents,
|
|
944
|
-
};
|
|
945
|
-
return Promise.resolve(response);
|
|
946
|
-
};
|
|
947
|
-
|
|
948
|
-
const deserializeAws_json1_1DetectPHICommandError = async (
|
|
949
|
-
output: __HttpResponse,
|
|
950
|
-
context: __SerdeContext
|
|
951
|
-
): Promise<DetectPHICommandOutput> => {
|
|
952
|
-
const parsedOutput: any = {
|
|
953
|
-
...output,
|
|
954
|
-
body: await parseBody(output.body, context),
|
|
955
|
-
};
|
|
956
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
957
|
-
let errorCode = "UnknownError";
|
|
958
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
959
|
-
switch (errorCode) {
|
|
960
|
-
case "InternalServerException":
|
|
961
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
962
|
-
response = {
|
|
963
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
964
|
-
name: errorCode,
|
|
965
|
-
$metadata: deserializeMetadata(output),
|
|
966
|
-
};
|
|
967
|
-
break;
|
|
968
|
-
case "InvalidEncodingException":
|
|
969
|
-
case "com.amazonaws.comprehendmedical#InvalidEncodingException":
|
|
970
|
-
response = {
|
|
971
|
-
...(await deserializeAws_json1_1InvalidEncodingExceptionResponse(parsedOutput, context)),
|
|
972
|
-
name: errorCode,
|
|
973
|
-
$metadata: deserializeMetadata(output),
|
|
974
|
-
};
|
|
975
|
-
break;
|
|
976
|
-
case "InvalidRequestException":
|
|
977
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
978
|
-
response = {
|
|
979
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
980
|
-
name: errorCode,
|
|
981
|
-
$metadata: deserializeMetadata(output),
|
|
982
|
-
};
|
|
983
|
-
break;
|
|
984
|
-
case "ServiceUnavailableException":
|
|
985
|
-
case "com.amazonaws.comprehendmedical#ServiceUnavailableException":
|
|
986
|
-
response = {
|
|
987
|
-
...(await deserializeAws_json1_1ServiceUnavailableExceptionResponse(parsedOutput, context)),
|
|
988
|
-
name: errorCode,
|
|
989
|
-
$metadata: deserializeMetadata(output),
|
|
990
|
-
};
|
|
991
|
-
break;
|
|
992
|
-
case "TextSizeLimitExceededException":
|
|
993
|
-
case "com.amazonaws.comprehendmedical#TextSizeLimitExceededException":
|
|
994
|
-
response = {
|
|
995
|
-
...(await deserializeAws_json1_1TextSizeLimitExceededExceptionResponse(parsedOutput, context)),
|
|
996
|
-
name: errorCode,
|
|
997
|
-
$metadata: deserializeMetadata(output),
|
|
998
|
-
};
|
|
999
|
-
break;
|
|
1000
|
-
case "TooManyRequestsException":
|
|
1001
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1002
|
-
response = {
|
|
1003
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1004
|
-
name: errorCode,
|
|
1005
|
-
$metadata: deserializeMetadata(output),
|
|
1006
|
-
};
|
|
1007
|
-
break;
|
|
1008
|
-
default:
|
|
1009
|
-
const parsedBody = parsedOutput.body;
|
|
1010
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1011
|
-
response = {
|
|
1012
|
-
...parsedBody,
|
|
1013
|
-
name: `${errorCode}`,
|
|
1014
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1015
|
-
$fault: "client",
|
|
1016
|
-
$metadata: deserializeMetadata(output),
|
|
1017
|
-
} as any;
|
|
1018
|
-
}
|
|
1019
|
-
const message = response.message || response.Message || errorCode;
|
|
1020
|
-
response.message = message;
|
|
1021
|
-
delete response.Message;
|
|
1022
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1023
|
-
};
|
|
1024
|
-
|
|
1025
|
-
export const deserializeAws_json1_1InferICD10CMCommand = async (
|
|
1026
|
-
output: __HttpResponse,
|
|
1027
|
-
context: __SerdeContext
|
|
1028
|
-
): Promise<InferICD10CMCommandOutput> => {
|
|
1029
|
-
if (output.statusCode >= 300) {
|
|
1030
|
-
return deserializeAws_json1_1InferICD10CMCommandError(output, context);
|
|
1031
|
-
}
|
|
1032
|
-
const data: any = await parseBody(output.body, context);
|
|
1033
|
-
let contents: any = {};
|
|
1034
|
-
contents = deserializeAws_json1_1InferICD10CMResponse(data, context);
|
|
1035
|
-
const response: InferICD10CMCommandOutput = {
|
|
1036
|
-
$metadata: deserializeMetadata(output),
|
|
1037
|
-
...contents,
|
|
1038
|
-
};
|
|
1039
|
-
return Promise.resolve(response);
|
|
1040
|
-
};
|
|
1041
|
-
|
|
1042
|
-
const deserializeAws_json1_1InferICD10CMCommandError = async (
|
|
1043
|
-
output: __HttpResponse,
|
|
1044
|
-
context: __SerdeContext
|
|
1045
|
-
): Promise<InferICD10CMCommandOutput> => {
|
|
1046
|
-
const parsedOutput: any = {
|
|
1047
|
-
...output,
|
|
1048
|
-
body: await parseBody(output.body, context),
|
|
1049
|
-
};
|
|
1050
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1051
|
-
let errorCode = "UnknownError";
|
|
1052
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1053
|
-
switch (errorCode) {
|
|
1054
|
-
case "InternalServerException":
|
|
1055
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1056
|
-
response = {
|
|
1057
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1058
|
-
name: errorCode,
|
|
1059
|
-
$metadata: deserializeMetadata(output),
|
|
1060
|
-
};
|
|
1061
|
-
break;
|
|
1062
|
-
case "InvalidEncodingException":
|
|
1063
|
-
case "com.amazonaws.comprehendmedical#InvalidEncodingException":
|
|
1064
|
-
response = {
|
|
1065
|
-
...(await deserializeAws_json1_1InvalidEncodingExceptionResponse(parsedOutput, context)),
|
|
1066
|
-
name: errorCode,
|
|
1067
|
-
$metadata: deserializeMetadata(output),
|
|
1068
|
-
};
|
|
1069
|
-
break;
|
|
1070
|
-
case "InvalidRequestException":
|
|
1071
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1072
|
-
response = {
|
|
1073
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1074
|
-
name: errorCode,
|
|
1075
|
-
$metadata: deserializeMetadata(output),
|
|
1076
|
-
};
|
|
1077
|
-
break;
|
|
1078
|
-
case "ServiceUnavailableException":
|
|
1079
|
-
case "com.amazonaws.comprehendmedical#ServiceUnavailableException":
|
|
1080
|
-
response = {
|
|
1081
|
-
...(await deserializeAws_json1_1ServiceUnavailableExceptionResponse(parsedOutput, context)),
|
|
1082
|
-
name: errorCode,
|
|
1083
|
-
$metadata: deserializeMetadata(output),
|
|
1084
|
-
};
|
|
1085
|
-
break;
|
|
1086
|
-
case "TextSizeLimitExceededException":
|
|
1087
|
-
case "com.amazonaws.comprehendmedical#TextSizeLimitExceededException":
|
|
1088
|
-
response = {
|
|
1089
|
-
...(await deserializeAws_json1_1TextSizeLimitExceededExceptionResponse(parsedOutput, context)),
|
|
1090
|
-
name: errorCode,
|
|
1091
|
-
$metadata: deserializeMetadata(output),
|
|
1092
|
-
};
|
|
1093
|
-
break;
|
|
1094
|
-
case "TooManyRequestsException":
|
|
1095
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1096
|
-
response = {
|
|
1097
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1098
|
-
name: errorCode,
|
|
1099
|
-
$metadata: deserializeMetadata(output),
|
|
1100
|
-
};
|
|
1101
|
-
break;
|
|
1102
|
-
default:
|
|
1103
|
-
const parsedBody = parsedOutput.body;
|
|
1104
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1105
|
-
response = {
|
|
1106
|
-
...parsedBody,
|
|
1107
|
-
name: `${errorCode}`,
|
|
1108
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1109
|
-
$fault: "client",
|
|
1110
|
-
$metadata: deserializeMetadata(output),
|
|
1111
|
-
} as any;
|
|
1112
|
-
}
|
|
1113
|
-
const message = response.message || response.Message || errorCode;
|
|
1114
|
-
response.message = message;
|
|
1115
|
-
delete response.Message;
|
|
1116
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1117
|
-
};
|
|
1118
|
-
|
|
1119
|
-
export const deserializeAws_json1_1InferRxNormCommand = async (
|
|
1120
|
-
output: __HttpResponse,
|
|
1121
|
-
context: __SerdeContext
|
|
1122
|
-
): Promise<InferRxNormCommandOutput> => {
|
|
1123
|
-
if (output.statusCode >= 300) {
|
|
1124
|
-
return deserializeAws_json1_1InferRxNormCommandError(output, context);
|
|
1125
|
-
}
|
|
1126
|
-
const data: any = await parseBody(output.body, context);
|
|
1127
|
-
let contents: any = {};
|
|
1128
|
-
contents = deserializeAws_json1_1InferRxNormResponse(data, context);
|
|
1129
|
-
const response: InferRxNormCommandOutput = {
|
|
1130
|
-
$metadata: deserializeMetadata(output),
|
|
1131
|
-
...contents,
|
|
1132
|
-
};
|
|
1133
|
-
return Promise.resolve(response);
|
|
1134
|
-
};
|
|
1135
|
-
|
|
1136
|
-
const deserializeAws_json1_1InferRxNormCommandError = async (
|
|
1137
|
-
output: __HttpResponse,
|
|
1138
|
-
context: __SerdeContext
|
|
1139
|
-
): Promise<InferRxNormCommandOutput> => {
|
|
1140
|
-
const parsedOutput: any = {
|
|
1141
|
-
...output,
|
|
1142
|
-
body: await parseBody(output.body, context),
|
|
1143
|
-
};
|
|
1144
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1145
|
-
let errorCode = "UnknownError";
|
|
1146
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1147
|
-
switch (errorCode) {
|
|
1148
|
-
case "InternalServerException":
|
|
1149
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1150
|
-
response = {
|
|
1151
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1152
|
-
name: errorCode,
|
|
1153
|
-
$metadata: deserializeMetadata(output),
|
|
1154
|
-
};
|
|
1155
|
-
break;
|
|
1156
|
-
case "InvalidEncodingException":
|
|
1157
|
-
case "com.amazonaws.comprehendmedical#InvalidEncodingException":
|
|
1158
|
-
response = {
|
|
1159
|
-
...(await deserializeAws_json1_1InvalidEncodingExceptionResponse(parsedOutput, context)),
|
|
1160
|
-
name: errorCode,
|
|
1161
|
-
$metadata: deserializeMetadata(output),
|
|
1162
|
-
};
|
|
1163
|
-
break;
|
|
1164
|
-
case "InvalidRequestException":
|
|
1165
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1166
|
-
response = {
|
|
1167
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1168
|
-
name: errorCode,
|
|
1169
|
-
$metadata: deserializeMetadata(output),
|
|
1170
|
-
};
|
|
1171
|
-
break;
|
|
1172
|
-
case "ServiceUnavailableException":
|
|
1173
|
-
case "com.amazonaws.comprehendmedical#ServiceUnavailableException":
|
|
1174
|
-
response = {
|
|
1175
|
-
...(await deserializeAws_json1_1ServiceUnavailableExceptionResponse(parsedOutput, context)),
|
|
1176
|
-
name: errorCode,
|
|
1177
|
-
$metadata: deserializeMetadata(output),
|
|
1178
|
-
};
|
|
1179
|
-
break;
|
|
1180
|
-
case "TextSizeLimitExceededException":
|
|
1181
|
-
case "com.amazonaws.comprehendmedical#TextSizeLimitExceededException":
|
|
1182
|
-
response = {
|
|
1183
|
-
...(await deserializeAws_json1_1TextSizeLimitExceededExceptionResponse(parsedOutput, context)),
|
|
1184
|
-
name: errorCode,
|
|
1185
|
-
$metadata: deserializeMetadata(output),
|
|
1186
|
-
};
|
|
1187
|
-
break;
|
|
1188
|
-
case "TooManyRequestsException":
|
|
1189
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1190
|
-
response = {
|
|
1191
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1192
|
-
name: errorCode,
|
|
1193
|
-
$metadata: deserializeMetadata(output),
|
|
1194
|
-
};
|
|
1195
|
-
break;
|
|
1196
|
-
default:
|
|
1197
|
-
const parsedBody = parsedOutput.body;
|
|
1198
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1199
|
-
response = {
|
|
1200
|
-
...parsedBody,
|
|
1201
|
-
name: `${errorCode}`,
|
|
1202
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1203
|
-
$fault: "client",
|
|
1204
|
-
$metadata: deserializeMetadata(output),
|
|
1205
|
-
} as any;
|
|
1206
|
-
}
|
|
1207
|
-
const message = response.message || response.Message || errorCode;
|
|
1208
|
-
response.message = message;
|
|
1209
|
-
delete response.Message;
|
|
1210
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1211
|
-
};
|
|
1212
|
-
|
|
1213
|
-
export const deserializeAws_json1_1ListEntitiesDetectionV2JobsCommand = async (
|
|
1214
|
-
output: __HttpResponse,
|
|
1215
|
-
context: __SerdeContext
|
|
1216
|
-
): Promise<ListEntitiesDetectionV2JobsCommandOutput> => {
|
|
1217
|
-
if (output.statusCode >= 300) {
|
|
1218
|
-
return deserializeAws_json1_1ListEntitiesDetectionV2JobsCommandError(output, context);
|
|
1219
|
-
}
|
|
1220
|
-
const data: any = await parseBody(output.body, context);
|
|
1221
|
-
let contents: any = {};
|
|
1222
|
-
contents = deserializeAws_json1_1ListEntitiesDetectionV2JobsResponse(data, context);
|
|
1223
|
-
const response: ListEntitiesDetectionV2JobsCommandOutput = {
|
|
1224
|
-
$metadata: deserializeMetadata(output),
|
|
1225
|
-
...contents,
|
|
1226
|
-
};
|
|
1227
|
-
return Promise.resolve(response);
|
|
1228
|
-
};
|
|
1229
|
-
|
|
1230
|
-
const deserializeAws_json1_1ListEntitiesDetectionV2JobsCommandError = async (
|
|
1231
|
-
output: __HttpResponse,
|
|
1232
|
-
context: __SerdeContext
|
|
1233
|
-
): Promise<ListEntitiesDetectionV2JobsCommandOutput> => {
|
|
1234
|
-
const parsedOutput: any = {
|
|
1235
|
-
...output,
|
|
1236
|
-
body: await parseBody(output.body, context),
|
|
1237
|
-
};
|
|
1238
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1239
|
-
let errorCode = "UnknownError";
|
|
1240
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1241
|
-
switch (errorCode) {
|
|
1242
|
-
case "InternalServerException":
|
|
1243
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1244
|
-
response = {
|
|
1245
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1246
|
-
name: errorCode,
|
|
1247
|
-
$metadata: deserializeMetadata(output),
|
|
1248
|
-
};
|
|
1249
|
-
break;
|
|
1250
|
-
case "InvalidRequestException":
|
|
1251
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1252
|
-
response = {
|
|
1253
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1254
|
-
name: errorCode,
|
|
1255
|
-
$metadata: deserializeMetadata(output),
|
|
1256
|
-
};
|
|
1257
|
-
break;
|
|
1258
|
-
case "TooManyRequestsException":
|
|
1259
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1260
|
-
response = {
|
|
1261
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1262
|
-
name: errorCode,
|
|
1263
|
-
$metadata: deserializeMetadata(output),
|
|
1264
|
-
};
|
|
1265
|
-
break;
|
|
1266
|
-
case "ValidationException":
|
|
1267
|
-
case "com.amazonaws.comprehendmedical#ValidationException":
|
|
1268
|
-
response = {
|
|
1269
|
-
...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
|
|
1270
|
-
name: errorCode,
|
|
1271
|
-
$metadata: deserializeMetadata(output),
|
|
1272
|
-
};
|
|
1273
|
-
break;
|
|
1274
|
-
default:
|
|
1275
|
-
const parsedBody = parsedOutput.body;
|
|
1276
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1277
|
-
response = {
|
|
1278
|
-
...parsedBody,
|
|
1279
|
-
name: `${errorCode}`,
|
|
1280
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1281
|
-
$fault: "client",
|
|
1282
|
-
$metadata: deserializeMetadata(output),
|
|
1283
|
-
} as any;
|
|
1284
|
-
}
|
|
1285
|
-
const message = response.message || response.Message || errorCode;
|
|
1286
|
-
response.message = message;
|
|
1287
|
-
delete response.Message;
|
|
1288
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1289
|
-
};
|
|
1290
|
-
|
|
1291
|
-
export const deserializeAws_json1_1ListICD10CMInferenceJobsCommand = async (
|
|
1292
|
-
output: __HttpResponse,
|
|
1293
|
-
context: __SerdeContext
|
|
1294
|
-
): Promise<ListICD10CMInferenceJobsCommandOutput> => {
|
|
1295
|
-
if (output.statusCode >= 300) {
|
|
1296
|
-
return deserializeAws_json1_1ListICD10CMInferenceJobsCommandError(output, context);
|
|
1297
|
-
}
|
|
1298
|
-
const data: any = await parseBody(output.body, context);
|
|
1299
|
-
let contents: any = {};
|
|
1300
|
-
contents = deserializeAws_json1_1ListICD10CMInferenceJobsResponse(data, context);
|
|
1301
|
-
const response: ListICD10CMInferenceJobsCommandOutput = {
|
|
1302
|
-
$metadata: deserializeMetadata(output),
|
|
1303
|
-
...contents,
|
|
1304
|
-
};
|
|
1305
|
-
return Promise.resolve(response);
|
|
1306
|
-
};
|
|
1307
|
-
|
|
1308
|
-
const deserializeAws_json1_1ListICD10CMInferenceJobsCommandError = async (
|
|
1309
|
-
output: __HttpResponse,
|
|
1310
|
-
context: __SerdeContext
|
|
1311
|
-
): Promise<ListICD10CMInferenceJobsCommandOutput> => {
|
|
1312
|
-
const parsedOutput: any = {
|
|
1313
|
-
...output,
|
|
1314
|
-
body: await parseBody(output.body, context),
|
|
1315
|
-
};
|
|
1316
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1317
|
-
let errorCode = "UnknownError";
|
|
1318
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1319
|
-
switch (errorCode) {
|
|
1320
|
-
case "InternalServerException":
|
|
1321
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1322
|
-
response = {
|
|
1323
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1324
|
-
name: errorCode,
|
|
1325
|
-
$metadata: deserializeMetadata(output),
|
|
1326
|
-
};
|
|
1327
|
-
break;
|
|
1328
|
-
case "InvalidRequestException":
|
|
1329
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1330
|
-
response = {
|
|
1331
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1332
|
-
name: errorCode,
|
|
1333
|
-
$metadata: deserializeMetadata(output),
|
|
1334
|
-
};
|
|
1335
|
-
break;
|
|
1336
|
-
case "TooManyRequestsException":
|
|
1337
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1338
|
-
response = {
|
|
1339
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1340
|
-
name: errorCode,
|
|
1341
|
-
$metadata: deserializeMetadata(output),
|
|
1342
|
-
};
|
|
1343
|
-
break;
|
|
1344
|
-
case "ValidationException":
|
|
1345
|
-
case "com.amazonaws.comprehendmedical#ValidationException":
|
|
1346
|
-
response = {
|
|
1347
|
-
...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
|
|
1348
|
-
name: errorCode,
|
|
1349
|
-
$metadata: deserializeMetadata(output),
|
|
1350
|
-
};
|
|
1351
|
-
break;
|
|
1352
|
-
default:
|
|
1353
|
-
const parsedBody = parsedOutput.body;
|
|
1354
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1355
|
-
response = {
|
|
1356
|
-
...parsedBody,
|
|
1357
|
-
name: `${errorCode}`,
|
|
1358
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1359
|
-
$fault: "client",
|
|
1360
|
-
$metadata: deserializeMetadata(output),
|
|
1361
|
-
} as any;
|
|
1362
|
-
}
|
|
1363
|
-
const message = response.message || response.Message || errorCode;
|
|
1364
|
-
response.message = message;
|
|
1365
|
-
delete response.Message;
|
|
1366
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1367
|
-
};
|
|
1368
|
-
|
|
1369
|
-
export const deserializeAws_json1_1ListPHIDetectionJobsCommand = async (
|
|
1370
|
-
output: __HttpResponse,
|
|
1371
|
-
context: __SerdeContext
|
|
1372
|
-
): Promise<ListPHIDetectionJobsCommandOutput> => {
|
|
1373
|
-
if (output.statusCode >= 300) {
|
|
1374
|
-
return deserializeAws_json1_1ListPHIDetectionJobsCommandError(output, context);
|
|
1375
|
-
}
|
|
1376
|
-
const data: any = await parseBody(output.body, context);
|
|
1377
|
-
let contents: any = {};
|
|
1378
|
-
contents = deserializeAws_json1_1ListPHIDetectionJobsResponse(data, context);
|
|
1379
|
-
const response: ListPHIDetectionJobsCommandOutput = {
|
|
1380
|
-
$metadata: deserializeMetadata(output),
|
|
1381
|
-
...contents,
|
|
1382
|
-
};
|
|
1383
|
-
return Promise.resolve(response);
|
|
1384
|
-
};
|
|
1385
|
-
|
|
1386
|
-
const deserializeAws_json1_1ListPHIDetectionJobsCommandError = async (
|
|
1387
|
-
output: __HttpResponse,
|
|
1388
|
-
context: __SerdeContext
|
|
1389
|
-
): Promise<ListPHIDetectionJobsCommandOutput> => {
|
|
1390
|
-
const parsedOutput: any = {
|
|
1391
|
-
...output,
|
|
1392
|
-
body: await parseBody(output.body, context),
|
|
1393
|
-
};
|
|
1394
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1395
|
-
let errorCode = "UnknownError";
|
|
1396
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1397
|
-
switch (errorCode) {
|
|
1398
|
-
case "InternalServerException":
|
|
1399
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1400
|
-
response = {
|
|
1401
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1402
|
-
name: errorCode,
|
|
1403
|
-
$metadata: deserializeMetadata(output),
|
|
1404
|
-
};
|
|
1405
|
-
break;
|
|
1406
|
-
case "InvalidRequestException":
|
|
1407
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1408
|
-
response = {
|
|
1409
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1410
|
-
name: errorCode,
|
|
1411
|
-
$metadata: deserializeMetadata(output),
|
|
1412
|
-
};
|
|
1413
|
-
break;
|
|
1414
|
-
case "TooManyRequestsException":
|
|
1415
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1416
|
-
response = {
|
|
1417
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1418
|
-
name: errorCode,
|
|
1419
|
-
$metadata: deserializeMetadata(output),
|
|
1420
|
-
};
|
|
1421
|
-
break;
|
|
1422
|
-
case "ValidationException":
|
|
1423
|
-
case "com.amazonaws.comprehendmedical#ValidationException":
|
|
1424
|
-
response = {
|
|
1425
|
-
...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
|
|
1426
|
-
name: errorCode,
|
|
1427
|
-
$metadata: deserializeMetadata(output),
|
|
1428
|
-
};
|
|
1429
|
-
break;
|
|
1430
|
-
default:
|
|
1431
|
-
const parsedBody = parsedOutput.body;
|
|
1432
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1433
|
-
response = {
|
|
1434
|
-
...parsedBody,
|
|
1435
|
-
name: `${errorCode}`,
|
|
1436
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1437
|
-
$fault: "client",
|
|
1438
|
-
$metadata: deserializeMetadata(output),
|
|
1439
|
-
} as any;
|
|
1440
|
-
}
|
|
1441
|
-
const message = response.message || response.Message || errorCode;
|
|
1442
|
-
response.message = message;
|
|
1443
|
-
delete response.Message;
|
|
1444
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1445
|
-
};
|
|
1446
|
-
|
|
1447
|
-
export const deserializeAws_json1_1ListRxNormInferenceJobsCommand = async (
|
|
1448
|
-
output: __HttpResponse,
|
|
1449
|
-
context: __SerdeContext
|
|
1450
|
-
): Promise<ListRxNormInferenceJobsCommandOutput> => {
|
|
1451
|
-
if (output.statusCode >= 300) {
|
|
1452
|
-
return deserializeAws_json1_1ListRxNormInferenceJobsCommandError(output, context);
|
|
1453
|
-
}
|
|
1454
|
-
const data: any = await parseBody(output.body, context);
|
|
1455
|
-
let contents: any = {};
|
|
1456
|
-
contents = deserializeAws_json1_1ListRxNormInferenceJobsResponse(data, context);
|
|
1457
|
-
const response: ListRxNormInferenceJobsCommandOutput = {
|
|
1458
|
-
$metadata: deserializeMetadata(output),
|
|
1459
|
-
...contents,
|
|
1460
|
-
};
|
|
1461
|
-
return Promise.resolve(response);
|
|
1462
|
-
};
|
|
1463
|
-
|
|
1464
|
-
const deserializeAws_json1_1ListRxNormInferenceJobsCommandError = async (
|
|
1465
|
-
output: __HttpResponse,
|
|
1466
|
-
context: __SerdeContext
|
|
1467
|
-
): Promise<ListRxNormInferenceJobsCommandOutput> => {
|
|
1468
|
-
const parsedOutput: any = {
|
|
1469
|
-
...output,
|
|
1470
|
-
body: await parseBody(output.body, context),
|
|
1471
|
-
};
|
|
1472
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1473
|
-
let errorCode = "UnknownError";
|
|
1474
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1475
|
-
switch (errorCode) {
|
|
1476
|
-
case "InternalServerException":
|
|
1477
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1478
|
-
response = {
|
|
1479
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1480
|
-
name: errorCode,
|
|
1481
|
-
$metadata: deserializeMetadata(output),
|
|
1482
|
-
};
|
|
1483
|
-
break;
|
|
1484
|
-
case "InvalidRequestException":
|
|
1485
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1486
|
-
response = {
|
|
1487
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1488
|
-
name: errorCode,
|
|
1489
|
-
$metadata: deserializeMetadata(output),
|
|
1490
|
-
};
|
|
1491
|
-
break;
|
|
1492
|
-
case "TooManyRequestsException":
|
|
1493
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1494
|
-
response = {
|
|
1495
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1496
|
-
name: errorCode,
|
|
1497
|
-
$metadata: deserializeMetadata(output),
|
|
1498
|
-
};
|
|
1499
|
-
break;
|
|
1500
|
-
case "ValidationException":
|
|
1501
|
-
case "com.amazonaws.comprehendmedical#ValidationException":
|
|
1502
|
-
response = {
|
|
1503
|
-
...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
|
|
1504
|
-
name: errorCode,
|
|
1505
|
-
$metadata: deserializeMetadata(output),
|
|
1506
|
-
};
|
|
1507
|
-
break;
|
|
1508
|
-
default:
|
|
1509
|
-
const parsedBody = parsedOutput.body;
|
|
1510
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1511
|
-
response = {
|
|
1512
|
-
...parsedBody,
|
|
1513
|
-
name: `${errorCode}`,
|
|
1514
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1515
|
-
$fault: "client",
|
|
1516
|
-
$metadata: deserializeMetadata(output),
|
|
1517
|
-
} as any;
|
|
1518
|
-
}
|
|
1519
|
-
const message = response.message || response.Message || errorCode;
|
|
1520
|
-
response.message = message;
|
|
1521
|
-
delete response.Message;
|
|
1522
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1523
|
-
};
|
|
1524
|
-
|
|
1525
|
-
export const deserializeAws_json1_1StartEntitiesDetectionV2JobCommand = async (
|
|
1526
|
-
output: __HttpResponse,
|
|
1527
|
-
context: __SerdeContext
|
|
1528
|
-
): Promise<StartEntitiesDetectionV2JobCommandOutput> => {
|
|
1529
|
-
if (output.statusCode >= 300) {
|
|
1530
|
-
return deserializeAws_json1_1StartEntitiesDetectionV2JobCommandError(output, context);
|
|
1531
|
-
}
|
|
1532
|
-
const data: any = await parseBody(output.body, context);
|
|
1533
|
-
let contents: any = {};
|
|
1534
|
-
contents = deserializeAws_json1_1StartEntitiesDetectionV2JobResponse(data, context);
|
|
1535
|
-
const response: StartEntitiesDetectionV2JobCommandOutput = {
|
|
1536
|
-
$metadata: deserializeMetadata(output),
|
|
1537
|
-
...contents,
|
|
1538
|
-
};
|
|
1539
|
-
return Promise.resolve(response);
|
|
1540
|
-
};
|
|
1541
|
-
|
|
1542
|
-
const deserializeAws_json1_1StartEntitiesDetectionV2JobCommandError = async (
|
|
1543
|
-
output: __HttpResponse,
|
|
1544
|
-
context: __SerdeContext
|
|
1545
|
-
): Promise<StartEntitiesDetectionV2JobCommandOutput> => {
|
|
1546
|
-
const parsedOutput: any = {
|
|
1547
|
-
...output,
|
|
1548
|
-
body: await parseBody(output.body, context),
|
|
1549
|
-
};
|
|
1550
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1551
|
-
let errorCode = "UnknownError";
|
|
1552
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1553
|
-
switch (errorCode) {
|
|
1554
|
-
case "InternalServerException":
|
|
1555
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1556
|
-
response = {
|
|
1557
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1558
|
-
name: errorCode,
|
|
1559
|
-
$metadata: deserializeMetadata(output),
|
|
1560
|
-
};
|
|
1561
|
-
break;
|
|
1562
|
-
case "InvalidRequestException":
|
|
1563
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1564
|
-
response = {
|
|
1565
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1566
|
-
name: errorCode,
|
|
1567
|
-
$metadata: deserializeMetadata(output),
|
|
1568
|
-
};
|
|
1569
|
-
break;
|
|
1570
|
-
case "ResourceNotFoundException":
|
|
1571
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
1572
|
-
response = {
|
|
1573
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
1574
|
-
name: errorCode,
|
|
1575
|
-
$metadata: deserializeMetadata(output),
|
|
1576
|
-
};
|
|
1577
|
-
break;
|
|
1578
|
-
case "TooManyRequestsException":
|
|
1579
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1580
|
-
response = {
|
|
1581
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1582
|
-
name: errorCode,
|
|
1583
|
-
$metadata: deserializeMetadata(output),
|
|
1584
|
-
};
|
|
1585
|
-
break;
|
|
1586
|
-
default:
|
|
1587
|
-
const parsedBody = parsedOutput.body;
|
|
1588
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1589
|
-
response = {
|
|
1590
|
-
...parsedBody,
|
|
1591
|
-
name: `${errorCode}`,
|
|
1592
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1593
|
-
$fault: "client",
|
|
1594
|
-
$metadata: deserializeMetadata(output),
|
|
1595
|
-
} as any;
|
|
1596
|
-
}
|
|
1597
|
-
const message = response.message || response.Message || errorCode;
|
|
1598
|
-
response.message = message;
|
|
1599
|
-
delete response.Message;
|
|
1600
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1601
|
-
};
|
|
1602
|
-
|
|
1603
|
-
export const deserializeAws_json1_1StartICD10CMInferenceJobCommand = async (
|
|
1604
|
-
output: __HttpResponse,
|
|
1605
|
-
context: __SerdeContext
|
|
1606
|
-
): Promise<StartICD10CMInferenceJobCommandOutput> => {
|
|
1607
|
-
if (output.statusCode >= 300) {
|
|
1608
|
-
return deserializeAws_json1_1StartICD10CMInferenceJobCommandError(output, context);
|
|
1609
|
-
}
|
|
1610
|
-
const data: any = await parseBody(output.body, context);
|
|
1611
|
-
let contents: any = {};
|
|
1612
|
-
contents = deserializeAws_json1_1StartICD10CMInferenceJobResponse(data, context);
|
|
1613
|
-
const response: StartICD10CMInferenceJobCommandOutput = {
|
|
1614
|
-
$metadata: deserializeMetadata(output),
|
|
1615
|
-
...contents,
|
|
1616
|
-
};
|
|
1617
|
-
return Promise.resolve(response);
|
|
1618
|
-
};
|
|
1619
|
-
|
|
1620
|
-
const deserializeAws_json1_1StartICD10CMInferenceJobCommandError = async (
|
|
1621
|
-
output: __HttpResponse,
|
|
1622
|
-
context: __SerdeContext
|
|
1623
|
-
): Promise<StartICD10CMInferenceJobCommandOutput> => {
|
|
1624
|
-
const parsedOutput: any = {
|
|
1625
|
-
...output,
|
|
1626
|
-
body: await parseBody(output.body, context),
|
|
1627
|
-
};
|
|
1628
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1629
|
-
let errorCode = "UnknownError";
|
|
1630
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1631
|
-
switch (errorCode) {
|
|
1632
|
-
case "InternalServerException":
|
|
1633
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1634
|
-
response = {
|
|
1635
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1636
|
-
name: errorCode,
|
|
1637
|
-
$metadata: deserializeMetadata(output),
|
|
1638
|
-
};
|
|
1639
|
-
break;
|
|
1640
|
-
case "InvalidRequestException":
|
|
1641
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1642
|
-
response = {
|
|
1643
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1644
|
-
name: errorCode,
|
|
1645
|
-
$metadata: deserializeMetadata(output),
|
|
1646
|
-
};
|
|
1647
|
-
break;
|
|
1648
|
-
case "ResourceNotFoundException":
|
|
1649
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
1650
|
-
response = {
|
|
1651
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
1652
|
-
name: errorCode,
|
|
1653
|
-
$metadata: deserializeMetadata(output),
|
|
1654
|
-
};
|
|
1655
|
-
break;
|
|
1656
|
-
case "TooManyRequestsException":
|
|
1657
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1658
|
-
response = {
|
|
1659
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1660
|
-
name: errorCode,
|
|
1661
|
-
$metadata: deserializeMetadata(output),
|
|
1662
|
-
};
|
|
1663
|
-
break;
|
|
1664
|
-
default:
|
|
1665
|
-
const parsedBody = parsedOutput.body;
|
|
1666
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1667
|
-
response = {
|
|
1668
|
-
...parsedBody,
|
|
1669
|
-
name: `${errorCode}`,
|
|
1670
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1671
|
-
$fault: "client",
|
|
1672
|
-
$metadata: deserializeMetadata(output),
|
|
1673
|
-
} as any;
|
|
1674
|
-
}
|
|
1675
|
-
const message = response.message || response.Message || errorCode;
|
|
1676
|
-
response.message = message;
|
|
1677
|
-
delete response.Message;
|
|
1678
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1679
|
-
};
|
|
1680
|
-
|
|
1681
|
-
export const deserializeAws_json1_1StartPHIDetectionJobCommand = async (
|
|
1682
|
-
output: __HttpResponse,
|
|
1683
|
-
context: __SerdeContext
|
|
1684
|
-
): Promise<StartPHIDetectionJobCommandOutput> => {
|
|
1685
|
-
if (output.statusCode >= 300) {
|
|
1686
|
-
return deserializeAws_json1_1StartPHIDetectionJobCommandError(output, context);
|
|
1687
|
-
}
|
|
1688
|
-
const data: any = await parseBody(output.body, context);
|
|
1689
|
-
let contents: any = {};
|
|
1690
|
-
contents = deserializeAws_json1_1StartPHIDetectionJobResponse(data, context);
|
|
1691
|
-
const response: StartPHIDetectionJobCommandOutput = {
|
|
1692
|
-
$metadata: deserializeMetadata(output),
|
|
1693
|
-
...contents,
|
|
1694
|
-
};
|
|
1695
|
-
return Promise.resolve(response);
|
|
1696
|
-
};
|
|
1697
|
-
|
|
1698
|
-
const deserializeAws_json1_1StartPHIDetectionJobCommandError = async (
|
|
1699
|
-
output: __HttpResponse,
|
|
1700
|
-
context: __SerdeContext
|
|
1701
|
-
): Promise<StartPHIDetectionJobCommandOutput> => {
|
|
1702
|
-
const parsedOutput: any = {
|
|
1703
|
-
...output,
|
|
1704
|
-
body: await parseBody(output.body, context),
|
|
1705
|
-
};
|
|
1706
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1707
|
-
let errorCode = "UnknownError";
|
|
1708
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1709
|
-
switch (errorCode) {
|
|
1710
|
-
case "InternalServerException":
|
|
1711
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1712
|
-
response = {
|
|
1713
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1714
|
-
name: errorCode,
|
|
1715
|
-
$metadata: deserializeMetadata(output),
|
|
1716
|
-
};
|
|
1717
|
-
break;
|
|
1718
|
-
case "InvalidRequestException":
|
|
1719
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1720
|
-
response = {
|
|
1721
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1722
|
-
name: errorCode,
|
|
1723
|
-
$metadata: deserializeMetadata(output),
|
|
1724
|
-
};
|
|
1725
|
-
break;
|
|
1726
|
-
case "ResourceNotFoundException":
|
|
1727
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
1728
|
-
response = {
|
|
1729
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
1730
|
-
name: errorCode,
|
|
1731
|
-
$metadata: deserializeMetadata(output),
|
|
1732
|
-
};
|
|
1733
|
-
break;
|
|
1734
|
-
case "TooManyRequestsException":
|
|
1735
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1736
|
-
response = {
|
|
1737
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1738
|
-
name: errorCode,
|
|
1739
|
-
$metadata: deserializeMetadata(output),
|
|
1740
|
-
};
|
|
1741
|
-
break;
|
|
1742
|
-
default:
|
|
1743
|
-
const parsedBody = parsedOutput.body;
|
|
1744
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1745
|
-
response = {
|
|
1746
|
-
...parsedBody,
|
|
1747
|
-
name: `${errorCode}`,
|
|
1748
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1749
|
-
$fault: "client",
|
|
1750
|
-
$metadata: deserializeMetadata(output),
|
|
1751
|
-
} as any;
|
|
1752
|
-
}
|
|
1753
|
-
const message = response.message || response.Message || errorCode;
|
|
1754
|
-
response.message = message;
|
|
1755
|
-
delete response.Message;
|
|
1756
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1757
|
-
};
|
|
1758
|
-
|
|
1759
|
-
export const deserializeAws_json1_1StartRxNormInferenceJobCommand = async (
|
|
1760
|
-
output: __HttpResponse,
|
|
1761
|
-
context: __SerdeContext
|
|
1762
|
-
): Promise<StartRxNormInferenceJobCommandOutput> => {
|
|
1763
|
-
if (output.statusCode >= 300) {
|
|
1764
|
-
return deserializeAws_json1_1StartRxNormInferenceJobCommandError(output, context);
|
|
1765
|
-
}
|
|
1766
|
-
const data: any = await parseBody(output.body, context);
|
|
1767
|
-
let contents: any = {};
|
|
1768
|
-
contents = deserializeAws_json1_1StartRxNormInferenceJobResponse(data, context);
|
|
1769
|
-
const response: StartRxNormInferenceJobCommandOutput = {
|
|
1770
|
-
$metadata: deserializeMetadata(output),
|
|
1771
|
-
...contents,
|
|
1772
|
-
};
|
|
1773
|
-
return Promise.resolve(response);
|
|
1774
|
-
};
|
|
1775
|
-
|
|
1776
|
-
const deserializeAws_json1_1StartRxNormInferenceJobCommandError = async (
|
|
1777
|
-
output: __HttpResponse,
|
|
1778
|
-
context: __SerdeContext
|
|
1779
|
-
): Promise<StartRxNormInferenceJobCommandOutput> => {
|
|
1780
|
-
const parsedOutput: any = {
|
|
1781
|
-
...output,
|
|
1782
|
-
body: await parseBody(output.body, context),
|
|
1783
|
-
};
|
|
1784
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1785
|
-
let errorCode = "UnknownError";
|
|
1786
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1787
|
-
switch (errorCode) {
|
|
1788
|
-
case "InternalServerException":
|
|
1789
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1790
|
-
response = {
|
|
1791
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1792
|
-
name: errorCode,
|
|
1793
|
-
$metadata: deserializeMetadata(output),
|
|
1794
|
-
};
|
|
1795
|
-
break;
|
|
1796
|
-
case "InvalidRequestException":
|
|
1797
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1798
|
-
response = {
|
|
1799
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1800
|
-
name: errorCode,
|
|
1801
|
-
$metadata: deserializeMetadata(output),
|
|
1802
|
-
};
|
|
1803
|
-
break;
|
|
1804
|
-
case "ResourceNotFoundException":
|
|
1805
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
1806
|
-
response = {
|
|
1807
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
1808
|
-
name: errorCode,
|
|
1809
|
-
$metadata: deserializeMetadata(output),
|
|
1810
|
-
};
|
|
1811
|
-
break;
|
|
1812
|
-
case "TooManyRequestsException":
|
|
1813
|
-
case "com.amazonaws.comprehendmedical#TooManyRequestsException":
|
|
1814
|
-
response = {
|
|
1815
|
-
...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)),
|
|
1816
|
-
name: errorCode,
|
|
1817
|
-
$metadata: deserializeMetadata(output),
|
|
1818
|
-
};
|
|
1819
|
-
break;
|
|
1820
|
-
default:
|
|
1821
|
-
const parsedBody = parsedOutput.body;
|
|
1822
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1823
|
-
response = {
|
|
1824
|
-
...parsedBody,
|
|
1825
|
-
name: `${errorCode}`,
|
|
1826
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1827
|
-
$fault: "client",
|
|
1828
|
-
$metadata: deserializeMetadata(output),
|
|
1829
|
-
} as any;
|
|
1830
|
-
}
|
|
1831
|
-
const message = response.message || response.Message || errorCode;
|
|
1832
|
-
response.message = message;
|
|
1833
|
-
delete response.Message;
|
|
1834
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1835
|
-
};
|
|
1836
|
-
|
|
1837
|
-
export const deserializeAws_json1_1StopEntitiesDetectionV2JobCommand = async (
|
|
1838
|
-
output: __HttpResponse,
|
|
1839
|
-
context: __SerdeContext
|
|
1840
|
-
): Promise<StopEntitiesDetectionV2JobCommandOutput> => {
|
|
1841
|
-
if (output.statusCode >= 300) {
|
|
1842
|
-
return deserializeAws_json1_1StopEntitiesDetectionV2JobCommandError(output, context);
|
|
1843
|
-
}
|
|
1844
|
-
const data: any = await parseBody(output.body, context);
|
|
1845
|
-
let contents: any = {};
|
|
1846
|
-
contents = deserializeAws_json1_1StopEntitiesDetectionV2JobResponse(data, context);
|
|
1847
|
-
const response: StopEntitiesDetectionV2JobCommandOutput = {
|
|
1848
|
-
$metadata: deserializeMetadata(output),
|
|
1849
|
-
...contents,
|
|
1850
|
-
};
|
|
1851
|
-
return Promise.resolve(response);
|
|
1852
|
-
};
|
|
1853
|
-
|
|
1854
|
-
const deserializeAws_json1_1StopEntitiesDetectionV2JobCommandError = async (
|
|
1855
|
-
output: __HttpResponse,
|
|
1856
|
-
context: __SerdeContext
|
|
1857
|
-
): Promise<StopEntitiesDetectionV2JobCommandOutput> => {
|
|
1858
|
-
const parsedOutput: any = {
|
|
1859
|
-
...output,
|
|
1860
|
-
body: await parseBody(output.body, context),
|
|
1861
|
-
};
|
|
1862
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1863
|
-
let errorCode = "UnknownError";
|
|
1864
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1865
|
-
switch (errorCode) {
|
|
1866
|
-
case "InternalServerException":
|
|
1867
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1868
|
-
response = {
|
|
1869
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1870
|
-
name: errorCode,
|
|
1871
|
-
$metadata: deserializeMetadata(output),
|
|
1872
|
-
};
|
|
1873
|
-
break;
|
|
1874
|
-
case "InvalidRequestException":
|
|
1875
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1876
|
-
response = {
|
|
1877
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1878
|
-
name: errorCode,
|
|
1879
|
-
$metadata: deserializeMetadata(output),
|
|
1880
|
-
};
|
|
1881
|
-
break;
|
|
1882
|
-
case "ResourceNotFoundException":
|
|
1883
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
1884
|
-
response = {
|
|
1885
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
1886
|
-
name: errorCode,
|
|
1887
|
-
$metadata: deserializeMetadata(output),
|
|
1888
|
-
};
|
|
1889
|
-
break;
|
|
1890
|
-
default:
|
|
1891
|
-
const parsedBody = parsedOutput.body;
|
|
1892
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1893
|
-
response = {
|
|
1894
|
-
...parsedBody,
|
|
1895
|
-
name: `${errorCode}`,
|
|
1896
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1897
|
-
$fault: "client",
|
|
1898
|
-
$metadata: deserializeMetadata(output),
|
|
1899
|
-
} as any;
|
|
1900
|
-
}
|
|
1901
|
-
const message = response.message || response.Message || errorCode;
|
|
1902
|
-
response.message = message;
|
|
1903
|
-
delete response.Message;
|
|
1904
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1905
|
-
};
|
|
1906
|
-
|
|
1907
|
-
export const deserializeAws_json1_1StopICD10CMInferenceJobCommand = async (
|
|
1908
|
-
output: __HttpResponse,
|
|
1909
|
-
context: __SerdeContext
|
|
1910
|
-
): Promise<StopICD10CMInferenceJobCommandOutput> => {
|
|
1911
|
-
if (output.statusCode >= 300) {
|
|
1912
|
-
return deserializeAws_json1_1StopICD10CMInferenceJobCommandError(output, context);
|
|
1913
|
-
}
|
|
1914
|
-
const data: any = await parseBody(output.body, context);
|
|
1915
|
-
let contents: any = {};
|
|
1916
|
-
contents = deserializeAws_json1_1StopICD10CMInferenceJobResponse(data, context);
|
|
1917
|
-
const response: StopICD10CMInferenceJobCommandOutput = {
|
|
1918
|
-
$metadata: deserializeMetadata(output),
|
|
1919
|
-
...contents,
|
|
1920
|
-
};
|
|
1921
|
-
return Promise.resolve(response);
|
|
1922
|
-
};
|
|
1923
|
-
|
|
1924
|
-
const deserializeAws_json1_1StopICD10CMInferenceJobCommandError = async (
|
|
1925
|
-
output: __HttpResponse,
|
|
1926
|
-
context: __SerdeContext
|
|
1927
|
-
): Promise<StopICD10CMInferenceJobCommandOutput> => {
|
|
1928
|
-
const parsedOutput: any = {
|
|
1929
|
-
...output,
|
|
1930
|
-
body: await parseBody(output.body, context),
|
|
1931
|
-
};
|
|
1932
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1933
|
-
let errorCode = "UnknownError";
|
|
1934
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1935
|
-
switch (errorCode) {
|
|
1936
|
-
case "InternalServerException":
|
|
1937
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
1938
|
-
response = {
|
|
1939
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1940
|
-
name: errorCode,
|
|
1941
|
-
$metadata: deserializeMetadata(output),
|
|
1942
|
-
};
|
|
1943
|
-
break;
|
|
1944
|
-
case "InvalidRequestException":
|
|
1945
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
1946
|
-
response = {
|
|
1947
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
1948
|
-
name: errorCode,
|
|
1949
|
-
$metadata: deserializeMetadata(output),
|
|
1950
|
-
};
|
|
1951
|
-
break;
|
|
1952
|
-
case "ResourceNotFoundException":
|
|
1953
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
1954
|
-
response = {
|
|
1955
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
1956
|
-
name: errorCode,
|
|
1957
|
-
$metadata: deserializeMetadata(output),
|
|
1958
|
-
};
|
|
1959
|
-
break;
|
|
1960
|
-
default:
|
|
1961
|
-
const parsedBody = parsedOutput.body;
|
|
1962
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1963
|
-
response = {
|
|
1964
|
-
...parsedBody,
|
|
1965
|
-
name: `${errorCode}`,
|
|
1966
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1967
|
-
$fault: "client",
|
|
1968
|
-
$metadata: deserializeMetadata(output),
|
|
1969
|
-
} as any;
|
|
1970
|
-
}
|
|
1971
|
-
const message = response.message || response.Message || errorCode;
|
|
1972
|
-
response.message = message;
|
|
1973
|
-
delete response.Message;
|
|
1974
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1975
|
-
};
|
|
1976
|
-
|
|
1977
|
-
export const deserializeAws_json1_1StopPHIDetectionJobCommand = async (
|
|
1978
|
-
output: __HttpResponse,
|
|
1979
|
-
context: __SerdeContext
|
|
1980
|
-
): Promise<StopPHIDetectionJobCommandOutput> => {
|
|
1981
|
-
if (output.statusCode >= 300) {
|
|
1982
|
-
return deserializeAws_json1_1StopPHIDetectionJobCommandError(output, context);
|
|
1983
|
-
}
|
|
1984
|
-
const data: any = await parseBody(output.body, context);
|
|
1985
|
-
let contents: any = {};
|
|
1986
|
-
contents = deserializeAws_json1_1StopPHIDetectionJobResponse(data, context);
|
|
1987
|
-
const response: StopPHIDetectionJobCommandOutput = {
|
|
1988
|
-
$metadata: deserializeMetadata(output),
|
|
1989
|
-
...contents,
|
|
1990
|
-
};
|
|
1991
|
-
return Promise.resolve(response);
|
|
1992
|
-
};
|
|
1993
|
-
|
|
1994
|
-
const deserializeAws_json1_1StopPHIDetectionJobCommandError = async (
|
|
1995
|
-
output: __HttpResponse,
|
|
1996
|
-
context: __SerdeContext
|
|
1997
|
-
): Promise<StopPHIDetectionJobCommandOutput> => {
|
|
1998
|
-
const parsedOutput: any = {
|
|
1999
|
-
...output,
|
|
2000
|
-
body: await parseBody(output.body, context),
|
|
2001
|
-
};
|
|
2002
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2003
|
-
let errorCode = "UnknownError";
|
|
2004
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2005
|
-
switch (errorCode) {
|
|
2006
|
-
case "InternalServerException":
|
|
2007
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
2008
|
-
response = {
|
|
2009
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
2010
|
-
name: errorCode,
|
|
2011
|
-
$metadata: deserializeMetadata(output),
|
|
2012
|
-
};
|
|
2013
|
-
break;
|
|
2014
|
-
case "InvalidRequestException":
|
|
2015
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
2016
|
-
response = {
|
|
2017
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
2018
|
-
name: errorCode,
|
|
2019
|
-
$metadata: deserializeMetadata(output),
|
|
2020
|
-
};
|
|
2021
|
-
break;
|
|
2022
|
-
case "ResourceNotFoundException":
|
|
2023
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
2024
|
-
response = {
|
|
2025
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
2026
|
-
name: errorCode,
|
|
2027
|
-
$metadata: deserializeMetadata(output),
|
|
2028
|
-
};
|
|
2029
|
-
break;
|
|
2030
|
-
default:
|
|
2031
|
-
const parsedBody = parsedOutput.body;
|
|
2032
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2033
|
-
response = {
|
|
2034
|
-
...parsedBody,
|
|
2035
|
-
name: `${errorCode}`,
|
|
2036
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2037
|
-
$fault: "client",
|
|
2038
|
-
$metadata: deserializeMetadata(output),
|
|
2039
|
-
} as any;
|
|
2040
|
-
}
|
|
2041
|
-
const message = response.message || response.Message || errorCode;
|
|
2042
|
-
response.message = message;
|
|
2043
|
-
delete response.Message;
|
|
2044
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2045
|
-
};
|
|
2046
|
-
|
|
2047
|
-
export const deserializeAws_json1_1StopRxNormInferenceJobCommand = async (
|
|
2048
|
-
output: __HttpResponse,
|
|
2049
|
-
context: __SerdeContext
|
|
2050
|
-
): Promise<StopRxNormInferenceJobCommandOutput> => {
|
|
2051
|
-
if (output.statusCode >= 300) {
|
|
2052
|
-
return deserializeAws_json1_1StopRxNormInferenceJobCommandError(output, context);
|
|
2053
|
-
}
|
|
2054
|
-
const data: any = await parseBody(output.body, context);
|
|
2055
|
-
let contents: any = {};
|
|
2056
|
-
contents = deserializeAws_json1_1StopRxNormInferenceJobResponse(data, context);
|
|
2057
|
-
const response: StopRxNormInferenceJobCommandOutput = {
|
|
2058
|
-
$metadata: deserializeMetadata(output),
|
|
2059
|
-
...contents,
|
|
2060
|
-
};
|
|
2061
|
-
return Promise.resolve(response);
|
|
2062
|
-
};
|
|
2063
|
-
|
|
2064
|
-
const deserializeAws_json1_1StopRxNormInferenceJobCommandError = async (
|
|
2065
|
-
output: __HttpResponse,
|
|
2066
|
-
context: __SerdeContext
|
|
2067
|
-
): Promise<StopRxNormInferenceJobCommandOutput> => {
|
|
2068
|
-
const parsedOutput: any = {
|
|
2069
|
-
...output,
|
|
2070
|
-
body: await parseBody(output.body, context),
|
|
2071
|
-
};
|
|
2072
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2073
|
-
let errorCode = "UnknownError";
|
|
2074
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2075
|
-
switch (errorCode) {
|
|
2076
|
-
case "InternalServerException":
|
|
2077
|
-
case "com.amazonaws.comprehendmedical#InternalServerException":
|
|
2078
|
-
response = {
|
|
2079
|
-
...(await deserializeAws_json1_1InternalServerExceptionResponse(parsedOutput, context)),
|
|
2080
|
-
name: errorCode,
|
|
2081
|
-
$metadata: deserializeMetadata(output),
|
|
2082
|
-
};
|
|
2083
|
-
break;
|
|
2084
|
-
case "InvalidRequestException":
|
|
2085
|
-
case "com.amazonaws.comprehendmedical#InvalidRequestException":
|
|
2086
|
-
response = {
|
|
2087
|
-
...(await deserializeAws_json1_1InvalidRequestExceptionResponse(parsedOutput, context)),
|
|
2088
|
-
name: errorCode,
|
|
2089
|
-
$metadata: deserializeMetadata(output),
|
|
2090
|
-
};
|
|
2091
|
-
break;
|
|
2092
|
-
case "ResourceNotFoundException":
|
|
2093
|
-
case "com.amazonaws.comprehendmedical#ResourceNotFoundException":
|
|
2094
|
-
response = {
|
|
2095
|
-
...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
2096
|
-
name: errorCode,
|
|
2097
|
-
$metadata: deserializeMetadata(output),
|
|
2098
|
-
};
|
|
2099
|
-
break;
|
|
2100
|
-
default:
|
|
2101
|
-
const parsedBody = parsedOutput.body;
|
|
2102
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2103
|
-
response = {
|
|
2104
|
-
...parsedBody,
|
|
2105
|
-
name: `${errorCode}`,
|
|
2106
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2107
|
-
$fault: "client",
|
|
2108
|
-
$metadata: deserializeMetadata(output),
|
|
2109
|
-
} as any;
|
|
2110
|
-
}
|
|
2111
|
-
const message = response.message || response.Message || errorCode;
|
|
2112
|
-
response.message = message;
|
|
2113
|
-
delete response.Message;
|
|
2114
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2115
|
-
};
|
|
2116
|
-
|
|
2117
|
-
const deserializeAws_json1_1InternalServerExceptionResponse = async (
|
|
2118
|
-
parsedOutput: any,
|
|
2119
|
-
context: __SerdeContext
|
|
2120
|
-
): Promise<InternalServerException> => {
|
|
2121
|
-
const body = parsedOutput.body;
|
|
2122
|
-
const deserialized: any = deserializeAws_json1_1InternalServerException(body, context);
|
|
2123
|
-
const contents: InternalServerException = {
|
|
2124
|
-
name: "InternalServerException",
|
|
2125
|
-
$fault: "server",
|
|
2126
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2127
|
-
...deserialized,
|
|
2128
|
-
};
|
|
2129
|
-
return contents;
|
|
2130
|
-
};
|
|
2131
|
-
|
|
2132
|
-
const deserializeAws_json1_1InvalidEncodingExceptionResponse = async (
|
|
2133
|
-
parsedOutput: any,
|
|
2134
|
-
context: __SerdeContext
|
|
2135
|
-
): Promise<InvalidEncodingException> => {
|
|
2136
|
-
const body = parsedOutput.body;
|
|
2137
|
-
const deserialized: any = deserializeAws_json1_1InvalidEncodingException(body, context);
|
|
2138
|
-
const contents: InvalidEncodingException = {
|
|
2139
|
-
name: "InvalidEncodingException",
|
|
2140
|
-
$fault: "client",
|
|
2141
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2142
|
-
...deserialized,
|
|
2143
|
-
};
|
|
2144
|
-
return contents;
|
|
2145
|
-
};
|
|
2146
|
-
|
|
2147
|
-
const deserializeAws_json1_1InvalidRequestExceptionResponse = async (
|
|
2148
|
-
parsedOutput: any,
|
|
2149
|
-
context: __SerdeContext
|
|
2150
|
-
): Promise<InvalidRequestException> => {
|
|
2151
|
-
const body = parsedOutput.body;
|
|
2152
|
-
const deserialized: any = deserializeAws_json1_1InvalidRequestException(body, context);
|
|
2153
|
-
const contents: InvalidRequestException = {
|
|
2154
|
-
name: "InvalidRequestException",
|
|
2155
|
-
$fault: "client",
|
|
2156
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2157
|
-
...deserialized,
|
|
2158
|
-
};
|
|
2159
|
-
return contents;
|
|
2160
|
-
};
|
|
2161
|
-
|
|
2162
|
-
const deserializeAws_json1_1ResourceNotFoundExceptionResponse = async (
|
|
2163
|
-
parsedOutput: any,
|
|
2164
|
-
context: __SerdeContext
|
|
2165
|
-
): Promise<ResourceNotFoundException> => {
|
|
2166
|
-
const body = parsedOutput.body;
|
|
2167
|
-
const deserialized: any = deserializeAws_json1_1ResourceNotFoundException(body, context);
|
|
2168
|
-
const contents: ResourceNotFoundException = {
|
|
2169
|
-
name: "ResourceNotFoundException",
|
|
2170
|
-
$fault: "client",
|
|
2171
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2172
|
-
...deserialized,
|
|
2173
|
-
};
|
|
2174
|
-
return contents;
|
|
2175
|
-
};
|
|
2176
|
-
|
|
2177
|
-
const deserializeAws_json1_1ServiceUnavailableExceptionResponse = async (
|
|
2178
|
-
parsedOutput: any,
|
|
2179
|
-
context: __SerdeContext
|
|
2180
|
-
): Promise<ServiceUnavailableException> => {
|
|
2181
|
-
const body = parsedOutput.body;
|
|
2182
|
-
const deserialized: any = deserializeAws_json1_1ServiceUnavailableException(body, context);
|
|
2183
|
-
const contents: ServiceUnavailableException = {
|
|
2184
|
-
name: "ServiceUnavailableException",
|
|
2185
|
-
$fault: "server",
|
|
2186
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2187
|
-
...deserialized,
|
|
2188
|
-
};
|
|
2189
|
-
return contents;
|
|
2190
|
-
};
|
|
2191
|
-
|
|
2192
|
-
const deserializeAws_json1_1TextSizeLimitExceededExceptionResponse = async (
|
|
2193
|
-
parsedOutput: any,
|
|
2194
|
-
context: __SerdeContext
|
|
2195
|
-
): Promise<TextSizeLimitExceededException> => {
|
|
2196
|
-
const body = parsedOutput.body;
|
|
2197
|
-
const deserialized: any = deserializeAws_json1_1TextSizeLimitExceededException(body, context);
|
|
2198
|
-
const contents: TextSizeLimitExceededException = {
|
|
2199
|
-
name: "TextSizeLimitExceededException",
|
|
2200
|
-
$fault: "client",
|
|
2201
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2202
|
-
...deserialized,
|
|
2203
|
-
};
|
|
2204
|
-
return contents;
|
|
2205
|
-
};
|
|
2206
|
-
|
|
2207
|
-
const deserializeAws_json1_1TooManyRequestsExceptionResponse = async (
|
|
2208
|
-
parsedOutput: any,
|
|
2209
|
-
context: __SerdeContext
|
|
2210
|
-
): Promise<TooManyRequestsException> => {
|
|
2211
|
-
const body = parsedOutput.body;
|
|
2212
|
-
const deserialized: any = deserializeAws_json1_1TooManyRequestsException(body, context);
|
|
2213
|
-
const contents: TooManyRequestsException = {
|
|
2214
|
-
name: "TooManyRequestsException",
|
|
2215
|
-
$fault: "client",
|
|
2216
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2217
|
-
...deserialized,
|
|
2218
|
-
};
|
|
2219
|
-
return contents;
|
|
2220
|
-
};
|
|
2221
|
-
|
|
2222
|
-
const deserializeAws_json1_1ValidationExceptionResponse = async (
|
|
2223
|
-
parsedOutput: any,
|
|
2224
|
-
context: __SerdeContext
|
|
2225
|
-
): Promise<ValidationException> => {
|
|
2226
|
-
const body = parsedOutput.body;
|
|
2227
|
-
const deserialized: any = deserializeAws_json1_1ValidationException(body, context);
|
|
2228
|
-
const contents: ValidationException = {
|
|
2229
|
-
name: "ValidationException",
|
|
2230
|
-
$fault: "client",
|
|
2231
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
2232
|
-
...deserialized,
|
|
2233
|
-
};
|
|
2234
|
-
return contents;
|
|
2235
|
-
};
|
|
2236
|
-
|
|
2237
|
-
const serializeAws_json1_1ComprehendMedicalAsyncJobFilter = (
|
|
2238
|
-
input: ComprehendMedicalAsyncJobFilter,
|
|
2239
|
-
context: __SerdeContext
|
|
2240
|
-
): any => {
|
|
2241
|
-
return {
|
|
2242
|
-
...(input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName }),
|
|
2243
|
-
...(input.JobStatus !== undefined && input.JobStatus !== null && { JobStatus: input.JobStatus }),
|
|
2244
|
-
...(input.SubmitTimeAfter !== undefined &&
|
|
2245
|
-
input.SubmitTimeAfter !== null && { SubmitTimeAfter: Math.round(input.SubmitTimeAfter.getTime() / 1000) }),
|
|
2246
|
-
...(input.SubmitTimeBefore !== undefined &&
|
|
2247
|
-
input.SubmitTimeBefore !== null && { SubmitTimeBefore: Math.round(input.SubmitTimeBefore.getTime() / 1000) }),
|
|
2248
|
-
};
|
|
2249
|
-
};
|
|
2250
|
-
|
|
2251
|
-
const serializeAws_json1_1DescribeEntitiesDetectionV2JobRequest = (
|
|
2252
|
-
input: DescribeEntitiesDetectionV2JobRequest,
|
|
2253
|
-
context: __SerdeContext
|
|
2254
|
-
): any => {
|
|
2255
|
-
return {
|
|
2256
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2257
|
-
};
|
|
2258
|
-
};
|
|
2259
|
-
|
|
2260
|
-
const serializeAws_json1_1DescribeICD10CMInferenceJobRequest = (
|
|
2261
|
-
input: DescribeICD10CMInferenceJobRequest,
|
|
2262
|
-
context: __SerdeContext
|
|
2263
|
-
): any => {
|
|
2264
|
-
return {
|
|
2265
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2266
|
-
};
|
|
2267
|
-
};
|
|
2268
|
-
|
|
2269
|
-
const serializeAws_json1_1DescribePHIDetectionJobRequest = (
|
|
2270
|
-
input: DescribePHIDetectionJobRequest,
|
|
2271
|
-
context: __SerdeContext
|
|
2272
|
-
): any => {
|
|
2273
|
-
return {
|
|
2274
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2275
|
-
};
|
|
2276
|
-
};
|
|
2277
|
-
|
|
2278
|
-
const serializeAws_json1_1DescribeRxNormInferenceJobRequest = (
|
|
2279
|
-
input: DescribeRxNormInferenceJobRequest,
|
|
2280
|
-
context: __SerdeContext
|
|
2281
|
-
): any => {
|
|
2282
|
-
return {
|
|
2283
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2284
|
-
};
|
|
2285
|
-
};
|
|
2286
|
-
|
|
2287
|
-
const serializeAws_json1_1DetectEntitiesRequest = (input: DetectEntitiesRequest, context: __SerdeContext): any => {
|
|
2288
|
-
return {
|
|
2289
|
-
...(input.Text !== undefined && input.Text !== null && { Text: input.Text }),
|
|
2290
|
-
};
|
|
2291
|
-
};
|
|
2292
|
-
|
|
2293
|
-
const serializeAws_json1_1DetectEntitiesV2Request = (input: DetectEntitiesV2Request, context: __SerdeContext): any => {
|
|
2294
|
-
return {
|
|
2295
|
-
...(input.Text !== undefined && input.Text !== null && { Text: input.Text }),
|
|
2296
|
-
};
|
|
2297
|
-
};
|
|
2298
|
-
|
|
2299
|
-
const serializeAws_json1_1DetectPHIRequest = (input: DetectPHIRequest, context: __SerdeContext): any => {
|
|
2300
|
-
return {
|
|
2301
|
-
...(input.Text !== undefined && input.Text !== null && { Text: input.Text }),
|
|
2302
|
-
};
|
|
2303
|
-
};
|
|
2304
|
-
|
|
2305
|
-
const serializeAws_json1_1InferICD10CMRequest = (input: InferICD10CMRequest, context: __SerdeContext): any => {
|
|
2306
|
-
return {
|
|
2307
|
-
...(input.Text !== undefined && input.Text !== null && { Text: input.Text }),
|
|
2308
|
-
};
|
|
2309
|
-
};
|
|
2310
|
-
|
|
2311
|
-
const serializeAws_json1_1InferRxNormRequest = (input: InferRxNormRequest, context: __SerdeContext): any => {
|
|
2312
|
-
return {
|
|
2313
|
-
...(input.Text !== undefined && input.Text !== null && { Text: input.Text }),
|
|
2314
|
-
};
|
|
2315
|
-
};
|
|
2316
|
-
|
|
2317
|
-
const serializeAws_json1_1InputDataConfig = (input: InputDataConfig, context: __SerdeContext): any => {
|
|
2318
|
-
return {
|
|
2319
|
-
...(input.S3Bucket !== undefined && input.S3Bucket !== null && { S3Bucket: input.S3Bucket }),
|
|
2320
|
-
...(input.S3Key !== undefined && input.S3Key !== null && { S3Key: input.S3Key }),
|
|
2321
|
-
};
|
|
2322
|
-
};
|
|
2323
|
-
|
|
2324
|
-
const serializeAws_json1_1ListEntitiesDetectionV2JobsRequest = (
|
|
2325
|
-
input: ListEntitiesDetectionV2JobsRequest,
|
|
2326
|
-
context: __SerdeContext
|
|
2327
|
-
): any => {
|
|
2328
|
-
return {
|
|
2329
|
-
...(input.Filter !== undefined &&
|
|
2330
|
-
input.Filter !== null && { Filter: serializeAws_json1_1ComprehendMedicalAsyncJobFilter(input.Filter, context) }),
|
|
2331
|
-
...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }),
|
|
2332
|
-
...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
|
|
2333
|
-
};
|
|
2334
|
-
};
|
|
2335
|
-
|
|
2336
|
-
const serializeAws_json1_1ListICD10CMInferenceJobsRequest = (
|
|
2337
|
-
input: ListICD10CMInferenceJobsRequest,
|
|
2338
|
-
context: __SerdeContext
|
|
2339
|
-
): any => {
|
|
2340
|
-
return {
|
|
2341
|
-
...(input.Filter !== undefined &&
|
|
2342
|
-
input.Filter !== null && { Filter: serializeAws_json1_1ComprehendMedicalAsyncJobFilter(input.Filter, context) }),
|
|
2343
|
-
...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }),
|
|
2344
|
-
...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
|
|
2345
|
-
};
|
|
2346
|
-
};
|
|
2347
|
-
|
|
2348
|
-
const serializeAws_json1_1ListPHIDetectionJobsRequest = (
|
|
2349
|
-
input: ListPHIDetectionJobsRequest,
|
|
2350
|
-
context: __SerdeContext
|
|
2351
|
-
): any => {
|
|
2352
|
-
return {
|
|
2353
|
-
...(input.Filter !== undefined &&
|
|
2354
|
-
input.Filter !== null && { Filter: serializeAws_json1_1ComprehendMedicalAsyncJobFilter(input.Filter, context) }),
|
|
2355
|
-
...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }),
|
|
2356
|
-
...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
|
|
2357
|
-
};
|
|
2358
|
-
};
|
|
2359
|
-
|
|
2360
|
-
const serializeAws_json1_1ListRxNormInferenceJobsRequest = (
|
|
2361
|
-
input: ListRxNormInferenceJobsRequest,
|
|
2362
|
-
context: __SerdeContext
|
|
2363
|
-
): any => {
|
|
2364
|
-
return {
|
|
2365
|
-
...(input.Filter !== undefined &&
|
|
2366
|
-
input.Filter !== null && { Filter: serializeAws_json1_1ComprehendMedicalAsyncJobFilter(input.Filter, context) }),
|
|
2367
|
-
...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }),
|
|
2368
|
-
...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
|
|
2369
|
-
};
|
|
2370
|
-
};
|
|
2371
|
-
|
|
2372
|
-
const serializeAws_json1_1OutputDataConfig = (input: OutputDataConfig, context: __SerdeContext): any => {
|
|
2373
|
-
return {
|
|
2374
|
-
...(input.S3Bucket !== undefined && input.S3Bucket !== null && { S3Bucket: input.S3Bucket }),
|
|
2375
|
-
...(input.S3Key !== undefined && input.S3Key !== null && { S3Key: input.S3Key }),
|
|
2376
|
-
};
|
|
2377
|
-
};
|
|
2378
|
-
|
|
2379
|
-
const serializeAws_json1_1StartEntitiesDetectionV2JobRequest = (
|
|
2380
|
-
input: StartEntitiesDetectionV2JobRequest,
|
|
2381
|
-
context: __SerdeContext
|
|
2382
|
-
): any => {
|
|
2383
|
-
return {
|
|
2384
|
-
ClientRequestToken: input.ClientRequestToken ?? generateIdempotencyToken(),
|
|
2385
|
-
...(input.DataAccessRoleArn !== undefined &&
|
|
2386
|
-
input.DataAccessRoleArn !== null && { DataAccessRoleArn: input.DataAccessRoleArn }),
|
|
2387
|
-
...(input.InputDataConfig !== undefined &&
|
|
2388
|
-
input.InputDataConfig !== null && {
|
|
2389
|
-
InputDataConfig: serializeAws_json1_1InputDataConfig(input.InputDataConfig, context),
|
|
2390
|
-
}),
|
|
2391
|
-
...(input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName }),
|
|
2392
|
-
...(input.KMSKey !== undefined && input.KMSKey !== null && { KMSKey: input.KMSKey }),
|
|
2393
|
-
...(input.LanguageCode !== undefined && input.LanguageCode !== null && { LanguageCode: input.LanguageCode }),
|
|
2394
|
-
...(input.OutputDataConfig !== undefined &&
|
|
2395
|
-
input.OutputDataConfig !== null && {
|
|
2396
|
-
OutputDataConfig: serializeAws_json1_1OutputDataConfig(input.OutputDataConfig, context),
|
|
2397
|
-
}),
|
|
2398
|
-
};
|
|
2399
|
-
};
|
|
2400
|
-
|
|
2401
|
-
const serializeAws_json1_1StartICD10CMInferenceJobRequest = (
|
|
2402
|
-
input: StartICD10CMInferenceJobRequest,
|
|
2403
|
-
context: __SerdeContext
|
|
2404
|
-
): any => {
|
|
2405
|
-
return {
|
|
2406
|
-
ClientRequestToken: input.ClientRequestToken ?? generateIdempotencyToken(),
|
|
2407
|
-
...(input.DataAccessRoleArn !== undefined &&
|
|
2408
|
-
input.DataAccessRoleArn !== null && { DataAccessRoleArn: input.DataAccessRoleArn }),
|
|
2409
|
-
...(input.InputDataConfig !== undefined &&
|
|
2410
|
-
input.InputDataConfig !== null && {
|
|
2411
|
-
InputDataConfig: serializeAws_json1_1InputDataConfig(input.InputDataConfig, context),
|
|
2412
|
-
}),
|
|
2413
|
-
...(input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName }),
|
|
2414
|
-
...(input.KMSKey !== undefined && input.KMSKey !== null && { KMSKey: input.KMSKey }),
|
|
2415
|
-
...(input.LanguageCode !== undefined && input.LanguageCode !== null && { LanguageCode: input.LanguageCode }),
|
|
2416
|
-
...(input.OutputDataConfig !== undefined &&
|
|
2417
|
-
input.OutputDataConfig !== null && {
|
|
2418
|
-
OutputDataConfig: serializeAws_json1_1OutputDataConfig(input.OutputDataConfig, context),
|
|
2419
|
-
}),
|
|
2420
|
-
};
|
|
2421
|
-
};
|
|
2422
|
-
|
|
2423
|
-
const serializeAws_json1_1StartPHIDetectionJobRequest = (
|
|
2424
|
-
input: StartPHIDetectionJobRequest,
|
|
2425
|
-
context: __SerdeContext
|
|
2426
|
-
): any => {
|
|
2427
|
-
return {
|
|
2428
|
-
ClientRequestToken: input.ClientRequestToken ?? generateIdempotencyToken(),
|
|
2429
|
-
...(input.DataAccessRoleArn !== undefined &&
|
|
2430
|
-
input.DataAccessRoleArn !== null && { DataAccessRoleArn: input.DataAccessRoleArn }),
|
|
2431
|
-
...(input.InputDataConfig !== undefined &&
|
|
2432
|
-
input.InputDataConfig !== null && {
|
|
2433
|
-
InputDataConfig: serializeAws_json1_1InputDataConfig(input.InputDataConfig, context),
|
|
2434
|
-
}),
|
|
2435
|
-
...(input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName }),
|
|
2436
|
-
...(input.KMSKey !== undefined && input.KMSKey !== null && { KMSKey: input.KMSKey }),
|
|
2437
|
-
...(input.LanguageCode !== undefined && input.LanguageCode !== null && { LanguageCode: input.LanguageCode }),
|
|
2438
|
-
...(input.OutputDataConfig !== undefined &&
|
|
2439
|
-
input.OutputDataConfig !== null && {
|
|
2440
|
-
OutputDataConfig: serializeAws_json1_1OutputDataConfig(input.OutputDataConfig, context),
|
|
2441
|
-
}),
|
|
2442
|
-
};
|
|
2443
|
-
};
|
|
2444
|
-
|
|
2445
|
-
const serializeAws_json1_1StartRxNormInferenceJobRequest = (
|
|
2446
|
-
input: StartRxNormInferenceJobRequest,
|
|
2447
|
-
context: __SerdeContext
|
|
2448
|
-
): any => {
|
|
2449
|
-
return {
|
|
2450
|
-
ClientRequestToken: input.ClientRequestToken ?? generateIdempotencyToken(),
|
|
2451
|
-
...(input.DataAccessRoleArn !== undefined &&
|
|
2452
|
-
input.DataAccessRoleArn !== null && { DataAccessRoleArn: input.DataAccessRoleArn }),
|
|
2453
|
-
...(input.InputDataConfig !== undefined &&
|
|
2454
|
-
input.InputDataConfig !== null && {
|
|
2455
|
-
InputDataConfig: serializeAws_json1_1InputDataConfig(input.InputDataConfig, context),
|
|
2456
|
-
}),
|
|
2457
|
-
...(input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName }),
|
|
2458
|
-
...(input.KMSKey !== undefined && input.KMSKey !== null && { KMSKey: input.KMSKey }),
|
|
2459
|
-
...(input.LanguageCode !== undefined && input.LanguageCode !== null && { LanguageCode: input.LanguageCode }),
|
|
2460
|
-
...(input.OutputDataConfig !== undefined &&
|
|
2461
|
-
input.OutputDataConfig !== null && {
|
|
2462
|
-
OutputDataConfig: serializeAws_json1_1OutputDataConfig(input.OutputDataConfig, context),
|
|
2463
|
-
}),
|
|
2464
|
-
};
|
|
2465
|
-
};
|
|
2466
|
-
|
|
2467
|
-
const serializeAws_json1_1StopEntitiesDetectionV2JobRequest = (
|
|
2468
|
-
input: StopEntitiesDetectionV2JobRequest,
|
|
2469
|
-
context: __SerdeContext
|
|
2470
|
-
): any => {
|
|
2471
|
-
return {
|
|
2472
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2473
|
-
};
|
|
2474
|
-
};
|
|
2475
|
-
|
|
2476
|
-
const serializeAws_json1_1StopICD10CMInferenceJobRequest = (
|
|
2477
|
-
input: StopICD10CMInferenceJobRequest,
|
|
2478
|
-
context: __SerdeContext
|
|
2479
|
-
): any => {
|
|
2480
|
-
return {
|
|
2481
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2482
|
-
};
|
|
2483
|
-
};
|
|
2484
|
-
|
|
2485
|
-
const serializeAws_json1_1StopPHIDetectionJobRequest = (
|
|
2486
|
-
input: StopPHIDetectionJobRequest,
|
|
2487
|
-
context: __SerdeContext
|
|
2488
|
-
): any => {
|
|
2489
|
-
return {
|
|
2490
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2491
|
-
};
|
|
2492
|
-
};
|
|
2493
|
-
|
|
2494
|
-
const serializeAws_json1_1StopRxNormInferenceJobRequest = (
|
|
2495
|
-
input: StopRxNormInferenceJobRequest,
|
|
2496
|
-
context: __SerdeContext
|
|
2497
|
-
): any => {
|
|
2498
|
-
return {
|
|
2499
|
-
...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }),
|
|
2500
|
-
};
|
|
2501
|
-
};
|
|
2502
|
-
|
|
2503
|
-
const deserializeAws_json1_1Attribute = (output: any, context: __SerdeContext): Attribute => {
|
|
2504
|
-
return {
|
|
2505
|
-
BeginOffset: __expectInt32(output.BeginOffset),
|
|
2506
|
-
Category: __expectString(output.Category),
|
|
2507
|
-
EndOffset: __expectInt32(output.EndOffset),
|
|
2508
|
-
Id: __expectInt32(output.Id),
|
|
2509
|
-
RelationshipScore: __limitedParseFloat32(output.RelationshipScore),
|
|
2510
|
-
RelationshipType: __expectString(output.RelationshipType),
|
|
2511
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2512
|
-
Text: __expectString(output.Text),
|
|
2513
|
-
Traits:
|
|
2514
|
-
output.Traits !== undefined && output.Traits !== null
|
|
2515
|
-
? deserializeAws_json1_1TraitList(output.Traits, context)
|
|
2516
|
-
: undefined,
|
|
2517
|
-
Type: __expectString(output.Type),
|
|
2518
|
-
} as any;
|
|
2519
|
-
};
|
|
2520
|
-
|
|
2521
|
-
const deserializeAws_json1_1AttributeList = (output: any, context: __SerdeContext): Attribute[] => {
|
|
2522
|
-
return (output || [])
|
|
2523
|
-
.filter((e: any) => e != null)
|
|
2524
|
-
.map((entry: any) => {
|
|
2525
|
-
if (entry === null) {
|
|
2526
|
-
return null as any;
|
|
2527
|
-
}
|
|
2528
|
-
return deserializeAws_json1_1Attribute(entry, context);
|
|
2529
|
-
});
|
|
2530
|
-
};
|
|
2531
|
-
|
|
2532
|
-
const deserializeAws_json1_1ComprehendMedicalAsyncJobProperties = (
|
|
2533
|
-
output: any,
|
|
2534
|
-
context: __SerdeContext
|
|
2535
|
-
): ComprehendMedicalAsyncJobProperties => {
|
|
2536
|
-
return {
|
|
2537
|
-
DataAccessRoleArn: __expectString(output.DataAccessRoleArn),
|
|
2538
|
-
EndTime:
|
|
2539
|
-
output.EndTime !== undefined && output.EndTime !== null
|
|
2540
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.EndTime)))
|
|
2541
|
-
: undefined,
|
|
2542
|
-
ExpirationTime:
|
|
2543
|
-
output.ExpirationTime !== undefined && output.ExpirationTime !== null
|
|
2544
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.ExpirationTime)))
|
|
2545
|
-
: undefined,
|
|
2546
|
-
InputDataConfig:
|
|
2547
|
-
output.InputDataConfig !== undefined && output.InputDataConfig !== null
|
|
2548
|
-
? deserializeAws_json1_1InputDataConfig(output.InputDataConfig, context)
|
|
2549
|
-
: undefined,
|
|
2550
|
-
JobId: __expectString(output.JobId),
|
|
2551
|
-
JobName: __expectString(output.JobName),
|
|
2552
|
-
JobStatus: __expectString(output.JobStatus),
|
|
2553
|
-
KMSKey: __expectString(output.KMSKey),
|
|
2554
|
-
LanguageCode: __expectString(output.LanguageCode),
|
|
2555
|
-
ManifestFilePath: __expectString(output.ManifestFilePath),
|
|
2556
|
-
Message: __expectString(output.Message),
|
|
2557
|
-
ModelVersion: __expectString(output.ModelVersion),
|
|
2558
|
-
OutputDataConfig:
|
|
2559
|
-
output.OutputDataConfig !== undefined && output.OutputDataConfig !== null
|
|
2560
|
-
? deserializeAws_json1_1OutputDataConfig(output.OutputDataConfig, context)
|
|
2561
|
-
: undefined,
|
|
2562
|
-
SubmitTime:
|
|
2563
|
-
output.SubmitTime !== undefined && output.SubmitTime !== null
|
|
2564
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.SubmitTime)))
|
|
2565
|
-
: undefined,
|
|
2566
|
-
} as any;
|
|
2567
|
-
};
|
|
2568
|
-
|
|
2569
|
-
const deserializeAws_json1_1ComprehendMedicalAsyncJobPropertiesList = (
|
|
2570
|
-
output: any,
|
|
2571
|
-
context: __SerdeContext
|
|
2572
|
-
): ComprehendMedicalAsyncJobProperties[] => {
|
|
2573
|
-
return (output || [])
|
|
2574
|
-
.filter((e: any) => e != null)
|
|
2575
|
-
.map((entry: any) => {
|
|
2576
|
-
if (entry === null) {
|
|
2577
|
-
return null as any;
|
|
2578
|
-
}
|
|
2579
|
-
return deserializeAws_json1_1ComprehendMedicalAsyncJobProperties(entry, context);
|
|
2580
|
-
});
|
|
2581
|
-
};
|
|
2582
|
-
|
|
2583
|
-
const deserializeAws_json1_1DescribeEntitiesDetectionV2JobResponse = (
|
|
2584
|
-
output: any,
|
|
2585
|
-
context: __SerdeContext
|
|
2586
|
-
): DescribeEntitiesDetectionV2JobResponse => {
|
|
2587
|
-
return {
|
|
2588
|
-
ComprehendMedicalAsyncJobProperties:
|
|
2589
|
-
output.ComprehendMedicalAsyncJobProperties !== undefined && output.ComprehendMedicalAsyncJobProperties !== null
|
|
2590
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobProperties(output.ComprehendMedicalAsyncJobProperties, context)
|
|
2591
|
-
: undefined,
|
|
2592
|
-
} as any;
|
|
2593
|
-
};
|
|
2594
|
-
|
|
2595
|
-
const deserializeAws_json1_1DescribeICD10CMInferenceJobResponse = (
|
|
2596
|
-
output: any,
|
|
2597
|
-
context: __SerdeContext
|
|
2598
|
-
): DescribeICD10CMInferenceJobResponse => {
|
|
2599
|
-
return {
|
|
2600
|
-
ComprehendMedicalAsyncJobProperties:
|
|
2601
|
-
output.ComprehendMedicalAsyncJobProperties !== undefined && output.ComprehendMedicalAsyncJobProperties !== null
|
|
2602
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobProperties(output.ComprehendMedicalAsyncJobProperties, context)
|
|
2603
|
-
: undefined,
|
|
2604
|
-
} as any;
|
|
2605
|
-
};
|
|
2606
|
-
|
|
2607
|
-
const deserializeAws_json1_1DescribePHIDetectionJobResponse = (
|
|
2608
|
-
output: any,
|
|
2609
|
-
context: __SerdeContext
|
|
2610
|
-
): DescribePHIDetectionJobResponse => {
|
|
2611
|
-
return {
|
|
2612
|
-
ComprehendMedicalAsyncJobProperties:
|
|
2613
|
-
output.ComprehendMedicalAsyncJobProperties !== undefined && output.ComprehendMedicalAsyncJobProperties !== null
|
|
2614
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobProperties(output.ComprehendMedicalAsyncJobProperties, context)
|
|
2615
|
-
: undefined,
|
|
2616
|
-
} as any;
|
|
2617
|
-
};
|
|
2618
|
-
|
|
2619
|
-
const deserializeAws_json1_1DescribeRxNormInferenceJobResponse = (
|
|
2620
|
-
output: any,
|
|
2621
|
-
context: __SerdeContext
|
|
2622
|
-
): DescribeRxNormInferenceJobResponse => {
|
|
2623
|
-
return {
|
|
2624
|
-
ComprehendMedicalAsyncJobProperties:
|
|
2625
|
-
output.ComprehendMedicalAsyncJobProperties !== undefined && output.ComprehendMedicalAsyncJobProperties !== null
|
|
2626
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobProperties(output.ComprehendMedicalAsyncJobProperties, context)
|
|
2627
|
-
: undefined,
|
|
2628
|
-
} as any;
|
|
2629
|
-
};
|
|
2630
|
-
|
|
2631
|
-
const deserializeAws_json1_1DetectEntitiesResponse = (output: any, context: __SerdeContext): DetectEntitiesResponse => {
|
|
2632
|
-
return {
|
|
2633
|
-
Entities:
|
|
2634
|
-
output.Entities !== undefined && output.Entities !== null
|
|
2635
|
-
? deserializeAws_json1_1EntityList(output.Entities, context)
|
|
2636
|
-
: undefined,
|
|
2637
|
-
ModelVersion: __expectString(output.ModelVersion),
|
|
2638
|
-
PaginationToken: __expectString(output.PaginationToken),
|
|
2639
|
-
UnmappedAttributes:
|
|
2640
|
-
output.UnmappedAttributes !== undefined && output.UnmappedAttributes !== null
|
|
2641
|
-
? deserializeAws_json1_1UnmappedAttributeList(output.UnmappedAttributes, context)
|
|
2642
|
-
: undefined,
|
|
2643
|
-
} as any;
|
|
2644
|
-
};
|
|
2645
|
-
|
|
2646
|
-
const deserializeAws_json1_1DetectEntitiesV2Response = (
|
|
2647
|
-
output: any,
|
|
2648
|
-
context: __SerdeContext
|
|
2649
|
-
): DetectEntitiesV2Response => {
|
|
2650
|
-
return {
|
|
2651
|
-
Entities:
|
|
2652
|
-
output.Entities !== undefined && output.Entities !== null
|
|
2653
|
-
? deserializeAws_json1_1EntityList(output.Entities, context)
|
|
2654
|
-
: undefined,
|
|
2655
|
-
ModelVersion: __expectString(output.ModelVersion),
|
|
2656
|
-
PaginationToken: __expectString(output.PaginationToken),
|
|
2657
|
-
UnmappedAttributes:
|
|
2658
|
-
output.UnmappedAttributes !== undefined && output.UnmappedAttributes !== null
|
|
2659
|
-
? deserializeAws_json1_1UnmappedAttributeList(output.UnmappedAttributes, context)
|
|
2660
|
-
: undefined,
|
|
2661
|
-
} as any;
|
|
2662
|
-
};
|
|
2663
|
-
|
|
2664
|
-
const deserializeAws_json1_1DetectPHIResponse = (output: any, context: __SerdeContext): DetectPHIResponse => {
|
|
2665
|
-
return {
|
|
2666
|
-
Entities:
|
|
2667
|
-
output.Entities !== undefined && output.Entities !== null
|
|
2668
|
-
? deserializeAws_json1_1EntityList(output.Entities, context)
|
|
2669
|
-
: undefined,
|
|
2670
|
-
ModelVersion: __expectString(output.ModelVersion),
|
|
2671
|
-
PaginationToken: __expectString(output.PaginationToken),
|
|
2672
|
-
} as any;
|
|
2673
|
-
};
|
|
2674
|
-
|
|
2675
|
-
const deserializeAws_json1_1Entity = (output: any, context: __SerdeContext): Entity => {
|
|
2676
|
-
return {
|
|
2677
|
-
Attributes:
|
|
2678
|
-
output.Attributes !== undefined && output.Attributes !== null
|
|
2679
|
-
? deserializeAws_json1_1AttributeList(output.Attributes, context)
|
|
2680
|
-
: undefined,
|
|
2681
|
-
BeginOffset: __expectInt32(output.BeginOffset),
|
|
2682
|
-
Category: __expectString(output.Category),
|
|
2683
|
-
EndOffset: __expectInt32(output.EndOffset),
|
|
2684
|
-
Id: __expectInt32(output.Id),
|
|
2685
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2686
|
-
Text: __expectString(output.Text),
|
|
2687
|
-
Traits:
|
|
2688
|
-
output.Traits !== undefined && output.Traits !== null
|
|
2689
|
-
? deserializeAws_json1_1TraitList(output.Traits, context)
|
|
2690
|
-
: undefined,
|
|
2691
|
-
Type: __expectString(output.Type),
|
|
2692
|
-
} as any;
|
|
2693
|
-
};
|
|
2694
|
-
|
|
2695
|
-
const deserializeAws_json1_1EntityList = (output: any, context: __SerdeContext): Entity[] => {
|
|
2696
|
-
return (output || [])
|
|
2697
|
-
.filter((e: any) => e != null)
|
|
2698
|
-
.map((entry: any) => {
|
|
2699
|
-
if (entry === null) {
|
|
2700
|
-
return null as any;
|
|
2701
|
-
}
|
|
2702
|
-
return deserializeAws_json1_1Entity(entry, context);
|
|
2703
|
-
});
|
|
2704
|
-
};
|
|
2705
|
-
|
|
2706
|
-
const deserializeAws_json1_1ICD10CMAttribute = (output: any, context: __SerdeContext): ICD10CMAttribute => {
|
|
2707
|
-
return {
|
|
2708
|
-
BeginOffset: __expectInt32(output.BeginOffset),
|
|
2709
|
-
Category: __expectString(output.Category),
|
|
2710
|
-
EndOffset: __expectInt32(output.EndOffset),
|
|
2711
|
-
Id: __expectInt32(output.Id),
|
|
2712
|
-
RelationshipScore: __limitedParseFloat32(output.RelationshipScore),
|
|
2713
|
-
RelationshipType: __expectString(output.RelationshipType),
|
|
2714
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2715
|
-
Text: __expectString(output.Text),
|
|
2716
|
-
Traits:
|
|
2717
|
-
output.Traits !== undefined && output.Traits !== null
|
|
2718
|
-
? deserializeAws_json1_1ICD10CMTraitList(output.Traits, context)
|
|
2719
|
-
: undefined,
|
|
2720
|
-
Type: __expectString(output.Type),
|
|
2721
|
-
} as any;
|
|
2722
|
-
};
|
|
2723
|
-
|
|
2724
|
-
const deserializeAws_json1_1ICD10CMAttributeList = (output: any, context: __SerdeContext): ICD10CMAttribute[] => {
|
|
2725
|
-
return (output || [])
|
|
2726
|
-
.filter((e: any) => e != null)
|
|
2727
|
-
.map((entry: any) => {
|
|
2728
|
-
if (entry === null) {
|
|
2729
|
-
return null as any;
|
|
2730
|
-
}
|
|
2731
|
-
return deserializeAws_json1_1ICD10CMAttribute(entry, context);
|
|
2732
|
-
});
|
|
2733
|
-
};
|
|
2734
|
-
|
|
2735
|
-
const deserializeAws_json1_1ICD10CMConcept = (output: any, context: __SerdeContext): ICD10CMConcept => {
|
|
2736
|
-
return {
|
|
2737
|
-
Code: __expectString(output.Code),
|
|
2738
|
-
Description: __expectString(output.Description),
|
|
2739
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2740
|
-
} as any;
|
|
2741
|
-
};
|
|
2742
|
-
|
|
2743
|
-
const deserializeAws_json1_1ICD10CMConceptList = (output: any, context: __SerdeContext): ICD10CMConcept[] => {
|
|
2744
|
-
return (output || [])
|
|
2745
|
-
.filter((e: any) => e != null)
|
|
2746
|
-
.map((entry: any) => {
|
|
2747
|
-
if (entry === null) {
|
|
2748
|
-
return null as any;
|
|
2749
|
-
}
|
|
2750
|
-
return deserializeAws_json1_1ICD10CMConcept(entry, context);
|
|
2751
|
-
});
|
|
2752
|
-
};
|
|
2753
|
-
|
|
2754
|
-
const deserializeAws_json1_1ICD10CMEntity = (output: any, context: __SerdeContext): ICD10CMEntity => {
|
|
2755
|
-
return {
|
|
2756
|
-
Attributes:
|
|
2757
|
-
output.Attributes !== undefined && output.Attributes !== null
|
|
2758
|
-
? deserializeAws_json1_1ICD10CMAttributeList(output.Attributes, context)
|
|
2759
|
-
: undefined,
|
|
2760
|
-
BeginOffset: __expectInt32(output.BeginOffset),
|
|
2761
|
-
Category: __expectString(output.Category),
|
|
2762
|
-
EndOffset: __expectInt32(output.EndOffset),
|
|
2763
|
-
ICD10CMConcepts:
|
|
2764
|
-
output.ICD10CMConcepts !== undefined && output.ICD10CMConcepts !== null
|
|
2765
|
-
? deserializeAws_json1_1ICD10CMConceptList(output.ICD10CMConcepts, context)
|
|
2766
|
-
: undefined,
|
|
2767
|
-
Id: __expectInt32(output.Id),
|
|
2768
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2769
|
-
Text: __expectString(output.Text),
|
|
2770
|
-
Traits:
|
|
2771
|
-
output.Traits !== undefined && output.Traits !== null
|
|
2772
|
-
? deserializeAws_json1_1ICD10CMTraitList(output.Traits, context)
|
|
2773
|
-
: undefined,
|
|
2774
|
-
Type: __expectString(output.Type),
|
|
2775
|
-
} as any;
|
|
2776
|
-
};
|
|
2777
|
-
|
|
2778
|
-
const deserializeAws_json1_1ICD10CMEntityList = (output: any, context: __SerdeContext): ICD10CMEntity[] => {
|
|
2779
|
-
return (output || [])
|
|
2780
|
-
.filter((e: any) => e != null)
|
|
2781
|
-
.map((entry: any) => {
|
|
2782
|
-
if (entry === null) {
|
|
2783
|
-
return null as any;
|
|
2784
|
-
}
|
|
2785
|
-
return deserializeAws_json1_1ICD10CMEntity(entry, context);
|
|
2786
|
-
});
|
|
2787
|
-
};
|
|
2788
|
-
|
|
2789
|
-
const deserializeAws_json1_1ICD10CMTrait = (output: any, context: __SerdeContext): ICD10CMTrait => {
|
|
2790
|
-
return {
|
|
2791
|
-
Name: __expectString(output.Name),
|
|
2792
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2793
|
-
} as any;
|
|
2794
|
-
};
|
|
2795
|
-
|
|
2796
|
-
const deserializeAws_json1_1ICD10CMTraitList = (output: any, context: __SerdeContext): ICD10CMTrait[] => {
|
|
2797
|
-
return (output || [])
|
|
2798
|
-
.filter((e: any) => e != null)
|
|
2799
|
-
.map((entry: any) => {
|
|
2800
|
-
if (entry === null) {
|
|
2801
|
-
return null as any;
|
|
2802
|
-
}
|
|
2803
|
-
return deserializeAws_json1_1ICD10CMTrait(entry, context);
|
|
2804
|
-
});
|
|
2805
|
-
};
|
|
2806
|
-
|
|
2807
|
-
const deserializeAws_json1_1InferICD10CMResponse = (output: any, context: __SerdeContext): InferICD10CMResponse => {
|
|
2808
|
-
return {
|
|
2809
|
-
Entities:
|
|
2810
|
-
output.Entities !== undefined && output.Entities !== null
|
|
2811
|
-
? deserializeAws_json1_1ICD10CMEntityList(output.Entities, context)
|
|
2812
|
-
: undefined,
|
|
2813
|
-
ModelVersion: __expectString(output.ModelVersion),
|
|
2814
|
-
PaginationToken: __expectString(output.PaginationToken),
|
|
2815
|
-
} as any;
|
|
2816
|
-
};
|
|
2817
|
-
|
|
2818
|
-
const deserializeAws_json1_1InferRxNormResponse = (output: any, context: __SerdeContext): InferRxNormResponse => {
|
|
2819
|
-
return {
|
|
2820
|
-
Entities:
|
|
2821
|
-
output.Entities !== undefined && output.Entities !== null
|
|
2822
|
-
? deserializeAws_json1_1RxNormEntityList(output.Entities, context)
|
|
2823
|
-
: undefined,
|
|
2824
|
-
ModelVersion: __expectString(output.ModelVersion),
|
|
2825
|
-
PaginationToken: __expectString(output.PaginationToken),
|
|
2826
|
-
} as any;
|
|
2827
|
-
};
|
|
2828
|
-
|
|
2829
|
-
const deserializeAws_json1_1InputDataConfig = (output: any, context: __SerdeContext): InputDataConfig => {
|
|
2830
|
-
return {
|
|
2831
|
-
S3Bucket: __expectString(output.S3Bucket),
|
|
2832
|
-
S3Key: __expectString(output.S3Key),
|
|
2833
|
-
} as any;
|
|
2834
|
-
};
|
|
2835
|
-
|
|
2836
|
-
const deserializeAws_json1_1InternalServerException = (
|
|
2837
|
-
output: any,
|
|
2838
|
-
context: __SerdeContext
|
|
2839
|
-
): InternalServerException => {
|
|
2840
|
-
return {
|
|
2841
|
-
Message: __expectString(output.Message),
|
|
2842
|
-
} as any;
|
|
2843
|
-
};
|
|
2844
|
-
|
|
2845
|
-
const deserializeAws_json1_1InvalidEncodingException = (
|
|
2846
|
-
output: any,
|
|
2847
|
-
context: __SerdeContext
|
|
2848
|
-
): InvalidEncodingException => {
|
|
2849
|
-
return {
|
|
2850
|
-
Message: __expectString(output.Message),
|
|
2851
|
-
} as any;
|
|
2852
|
-
};
|
|
2853
|
-
|
|
2854
|
-
const deserializeAws_json1_1InvalidRequestException = (
|
|
2855
|
-
output: any,
|
|
2856
|
-
context: __SerdeContext
|
|
2857
|
-
): InvalidRequestException => {
|
|
2858
|
-
return {
|
|
2859
|
-
Message: __expectString(output.Message),
|
|
2860
|
-
} as any;
|
|
2861
|
-
};
|
|
2862
|
-
|
|
2863
|
-
const deserializeAws_json1_1ListEntitiesDetectionV2JobsResponse = (
|
|
2864
|
-
output: any,
|
|
2865
|
-
context: __SerdeContext
|
|
2866
|
-
): ListEntitiesDetectionV2JobsResponse => {
|
|
2867
|
-
return {
|
|
2868
|
-
ComprehendMedicalAsyncJobPropertiesList:
|
|
2869
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== undefined &&
|
|
2870
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== null
|
|
2871
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobPropertiesList(
|
|
2872
|
-
output.ComprehendMedicalAsyncJobPropertiesList,
|
|
2873
|
-
context
|
|
2874
|
-
)
|
|
2875
|
-
: undefined,
|
|
2876
|
-
NextToken: __expectString(output.NextToken),
|
|
2877
|
-
} as any;
|
|
2878
|
-
};
|
|
2879
|
-
|
|
2880
|
-
const deserializeAws_json1_1ListICD10CMInferenceJobsResponse = (
|
|
2881
|
-
output: any,
|
|
2882
|
-
context: __SerdeContext
|
|
2883
|
-
): ListICD10CMInferenceJobsResponse => {
|
|
2884
|
-
return {
|
|
2885
|
-
ComprehendMedicalAsyncJobPropertiesList:
|
|
2886
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== undefined &&
|
|
2887
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== null
|
|
2888
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobPropertiesList(
|
|
2889
|
-
output.ComprehendMedicalAsyncJobPropertiesList,
|
|
2890
|
-
context
|
|
2891
|
-
)
|
|
2892
|
-
: undefined,
|
|
2893
|
-
NextToken: __expectString(output.NextToken),
|
|
2894
|
-
} as any;
|
|
2895
|
-
};
|
|
2896
|
-
|
|
2897
|
-
const deserializeAws_json1_1ListPHIDetectionJobsResponse = (
|
|
2898
|
-
output: any,
|
|
2899
|
-
context: __SerdeContext
|
|
2900
|
-
): ListPHIDetectionJobsResponse => {
|
|
2901
|
-
return {
|
|
2902
|
-
ComprehendMedicalAsyncJobPropertiesList:
|
|
2903
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== undefined &&
|
|
2904
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== null
|
|
2905
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobPropertiesList(
|
|
2906
|
-
output.ComprehendMedicalAsyncJobPropertiesList,
|
|
2907
|
-
context
|
|
2908
|
-
)
|
|
2909
|
-
: undefined,
|
|
2910
|
-
NextToken: __expectString(output.NextToken),
|
|
2911
|
-
} as any;
|
|
2912
|
-
};
|
|
2913
|
-
|
|
2914
|
-
const deserializeAws_json1_1ListRxNormInferenceJobsResponse = (
|
|
2915
|
-
output: any,
|
|
2916
|
-
context: __SerdeContext
|
|
2917
|
-
): ListRxNormInferenceJobsResponse => {
|
|
2918
|
-
return {
|
|
2919
|
-
ComprehendMedicalAsyncJobPropertiesList:
|
|
2920
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== undefined &&
|
|
2921
|
-
output.ComprehendMedicalAsyncJobPropertiesList !== null
|
|
2922
|
-
? deserializeAws_json1_1ComprehendMedicalAsyncJobPropertiesList(
|
|
2923
|
-
output.ComprehendMedicalAsyncJobPropertiesList,
|
|
2924
|
-
context
|
|
2925
|
-
)
|
|
2926
|
-
: undefined,
|
|
2927
|
-
NextToken: __expectString(output.NextToken),
|
|
2928
|
-
} as any;
|
|
2929
|
-
};
|
|
2930
|
-
|
|
2931
|
-
const deserializeAws_json1_1OutputDataConfig = (output: any, context: __SerdeContext): OutputDataConfig => {
|
|
2932
|
-
return {
|
|
2933
|
-
S3Bucket: __expectString(output.S3Bucket),
|
|
2934
|
-
S3Key: __expectString(output.S3Key),
|
|
2935
|
-
} as any;
|
|
2936
|
-
};
|
|
2937
|
-
|
|
2938
|
-
const deserializeAws_json1_1ResourceNotFoundException = (
|
|
2939
|
-
output: any,
|
|
2940
|
-
context: __SerdeContext
|
|
2941
|
-
): ResourceNotFoundException => {
|
|
2942
|
-
return {
|
|
2943
|
-
Message: __expectString(output.Message),
|
|
2944
|
-
} as any;
|
|
2945
|
-
};
|
|
2946
|
-
|
|
2947
|
-
const deserializeAws_json1_1RxNormAttribute = (output: any, context: __SerdeContext): RxNormAttribute => {
|
|
2948
|
-
return {
|
|
2949
|
-
BeginOffset: __expectInt32(output.BeginOffset),
|
|
2950
|
-
EndOffset: __expectInt32(output.EndOffset),
|
|
2951
|
-
Id: __expectInt32(output.Id),
|
|
2952
|
-
RelationshipScore: __limitedParseFloat32(output.RelationshipScore),
|
|
2953
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2954
|
-
Text: __expectString(output.Text),
|
|
2955
|
-
Traits:
|
|
2956
|
-
output.Traits !== undefined && output.Traits !== null
|
|
2957
|
-
? deserializeAws_json1_1RxNormTraitList(output.Traits, context)
|
|
2958
|
-
: undefined,
|
|
2959
|
-
Type: __expectString(output.Type),
|
|
2960
|
-
} as any;
|
|
2961
|
-
};
|
|
2962
|
-
|
|
2963
|
-
const deserializeAws_json1_1RxNormAttributeList = (output: any, context: __SerdeContext): RxNormAttribute[] => {
|
|
2964
|
-
return (output || [])
|
|
2965
|
-
.filter((e: any) => e != null)
|
|
2966
|
-
.map((entry: any) => {
|
|
2967
|
-
if (entry === null) {
|
|
2968
|
-
return null as any;
|
|
2969
|
-
}
|
|
2970
|
-
return deserializeAws_json1_1RxNormAttribute(entry, context);
|
|
2971
|
-
});
|
|
2972
|
-
};
|
|
2973
|
-
|
|
2974
|
-
const deserializeAws_json1_1RxNormConcept = (output: any, context: __SerdeContext): RxNormConcept => {
|
|
2975
|
-
return {
|
|
2976
|
-
Code: __expectString(output.Code),
|
|
2977
|
-
Description: __expectString(output.Description),
|
|
2978
|
-
Score: __limitedParseFloat32(output.Score),
|
|
2979
|
-
} as any;
|
|
2980
|
-
};
|
|
2981
|
-
|
|
2982
|
-
const deserializeAws_json1_1RxNormConceptList = (output: any, context: __SerdeContext): RxNormConcept[] => {
|
|
2983
|
-
return (output || [])
|
|
2984
|
-
.filter((e: any) => e != null)
|
|
2985
|
-
.map((entry: any) => {
|
|
2986
|
-
if (entry === null) {
|
|
2987
|
-
return null as any;
|
|
2988
|
-
}
|
|
2989
|
-
return deserializeAws_json1_1RxNormConcept(entry, context);
|
|
2990
|
-
});
|
|
2991
|
-
};
|
|
2992
|
-
|
|
2993
|
-
const deserializeAws_json1_1RxNormEntity = (output: any, context: __SerdeContext): RxNormEntity => {
|
|
2994
|
-
return {
|
|
2995
|
-
Attributes:
|
|
2996
|
-
output.Attributes !== undefined && output.Attributes !== null
|
|
2997
|
-
? deserializeAws_json1_1RxNormAttributeList(output.Attributes, context)
|
|
2998
|
-
: undefined,
|
|
2999
|
-
BeginOffset: __expectInt32(output.BeginOffset),
|
|
3000
|
-
Category: __expectString(output.Category),
|
|
3001
|
-
EndOffset: __expectInt32(output.EndOffset),
|
|
3002
|
-
Id: __expectInt32(output.Id),
|
|
3003
|
-
RxNormConcepts:
|
|
3004
|
-
output.RxNormConcepts !== undefined && output.RxNormConcepts !== null
|
|
3005
|
-
? deserializeAws_json1_1RxNormConceptList(output.RxNormConcepts, context)
|
|
3006
|
-
: undefined,
|
|
3007
|
-
Score: __limitedParseFloat32(output.Score),
|
|
3008
|
-
Text: __expectString(output.Text),
|
|
3009
|
-
Traits:
|
|
3010
|
-
output.Traits !== undefined && output.Traits !== null
|
|
3011
|
-
? deserializeAws_json1_1RxNormTraitList(output.Traits, context)
|
|
3012
|
-
: undefined,
|
|
3013
|
-
Type: __expectString(output.Type),
|
|
3014
|
-
} as any;
|
|
3015
|
-
};
|
|
3016
|
-
|
|
3017
|
-
const deserializeAws_json1_1RxNormEntityList = (output: any, context: __SerdeContext): RxNormEntity[] => {
|
|
3018
|
-
return (output || [])
|
|
3019
|
-
.filter((e: any) => e != null)
|
|
3020
|
-
.map((entry: any) => {
|
|
3021
|
-
if (entry === null) {
|
|
3022
|
-
return null as any;
|
|
3023
|
-
}
|
|
3024
|
-
return deserializeAws_json1_1RxNormEntity(entry, context);
|
|
3025
|
-
});
|
|
3026
|
-
};
|
|
3027
|
-
|
|
3028
|
-
const deserializeAws_json1_1RxNormTrait = (output: any, context: __SerdeContext): RxNormTrait => {
|
|
3029
|
-
return {
|
|
3030
|
-
Name: __expectString(output.Name),
|
|
3031
|
-
Score: __limitedParseFloat32(output.Score),
|
|
3032
|
-
} as any;
|
|
3033
|
-
};
|
|
3034
|
-
|
|
3035
|
-
const deserializeAws_json1_1RxNormTraitList = (output: any, context: __SerdeContext): RxNormTrait[] => {
|
|
3036
|
-
return (output || [])
|
|
3037
|
-
.filter((e: any) => e != null)
|
|
3038
|
-
.map((entry: any) => {
|
|
3039
|
-
if (entry === null) {
|
|
3040
|
-
return null as any;
|
|
3041
|
-
}
|
|
3042
|
-
return deserializeAws_json1_1RxNormTrait(entry, context);
|
|
3043
|
-
});
|
|
3044
|
-
};
|
|
3045
|
-
|
|
3046
|
-
const deserializeAws_json1_1ServiceUnavailableException = (
|
|
3047
|
-
output: any,
|
|
3048
|
-
context: __SerdeContext
|
|
3049
|
-
): ServiceUnavailableException => {
|
|
3050
|
-
return {
|
|
3051
|
-
Message: __expectString(output.Message),
|
|
3052
|
-
} as any;
|
|
3053
|
-
};
|
|
3054
|
-
|
|
3055
|
-
const deserializeAws_json1_1StartEntitiesDetectionV2JobResponse = (
|
|
3056
|
-
output: any,
|
|
3057
|
-
context: __SerdeContext
|
|
3058
|
-
): StartEntitiesDetectionV2JobResponse => {
|
|
3059
|
-
return {
|
|
3060
|
-
JobId: __expectString(output.JobId),
|
|
3061
|
-
} as any;
|
|
3062
|
-
};
|
|
3063
|
-
|
|
3064
|
-
const deserializeAws_json1_1StartICD10CMInferenceJobResponse = (
|
|
3065
|
-
output: any,
|
|
3066
|
-
context: __SerdeContext
|
|
3067
|
-
): StartICD10CMInferenceJobResponse => {
|
|
3068
|
-
return {
|
|
3069
|
-
JobId: __expectString(output.JobId),
|
|
3070
|
-
} as any;
|
|
3071
|
-
};
|
|
3072
|
-
|
|
3073
|
-
const deserializeAws_json1_1StartPHIDetectionJobResponse = (
|
|
3074
|
-
output: any,
|
|
3075
|
-
context: __SerdeContext
|
|
3076
|
-
): StartPHIDetectionJobResponse => {
|
|
3077
|
-
return {
|
|
3078
|
-
JobId: __expectString(output.JobId),
|
|
3079
|
-
} as any;
|
|
3080
|
-
};
|
|
3081
|
-
|
|
3082
|
-
const deserializeAws_json1_1StartRxNormInferenceJobResponse = (
|
|
3083
|
-
output: any,
|
|
3084
|
-
context: __SerdeContext
|
|
3085
|
-
): StartRxNormInferenceJobResponse => {
|
|
3086
|
-
return {
|
|
3087
|
-
JobId: __expectString(output.JobId),
|
|
3088
|
-
} as any;
|
|
3089
|
-
};
|
|
3090
|
-
|
|
3091
|
-
const deserializeAws_json1_1StopEntitiesDetectionV2JobResponse = (
|
|
3092
|
-
output: any,
|
|
3093
|
-
context: __SerdeContext
|
|
3094
|
-
): StopEntitiesDetectionV2JobResponse => {
|
|
3095
|
-
return {
|
|
3096
|
-
JobId: __expectString(output.JobId),
|
|
3097
|
-
} as any;
|
|
3098
|
-
};
|
|
3099
|
-
|
|
3100
|
-
const deserializeAws_json1_1StopICD10CMInferenceJobResponse = (
|
|
3101
|
-
output: any,
|
|
3102
|
-
context: __SerdeContext
|
|
3103
|
-
): StopICD10CMInferenceJobResponse => {
|
|
3104
|
-
return {
|
|
3105
|
-
JobId: __expectString(output.JobId),
|
|
3106
|
-
} as any;
|
|
3107
|
-
};
|
|
3108
|
-
|
|
3109
|
-
const deserializeAws_json1_1StopPHIDetectionJobResponse = (
|
|
3110
|
-
output: any,
|
|
3111
|
-
context: __SerdeContext
|
|
3112
|
-
): StopPHIDetectionJobResponse => {
|
|
3113
|
-
return {
|
|
3114
|
-
JobId: __expectString(output.JobId),
|
|
3115
|
-
} as any;
|
|
3116
|
-
};
|
|
3117
|
-
|
|
3118
|
-
const deserializeAws_json1_1StopRxNormInferenceJobResponse = (
|
|
3119
|
-
output: any,
|
|
3120
|
-
context: __SerdeContext
|
|
3121
|
-
): StopRxNormInferenceJobResponse => {
|
|
3122
|
-
return {
|
|
3123
|
-
JobId: __expectString(output.JobId),
|
|
3124
|
-
} as any;
|
|
3125
|
-
};
|
|
3126
|
-
|
|
3127
|
-
const deserializeAws_json1_1TextSizeLimitExceededException = (
|
|
3128
|
-
output: any,
|
|
3129
|
-
context: __SerdeContext
|
|
3130
|
-
): TextSizeLimitExceededException => {
|
|
3131
|
-
return {
|
|
3132
|
-
Message: __expectString(output.Message),
|
|
3133
|
-
} as any;
|
|
3134
|
-
};
|
|
3135
|
-
|
|
3136
|
-
const deserializeAws_json1_1TooManyRequestsException = (
|
|
3137
|
-
output: any,
|
|
3138
|
-
context: __SerdeContext
|
|
3139
|
-
): TooManyRequestsException => {
|
|
3140
|
-
return {
|
|
3141
|
-
Message: __expectString(output.Message),
|
|
3142
|
-
} as any;
|
|
3143
|
-
};
|
|
3144
|
-
|
|
3145
|
-
const deserializeAws_json1_1Trait = (output: any, context: __SerdeContext): Trait => {
|
|
3146
|
-
return {
|
|
3147
|
-
Name: __expectString(output.Name),
|
|
3148
|
-
Score: __limitedParseFloat32(output.Score),
|
|
3149
|
-
} as any;
|
|
3150
|
-
};
|
|
3151
|
-
|
|
3152
|
-
const deserializeAws_json1_1TraitList = (output: any, context: __SerdeContext): Trait[] => {
|
|
3153
|
-
return (output || [])
|
|
3154
|
-
.filter((e: any) => e != null)
|
|
3155
|
-
.map((entry: any) => {
|
|
3156
|
-
if (entry === null) {
|
|
3157
|
-
return null as any;
|
|
3158
|
-
}
|
|
3159
|
-
return deserializeAws_json1_1Trait(entry, context);
|
|
3160
|
-
});
|
|
3161
|
-
};
|
|
3162
|
-
|
|
3163
|
-
const deserializeAws_json1_1UnmappedAttribute = (output: any, context: __SerdeContext): UnmappedAttribute => {
|
|
3164
|
-
return {
|
|
3165
|
-
Attribute:
|
|
3166
|
-
output.Attribute !== undefined && output.Attribute !== null
|
|
3167
|
-
? deserializeAws_json1_1Attribute(output.Attribute, context)
|
|
3168
|
-
: undefined,
|
|
3169
|
-
Type: __expectString(output.Type),
|
|
3170
|
-
} as any;
|
|
3171
|
-
};
|
|
3172
|
-
|
|
3173
|
-
const deserializeAws_json1_1UnmappedAttributeList = (output: any, context: __SerdeContext): UnmappedAttribute[] => {
|
|
3174
|
-
return (output || [])
|
|
3175
|
-
.filter((e: any) => e != null)
|
|
3176
|
-
.map((entry: any) => {
|
|
3177
|
-
if (entry === null) {
|
|
3178
|
-
return null as any;
|
|
3179
|
-
}
|
|
3180
|
-
return deserializeAws_json1_1UnmappedAttribute(entry, context);
|
|
3181
|
-
});
|
|
3182
|
-
};
|
|
3183
|
-
|
|
3184
|
-
const deserializeAws_json1_1ValidationException = (output: any, context: __SerdeContext): ValidationException => {
|
|
3185
|
-
return {
|
|
3186
|
-
Message: __expectString(output.Message),
|
|
3187
|
-
} as any;
|
|
3188
|
-
};
|
|
3189
|
-
|
|
3190
|
-
const deserializeMetadata = (output: __HttpResponse): __ResponseMetadata => ({
|
|
3191
|
-
httpStatusCode: output.statusCode,
|
|
3192
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"],
|
|
3193
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
3194
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
3195
|
-
});
|
|
3196
|
-
|
|
3197
|
-
// Collect low-level response body stream to Uint8Array.
|
|
3198
|
-
const collectBody = (streamBody: any = new Uint8Array(), context: __SerdeContext): Promise<Uint8Array> => {
|
|
3199
|
-
if (streamBody instanceof Uint8Array) {
|
|
3200
|
-
return Promise.resolve(streamBody);
|
|
3201
|
-
}
|
|
3202
|
-
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
3203
|
-
};
|
|
3204
|
-
|
|
3205
|
-
// Encode Uint8Array data into string with utf-8.
|
|
3206
|
-
const collectBodyString = (streamBody: any, context: __SerdeContext): Promise<string> =>
|
|
3207
|
-
collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
3208
|
-
|
|
3209
|
-
const buildHttpRpcRequest = async (
|
|
3210
|
-
context: __SerdeContext,
|
|
3211
|
-
headers: __HeaderBag,
|
|
3212
|
-
path: string,
|
|
3213
|
-
resolvedHostname: string | undefined,
|
|
3214
|
-
body: any
|
|
3215
|
-
): Promise<__HttpRequest> => {
|
|
3216
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
3217
|
-
const contents: any = {
|
|
3218
|
-
protocol,
|
|
3219
|
-
hostname,
|
|
3220
|
-
port,
|
|
3221
|
-
method: "POST",
|
|
3222
|
-
path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
|
|
3223
|
-
headers,
|
|
3224
|
-
};
|
|
3225
|
-
if (resolvedHostname !== undefined) {
|
|
3226
|
-
contents.hostname = resolvedHostname;
|
|
3227
|
-
}
|
|
3228
|
-
if (body !== undefined) {
|
|
3229
|
-
contents.body = body;
|
|
3230
|
-
}
|
|
3231
|
-
return new __HttpRequest(contents);
|
|
3232
|
-
};
|
|
3233
|
-
|
|
3234
|
-
const parseBody = (streamBody: any, context: __SerdeContext): any =>
|
|
3235
|
-
collectBodyString(streamBody, context).then((encoded) => {
|
|
3236
|
-
if (encoded.length) {
|
|
3237
|
-
return JSON.parse(encoded);
|
|
3238
|
-
}
|
|
3239
|
-
return {};
|
|
3240
|
-
});
|
|
3241
|
-
|
|
3242
|
-
/**
|
|
3243
|
-
* Load an error code for the aws.rest-json-1.1 protocol.
|
|
3244
|
-
*/
|
|
3245
|
-
const loadRestJsonErrorCode = (output: __HttpResponse, data: any): string => {
|
|
3246
|
-
const findKey = (object: any, key: string) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
3247
|
-
|
|
3248
|
-
const sanitizeErrorCode = (rawValue: string): string => {
|
|
3249
|
-
let cleanValue = rawValue;
|
|
3250
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
3251
|
-
cleanValue = cleanValue.split(":")[0];
|
|
3252
|
-
}
|
|
3253
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
3254
|
-
cleanValue = cleanValue.split("#")[1];
|
|
3255
|
-
}
|
|
3256
|
-
return cleanValue;
|
|
3257
|
-
};
|
|
3258
|
-
|
|
3259
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
3260
|
-
if (headerKey !== undefined) {
|
|
3261
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
3262
|
-
}
|
|
3263
|
-
|
|
3264
|
-
if (data.code !== undefined) {
|
|
3265
|
-
return sanitizeErrorCode(data.code);
|
|
3266
|
-
}
|
|
3267
|
-
|
|
3268
|
-
if (data["__type"] !== undefined) {
|
|
3269
|
-
return sanitizeErrorCode(data["__type"]);
|
|
3270
|
-
}
|
|
3271
|
-
|
|
3272
|
-
return "";
|
|
3273
|
-
};
|