module Stratosphere.Bedrock.KnowledgeBase.RedshiftServerlessAuthConfigurationProperty (
        RedshiftServerlessAuthConfigurationProperty(..),
        mkRedshiftServerlessAuthConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data RedshiftServerlessAuthConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-knowledgebase-redshiftserverlessauthconfiguration.html>
    RedshiftServerlessAuthConfigurationProperty {RedshiftServerlessAuthConfigurationProperty -> ()
haddock_workaround_ :: (),
                                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-knowledgebase-redshiftserverlessauthconfiguration.html#cfn-bedrock-knowledgebase-redshiftserverlessauthconfiguration-type>
                                                 RedshiftServerlessAuthConfigurationProperty -> Value Text
type' :: (Value Prelude.Text),
                                                 -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-knowledgebase-redshiftserverlessauthconfiguration.html#cfn-bedrock-knowledgebase-redshiftserverlessauthconfiguration-usernamepasswordsecretarn>
                                                 RedshiftServerlessAuthConfigurationProperty -> Maybe (Value Text)
usernamePasswordSecretArn :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty -> Bool
(RedshiftServerlessAuthConfigurationProperty
 -> RedshiftServerlessAuthConfigurationProperty -> Bool)
-> (RedshiftServerlessAuthConfigurationProperty
    -> RedshiftServerlessAuthConfigurationProperty -> Bool)
-> Eq RedshiftServerlessAuthConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty -> Bool
== :: RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty -> Bool
$c/= :: RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty -> Bool
/= :: RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty -> Bool
Prelude.Eq, Int -> RedshiftServerlessAuthConfigurationProperty -> ShowS
[RedshiftServerlessAuthConfigurationProperty] -> ShowS
RedshiftServerlessAuthConfigurationProperty -> String
(Int -> RedshiftServerlessAuthConfigurationProperty -> ShowS)
-> (RedshiftServerlessAuthConfigurationProperty -> String)
-> ([RedshiftServerlessAuthConfigurationProperty] -> ShowS)
-> Show RedshiftServerlessAuthConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> RedshiftServerlessAuthConfigurationProperty -> ShowS
showsPrec :: Int -> RedshiftServerlessAuthConfigurationProperty -> ShowS
$cshow :: RedshiftServerlessAuthConfigurationProperty -> String
show :: RedshiftServerlessAuthConfigurationProperty -> String
$cshowList :: [RedshiftServerlessAuthConfigurationProperty] -> ShowS
showList :: [RedshiftServerlessAuthConfigurationProperty] -> ShowS
Prelude.Show)
mkRedshiftServerlessAuthConfigurationProperty ::
  Value Prelude.Text -> RedshiftServerlessAuthConfigurationProperty
mkRedshiftServerlessAuthConfigurationProperty :: Value Text -> RedshiftServerlessAuthConfigurationProperty
mkRedshiftServerlessAuthConfigurationProperty Value Text
type'
  = RedshiftServerlessAuthConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), type' :: Value Text
type' = Value Text
type',
       usernamePasswordSecretArn :: Maybe (Value Text)
usernamePasswordSecretArn = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties RedshiftServerlessAuthConfigurationProperty where
  toResourceProperties :: RedshiftServerlessAuthConfigurationProperty -> ResourceProperties
toResourceProperties
    RedshiftServerlessAuthConfigurationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: RedshiftServerlessAuthConfigurationProperty -> ()
type' :: RedshiftServerlessAuthConfigurationProperty -> Value Text
usernamePasswordSecretArn :: RedshiftServerlessAuthConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
type' :: Value Text
usernamePasswordSecretArn :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Bedrock::KnowledgeBase.RedshiftServerlessAuthConfiguration",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
                           [Key
"Type" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
type']
                           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                              [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"UsernamePasswordSecretArn"
                                 (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
usernamePasswordSecretArn]))}
instance JSON.ToJSON RedshiftServerlessAuthConfigurationProperty where
  toJSON :: RedshiftServerlessAuthConfigurationProperty -> Value
toJSON RedshiftServerlessAuthConfigurationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: RedshiftServerlessAuthConfigurationProperty -> ()
type' :: RedshiftServerlessAuthConfigurationProperty -> Value Text
usernamePasswordSecretArn :: RedshiftServerlessAuthConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
type' :: Value Text
usernamePasswordSecretArn :: Maybe (Value Text)
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
              [Key
"Type" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
type']
              ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                 [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"UsernamePasswordSecretArn"
                    (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
usernamePasswordSecretArn])))
instance Property "Type" RedshiftServerlessAuthConfigurationProperty where
  type PropertyType "Type" RedshiftServerlessAuthConfigurationProperty = Value Prelude.Text
  set :: PropertyType "Type" RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty
set PropertyType "Type" RedshiftServerlessAuthConfigurationProperty
newValue RedshiftServerlessAuthConfigurationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: RedshiftServerlessAuthConfigurationProperty -> ()
type' :: RedshiftServerlessAuthConfigurationProperty -> Value Text
usernamePasswordSecretArn :: RedshiftServerlessAuthConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
type' :: Value Text
usernamePasswordSecretArn :: Maybe (Value Text)
..}
    = RedshiftServerlessAuthConfigurationProperty
        {type' :: Value Text
type' = PropertyType "Type" RedshiftServerlessAuthConfigurationProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
usernamePasswordSecretArn :: Maybe (Value Text)
haddock_workaround_ :: ()
usernamePasswordSecretArn :: Maybe (Value Text)
..}
instance Property "UsernamePasswordSecretArn" RedshiftServerlessAuthConfigurationProperty where
  type PropertyType "UsernamePasswordSecretArn" RedshiftServerlessAuthConfigurationProperty = Value Prelude.Text
  set :: PropertyType
  "UsernamePasswordSecretArn"
  RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty
-> RedshiftServerlessAuthConfigurationProperty
set PropertyType
  "UsernamePasswordSecretArn"
  RedshiftServerlessAuthConfigurationProperty
newValue RedshiftServerlessAuthConfigurationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: RedshiftServerlessAuthConfigurationProperty -> ()
type' :: RedshiftServerlessAuthConfigurationProperty -> Value Text
usernamePasswordSecretArn :: RedshiftServerlessAuthConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
type' :: Value Text
usernamePasswordSecretArn :: Maybe (Value Text)
..}
    = RedshiftServerlessAuthConfigurationProperty
        {usernamePasswordSecretArn :: Maybe (Value Text)
usernamePasswordSecretArn = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
  "UsernamePasswordSecretArn"
  RedshiftServerlessAuthConfigurationProperty
Value Text
newValue, ()
Value Text
haddock_workaround_ :: ()
type' :: Value Text
haddock_workaround_ :: ()
type' :: Value Text
..}