Skip to content

Commit 816e1f3

Browse files
author
awstools
committed
feat(client-pricing): Add ResourceNotFoundException to ListPriceLists and GetPriceListFileUrl APIs
1 parent 9099163 commit 816e1f3

File tree

5 files changed

+69
-0
lines changed

5 files changed

+69
-0
lines changed

clients/client-pricing/src/commands/GetPriceListFileUrlCommand.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,9 @@ export interface GetPriceListFileUrlCommandOutput extends GetPriceListFileUrlRes
7171
* @throws {@link NotFoundException} (client fault)
7272
* <p>The requested resource can't be found.</p>
7373
*
74+
* @throws {@link ResourceNotFoundException} (client fault)
75+
* <p>The requested resource can't be found.</p>
76+
*
7477
* @throws {@link ThrottlingException} (client fault)
7578
* <p>You've made too many requests exceeding service quotas.
7679
* </p>

clients/client-pricing/src/commands/ListPriceListsCommand.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,9 @@ export interface ListPriceListsCommandOutput extends ListPriceListsResponse, __M
9595
* @throws {@link NotFoundException} (client fault)
9696
* <p>The requested resource can't be found.</p>
9797
*
98+
* @throws {@link ResourceNotFoundException} (client fault)
99+
* <p>The requested resource can't be found.</p>
100+
*
98101
* @throws {@link ThrottlingException} (client fault)
99102
* <p>You've made too many requests exceeding service quotas.
100103
* </p>

clients/client-pricing/src/models/models_0.ts

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -333,6 +333,28 @@ export interface GetPriceListFileUrlResponse {
333333
Url?: string;
334334
}
335335

336+
/**
337+
* <p>The requested resource can't be found.</p>
338+
* @public
339+
*/
340+
export class ResourceNotFoundException extends __BaseException {
341+
readonly name: "ResourceNotFoundException" = "ResourceNotFoundException";
342+
readonly $fault: "client" = "client";
343+
Message?: string;
344+
/**
345+
* @internal
346+
*/
347+
constructor(opts: __ExceptionOptionType<ResourceNotFoundException, __BaseException>) {
348+
super({
349+
name: "ResourceNotFoundException",
350+
$fault: "client",
351+
...opts,
352+
});
353+
Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
354+
this.Message = opts.Message;
355+
}
356+
}
357+
336358
/**
337359
* @public
338360
* @enum

clients/client-pricing/src/protocols/Aws_json1_1.ts

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ import {
3939
InvalidParameterException,
4040
ListPriceListsRequest,
4141
NotFoundException,
42+
ResourceNotFoundException,
4243
ThrottlingException,
4344
} from "../models/models_0";
4445
import { PricingServiceException as __BaseException } from "../models/PricingServiceException";
@@ -239,6 +240,9 @@ const de_CommandError = async (output: __HttpResponse, context: __SerdeContext):
239240
case "AccessDeniedException":
240241
case "com.amazonaws.pricing#AccessDeniedException":
241242
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
243+
case "ResourceNotFoundException":
244+
case "com.amazonaws.pricing#ResourceNotFoundException":
245+
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
242246
default:
243247
const parsedBody = parsedOutput.body;
244248
return throwDefaultError({
@@ -342,6 +346,22 @@ const de_NotFoundExceptionRes = async (parsedOutput: any, context: __SerdeContex
342346
return __decorateServiceException(exception, body);
343347
};
344348

349+
/**
350+
* deserializeAws_json1_1ResourceNotFoundExceptionRes
351+
*/
352+
const de_ResourceNotFoundExceptionRes = async (
353+
parsedOutput: any,
354+
context: __SerdeContext
355+
): Promise<ResourceNotFoundException> => {
356+
const body = parsedOutput.body;
357+
const deserialized: any = _json(body);
358+
const exception = new ResourceNotFoundException({
359+
$metadata: deserializeMetadata(parsedOutput),
360+
...deserialized,
361+
});
362+
return __decorateServiceException(exception, body);
363+
};
364+
345365
/**
346366
* deserializeAws_json1_1ThrottlingExceptionRes
347367
*/
@@ -436,6 +456,8 @@ const de_PriceListJsonItems = (output: any, context: __SerdeContext): (__LazyJso
436456

437457
// de_PriceLists omitted.
438458

459+
// de_ResourceNotFoundException omitted.
460+
439461
// de_Service omitted.
440462

441463
// de_ServiceList omitted.

codegen/sdk-codegen/aws-models/pricing.json

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1046,6 +1046,9 @@
10461046
{
10471047
"target": "com.amazonaws.pricing#NotFoundException"
10481048
},
1049+
{
1050+
"target": "com.amazonaws.pricing#ResourceNotFoundException"
1051+
},
10491052
{
10501053
"target": "com.amazonaws.pricing#ThrottlingException"
10511054
}
@@ -1261,6 +1264,9 @@
12611264
{
12621265
"target": "com.amazonaws.pricing#NotFoundException"
12631266
},
1267+
{
1268+
"target": "com.amazonaws.pricing#ResourceNotFoundException"
1269+
},
12641270
{
12651271
"target": "com.amazonaws.pricing#ThrottlingException"
12661272
}
@@ -1429,6 +1435,19 @@
14291435
}
14301436
}
14311437
},
1438+
"com.amazonaws.pricing#ResourceNotFoundException": {
1439+
"type": "structure",
1440+
"members": {
1441+
"Message": {
1442+
"target": "com.amazonaws.pricing#errorMessage"
1443+
}
1444+
},
1445+
"traits": {
1446+
"smithy.api#documentation": "<p>The requested resource can't be found.</p>",
1447+
"smithy.api#error": "client",
1448+
"smithy.api#httpError": 404
1449+
}
1450+
},
14321451
"com.amazonaws.pricing#Service": {
14331452
"type": "structure",
14341453
"members": {

0 commit comments

Comments
 (0)