@aws-sdk/client-taxsettings 3.893.0 → 3.894.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/dist-cjs/index.js +1597 -10
- package/package.json +6 -6
- package/dist-cjs/TaxSettings.js +0 -43
- package/dist-cjs/TaxSettingsClient.js +0 -52
- package/dist-cjs/auth/httpAuthExtensionConfiguration.js +0 -43
- package/dist-cjs/commands/BatchDeleteTaxRegistrationCommand.js +0 -27
- package/dist-cjs/commands/BatchGetTaxExemptionsCommand.js +0 -26
- package/dist-cjs/commands/BatchPutTaxRegistrationCommand.js +0 -27
- package/dist-cjs/commands/DeleteSupplementalTaxRegistrationCommand.js +0 -26
- package/dist-cjs/commands/DeleteTaxRegistrationCommand.js +0 -26
- package/dist-cjs/commands/GetTaxExemptionTypesCommand.js +0 -26
- package/dist-cjs/commands/GetTaxInheritanceCommand.js +0 -26
- package/dist-cjs/commands/GetTaxRegistrationCommand.js +0 -27
- package/dist-cjs/commands/GetTaxRegistrationDocumentCommand.js +0 -26
- package/dist-cjs/commands/ListSupplementalTaxRegistrationsCommand.js +0 -27
- package/dist-cjs/commands/ListTaxExemptionsCommand.js +0 -26
- package/dist-cjs/commands/ListTaxRegistrationsCommand.js +0 -27
- package/dist-cjs/commands/PutSupplementalTaxRegistrationCommand.js +0 -27
- package/dist-cjs/commands/PutTaxExemptionCommand.js +0 -26
- package/dist-cjs/commands/PutTaxInheritanceCommand.js +0 -26
- package/dist-cjs/commands/PutTaxRegistrationCommand.js +0 -27
- package/dist-cjs/commands/index.js +0 -19
- package/dist-cjs/endpoint/EndpointParameters.js +0 -17
- package/dist-cjs/extensionConfiguration.js +0 -2
- package/dist-cjs/models/TaxSettingsServiceException.js +0 -12
- package/dist-cjs/models/index.js +0 -4
- package/dist-cjs/models/models_0.js +0 -285
- package/dist-cjs/pagination/Interfaces.js +0 -2
- package/dist-cjs/pagination/ListSupplementalTaxRegistrationsPaginator.js +0 -7
- package/dist-cjs/pagination/ListTaxExemptionsPaginator.js +0 -7
- package/dist-cjs/pagination/ListTaxRegistrationsPaginator.js +0 -7
- package/dist-cjs/pagination/index.js +0 -7
- package/dist-cjs/protocols/Aws_restJson1.js +0 -685
- package/dist-cjs/runtimeExtensions.js +0 -13
|
@@ -1,685 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.de_PutTaxRegistrationCommand = exports.de_PutTaxInheritanceCommand = exports.de_PutTaxExemptionCommand = exports.de_PutSupplementalTaxRegistrationCommand = exports.de_ListTaxRegistrationsCommand = exports.de_ListTaxExemptionsCommand = exports.de_ListSupplementalTaxRegistrationsCommand = exports.de_GetTaxRegistrationDocumentCommand = exports.de_GetTaxRegistrationCommand = exports.de_GetTaxInheritanceCommand = exports.de_GetTaxExemptionTypesCommand = exports.de_DeleteTaxRegistrationCommand = exports.de_DeleteSupplementalTaxRegistrationCommand = exports.de_BatchPutTaxRegistrationCommand = exports.de_BatchGetTaxExemptionsCommand = exports.de_BatchDeleteTaxRegistrationCommand = exports.se_PutTaxRegistrationCommand = exports.se_PutTaxInheritanceCommand = exports.se_PutTaxExemptionCommand = exports.se_PutSupplementalTaxRegistrationCommand = exports.se_ListTaxRegistrationsCommand = exports.se_ListTaxExemptionsCommand = exports.se_ListSupplementalTaxRegistrationsCommand = exports.se_GetTaxRegistrationDocumentCommand = exports.se_GetTaxRegistrationCommand = exports.se_GetTaxInheritanceCommand = exports.se_GetTaxExemptionTypesCommand = exports.se_DeleteTaxRegistrationCommand = exports.se_DeleteSupplementalTaxRegistrationCommand = exports.se_BatchPutTaxRegistrationCommand = exports.se_BatchGetTaxExemptionsCommand = exports.se_BatchDeleteTaxRegistrationCommand = void 0;
|
|
4
|
-
const core_1 = require("@aws-sdk/core");
|
|
5
|
-
const core_2 = require("@smithy/core");
|
|
6
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
7
|
-
const models_0_1 = require("../models/models_0");
|
|
8
|
-
const TaxSettingsServiceException_1 = require("../models/TaxSettingsServiceException");
|
|
9
|
-
const se_BatchDeleteTaxRegistrationCommand = async (input, context) => {
|
|
10
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
11
|
-
const headers = {
|
|
12
|
-
"content-type": "application/json",
|
|
13
|
-
};
|
|
14
|
-
b.bp("/BatchDeleteTaxRegistration");
|
|
15
|
-
let body;
|
|
16
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
17
|
-
accountIds: (_) => (0, smithy_client_1._json)(_),
|
|
18
|
-
}));
|
|
19
|
-
b.m("POST").h(headers).b(body);
|
|
20
|
-
return b.build();
|
|
21
|
-
};
|
|
22
|
-
exports.se_BatchDeleteTaxRegistrationCommand = se_BatchDeleteTaxRegistrationCommand;
|
|
23
|
-
const se_BatchGetTaxExemptionsCommand = async (input, context) => {
|
|
24
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
25
|
-
const headers = {
|
|
26
|
-
"content-type": "application/json",
|
|
27
|
-
};
|
|
28
|
-
b.bp("/BatchGetTaxExemptions");
|
|
29
|
-
let body;
|
|
30
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
31
|
-
accountIds: (_) => (0, smithy_client_1._json)(_),
|
|
32
|
-
}));
|
|
33
|
-
b.m("POST").h(headers).b(body);
|
|
34
|
-
return b.build();
|
|
35
|
-
};
|
|
36
|
-
exports.se_BatchGetTaxExemptionsCommand = se_BatchGetTaxExemptionsCommand;
|
|
37
|
-
const se_BatchPutTaxRegistrationCommand = async (input, context) => {
|
|
38
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
39
|
-
const headers = {
|
|
40
|
-
"content-type": "application/json",
|
|
41
|
-
};
|
|
42
|
-
b.bp("/BatchPutTaxRegistration");
|
|
43
|
-
let body;
|
|
44
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
45
|
-
accountIds: (_) => (0, smithy_client_1._json)(_),
|
|
46
|
-
taxRegistrationEntry: (_) => se_TaxRegistrationEntry(_, context),
|
|
47
|
-
}));
|
|
48
|
-
b.m("POST").h(headers).b(body);
|
|
49
|
-
return b.build();
|
|
50
|
-
};
|
|
51
|
-
exports.se_BatchPutTaxRegistrationCommand = se_BatchPutTaxRegistrationCommand;
|
|
52
|
-
const se_DeleteSupplementalTaxRegistrationCommand = async (input, context) => {
|
|
53
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
54
|
-
const headers = {
|
|
55
|
-
"content-type": "application/json",
|
|
56
|
-
};
|
|
57
|
-
b.bp("/DeleteSupplementalTaxRegistration");
|
|
58
|
-
let body;
|
|
59
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
60
|
-
authorityId: [],
|
|
61
|
-
}));
|
|
62
|
-
b.m("POST").h(headers).b(body);
|
|
63
|
-
return b.build();
|
|
64
|
-
};
|
|
65
|
-
exports.se_DeleteSupplementalTaxRegistrationCommand = se_DeleteSupplementalTaxRegistrationCommand;
|
|
66
|
-
const se_DeleteTaxRegistrationCommand = async (input, context) => {
|
|
67
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
68
|
-
const headers = {
|
|
69
|
-
"content-type": "application/json",
|
|
70
|
-
};
|
|
71
|
-
b.bp("/DeleteTaxRegistration");
|
|
72
|
-
let body;
|
|
73
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
74
|
-
accountId: [],
|
|
75
|
-
}));
|
|
76
|
-
b.m("POST").h(headers).b(body);
|
|
77
|
-
return b.build();
|
|
78
|
-
};
|
|
79
|
-
exports.se_DeleteTaxRegistrationCommand = se_DeleteTaxRegistrationCommand;
|
|
80
|
-
const se_GetTaxExemptionTypesCommand = async (input, context) => {
|
|
81
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
82
|
-
const headers = {};
|
|
83
|
-
b.bp("/GetTaxExemptionTypes");
|
|
84
|
-
let body;
|
|
85
|
-
b.m("POST").h(headers).b(body);
|
|
86
|
-
return b.build();
|
|
87
|
-
};
|
|
88
|
-
exports.se_GetTaxExemptionTypesCommand = se_GetTaxExemptionTypesCommand;
|
|
89
|
-
const se_GetTaxInheritanceCommand = async (input, context) => {
|
|
90
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
91
|
-
const headers = {};
|
|
92
|
-
b.bp("/GetTaxInheritance");
|
|
93
|
-
let body;
|
|
94
|
-
b.m("POST").h(headers).b(body);
|
|
95
|
-
return b.build();
|
|
96
|
-
};
|
|
97
|
-
exports.se_GetTaxInheritanceCommand = se_GetTaxInheritanceCommand;
|
|
98
|
-
const se_GetTaxRegistrationCommand = async (input, context) => {
|
|
99
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
100
|
-
const headers = {
|
|
101
|
-
"content-type": "application/json",
|
|
102
|
-
};
|
|
103
|
-
b.bp("/GetTaxRegistration");
|
|
104
|
-
let body;
|
|
105
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
106
|
-
accountId: [],
|
|
107
|
-
}));
|
|
108
|
-
b.m("POST").h(headers).b(body);
|
|
109
|
-
return b.build();
|
|
110
|
-
};
|
|
111
|
-
exports.se_GetTaxRegistrationCommand = se_GetTaxRegistrationCommand;
|
|
112
|
-
const se_GetTaxRegistrationDocumentCommand = async (input, context) => {
|
|
113
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
114
|
-
const headers = {
|
|
115
|
-
"content-type": "application/json",
|
|
116
|
-
};
|
|
117
|
-
b.bp("/GetTaxRegistrationDocument");
|
|
118
|
-
let body;
|
|
119
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
120
|
-
destinationS3Location: (_) => (0, smithy_client_1._json)(_),
|
|
121
|
-
taxDocumentMetadata: (_) => (0, smithy_client_1._json)(_),
|
|
122
|
-
}));
|
|
123
|
-
b.m("POST").h(headers).b(body);
|
|
124
|
-
return b.build();
|
|
125
|
-
};
|
|
126
|
-
exports.se_GetTaxRegistrationDocumentCommand = se_GetTaxRegistrationDocumentCommand;
|
|
127
|
-
const se_ListSupplementalTaxRegistrationsCommand = async (input, context) => {
|
|
128
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
129
|
-
const headers = {
|
|
130
|
-
"content-type": "application/json",
|
|
131
|
-
};
|
|
132
|
-
b.bp("/ListSupplementalTaxRegistrations");
|
|
133
|
-
let body;
|
|
134
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
135
|
-
maxResults: [],
|
|
136
|
-
nextToken: [],
|
|
137
|
-
}));
|
|
138
|
-
b.m("POST").h(headers).b(body);
|
|
139
|
-
return b.build();
|
|
140
|
-
};
|
|
141
|
-
exports.se_ListSupplementalTaxRegistrationsCommand = se_ListSupplementalTaxRegistrationsCommand;
|
|
142
|
-
const se_ListTaxExemptionsCommand = async (input, context) => {
|
|
143
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
144
|
-
const headers = {
|
|
145
|
-
"content-type": "application/json",
|
|
146
|
-
};
|
|
147
|
-
b.bp("/ListTaxExemptions");
|
|
148
|
-
let body;
|
|
149
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
150
|
-
maxResults: [],
|
|
151
|
-
nextToken: [],
|
|
152
|
-
}));
|
|
153
|
-
b.m("POST").h(headers).b(body);
|
|
154
|
-
return b.build();
|
|
155
|
-
};
|
|
156
|
-
exports.se_ListTaxExemptionsCommand = se_ListTaxExemptionsCommand;
|
|
157
|
-
const se_ListTaxRegistrationsCommand = async (input, context) => {
|
|
158
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
159
|
-
const headers = {
|
|
160
|
-
"content-type": "application/json",
|
|
161
|
-
};
|
|
162
|
-
b.bp("/ListTaxRegistrations");
|
|
163
|
-
let body;
|
|
164
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
165
|
-
maxResults: [],
|
|
166
|
-
nextToken: [],
|
|
167
|
-
}));
|
|
168
|
-
b.m("POST").h(headers).b(body);
|
|
169
|
-
return b.build();
|
|
170
|
-
};
|
|
171
|
-
exports.se_ListTaxRegistrationsCommand = se_ListTaxRegistrationsCommand;
|
|
172
|
-
const se_PutSupplementalTaxRegistrationCommand = async (input, context) => {
|
|
173
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
174
|
-
const headers = {
|
|
175
|
-
"content-type": "application/json",
|
|
176
|
-
};
|
|
177
|
-
b.bp("/PutSupplementalTaxRegistration");
|
|
178
|
-
let body;
|
|
179
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
180
|
-
taxRegistrationEntry: (_) => (0, smithy_client_1._json)(_),
|
|
181
|
-
}));
|
|
182
|
-
b.m("POST").h(headers).b(body);
|
|
183
|
-
return b.build();
|
|
184
|
-
};
|
|
185
|
-
exports.se_PutSupplementalTaxRegistrationCommand = se_PutSupplementalTaxRegistrationCommand;
|
|
186
|
-
const se_PutTaxExemptionCommand = async (input, context) => {
|
|
187
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
188
|
-
const headers = {
|
|
189
|
-
"content-type": "application/json",
|
|
190
|
-
};
|
|
191
|
-
b.bp("/PutTaxExemption");
|
|
192
|
-
let body;
|
|
193
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
194
|
-
accountIds: (_) => (0, smithy_client_1._json)(_),
|
|
195
|
-
authority: (_) => (0, smithy_client_1._json)(_),
|
|
196
|
-
exemptionCertificate: (_) => se_ExemptionCertificate(_, context),
|
|
197
|
-
exemptionType: [],
|
|
198
|
-
}));
|
|
199
|
-
b.m("POST").h(headers).b(body);
|
|
200
|
-
return b.build();
|
|
201
|
-
};
|
|
202
|
-
exports.se_PutTaxExemptionCommand = se_PutTaxExemptionCommand;
|
|
203
|
-
const se_PutTaxInheritanceCommand = async (input, context) => {
|
|
204
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
205
|
-
const headers = {
|
|
206
|
-
"content-type": "application/json",
|
|
207
|
-
};
|
|
208
|
-
b.bp("/PutTaxInheritance");
|
|
209
|
-
let body;
|
|
210
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
211
|
-
heritageStatus: [],
|
|
212
|
-
}));
|
|
213
|
-
b.m("POST").h(headers).b(body);
|
|
214
|
-
return b.build();
|
|
215
|
-
};
|
|
216
|
-
exports.se_PutTaxInheritanceCommand = se_PutTaxInheritanceCommand;
|
|
217
|
-
const se_PutTaxRegistrationCommand = async (input, context) => {
|
|
218
|
-
const b = (0, core_2.requestBuilder)(input, context);
|
|
219
|
-
const headers = {
|
|
220
|
-
"content-type": "application/json",
|
|
221
|
-
};
|
|
222
|
-
b.bp("/PutTaxRegistration");
|
|
223
|
-
let body;
|
|
224
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
225
|
-
accountId: [],
|
|
226
|
-
taxRegistrationEntry: (_) => se_TaxRegistrationEntry(_, context),
|
|
227
|
-
}));
|
|
228
|
-
b.m("POST").h(headers).b(body);
|
|
229
|
-
return b.build();
|
|
230
|
-
};
|
|
231
|
-
exports.se_PutTaxRegistrationCommand = se_PutTaxRegistrationCommand;
|
|
232
|
-
const de_BatchDeleteTaxRegistrationCommand = async (output, context) => {
|
|
233
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
234
|
-
return de_CommandError(output, context);
|
|
235
|
-
}
|
|
236
|
-
const contents = (0, smithy_client_1.map)({
|
|
237
|
-
$metadata: deserializeMetadata(output),
|
|
238
|
-
});
|
|
239
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
240
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
241
|
-
errors: smithy_client_1._json,
|
|
242
|
-
});
|
|
243
|
-
Object.assign(contents, doc);
|
|
244
|
-
return contents;
|
|
245
|
-
};
|
|
246
|
-
exports.de_BatchDeleteTaxRegistrationCommand = de_BatchDeleteTaxRegistrationCommand;
|
|
247
|
-
const de_BatchGetTaxExemptionsCommand = async (output, context) => {
|
|
248
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
249
|
-
return de_CommandError(output, context);
|
|
250
|
-
}
|
|
251
|
-
const contents = (0, smithy_client_1.map)({
|
|
252
|
-
$metadata: deserializeMetadata(output),
|
|
253
|
-
});
|
|
254
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
255
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
256
|
-
failedAccounts: smithy_client_1._json,
|
|
257
|
-
taxExemptionDetailsMap: (_) => de_TaxExemptionDetailsMap(_, context),
|
|
258
|
-
});
|
|
259
|
-
Object.assign(contents, doc);
|
|
260
|
-
return contents;
|
|
261
|
-
};
|
|
262
|
-
exports.de_BatchGetTaxExemptionsCommand = de_BatchGetTaxExemptionsCommand;
|
|
263
|
-
const de_BatchPutTaxRegistrationCommand = async (output, context) => {
|
|
264
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
265
|
-
return de_CommandError(output, context);
|
|
266
|
-
}
|
|
267
|
-
const contents = (0, smithy_client_1.map)({
|
|
268
|
-
$metadata: deserializeMetadata(output),
|
|
269
|
-
});
|
|
270
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
271
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
272
|
-
errors: smithy_client_1._json,
|
|
273
|
-
status: smithy_client_1.expectString,
|
|
274
|
-
});
|
|
275
|
-
Object.assign(contents, doc);
|
|
276
|
-
return contents;
|
|
277
|
-
};
|
|
278
|
-
exports.de_BatchPutTaxRegistrationCommand = de_BatchPutTaxRegistrationCommand;
|
|
279
|
-
const de_DeleteSupplementalTaxRegistrationCommand = async (output, context) => {
|
|
280
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
281
|
-
return de_CommandError(output, context);
|
|
282
|
-
}
|
|
283
|
-
const contents = (0, smithy_client_1.map)({
|
|
284
|
-
$metadata: deserializeMetadata(output),
|
|
285
|
-
});
|
|
286
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
287
|
-
return contents;
|
|
288
|
-
};
|
|
289
|
-
exports.de_DeleteSupplementalTaxRegistrationCommand = de_DeleteSupplementalTaxRegistrationCommand;
|
|
290
|
-
const de_DeleteTaxRegistrationCommand = async (output, context) => {
|
|
291
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
292
|
-
return de_CommandError(output, context);
|
|
293
|
-
}
|
|
294
|
-
const contents = (0, smithy_client_1.map)({
|
|
295
|
-
$metadata: deserializeMetadata(output),
|
|
296
|
-
});
|
|
297
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
298
|
-
return contents;
|
|
299
|
-
};
|
|
300
|
-
exports.de_DeleteTaxRegistrationCommand = de_DeleteTaxRegistrationCommand;
|
|
301
|
-
const de_GetTaxExemptionTypesCommand = async (output, context) => {
|
|
302
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
303
|
-
return de_CommandError(output, context);
|
|
304
|
-
}
|
|
305
|
-
const contents = (0, smithy_client_1.map)({
|
|
306
|
-
$metadata: deserializeMetadata(output),
|
|
307
|
-
});
|
|
308
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
309
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
310
|
-
taxExemptionTypes: smithy_client_1._json,
|
|
311
|
-
});
|
|
312
|
-
Object.assign(contents, doc);
|
|
313
|
-
return contents;
|
|
314
|
-
};
|
|
315
|
-
exports.de_GetTaxExemptionTypesCommand = de_GetTaxExemptionTypesCommand;
|
|
316
|
-
const de_GetTaxInheritanceCommand = async (output, context) => {
|
|
317
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
318
|
-
return de_CommandError(output, context);
|
|
319
|
-
}
|
|
320
|
-
const contents = (0, smithy_client_1.map)({
|
|
321
|
-
$metadata: deserializeMetadata(output),
|
|
322
|
-
});
|
|
323
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
324
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
325
|
-
heritageStatus: smithy_client_1.expectString,
|
|
326
|
-
});
|
|
327
|
-
Object.assign(contents, doc);
|
|
328
|
-
return contents;
|
|
329
|
-
};
|
|
330
|
-
exports.de_GetTaxInheritanceCommand = de_GetTaxInheritanceCommand;
|
|
331
|
-
const de_GetTaxRegistrationCommand = async (output, context) => {
|
|
332
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
333
|
-
return de_CommandError(output, context);
|
|
334
|
-
}
|
|
335
|
-
const contents = (0, smithy_client_1.map)({
|
|
336
|
-
$metadata: deserializeMetadata(output),
|
|
337
|
-
});
|
|
338
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
339
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
340
|
-
taxRegistration: smithy_client_1._json,
|
|
341
|
-
});
|
|
342
|
-
Object.assign(contents, doc);
|
|
343
|
-
return contents;
|
|
344
|
-
};
|
|
345
|
-
exports.de_GetTaxRegistrationCommand = de_GetTaxRegistrationCommand;
|
|
346
|
-
const de_GetTaxRegistrationDocumentCommand = async (output, context) => {
|
|
347
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
348
|
-
return de_CommandError(output, context);
|
|
349
|
-
}
|
|
350
|
-
const contents = (0, smithy_client_1.map)({
|
|
351
|
-
$metadata: deserializeMetadata(output),
|
|
352
|
-
});
|
|
353
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
354
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
355
|
-
destinationFilePath: smithy_client_1.expectString,
|
|
356
|
-
presignedS3Url: smithy_client_1.expectString,
|
|
357
|
-
});
|
|
358
|
-
Object.assign(contents, doc);
|
|
359
|
-
return contents;
|
|
360
|
-
};
|
|
361
|
-
exports.de_GetTaxRegistrationDocumentCommand = de_GetTaxRegistrationDocumentCommand;
|
|
362
|
-
const de_ListSupplementalTaxRegistrationsCommand = async (output, context) => {
|
|
363
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
364
|
-
return de_CommandError(output, context);
|
|
365
|
-
}
|
|
366
|
-
const contents = (0, smithy_client_1.map)({
|
|
367
|
-
$metadata: deserializeMetadata(output),
|
|
368
|
-
});
|
|
369
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
370
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
371
|
-
nextToken: smithy_client_1.expectString,
|
|
372
|
-
taxRegistrations: smithy_client_1._json,
|
|
373
|
-
});
|
|
374
|
-
Object.assign(contents, doc);
|
|
375
|
-
return contents;
|
|
376
|
-
};
|
|
377
|
-
exports.de_ListSupplementalTaxRegistrationsCommand = de_ListSupplementalTaxRegistrationsCommand;
|
|
378
|
-
const de_ListTaxExemptionsCommand = async (output, context) => {
|
|
379
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
380
|
-
return de_CommandError(output, context);
|
|
381
|
-
}
|
|
382
|
-
const contents = (0, smithy_client_1.map)({
|
|
383
|
-
$metadata: deserializeMetadata(output),
|
|
384
|
-
});
|
|
385
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
386
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
387
|
-
nextToken: smithy_client_1.expectString,
|
|
388
|
-
taxExemptionDetailsMap: (_) => de_TaxExemptionDetailsMap(_, context),
|
|
389
|
-
});
|
|
390
|
-
Object.assign(contents, doc);
|
|
391
|
-
return contents;
|
|
392
|
-
};
|
|
393
|
-
exports.de_ListTaxExemptionsCommand = de_ListTaxExemptionsCommand;
|
|
394
|
-
const de_ListTaxRegistrationsCommand = async (output, context) => {
|
|
395
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
396
|
-
return de_CommandError(output, context);
|
|
397
|
-
}
|
|
398
|
-
const contents = (0, smithy_client_1.map)({
|
|
399
|
-
$metadata: deserializeMetadata(output),
|
|
400
|
-
});
|
|
401
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
402
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
403
|
-
accountDetails: smithy_client_1._json,
|
|
404
|
-
nextToken: smithy_client_1.expectString,
|
|
405
|
-
});
|
|
406
|
-
Object.assign(contents, doc);
|
|
407
|
-
return contents;
|
|
408
|
-
};
|
|
409
|
-
exports.de_ListTaxRegistrationsCommand = de_ListTaxRegistrationsCommand;
|
|
410
|
-
const de_PutSupplementalTaxRegistrationCommand = async (output, context) => {
|
|
411
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
412
|
-
return de_CommandError(output, context);
|
|
413
|
-
}
|
|
414
|
-
const contents = (0, smithy_client_1.map)({
|
|
415
|
-
$metadata: deserializeMetadata(output),
|
|
416
|
-
});
|
|
417
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
418
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
419
|
-
authorityId: smithy_client_1.expectString,
|
|
420
|
-
status: smithy_client_1.expectString,
|
|
421
|
-
});
|
|
422
|
-
Object.assign(contents, doc);
|
|
423
|
-
return contents;
|
|
424
|
-
};
|
|
425
|
-
exports.de_PutSupplementalTaxRegistrationCommand = de_PutSupplementalTaxRegistrationCommand;
|
|
426
|
-
const de_PutTaxExemptionCommand = async (output, context) => {
|
|
427
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
428
|
-
return de_CommandError(output, context);
|
|
429
|
-
}
|
|
430
|
-
const contents = (0, smithy_client_1.map)({
|
|
431
|
-
$metadata: deserializeMetadata(output),
|
|
432
|
-
});
|
|
433
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
434
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
435
|
-
caseId: smithy_client_1.expectString,
|
|
436
|
-
});
|
|
437
|
-
Object.assign(contents, doc);
|
|
438
|
-
return contents;
|
|
439
|
-
};
|
|
440
|
-
exports.de_PutTaxExemptionCommand = de_PutTaxExemptionCommand;
|
|
441
|
-
const de_PutTaxInheritanceCommand = async (output, context) => {
|
|
442
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
443
|
-
return de_CommandError(output, context);
|
|
444
|
-
}
|
|
445
|
-
const contents = (0, smithy_client_1.map)({
|
|
446
|
-
$metadata: deserializeMetadata(output),
|
|
447
|
-
});
|
|
448
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
449
|
-
return contents;
|
|
450
|
-
};
|
|
451
|
-
exports.de_PutTaxInheritanceCommand = de_PutTaxInheritanceCommand;
|
|
452
|
-
const de_PutTaxRegistrationCommand = async (output, context) => {
|
|
453
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
454
|
-
return de_CommandError(output, context);
|
|
455
|
-
}
|
|
456
|
-
const contents = (0, smithy_client_1.map)({
|
|
457
|
-
$metadata: deserializeMetadata(output),
|
|
458
|
-
});
|
|
459
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context)), "body");
|
|
460
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
461
|
-
status: smithy_client_1.expectString,
|
|
462
|
-
});
|
|
463
|
-
Object.assign(contents, doc);
|
|
464
|
-
return contents;
|
|
465
|
-
};
|
|
466
|
-
exports.de_PutTaxRegistrationCommand = de_PutTaxRegistrationCommand;
|
|
467
|
-
const de_CommandError = async (output, context) => {
|
|
468
|
-
const parsedOutput = {
|
|
469
|
-
...output,
|
|
470
|
-
body: await (0, core_1.parseJsonErrorBody)(output.body, context),
|
|
471
|
-
};
|
|
472
|
-
const errorCode = (0, core_1.loadRestJsonErrorCode)(output, parsedOutput.body);
|
|
473
|
-
switch (errorCode) {
|
|
474
|
-
case "ConflictException":
|
|
475
|
-
case "com.amazonaws.taxsettings#ConflictException":
|
|
476
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
477
|
-
case "InternalServerException":
|
|
478
|
-
case "com.amazonaws.taxsettings#InternalServerException":
|
|
479
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
480
|
-
case "ValidationException":
|
|
481
|
-
case "com.amazonaws.taxsettings#ValidationException":
|
|
482
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
483
|
-
case "ResourceNotFoundException":
|
|
484
|
-
case "com.amazonaws.taxsettings#ResourceNotFoundException":
|
|
485
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
486
|
-
case "AccessDeniedException":
|
|
487
|
-
case "com.amazonaws.taxsettings#AccessDeniedException":
|
|
488
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
489
|
-
case "AttachmentUploadException":
|
|
490
|
-
case "com.amazonaws.taxsettings#AttachmentUploadException":
|
|
491
|
-
throw await de_AttachmentUploadExceptionRes(parsedOutput, context);
|
|
492
|
-
case "CaseCreationLimitExceededException":
|
|
493
|
-
case "com.amazonaws.taxsettings#CaseCreationLimitExceededException":
|
|
494
|
-
throw await de_CaseCreationLimitExceededExceptionRes(parsedOutput, context);
|
|
495
|
-
default:
|
|
496
|
-
const parsedBody = parsedOutput.body;
|
|
497
|
-
return throwDefaultError({
|
|
498
|
-
output,
|
|
499
|
-
parsedBody,
|
|
500
|
-
errorCode,
|
|
501
|
-
});
|
|
502
|
-
}
|
|
503
|
-
};
|
|
504
|
-
const throwDefaultError = (0, smithy_client_1.withBaseException)(TaxSettingsServiceException_1.TaxSettingsServiceException);
|
|
505
|
-
const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
506
|
-
const contents = (0, smithy_client_1.map)({});
|
|
507
|
-
const data = parsedOutput.body;
|
|
508
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
509
|
-
message: smithy_client_1.expectString,
|
|
510
|
-
});
|
|
511
|
-
Object.assign(contents, doc);
|
|
512
|
-
const exception = new models_0_1.AccessDeniedException({
|
|
513
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
514
|
-
...contents,
|
|
515
|
-
});
|
|
516
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
517
|
-
};
|
|
518
|
-
const de_AttachmentUploadExceptionRes = async (parsedOutput, context) => {
|
|
519
|
-
const contents = (0, smithy_client_1.map)({});
|
|
520
|
-
const data = parsedOutput.body;
|
|
521
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
522
|
-
message: smithy_client_1.expectString,
|
|
523
|
-
});
|
|
524
|
-
Object.assign(contents, doc);
|
|
525
|
-
const exception = new models_0_1.AttachmentUploadException({
|
|
526
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
527
|
-
...contents,
|
|
528
|
-
});
|
|
529
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
530
|
-
};
|
|
531
|
-
const de_CaseCreationLimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
532
|
-
const contents = (0, smithy_client_1.map)({});
|
|
533
|
-
const data = parsedOutput.body;
|
|
534
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
535
|
-
message: smithy_client_1.expectString,
|
|
536
|
-
});
|
|
537
|
-
Object.assign(contents, doc);
|
|
538
|
-
const exception = new models_0_1.CaseCreationLimitExceededException({
|
|
539
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
540
|
-
...contents,
|
|
541
|
-
});
|
|
542
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
543
|
-
};
|
|
544
|
-
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
545
|
-
const contents = (0, smithy_client_1.map)({});
|
|
546
|
-
const data = parsedOutput.body;
|
|
547
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
548
|
-
errorCode: smithy_client_1.expectString,
|
|
549
|
-
message: smithy_client_1.expectString,
|
|
550
|
-
});
|
|
551
|
-
Object.assign(contents, doc);
|
|
552
|
-
const exception = new models_0_1.ConflictException({
|
|
553
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
554
|
-
...contents,
|
|
555
|
-
});
|
|
556
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
557
|
-
};
|
|
558
|
-
const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
559
|
-
const contents = (0, smithy_client_1.map)({});
|
|
560
|
-
const data = parsedOutput.body;
|
|
561
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
562
|
-
errorCode: smithy_client_1.expectString,
|
|
563
|
-
message: smithy_client_1.expectString,
|
|
564
|
-
});
|
|
565
|
-
Object.assign(contents, doc);
|
|
566
|
-
const exception = new models_0_1.InternalServerException({
|
|
567
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
568
|
-
...contents,
|
|
569
|
-
});
|
|
570
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
571
|
-
};
|
|
572
|
-
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
573
|
-
const contents = (0, smithy_client_1.map)({});
|
|
574
|
-
const data = parsedOutput.body;
|
|
575
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
576
|
-
errorCode: smithy_client_1.expectString,
|
|
577
|
-
message: smithy_client_1.expectString,
|
|
578
|
-
});
|
|
579
|
-
Object.assign(contents, doc);
|
|
580
|
-
const exception = new models_0_1.ResourceNotFoundException({
|
|
581
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
582
|
-
...contents,
|
|
583
|
-
});
|
|
584
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
585
|
-
};
|
|
586
|
-
const de_ValidationExceptionRes = async (parsedOutput, context) => {
|
|
587
|
-
const contents = (0, smithy_client_1.map)({});
|
|
588
|
-
const data = parsedOutput.body;
|
|
589
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
590
|
-
errorCode: smithy_client_1.expectString,
|
|
591
|
-
fieldList: smithy_client_1._json,
|
|
592
|
-
message: smithy_client_1.expectString,
|
|
593
|
-
});
|
|
594
|
-
Object.assign(contents, doc);
|
|
595
|
-
const exception = new models_0_1.ValidationException({
|
|
596
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
597
|
-
...contents,
|
|
598
|
-
});
|
|
599
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
600
|
-
};
|
|
601
|
-
const se_ExemptionCertificate = (input, context) => {
|
|
602
|
-
return (0, smithy_client_1.take)(input, {
|
|
603
|
-
documentFile: context.base64Encoder,
|
|
604
|
-
documentName: [],
|
|
605
|
-
});
|
|
606
|
-
};
|
|
607
|
-
const se_TaxRegistrationDocFile = (input, context) => {
|
|
608
|
-
return (0, smithy_client_1.take)(input, {
|
|
609
|
-
fileContent: context.base64Encoder,
|
|
610
|
-
fileName: [],
|
|
611
|
-
});
|
|
612
|
-
};
|
|
613
|
-
const se_TaxRegistrationDocument = (input, context) => {
|
|
614
|
-
return (0, smithy_client_1.take)(input, {
|
|
615
|
-
file: (_) => se_TaxRegistrationDocFile(_, context),
|
|
616
|
-
s3Location: smithy_client_1._json,
|
|
617
|
-
});
|
|
618
|
-
};
|
|
619
|
-
const se_TaxRegistrationDocuments = (input, context) => {
|
|
620
|
-
return input
|
|
621
|
-
.filter((e) => e != null)
|
|
622
|
-
.map((entry) => {
|
|
623
|
-
return se_TaxRegistrationDocument(entry, context);
|
|
624
|
-
});
|
|
625
|
-
};
|
|
626
|
-
const se_TaxRegistrationEntry = (input, context) => {
|
|
627
|
-
return (0, smithy_client_1.take)(input, {
|
|
628
|
-
additionalTaxInformation: smithy_client_1._json,
|
|
629
|
-
certifiedEmailId: [],
|
|
630
|
-
legalAddress: smithy_client_1._json,
|
|
631
|
-
legalName: [],
|
|
632
|
-
registrationId: [],
|
|
633
|
-
registrationType: [],
|
|
634
|
-
sector: [],
|
|
635
|
-
verificationDetails: (_) => se_VerificationDetails(_, context),
|
|
636
|
-
});
|
|
637
|
-
};
|
|
638
|
-
const se_VerificationDetails = (input, context) => {
|
|
639
|
-
return (0, smithy_client_1.take)(input, {
|
|
640
|
-
dateOfBirth: [],
|
|
641
|
-
taxRegistrationDocuments: (_) => se_TaxRegistrationDocuments(_, context),
|
|
642
|
-
});
|
|
643
|
-
};
|
|
644
|
-
const de_TaxExemption = (output, context) => {
|
|
645
|
-
return (0, smithy_client_1.take)(output, {
|
|
646
|
-
authority: smithy_client_1._json,
|
|
647
|
-
effectiveDate: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
648
|
-
expirationDate: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
649
|
-
status: smithy_client_1.expectString,
|
|
650
|
-
systemEffectiveDate: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
651
|
-
taxExemptionType: smithy_client_1._json,
|
|
652
|
-
});
|
|
653
|
-
};
|
|
654
|
-
const de_TaxExemptionDetails = (output, context) => {
|
|
655
|
-
return (0, smithy_client_1.take)(output, {
|
|
656
|
-
heritageObtainedDetails: smithy_client_1.expectBoolean,
|
|
657
|
-
heritageObtainedParentEntity: smithy_client_1.expectString,
|
|
658
|
-
heritageObtainedReason: smithy_client_1.expectString,
|
|
659
|
-
taxExemptions: (_) => de_TaxExemptions(_, context),
|
|
660
|
-
});
|
|
661
|
-
};
|
|
662
|
-
const de_TaxExemptionDetailsMap = (output, context) => {
|
|
663
|
-
return Object.entries(output).reduce((acc, [key, value]) => {
|
|
664
|
-
if (value === null) {
|
|
665
|
-
return acc;
|
|
666
|
-
}
|
|
667
|
-
acc[key] = de_TaxExemptionDetails(value, context);
|
|
668
|
-
return acc;
|
|
669
|
-
}, {});
|
|
670
|
-
};
|
|
671
|
-
const de_TaxExemptions = (output, context) => {
|
|
672
|
-
const retVal = (output || [])
|
|
673
|
-
.filter((e) => e != null)
|
|
674
|
-
.map((entry) => {
|
|
675
|
-
return de_TaxExemption(entry, context);
|
|
676
|
-
});
|
|
677
|
-
return retVal;
|
|
678
|
-
};
|
|
679
|
-
const deserializeMetadata = (output) => ({
|
|
680
|
-
httpStatusCode: output.statusCode,
|
|
681
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
682
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
683
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
684
|
-
});
|
|
685
|
-
const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body));
|