@cdk8s/awscdk-resolver 0.0.405 → 0.0.407

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.
Files changed (78) hide show
  1. package/.jsii +3 -3
  2. package/lib/resolve.js +1 -1
  3. package/node_modules/@aws-sdk/client-cloudformation/README.md +10 -2
  4. package/node_modules/@aws-sdk/client-cloudformation/dist-cjs/index.js +90 -30
  5. package/node_modules/@aws-sdk/client-cloudformation/dist-es/CloudFormation.js +2 -0
  6. package/node_modules/@aws-sdk/client-cloudformation/dist-es/commands/GetHookResultCommand.js +16 -0
  7. package/node_modules/@aws-sdk/client-cloudformation/dist-es/commands/index.js +1 -0
  8. package/node_modules/@aws-sdk/client-cloudformation/dist-es/models/models_0.js +29 -18
  9. package/node_modules/@aws-sdk/client-cloudformation/dist-es/models/models_1.js +7 -0
  10. package/node_modules/@aws-sdk/client-cloudformation/dist-es/schemas/schemas_0.js +43 -18
  11. package/node_modules/@aws-sdk/client-cloudformation/dist-types/CloudFormation.d.ts +15 -8
  12. package/node_modules/@aws-sdk/client-cloudformation/dist-types/CloudFormationClient.d.ts +10 -9
  13. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/ActivateTypeCommand.d.ts +1 -2
  14. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/DescribeChangeSetHooksCommand.d.ts +2 -2
  15. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/DescribeStackEventsCommand.d.ts +2 -2
  16. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/GetHookResultCommand.d.ts +104 -0
  17. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/ListHookResultsCommand.d.ts +2 -2
  18. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/ListStackSetOperationResultsCommand.d.ts +1 -1
  19. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/ListStackSetOperationsCommand.d.ts +1 -1
  20. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/SetTypeConfigurationCommand.d.ts +1 -2
  21. package/node_modules/@aws-sdk/client-cloudformation/dist-types/commands/index.d.ts +1 -0
  22. package/node_modules/@aws-sdk/client-cloudformation/dist-types/index.d.ts +7 -7
  23. package/node_modules/@aws-sdk/client-cloudformation/dist-types/models/models_0.d.ts +319 -434
  24. package/node_modules/@aws-sdk/client-cloudformation/dist-types/models/models_1.d.ts +328 -27
  25. package/node_modules/@aws-sdk/client-cloudformation/dist-types/schemas/schemas_0.d.ts +6 -0
  26. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/CloudFormation.d.ts +18 -1
  27. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/CloudFormationClient.d.ts +6 -0
  28. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/commands/DescribeStackEventsCommand.d.ts +1 -1
  29. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/commands/GetHookResultCommand.d.ts +47 -0
  30. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/commands/ListStackSetOperationResultsCommand.d.ts +1 -1
  31. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/commands/ListStackSetOperationsCommand.d.ts +1 -1
  32. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/commands/index.d.ts +1 -0
  33. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/models/models_0.d.ts +65 -58
  34. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/models/models_1.d.ts +54 -0
  35. package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/schemas/schemas_0.d.ts +6 -0
  36. package/node_modules/@aws-sdk/client-cloudformation/package.json +5 -5
  37. package/node_modules/@aws-sdk/client-sso/package.json +4 -4
  38. package/node_modules/@aws-sdk/core/dist-cjs/index.js +44 -17
  39. package/node_modules/@aws-sdk/core/dist-cjs/submodules/protocols/index.js +44 -17
  40. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/ProtocolLib.js +19 -3
  41. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/cbor/AwsSmithyRpcV2CborProtocol.js +4 -3
  42. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsJsonRpcProtocol.js +4 -3
  43. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsRestJsonProtocol.js +13 -3
  44. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/query/AwsQueryProtocol.js +2 -2
  45. package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/xml/AwsRestXmlProtocol.js +2 -2
  46. package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/ProtocolLib.d.ts +7 -1
  47. package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/AwsJsonRpcProtocol.d.ts +3 -0
  48. package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/json/AwsRestJsonProtocol.d.ts +11 -1
  49. package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/query/AwsQueryProtocol.d.ts +3 -0
  50. package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/xml/AwsRestXmlProtocol.d.ts +3 -0
  51. package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/ProtocolLib.d.ts +7 -1
  52. package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/json/AwsRestJsonProtocol.d.ts +6 -0
  53. package/node_modules/@aws-sdk/core/package.json +1 -1
  54. package/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
  55. package/node_modules/@aws-sdk/credential-provider-http/package.json +2 -2
  56. package/node_modules/@aws-sdk/credential-provider-ini/package.json +8 -8
  57. package/node_modules/@aws-sdk/credential-provider-node/package.json +7 -7
  58. package/node_modules/@aws-sdk/credential-provider-process/package.json +2 -2
  59. package/node_modules/@aws-sdk/credential-provider-sso/package.json +4 -4
  60. package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +3 -3
  61. package/node_modules/@aws-sdk/middleware-user-agent/package.json +2 -2
  62. package/node_modules/@aws-sdk/nested-clients/package.json +4 -4
  63. package/node_modules/@aws-sdk/token-providers/package.json +3 -3
  64. package/node_modules/@aws-sdk/util-user-agent-node/package.json +2 -2
  65. package/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js +0 -1
  66. package/node_modules/@smithy/core/dist-cjs/submodules/schema/index.js +3 -0
  67. package/node_modules/@smithy/core/dist-es/submodules/cbor/SmithyRpcV2CborProtocol.js +0 -1
  68. package/node_modules/@smithy/core/dist-es/submodules/schema/middleware/schemaDeserializationMiddleware.js +3 -0
  69. package/node_modules/@smithy/core/package.json +2 -2
  70. package/node_modules/@smithy/middleware-endpoint/package.json +3 -3
  71. package/node_modules/@smithy/middleware-retry/package.json +2 -2
  72. package/node_modules/@smithy/middleware-serde/dist-cjs/index.js +3 -0
  73. package/node_modules/@smithy/middleware-serde/dist-es/deserializerMiddleware.js +3 -0
  74. package/node_modules/@smithy/middleware-serde/package.json +1 -1
  75. package/node_modules/@smithy/smithy-client/package.json +3 -3
  76. package/node_modules/@smithy/util-defaults-mode-browser/package.json +2 -2
  77. package/node_modules/@smithy/util-defaults-mode-node/package.json +2 -2
  78. package/package.json +2 -2
@@ -96,6 +96,30 @@ export declare class AlreadyExistsException extends __BaseException {
96
96
  opts: __ExceptionOptionType<AlreadyExistsException, __BaseException>
97
97
  );
98
98
  }
99
+ export declare const AnnotationSeverityLevel: {
100
+ readonly CRITICAL: "CRITICAL";
101
+ readonly HIGH: "HIGH";
102
+ readonly INFORMATIONAL: "INFORMATIONAL";
103
+ readonly LOW: "LOW";
104
+ readonly MEDIUM: "MEDIUM";
105
+ };
106
+ export type AnnotationSeverityLevel =
107
+ (typeof AnnotationSeverityLevel)[keyof typeof AnnotationSeverityLevel];
108
+ export declare const AnnotationStatus: {
109
+ readonly FAILED: "FAILED";
110
+ readonly PASSED: "PASSED";
111
+ readonly SKIPPED: "SKIPPED";
112
+ };
113
+ export type AnnotationStatus =
114
+ (typeof AnnotationStatus)[keyof typeof AnnotationStatus];
115
+ export interface Annotation {
116
+ AnnotationName?: string | undefined;
117
+ Status?: AnnotationStatus | undefined;
118
+ StatusMessage?: string | undefined;
119
+ RemediationMessage?: string | undefined;
120
+ RemediationLink?: string | undefined;
121
+ SeverityLevel?: AnnotationSeverityLevel | undefined;
122
+ }
99
123
  export declare const AttributeChangeType: {
100
124
  readonly Add: "Add";
101
125
  readonly Modify: "Modify";
@@ -962,7 +986,7 @@ export interface DescribeStackDriftDetectionStatusOutput {
962
986
  Timestamp: Date | undefined;
963
987
  }
964
988
  export interface DescribeStackEventsInput {
965
- StackName?: string | undefined;
989
+ StackName: string | undefined;
966
990
  NextToken?: string | undefined;
967
991
  }
968
992
  export declare const DetailedStatus: {
@@ -1543,6 +1567,46 @@ export interface GetGeneratedTemplateOutput {
1543
1567
  Status?: GeneratedTemplateStatus | undefined;
1544
1568
  TemplateBody?: string | undefined;
1545
1569
  }
1570
+ export interface GetHookResultInput {
1571
+ HookResultId?: string | undefined;
1572
+ }
1573
+ export declare const HookTargetAction: {
1574
+ readonly CREATE: "CREATE";
1575
+ readonly DELETE: "DELETE";
1576
+ readonly IMPORT: "IMPORT";
1577
+ readonly UPDATE: "UPDATE";
1578
+ };
1579
+ export type HookTargetAction =
1580
+ (typeof HookTargetAction)[keyof typeof HookTargetAction];
1581
+ export interface HookTarget {
1582
+ TargetType: HookTargetType | undefined;
1583
+ TargetTypeName: string | undefined;
1584
+ TargetId: string | undefined;
1585
+ Action: HookTargetAction | undefined;
1586
+ }
1587
+ export interface GetHookResultOutput {
1588
+ HookResultId?: string | undefined;
1589
+ InvocationPoint?: HookInvocationPoint | undefined;
1590
+ FailureMode?: HookFailureMode | undefined;
1591
+ TypeName?: string | undefined;
1592
+ OriginalTypeName?: string | undefined;
1593
+ TypeVersionId?: string | undefined;
1594
+ TypeConfigurationVersionId?: string | undefined;
1595
+ TypeArn?: string | undefined;
1596
+ Status?: HookStatus | undefined;
1597
+ HookStatusReason?: string | undefined;
1598
+ InvokedAt?: Date | undefined;
1599
+ Target?: HookTarget | undefined;
1600
+ Annotations?: Annotation[] | undefined;
1601
+ }
1602
+ export declare class HookResultNotFoundException extends __BaseException {
1603
+ readonly name: "HookResultNotFoundException";
1604
+ readonly $fault: "client";
1605
+ Message?: string | undefined;
1606
+ constructor(
1607
+ opts: __ExceptionOptionType<HookResultNotFoundException, __BaseException>
1608
+ );
1609
+ }
1546
1610
  export interface GetStackPolicyInput {
1547
1611
  StackName: string | undefined;
1548
1612
  }
@@ -1662,14 +1726,6 @@ export interface ListGeneratedTemplatesOutput {
1662
1726
  Summaries?: TemplateSummary[] | undefined;
1663
1727
  NextToken?: string | undefined;
1664
1728
  }
1665
- export declare class HookResultNotFoundException extends __BaseException {
1666
- readonly name: "HookResultNotFoundException";
1667
- readonly $fault: "client";
1668
- Message?: string | undefined;
1669
- constructor(
1670
- opts: __ExceptionOptionType<HookResultNotFoundException, __BaseException>
1671
- );
1672
- }
1673
1729
  export declare const ListHookResultsTargetType: {
1674
1730
  readonly CHANGE_SET: "CHANGE_SET";
1675
1731
  readonly CLOUD_CONTROL: "CLOUD_CONTROL";
@@ -1969,52 +2025,3 @@ export interface OperationResultFilter {
1969
2025
  Name?: OperationResultFilterName | undefined;
1970
2026
  Values?: string | undefined;
1971
2027
  }
1972
- export interface ListStackSetOperationResultsInput {
1973
- StackSetName: string | undefined;
1974
- OperationId: string | undefined;
1975
- NextToken?: string | undefined;
1976
- MaxResults?: number | undefined;
1977
- CallAs?: CallAs | undefined;
1978
- Filters?: OperationResultFilter[] | undefined;
1979
- }
1980
- export declare const StackSetOperationResultStatus: {
1981
- readonly CANCELLED: "CANCELLED";
1982
- readonly FAILED: "FAILED";
1983
- readonly PENDING: "PENDING";
1984
- readonly RUNNING: "RUNNING";
1985
- readonly SUCCEEDED: "SUCCEEDED";
1986
- };
1987
- export type StackSetOperationResultStatus =
1988
- (typeof StackSetOperationResultStatus)[keyof typeof StackSetOperationResultStatus];
1989
- export interface StackSetOperationResultSummary {
1990
- Account?: string | undefined;
1991
- Region?: string | undefined;
1992
- Status?: StackSetOperationResultStatus | undefined;
1993
- StatusReason?: string | undefined;
1994
- AccountGateResult?: AccountGateResult | undefined;
1995
- OrganizationalUnitId?: string | undefined;
1996
- }
1997
- export interface ListStackSetOperationResultsOutput {
1998
- Summaries?: StackSetOperationResultSummary[] | undefined;
1999
- NextToken?: string | undefined;
2000
- }
2001
- export interface ListStackSetOperationsInput {
2002
- StackSetName: string | undefined;
2003
- NextToken?: string | undefined;
2004
- MaxResults?: number | undefined;
2005
- CallAs?: CallAs | undefined;
2006
- }
2007
- export interface StackSetOperationSummary {
2008
- OperationId?: string | undefined;
2009
- Action?: StackSetOperationAction | undefined;
2010
- Status?: StackSetOperationStatus | undefined;
2011
- CreationTimestamp?: Date | undefined;
2012
- EndTimestamp?: Date | undefined;
2013
- StatusReason?: string | undefined;
2014
- StatusDetails?: StackSetOperationStatusDetails | undefined;
2015
- OperationPreferences?: StackSetOperationPreferences | undefined;
2016
- }
2017
- export interface ListStackSetOperationsOutput {
2018
- Summaries?: StackSetOperationSummary[] | undefined;
2019
- NextToken?: string | undefined;
2020
- }
@@ -1,6 +1,7 @@
1
1
  import { ExceptionOptionType as __ExceptionOptionType } from "@smithy/smithy-client";
2
2
  import { CloudFormationServiceException as __BaseException } from "./CloudFormationServiceException";
3
3
  import {
4
+ AccountGateResult,
4
5
  AutoDeployment,
5
6
  CallAs,
6
7
  Capability,
@@ -10,6 +11,7 @@ import {
10
11
  IdentityProvider,
11
12
  LoggingConfig,
12
13
  ManagedExecution,
14
+ OperationResultFilter,
13
15
  Parameter,
14
16
  PermissionModels,
15
17
  ProvisioningType,
@@ -19,13 +21,65 @@ import {
19
21
  RollbackConfiguration,
20
22
  ScanFilter,
21
23
  StackDriftStatus,
24
+ StackSetOperationAction,
22
25
  StackSetOperationPreferences,
26
+ StackSetOperationStatus,
27
+ StackSetOperationStatusDetails,
23
28
  StackSetStatus,
24
29
  Tag,
25
30
  TemplateConfiguration,
26
31
  ThirdPartyType,
27
32
  Visibility,
28
33
  } from "./models_0";
34
+ export interface ListStackSetOperationResultsInput {
35
+ StackSetName: string | undefined;
36
+ OperationId: string | undefined;
37
+ NextToken?: string | undefined;
38
+ MaxResults?: number | undefined;
39
+ CallAs?: CallAs | undefined;
40
+ Filters?: OperationResultFilter[] | undefined;
41
+ }
42
+ export declare const StackSetOperationResultStatus: {
43
+ readonly CANCELLED: "CANCELLED";
44
+ readonly FAILED: "FAILED";
45
+ readonly PENDING: "PENDING";
46
+ readonly RUNNING: "RUNNING";
47
+ readonly SUCCEEDED: "SUCCEEDED";
48
+ };
49
+ export type StackSetOperationResultStatus =
50
+ (typeof StackSetOperationResultStatus)[keyof typeof StackSetOperationResultStatus];
51
+ export interface StackSetOperationResultSummary {
52
+ Account?: string | undefined;
53
+ Region?: string | undefined;
54
+ Status?: StackSetOperationResultStatus | undefined;
55
+ StatusReason?: string | undefined;
56
+ AccountGateResult?: AccountGateResult | undefined;
57
+ OrganizationalUnitId?: string | undefined;
58
+ }
59
+ export interface ListStackSetOperationResultsOutput {
60
+ Summaries?: StackSetOperationResultSummary[] | undefined;
61
+ NextToken?: string | undefined;
62
+ }
63
+ export interface ListStackSetOperationsInput {
64
+ StackSetName: string | undefined;
65
+ NextToken?: string | undefined;
66
+ MaxResults?: number | undefined;
67
+ CallAs?: CallAs | undefined;
68
+ }
69
+ export interface StackSetOperationSummary {
70
+ OperationId?: string | undefined;
71
+ Action?: StackSetOperationAction | undefined;
72
+ Status?: StackSetOperationStatus | undefined;
73
+ CreationTimestamp?: Date | undefined;
74
+ EndTimestamp?: Date | undefined;
75
+ StatusReason?: string | undefined;
76
+ StatusDetails?: StackSetOperationStatusDetails | undefined;
77
+ OperationPreferences?: StackSetOperationPreferences | undefined;
78
+ }
79
+ export interface ListStackSetOperationsOutput {
80
+ Summaries?: StackSetOperationSummary[] | undefined;
81
+ NextToken?: string | undefined;
82
+ }
29
83
  export interface ListStackSetsInput {
30
84
  NextToken?: string | undefined;
31
85
  MaxResults?: number | undefined;
@@ -11,6 +11,7 @@ export declare var ActivateOrganizationsAccessOutput: StaticStructureSchema;
11
11
  export declare var ActivateTypeInput: StaticStructureSchema;
12
12
  export declare var ActivateTypeOutput: StaticStructureSchema;
13
13
  export declare var AlreadyExistsException: StaticErrorSchema;
14
+ export declare var Annotation: StaticStructureSchema;
14
15
  export declare var AutoDeployment: StaticStructureSchema;
15
16
  export declare var BatchDescribeTypeConfigurationsError: StaticStructureSchema;
16
17
  export declare var BatchDescribeTypeConfigurationsInput: StaticStructureSchema;
@@ -107,6 +108,8 @@ export declare var Export: StaticStructureSchema;
107
108
  export declare var GeneratedTemplateNotFoundException: StaticErrorSchema;
108
109
  export declare var GetGeneratedTemplateInput: StaticStructureSchema;
109
110
  export declare var GetGeneratedTemplateOutput: StaticStructureSchema;
111
+ export declare var GetHookResultInput: StaticStructureSchema;
112
+ export declare var GetHookResultOutput: StaticStructureSchema;
110
113
  export declare var GetStackPolicyInput: StaticStructureSchema;
111
114
  export declare var GetStackPolicyOutput: StaticStructureSchema;
112
115
  export declare var GetTemplateInput: StaticStructureSchema;
@@ -115,6 +118,7 @@ export declare var GetTemplateSummaryInput: StaticStructureSchema;
115
118
  export declare var GetTemplateSummaryOutput: StaticStructureSchema;
116
119
  export declare var HookResultNotFoundException: StaticErrorSchema;
117
120
  export declare var HookResultSummary: StaticStructureSchema;
121
+ export declare var HookTarget: StaticStructureSchema;
118
122
  export declare var ImportStacksToStackSetInput: StaticStructureSchema;
119
123
  export declare var ImportStacksToStackSetOutput: StaticStructureSchema;
120
124
  export declare var InsufficientCapabilitiesException: StaticErrorSchema;
@@ -288,6 +292,7 @@ export declare var CloudFormationServiceException: StaticErrorSchema;
288
292
  export declare var AccountLimitList: StaticListSchema;
289
293
  export declare var AccountList: number;
290
294
  export declare var AllowedValues: number;
295
+ export declare var AnnotationList: StaticListSchema;
291
296
  export declare var BatchDescribeTypeConfigurationsErrors: StaticListSchema;
292
297
  export declare var Capabilities: number;
293
298
  export declare var Changes: StaticListSchema;
@@ -410,6 +415,7 @@ export declare var EstimateTemplateCost: StaticOperationSchema;
410
415
  export declare var ExecuteChangeSet: StaticOperationSchema;
411
416
  export declare var ExecuteStackRefactor: StaticOperationSchema;
412
417
  export declare var GetGeneratedTemplate: StaticOperationSchema;
418
+ export declare var GetHookResult: StaticOperationSchema;
413
419
  export declare var GetStackPolicy: StaticOperationSchema;
414
420
  export declare var GetTemplate: StaticOperationSchema;
415
421
  export declare var GetTemplateSummary: StaticOperationSchema;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-cloudformation",
3
3
  "description": "AWS SDK for JavaScript Cloudformation Client for Node.js, Browser and React Native",
4
- "version": "3.930.0",
4
+ "version": "3.932.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "node ../../scripts/compilation/inline client-cloudformation",
@@ -20,17 +20,17 @@
20
20
  "dependencies": {
21
21
  "@aws-crypto/sha256-browser": "5.2.0",
22
22
  "@aws-crypto/sha256-js": "5.2.0",
23
- "@aws-sdk/core": "3.930.0",
24
- "@aws-sdk/credential-provider-node": "3.930.0",
23
+ "@aws-sdk/core": "3.932.0",
24
+ "@aws-sdk/credential-provider-node": "3.932.0",
25
25
  "@aws-sdk/middleware-host-header": "3.930.0",
26
26
  "@aws-sdk/middleware-logger": "3.930.0",
27
27
  "@aws-sdk/middleware-recursion-detection": "3.930.0",
28
- "@aws-sdk/middleware-user-agent": "3.930.0",
28
+ "@aws-sdk/middleware-user-agent": "3.932.0",
29
29
  "@aws-sdk/region-config-resolver": "3.930.0",
30
30
  "@aws-sdk/types": "3.930.0",
31
31
  "@aws-sdk/util-endpoints": "3.930.0",
32
32
  "@aws-sdk/util-user-agent-browser": "3.930.0",
33
- "@aws-sdk/util-user-agent-node": "3.930.0",
33
+ "@aws-sdk/util-user-agent-node": "3.932.0",
34
34
  "@smithy/config-resolver": "^4.4.3",
35
35
  "@smithy/core": "^3.18.2",
36
36
  "@smithy/fetch-http-handler": "^5.3.6",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-sso",
3
3
  "description": "AWS SDK for JavaScript Sso Client for Node.js, Browser and React Native",
4
- "version": "3.930.0",
4
+ "version": "3.932.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "node ../../scripts/compilation/inline client-sso",
@@ -20,16 +20,16 @@
20
20
  "dependencies": {
21
21
  "@aws-crypto/sha256-browser": "5.2.0",
22
22
  "@aws-crypto/sha256-js": "5.2.0",
23
- "@aws-sdk/core": "3.930.0",
23
+ "@aws-sdk/core": "3.932.0",
24
24
  "@aws-sdk/middleware-host-header": "3.930.0",
25
25
  "@aws-sdk/middleware-logger": "3.930.0",
26
26
  "@aws-sdk/middleware-recursion-detection": "3.930.0",
27
- "@aws-sdk/middleware-user-agent": "3.930.0",
27
+ "@aws-sdk/middleware-user-agent": "3.932.0",
28
28
  "@aws-sdk/region-config-resolver": "3.930.0",
29
29
  "@aws-sdk/types": "3.930.0",
30
30
  "@aws-sdk/util-endpoints": "3.930.0",
31
31
  "@aws-sdk/util-user-agent-browser": "3.930.0",
32
- "@aws-sdk/util-user-agent-node": "3.930.0",
32
+ "@aws-sdk/util-user-agent-node": "3.932.0",
33
33
  "@smithy/config-resolver": "^4.4.3",
34
34
  "@smithy/core": "^3.18.2",
35
35
  "@smithy/fetch-http-handler": "^5.3.6",
@@ -7,10 +7,10 @@ var client = require('@aws-sdk/core/client');
7
7
  var signatureV4 = require('@smithy/signature-v4');
8
8
  var cbor = require('@smithy/core/cbor');
9
9
  var schema = require('@smithy/core/schema');
10
+ var smithyClient = require('@smithy/smithy-client');
10
11
  var protocols = require('@smithy/core/protocols');
11
12
  var serde = require('@smithy/core/serde');
12
13
  var utilBase64 = require('@smithy/util-base64');
13
- var smithyClient = require('@smithy/smithy-client');
14
14
  var utilUtf8 = require('@smithy/util-utf8');
15
15
  var xmlBuilder = require('@aws-sdk/xml-builder');
16
16
 
@@ -340,6 +340,10 @@ function bindCallerConfig(config, credentialsProvider) {
340
340
  }
341
341
 
342
342
  class ProtocolLib {
343
+ queryCompat;
344
+ constructor(queryCompat = false) {
345
+ this.queryCompat = queryCompat;
346
+ }
343
347
  resolveRestContentType(defaultContentType, inputSchema) {
344
348
  const members = inputSchema.getMemberSchemas();
345
349
  const httpPayloadMember = Object.values(members).find((m) => {
@@ -379,7 +383,6 @@ class ProtocolLib {
379
383
  }
380
384
  const errorMetadata = {
381
385
  $metadata: metadata,
382
- $response: response,
383
386
  $fault: response.statusCode < 500 ? "client" : "server",
384
387
  };
385
388
  const registry = schema.TypeRegistry.for(namespace);
@@ -393,11 +396,23 @@ class ProtocolLib {
393
396
  const baseExceptionSchema = synthetic.getBaseException();
394
397
  if (baseExceptionSchema) {
395
398
  const ErrorCtor = synthetic.getErrorCtor(baseExceptionSchema) ?? Error;
396
- throw Object.assign(new ErrorCtor({ name: errorName }), errorMetadata, dataObject);
399
+ throw this.decorateServiceException(Object.assign(new ErrorCtor({ name: errorName }), errorMetadata), dataObject);
397
400
  }
398
- throw Object.assign(new Error(errorName), errorMetadata, dataObject);
401
+ throw this.decorateServiceException(Object.assign(new Error(errorName), errorMetadata), dataObject);
399
402
  }
400
403
  }
404
+ decorateServiceException(exception, additions = {}) {
405
+ if (this.queryCompat) {
406
+ const msg = exception.Message ?? additions.Message;
407
+ const error = smithyClient.decorateServiceException(exception, additions);
408
+ if (msg) {
409
+ error.Message = msg;
410
+ error.message = msg;
411
+ }
412
+ return error;
413
+ }
414
+ return smithyClient.decorateServiceException(exception, additions);
415
+ }
401
416
  setQueryCompatError(output, response) {
402
417
  const queryErrorHeader = response.headers?.["x-amzn-query-error"];
403
418
  if (output !== undefined && queryErrorHeader != null) {
@@ -430,10 +445,11 @@ class ProtocolLib {
430
445
 
431
446
  class AwsSmithyRpcV2CborProtocol extends cbor.SmithyRpcV2CborProtocol {
432
447
  awsQueryCompatible;
433
- mixin = new ProtocolLib();
448
+ mixin;
434
449
  constructor({ defaultNamespace, awsQueryCompatible, }) {
435
450
  super({ defaultNamespace });
436
451
  this.awsQueryCompatible = !!awsQueryCompatible;
452
+ this.mixin = new ProtocolLib(this.awsQueryCompatible);
437
453
  }
438
454
  async serializeRequest(operationSchema, input, context) {
439
455
  const request = await super.serializeRequest(operationSchema, input, context);
@@ -459,10 +475,10 @@ class AwsSmithyRpcV2CborProtocol extends cbor.SmithyRpcV2CborProtocol {
459
475
  if (this.awsQueryCompatible) {
460
476
  this.mixin.queryCompatOutput(dataObject, output);
461
477
  }
462
- throw Object.assign(exception, errorMetadata, {
478
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
463
479
  $fault: ns.getMergedTraits().error,
464
480
  message,
465
- }, output);
481
+ }, output), dataObject);
466
482
  }
467
483
  }
468
484
 
@@ -907,7 +923,7 @@ class AwsJsonRpcProtocol extends protocols.RpcProtocol {
907
923
  deserializer;
908
924
  serviceTarget;
909
925
  codec;
910
- mixin = new ProtocolLib();
926
+ mixin;
911
927
  awsQueryCompatible;
912
928
  constructor({ defaultNamespace, serviceTarget, awsQueryCompatible, }) {
913
929
  super({
@@ -924,6 +940,7 @@ class AwsJsonRpcProtocol extends protocols.RpcProtocol {
924
940
  this.serializer = this.codec.createSerializer();
925
941
  this.deserializer = this.codec.createDeserializer();
926
942
  this.awsQueryCompatible = !!awsQueryCompatible;
943
+ this.mixin = new ProtocolLib(this.awsQueryCompatible);
927
944
  }
928
945
  async serializeRequest(operationSchema, input, context) {
929
946
  const request = await super.serializeRequest(operationSchema, input, context);
@@ -963,10 +980,10 @@ class AwsJsonRpcProtocol extends protocols.RpcProtocol {
963
980
  if (this.awsQueryCompatible) {
964
981
  this.mixin.queryCompatOutput(dataObject, output);
965
982
  }
966
- throw Object.assign(exception, errorMetadata, {
983
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
967
984
  $fault: ns.getMergedTraits().error,
968
985
  message,
969
- }, output);
986
+ }, output), dataObject);
970
987
  }
971
988
  }
972
989
 
@@ -1048,11 +1065,21 @@ class AwsRestJsonProtocol extends protocols.HttpBindingProtocol {
1048
1065
  request.headers["content-type"] = contentType;
1049
1066
  }
1050
1067
  }
1051
- if (request.headers["content-type"] && !request.body) {
1068
+ if (request.body == null && request.headers["content-type"] === this.getDefaultContentType()) {
1052
1069
  request.body = "{}";
1053
1070
  }
1054
1071
  return request;
1055
1072
  }
1073
+ async deserializeResponse(operationSchema, context, response) {
1074
+ const output = await super.deserializeResponse(operationSchema, context, response);
1075
+ const outputSchema = schema.NormalizedSchema.of(operationSchema.output);
1076
+ for (const [name, member] of outputSchema.structIterator()) {
1077
+ if (member.getMemberTraits().httpPayload && !(name in output)) {
1078
+ output[name] = null;
1079
+ }
1080
+ }
1081
+ return output;
1082
+ }
1056
1083
  async handleError(operationSchema, context, response, dataObject, metadata) {
1057
1084
  const errorIdentifier = loadRestJsonErrorCode(response, dataObject) ?? "Unknown";
1058
1085
  const { errorSchema, errorMetadata } = await this.mixin.getErrorSchemaOrThrowBaseException(errorIdentifier, this.options.defaultNamespace, response, dataObject, metadata);
@@ -1066,10 +1093,10 @@ class AwsRestJsonProtocol extends protocols.HttpBindingProtocol {
1066
1093
  const target = member.getMergedTraits().jsonName ?? name;
1067
1094
  output[name] = this.codec.createDeserializer().readObject(member, dataObject[target]);
1068
1095
  }
1069
- throw Object.assign(exception, errorMetadata, {
1096
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
1070
1097
  $fault: ns.getMergedTraits().error,
1071
1098
  message,
1072
- }, output);
1099
+ }, output), dataObject);
1073
1100
  }
1074
1101
  getDefaultContentType() {
1075
1102
  return "application/json";
@@ -1485,10 +1512,10 @@ class AwsQueryProtocol extends protocols.RpcProtocol {
1485
1512
  const value = errorData[target] ?? dataObject[target];
1486
1513
  output[name] = this.deserializer.readSchema(member, value);
1487
1514
  }
1488
- throw Object.assign(exception, errorMetadata, {
1515
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
1489
1516
  $fault: ns.getMergedTraits().error,
1490
1517
  message,
1491
- }, output);
1518
+ }, output), dataObject);
1492
1519
  }
1493
1520
  loadQueryErrorCode(output, data) {
1494
1521
  const code = (data.Errors?.[0]?.Error ?? data.Errors?.Error ?? data.Error)?.Code;
@@ -1922,10 +1949,10 @@ class AwsRestXmlProtocol extends protocols.HttpBindingProtocol {
1922
1949
  const value = dataObject.Error?.[target] ?? dataObject[target];
1923
1950
  output[name] = this.codec.createDeserializer().readSchema(member, value);
1924
1951
  }
1925
- throw Object.assign(exception, errorMetadata, {
1952
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
1926
1953
  $fault: ns.getMergedTraits().error,
1927
1954
  message,
1928
- }, output);
1955
+ }, output), dataObject);
1929
1956
  }
1930
1957
  getDefaultContentType() {
1931
1958
  return "application/xml";
@@ -2,14 +2,18 @@
2
2
 
3
3
  var cbor = require('@smithy/core/cbor');
4
4
  var schema = require('@smithy/core/schema');
5
+ var smithyClient = require('@smithy/smithy-client');
5
6
  var protocols = require('@smithy/core/protocols');
6
7
  var serde = require('@smithy/core/serde');
7
8
  var utilBase64 = require('@smithy/util-base64');
8
- var smithyClient = require('@smithy/smithy-client');
9
9
  var utilUtf8 = require('@smithy/util-utf8');
10
10
  var xmlBuilder = require('@aws-sdk/xml-builder');
11
11
 
12
12
  class ProtocolLib {
13
+ queryCompat;
14
+ constructor(queryCompat = false) {
15
+ this.queryCompat = queryCompat;
16
+ }
13
17
  resolveRestContentType(defaultContentType, inputSchema) {
14
18
  const members = inputSchema.getMemberSchemas();
15
19
  const httpPayloadMember = Object.values(members).find((m) => {
@@ -49,7 +53,6 @@ class ProtocolLib {
49
53
  }
50
54
  const errorMetadata = {
51
55
  $metadata: metadata,
52
- $response: response,
53
56
  $fault: response.statusCode < 500 ? "client" : "server",
54
57
  };
55
58
  const registry = schema.TypeRegistry.for(namespace);
@@ -63,11 +66,23 @@ class ProtocolLib {
63
66
  const baseExceptionSchema = synthetic.getBaseException();
64
67
  if (baseExceptionSchema) {
65
68
  const ErrorCtor = synthetic.getErrorCtor(baseExceptionSchema) ?? Error;
66
- throw Object.assign(new ErrorCtor({ name: errorName }), errorMetadata, dataObject);
69
+ throw this.decorateServiceException(Object.assign(new ErrorCtor({ name: errorName }), errorMetadata), dataObject);
67
70
  }
68
- throw Object.assign(new Error(errorName), errorMetadata, dataObject);
71
+ throw this.decorateServiceException(Object.assign(new Error(errorName), errorMetadata), dataObject);
69
72
  }
70
73
  }
74
+ decorateServiceException(exception, additions = {}) {
75
+ if (this.queryCompat) {
76
+ const msg = exception.Message ?? additions.Message;
77
+ const error = smithyClient.decorateServiceException(exception, additions);
78
+ if (msg) {
79
+ error.Message = msg;
80
+ error.message = msg;
81
+ }
82
+ return error;
83
+ }
84
+ return smithyClient.decorateServiceException(exception, additions);
85
+ }
71
86
  setQueryCompatError(output, response) {
72
87
  const queryErrorHeader = response.headers?.["x-amzn-query-error"];
73
88
  if (output !== undefined && queryErrorHeader != null) {
@@ -100,10 +115,11 @@ class ProtocolLib {
100
115
 
101
116
  class AwsSmithyRpcV2CborProtocol extends cbor.SmithyRpcV2CborProtocol {
102
117
  awsQueryCompatible;
103
- mixin = new ProtocolLib();
118
+ mixin;
104
119
  constructor({ defaultNamespace, awsQueryCompatible, }) {
105
120
  super({ defaultNamespace });
106
121
  this.awsQueryCompatible = !!awsQueryCompatible;
122
+ this.mixin = new ProtocolLib(this.awsQueryCompatible);
107
123
  }
108
124
  async serializeRequest(operationSchema, input, context) {
109
125
  const request = await super.serializeRequest(operationSchema, input, context);
@@ -129,10 +145,10 @@ class AwsSmithyRpcV2CborProtocol extends cbor.SmithyRpcV2CborProtocol {
129
145
  if (this.awsQueryCompatible) {
130
146
  this.mixin.queryCompatOutput(dataObject, output);
131
147
  }
132
- throw Object.assign(exception, errorMetadata, {
148
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
133
149
  $fault: ns.getMergedTraits().error,
134
150
  message,
135
- }, output);
151
+ }, output), dataObject);
136
152
  }
137
153
  }
138
154
 
@@ -577,7 +593,7 @@ class AwsJsonRpcProtocol extends protocols.RpcProtocol {
577
593
  deserializer;
578
594
  serviceTarget;
579
595
  codec;
580
- mixin = new ProtocolLib();
596
+ mixin;
581
597
  awsQueryCompatible;
582
598
  constructor({ defaultNamespace, serviceTarget, awsQueryCompatible, }) {
583
599
  super({
@@ -594,6 +610,7 @@ class AwsJsonRpcProtocol extends protocols.RpcProtocol {
594
610
  this.serializer = this.codec.createSerializer();
595
611
  this.deserializer = this.codec.createDeserializer();
596
612
  this.awsQueryCompatible = !!awsQueryCompatible;
613
+ this.mixin = new ProtocolLib(this.awsQueryCompatible);
597
614
  }
598
615
  async serializeRequest(operationSchema, input, context) {
599
616
  const request = await super.serializeRequest(operationSchema, input, context);
@@ -633,10 +650,10 @@ class AwsJsonRpcProtocol extends protocols.RpcProtocol {
633
650
  if (this.awsQueryCompatible) {
634
651
  this.mixin.queryCompatOutput(dataObject, output);
635
652
  }
636
- throw Object.assign(exception, errorMetadata, {
653
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
637
654
  $fault: ns.getMergedTraits().error,
638
655
  message,
639
- }, output);
656
+ }, output), dataObject);
640
657
  }
641
658
  }
642
659
 
@@ -718,11 +735,21 @@ class AwsRestJsonProtocol extends protocols.HttpBindingProtocol {
718
735
  request.headers["content-type"] = contentType;
719
736
  }
720
737
  }
721
- if (request.headers["content-type"] && !request.body) {
738
+ if (request.body == null && request.headers["content-type"] === this.getDefaultContentType()) {
722
739
  request.body = "{}";
723
740
  }
724
741
  return request;
725
742
  }
743
+ async deserializeResponse(operationSchema, context, response) {
744
+ const output = await super.deserializeResponse(operationSchema, context, response);
745
+ const outputSchema = schema.NormalizedSchema.of(operationSchema.output);
746
+ for (const [name, member] of outputSchema.structIterator()) {
747
+ if (member.getMemberTraits().httpPayload && !(name in output)) {
748
+ output[name] = null;
749
+ }
750
+ }
751
+ return output;
752
+ }
726
753
  async handleError(operationSchema, context, response, dataObject, metadata) {
727
754
  const errorIdentifier = loadRestJsonErrorCode(response, dataObject) ?? "Unknown";
728
755
  const { errorSchema, errorMetadata } = await this.mixin.getErrorSchemaOrThrowBaseException(errorIdentifier, this.options.defaultNamespace, response, dataObject, metadata);
@@ -736,10 +763,10 @@ class AwsRestJsonProtocol extends protocols.HttpBindingProtocol {
736
763
  const target = member.getMergedTraits().jsonName ?? name;
737
764
  output[name] = this.codec.createDeserializer().readObject(member, dataObject[target]);
738
765
  }
739
- throw Object.assign(exception, errorMetadata, {
766
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
740
767
  $fault: ns.getMergedTraits().error,
741
768
  message,
742
- }, output);
769
+ }, output), dataObject);
743
770
  }
744
771
  getDefaultContentType() {
745
772
  return "application/json";
@@ -1155,10 +1182,10 @@ class AwsQueryProtocol extends protocols.RpcProtocol {
1155
1182
  const value = errorData[target] ?? dataObject[target];
1156
1183
  output[name] = this.deserializer.readSchema(member, value);
1157
1184
  }
1158
- throw Object.assign(exception, errorMetadata, {
1185
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
1159
1186
  $fault: ns.getMergedTraits().error,
1160
1187
  message,
1161
- }, output);
1188
+ }, output), dataObject);
1162
1189
  }
1163
1190
  loadQueryErrorCode(output, data) {
1164
1191
  const code = (data.Errors?.[0]?.Error ?? data.Errors?.Error ?? data.Error)?.Code;
@@ -1592,10 +1619,10 @@ class AwsRestXmlProtocol extends protocols.HttpBindingProtocol {
1592
1619
  const value = dataObject.Error?.[target] ?? dataObject[target];
1593
1620
  output[name] = this.codec.createDeserializer().readSchema(member, value);
1594
1621
  }
1595
- throw Object.assign(exception, errorMetadata, {
1622
+ throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
1596
1623
  $fault: ns.getMergedTraits().error,
1597
1624
  message,
1598
- }, output);
1625
+ }, output), dataObject);
1599
1626
  }
1600
1627
  getDefaultContentType() {
1601
1628
  return "application/xml";