module Stratosphere.Bedrock.Agent.PromptOverrideConfigurationProperty (
        module Exports, PromptOverrideConfigurationProperty(..),
        mkPromptOverrideConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.Bedrock.Agent.PromptConfigurationProperty as Exports
import Stratosphere.ResourceProperties
import Stratosphere.Value
data PromptOverrideConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-agent-promptoverrideconfiguration.html>
    PromptOverrideConfigurationProperty {PromptOverrideConfigurationProperty -> ()
haddock_workaround_ :: (),
                                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-agent-promptoverrideconfiguration.html#cfn-bedrock-agent-promptoverrideconfiguration-overridelambda>
                                         PromptOverrideConfigurationProperty -> Maybe (Value Text)
overrideLambda :: (Prelude.Maybe (Value Prelude.Text)),
                                         -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-agent-promptoverrideconfiguration.html#cfn-bedrock-agent-promptoverrideconfiguration-promptconfigurations>
                                         PromptOverrideConfigurationProperty
-> [PromptConfigurationProperty]
promptConfigurations :: [PromptConfigurationProperty]}
  deriving stock (PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty -> Bool
(PromptOverrideConfigurationProperty
 -> PromptOverrideConfigurationProperty -> Bool)
-> (PromptOverrideConfigurationProperty
    -> PromptOverrideConfigurationProperty -> Bool)
-> Eq PromptOverrideConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty -> Bool
== :: PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty -> Bool
$c/= :: PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty -> Bool
/= :: PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty -> Bool
Prelude.Eq, Int -> PromptOverrideConfigurationProperty -> ShowS
[PromptOverrideConfigurationProperty] -> ShowS
PromptOverrideConfigurationProperty -> String
(Int -> PromptOverrideConfigurationProperty -> ShowS)
-> (PromptOverrideConfigurationProperty -> String)
-> ([PromptOverrideConfigurationProperty] -> ShowS)
-> Show PromptOverrideConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> PromptOverrideConfigurationProperty -> ShowS
showsPrec :: Int -> PromptOverrideConfigurationProperty -> ShowS
$cshow :: PromptOverrideConfigurationProperty -> String
show :: PromptOverrideConfigurationProperty -> String
$cshowList :: [PromptOverrideConfigurationProperty] -> ShowS
showList :: [PromptOverrideConfigurationProperty] -> ShowS
Prelude.Show)
mkPromptOverrideConfigurationProperty ::
  [PromptConfigurationProperty]
  -> PromptOverrideConfigurationProperty
mkPromptOverrideConfigurationProperty :: [PromptConfigurationProperty]
-> PromptOverrideConfigurationProperty
mkPromptOverrideConfigurationProperty [PromptConfigurationProperty]
promptConfigurations
  = PromptOverrideConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       promptConfigurations :: [PromptConfigurationProperty]
promptConfigurations = [PromptConfigurationProperty]
promptConfigurations,
       overrideLambda :: Maybe (Value Text)
overrideLambda = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties PromptOverrideConfigurationProperty where
  toResourceProperties :: PromptOverrideConfigurationProperty -> ResourceProperties
toResourceProperties PromptOverrideConfigurationProperty {[PromptConfigurationProperty]
Maybe (Value Text)
()
haddock_workaround_ :: PromptOverrideConfigurationProperty -> ()
overrideLambda :: PromptOverrideConfigurationProperty -> Maybe (Value Text)
promptConfigurations :: PromptOverrideConfigurationProperty
-> [PromptConfigurationProperty]
haddock_workaround_ :: ()
overrideLambda :: Maybe (Value Text)
promptConfigurations :: [PromptConfigurationProperty]
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Bedrock::Agent.PromptOverrideConfiguration",
         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
"PromptConfigurations" Key -> [PromptConfigurationProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [PromptConfigurationProperty]
promptConfigurations]
                           ([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
"OverrideLambda" (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)
overrideLambda]))}
instance JSON.ToJSON PromptOverrideConfigurationProperty where
  toJSON :: PromptOverrideConfigurationProperty -> Value
toJSON PromptOverrideConfigurationProperty {[PromptConfigurationProperty]
Maybe (Value Text)
()
haddock_workaround_ :: PromptOverrideConfigurationProperty -> ()
overrideLambda :: PromptOverrideConfigurationProperty -> Maybe (Value Text)
promptConfigurations :: PromptOverrideConfigurationProperty
-> [PromptConfigurationProperty]
haddock_workaround_ :: ()
overrideLambda :: Maybe (Value Text)
promptConfigurations :: [PromptConfigurationProperty]
..}
    = [(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
"PromptConfigurations" Key -> [PromptConfigurationProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= [PromptConfigurationProperty]
promptConfigurations]
              ([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
"OverrideLambda" (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)
overrideLambda])))
instance Property "OverrideLambda" PromptOverrideConfigurationProperty where
  type PropertyType "OverrideLambda" PromptOverrideConfigurationProperty = Value Prelude.Text
  set :: PropertyType "OverrideLambda" PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty
set PropertyType "OverrideLambda" PromptOverrideConfigurationProperty
newValue PromptOverrideConfigurationProperty {[PromptConfigurationProperty]
Maybe (Value Text)
()
haddock_workaround_ :: PromptOverrideConfigurationProperty -> ()
overrideLambda :: PromptOverrideConfigurationProperty -> Maybe (Value Text)
promptConfigurations :: PromptOverrideConfigurationProperty
-> [PromptConfigurationProperty]
haddock_workaround_ :: ()
overrideLambda :: Maybe (Value Text)
promptConfigurations :: [PromptConfigurationProperty]
..}
    = PromptOverrideConfigurationProperty
        {overrideLambda :: Maybe (Value Text)
overrideLambda = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "OverrideLambda" PromptOverrideConfigurationProperty
Value Text
newValue, [PromptConfigurationProperty]
()
haddock_workaround_ :: ()
promptConfigurations :: [PromptConfigurationProperty]
haddock_workaround_ :: ()
promptConfigurations :: [PromptConfigurationProperty]
..}
instance Property "PromptConfigurations" PromptOverrideConfigurationProperty where
  type PropertyType "PromptConfigurations" PromptOverrideConfigurationProperty = [PromptConfigurationProperty]
  set :: PropertyType
  "PromptConfigurations" PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty
-> PromptOverrideConfigurationProperty
set PropertyType
  "PromptConfigurations" PromptOverrideConfigurationProperty
newValue PromptOverrideConfigurationProperty {[PromptConfigurationProperty]
Maybe (Value Text)
()
haddock_workaround_ :: PromptOverrideConfigurationProperty -> ()
overrideLambda :: PromptOverrideConfigurationProperty -> Maybe (Value Text)
promptConfigurations :: PromptOverrideConfigurationProperty
-> [PromptConfigurationProperty]
haddock_workaround_ :: ()
overrideLambda :: Maybe (Value Text)
promptConfigurations :: [PromptConfigurationProperty]
..}
    = PromptOverrideConfigurationProperty
        {promptConfigurations :: [PromptConfigurationProperty]
promptConfigurations = [PromptConfigurationProperty]
PropertyType
  "PromptConfigurations" PromptOverrideConfigurationProperty
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
overrideLambda :: Maybe (Value Text)
haddock_workaround_ :: ()
overrideLambda :: Maybe (Value Text)
..}