diff --git a/Sources/SotoSmithyAWS/Smithy.swift b/Sources/SotoSmithyAWS/Smithy.swift index e033728..86a6ecd 100644 --- a/Sources/SotoSmithyAWS/Smithy.swift +++ b/Sources/SotoSmithyAWS/Smithy.swift @@ -52,7 +52,8 @@ extension Smithy { AwsIAMRequiredActionsTrait.self, AwsIAMDefineConditionKeysTrait.self, AwsIAMActionPermissionDescriptionTrait.self, - AwsDisableConditionKeyInferenceTrait.self, + AwsIAMConditionKeyValueTrait.self, + AwsIAMDisableConditionKeyInferenceTrait.self, AwsIAMSupportPrincipalTypesTrait.self, AwsIAMResourceTrait.self, // API Gateway traits diff --git a/Sources/SotoSmithyAWS/Traits/AwsIAMTraits.swift b/Sources/SotoSmithyAWS/Traits/AwsIAMTraits.swift index b52bad9..29b0c20 100644 --- a/Sources/SotoSmithyAWS/Traits/AwsIAMTraits.swift +++ b/Sources/SotoSmithyAWS/Traits/AwsIAMTraits.swift @@ -98,10 +98,20 @@ public struct AwsIAMDefineConditionKeysTrait: SingleValueTrait { } } +/// Uses the associated member’s value for the specified condition key. +public struct AwsIAMConditionKeyValueTrait: SingleValueTrait { + public static let staticName: ShapeId = "aws.iam#conditionKeyValue" + public var selector: Selector { TypeSelector() } + public let value: String + public init(value: String) { + self.value = value + } +} + /// Declares that the condition keys of a resource should not be inferred. -public struct AwsDisableConditionKeyInferenceTrait: StaticTrait { +public struct AwsIAMDisableConditionKeyInferenceTrait: StaticTrait { public static let staticName: ShapeId = "aws.iam#disableConditionKeyInference" - public var selector: Selector { TypeSelector() } + public var selector: Selector { OrSelector(TypeSelector(), TypeSelector()) } } /// Other actions that the invoker must be authorized to perform when executing the targeted operation.