{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.CodePipeline.Types.ActionConfigurationProperty
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.CodePipeline.Types.ActionConfigurationProperty where

import Amazonka.CodePipeline.Types.ActionConfigurationPropertyType
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Represents information about an action configuration property.
--
-- /See:/ 'newActionConfigurationProperty' smart constructor.
data ActionConfigurationProperty = ActionConfigurationProperty'
  { -- | Indicates that the property is used with @PollForJobs@. When creating a
    -- custom action, an action can have up to one queryable property. If it
    -- has one, that property must be both required and not secret.
    --
    -- If you create a pipeline with a custom action type, and that custom
    -- action contains a queryable property, the value for that configuration
    -- property is subject to other restrictions. The value must be less than
    -- or equal to twenty (20) characters. The value can contain only
    -- alphanumeric characters, underscores, and hyphens.
    ActionConfigurationProperty -> Maybe Bool
queryable :: Prelude.Maybe Prelude.Bool,
    -- | The type of the configuration property.
    ActionConfigurationProperty
-> Maybe ActionConfigurationPropertyType
type' :: Prelude.Maybe ActionConfigurationPropertyType,
    -- | The description of the action configuration property that is displayed
    -- to users.
    ActionConfigurationProperty -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | The name of the action configuration property.
    ActionConfigurationProperty -> Text
name :: Prelude.Text,
    -- | Whether the configuration property is a required value.
    ActionConfigurationProperty -> Bool
required :: Prelude.Bool,
    -- | Whether the configuration property is a key.
    ActionConfigurationProperty -> Bool
key :: Prelude.Bool,
    -- | Whether the configuration property is secret. Secrets are hidden from
    -- all calls except for @GetJobDetails@, @GetThirdPartyJobDetails@,
    -- @PollForJobs@, and @PollForThirdPartyJobs@.
    --
    -- When updating a pipeline, passing * * * * * without changing any other
    -- values of the action preserves the previous value of the secret.
    ActionConfigurationProperty -> Bool
secret :: Prelude.Bool
  }
  deriving (ActionConfigurationProperty -> ActionConfigurationProperty -> Bool
(ActionConfigurationProperty
 -> ActionConfigurationProperty -> Bool)
-> (ActionConfigurationProperty
    -> ActionConfigurationProperty -> Bool)
-> Eq ActionConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ActionConfigurationProperty -> ActionConfigurationProperty -> Bool
$c/= :: ActionConfigurationProperty -> ActionConfigurationProperty -> Bool
== :: ActionConfigurationProperty -> ActionConfigurationProperty -> Bool
$c== :: ActionConfigurationProperty -> ActionConfigurationProperty -> Bool
Prelude.Eq, ReadPrec [ActionConfigurationProperty]
ReadPrec ActionConfigurationProperty
Int -> ReadS ActionConfigurationProperty
ReadS [ActionConfigurationProperty]
(Int -> ReadS ActionConfigurationProperty)
-> ReadS [ActionConfigurationProperty]
-> ReadPrec ActionConfigurationProperty
-> ReadPrec [ActionConfigurationProperty]
-> Read ActionConfigurationProperty
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ActionConfigurationProperty]
$creadListPrec :: ReadPrec [ActionConfigurationProperty]
readPrec :: ReadPrec ActionConfigurationProperty
$creadPrec :: ReadPrec ActionConfigurationProperty
readList :: ReadS [ActionConfigurationProperty]
$creadList :: ReadS [ActionConfigurationProperty]
readsPrec :: Int -> ReadS ActionConfigurationProperty
$creadsPrec :: Int -> ReadS ActionConfigurationProperty
Prelude.Read, Int -> ActionConfigurationProperty -> ShowS
[ActionConfigurationProperty] -> ShowS
ActionConfigurationProperty -> String
(Int -> ActionConfigurationProperty -> ShowS)
-> (ActionConfigurationProperty -> String)
-> ([ActionConfigurationProperty] -> ShowS)
-> Show ActionConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ActionConfigurationProperty] -> ShowS
$cshowList :: [ActionConfigurationProperty] -> ShowS
show :: ActionConfigurationProperty -> String
$cshow :: ActionConfigurationProperty -> String
showsPrec :: Int -> ActionConfigurationProperty -> ShowS
$cshowsPrec :: Int -> ActionConfigurationProperty -> ShowS
Prelude.Show, (forall x.
 ActionConfigurationProperty -> Rep ActionConfigurationProperty x)
-> (forall x.
    Rep ActionConfigurationProperty x -> ActionConfigurationProperty)
-> Generic ActionConfigurationProperty
forall x.
Rep ActionConfigurationProperty x -> ActionConfigurationProperty
forall x.
ActionConfigurationProperty -> Rep ActionConfigurationProperty x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ActionConfigurationProperty x -> ActionConfigurationProperty
$cfrom :: forall x.
ActionConfigurationProperty -> Rep ActionConfigurationProperty x
Prelude.Generic)

-- |
-- Create a value of 'ActionConfigurationProperty' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'queryable', 'actionConfigurationProperty_queryable' - Indicates that the property is used with @PollForJobs@. When creating a
-- custom action, an action can have up to one queryable property. If it
-- has one, that property must be both required and not secret.
--
-- If you create a pipeline with a custom action type, and that custom
-- action contains a queryable property, the value for that configuration
-- property is subject to other restrictions. The value must be less than
-- or equal to twenty (20) characters. The value can contain only
-- alphanumeric characters, underscores, and hyphens.
--
-- 'type'', 'actionConfigurationProperty_type' - The type of the configuration property.
--
-- 'description', 'actionConfigurationProperty_description' - The description of the action configuration property that is displayed
-- to users.
--
-- 'name', 'actionConfigurationProperty_name' - The name of the action configuration property.
--
-- 'required', 'actionConfigurationProperty_required' - Whether the configuration property is a required value.
--
-- 'key', 'actionConfigurationProperty_key' - Whether the configuration property is a key.
--
-- 'secret', 'actionConfigurationProperty_secret' - Whether the configuration property is secret. Secrets are hidden from
-- all calls except for @GetJobDetails@, @GetThirdPartyJobDetails@,
-- @PollForJobs@, and @PollForThirdPartyJobs@.
--
-- When updating a pipeline, passing * * * * * without changing any other
-- values of the action preserves the previous value of the secret.
newActionConfigurationProperty ::
  -- | 'name'
  Prelude.Text ->
  -- | 'required'
  Prelude.Bool ->
  -- | 'key'
  Prelude.Bool ->
  -- | 'secret'
  Prelude.Bool ->
  ActionConfigurationProperty
newActionConfigurationProperty :: Text -> Bool -> Bool -> Bool -> ActionConfigurationProperty
newActionConfigurationProperty
  Text
pName_
  Bool
pRequired_
  Bool
pKey_
  Bool
pSecret_ =
    ActionConfigurationProperty' :: Maybe Bool
-> Maybe ActionConfigurationPropertyType
-> Maybe Text
-> Text
-> Bool
-> Bool
-> Bool
-> ActionConfigurationProperty
ActionConfigurationProperty'
      { $sel:queryable:ActionConfigurationProperty' :: Maybe Bool
queryable =
          Maybe Bool
forall a. Maybe a
Prelude.Nothing,
        $sel:type':ActionConfigurationProperty' :: Maybe ActionConfigurationPropertyType
type' = Maybe ActionConfigurationPropertyType
forall a. Maybe a
Prelude.Nothing,
        $sel:description:ActionConfigurationProperty' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:name:ActionConfigurationProperty' :: Text
name = Text
pName_,
        $sel:required:ActionConfigurationProperty' :: Bool
required = Bool
pRequired_,
        $sel:key:ActionConfigurationProperty' :: Bool
key = Bool
pKey_,
        $sel:secret:ActionConfigurationProperty' :: Bool
secret = Bool
pSecret_
      }

-- | Indicates that the property is used with @PollForJobs@. When creating a
-- custom action, an action can have up to one queryable property. If it
-- has one, that property must be both required and not secret.
--
-- If you create a pipeline with a custom action type, and that custom
-- action contains a queryable property, the value for that configuration
-- property is subject to other restrictions. The value must be less than
-- or equal to twenty (20) characters. The value can contain only
-- alphanumeric characters, underscores, and hyphens.
actionConfigurationProperty_queryable :: Lens.Lens' ActionConfigurationProperty (Prelude.Maybe Prelude.Bool)
actionConfigurationProperty_queryable :: (Maybe Bool -> f (Maybe Bool))
-> ActionConfigurationProperty -> f ActionConfigurationProperty
actionConfigurationProperty_queryable = (ActionConfigurationProperty -> Maybe Bool)
-> (ActionConfigurationProperty
    -> Maybe Bool -> ActionConfigurationProperty)
-> Lens
     ActionConfigurationProperty
     ActionConfigurationProperty
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActionConfigurationProperty' {Maybe Bool
queryable :: Maybe Bool
$sel:queryable:ActionConfigurationProperty' :: ActionConfigurationProperty -> Maybe Bool
queryable} -> Maybe Bool
queryable) (\s :: ActionConfigurationProperty
s@ActionConfigurationProperty' {} Maybe Bool
a -> ActionConfigurationProperty
s {$sel:queryable:ActionConfigurationProperty' :: Maybe Bool
queryable = Maybe Bool
a} :: ActionConfigurationProperty)

-- | The type of the configuration property.
actionConfigurationProperty_type :: Lens.Lens' ActionConfigurationProperty (Prelude.Maybe ActionConfigurationPropertyType)
actionConfigurationProperty_type :: (Maybe ActionConfigurationPropertyType
 -> f (Maybe ActionConfigurationPropertyType))
-> ActionConfigurationProperty -> f ActionConfigurationProperty
actionConfigurationProperty_type = (ActionConfigurationProperty
 -> Maybe ActionConfigurationPropertyType)
-> (ActionConfigurationProperty
    -> Maybe ActionConfigurationPropertyType
    -> ActionConfigurationProperty)
-> Lens
     ActionConfigurationProperty
     ActionConfigurationProperty
     (Maybe ActionConfigurationPropertyType)
     (Maybe ActionConfigurationPropertyType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActionConfigurationProperty' {Maybe ActionConfigurationPropertyType
type' :: Maybe ActionConfigurationPropertyType
$sel:type':ActionConfigurationProperty' :: ActionConfigurationProperty
-> Maybe ActionConfigurationPropertyType
type'} -> Maybe ActionConfigurationPropertyType
type') (\s :: ActionConfigurationProperty
s@ActionConfigurationProperty' {} Maybe ActionConfigurationPropertyType
a -> ActionConfigurationProperty
s {$sel:type':ActionConfigurationProperty' :: Maybe ActionConfigurationPropertyType
type' = Maybe ActionConfigurationPropertyType
a} :: ActionConfigurationProperty)

-- | The description of the action configuration property that is displayed
-- to users.
actionConfigurationProperty_description :: Lens.Lens' ActionConfigurationProperty (Prelude.Maybe Prelude.Text)
actionConfigurationProperty_description :: (Maybe Text -> f (Maybe Text))
-> ActionConfigurationProperty -> f ActionConfigurationProperty
actionConfigurationProperty_description = (ActionConfigurationProperty -> Maybe Text)
-> (ActionConfigurationProperty
    -> Maybe Text -> ActionConfigurationProperty)
-> Lens
     ActionConfigurationProperty
     ActionConfigurationProperty
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActionConfigurationProperty' {Maybe Text
description :: Maybe Text
$sel:description:ActionConfigurationProperty' :: ActionConfigurationProperty -> Maybe Text
description} -> Maybe Text
description) (\s :: ActionConfigurationProperty
s@ActionConfigurationProperty' {} Maybe Text
a -> ActionConfigurationProperty
s {$sel:description:ActionConfigurationProperty' :: Maybe Text
description = Maybe Text
a} :: ActionConfigurationProperty)

-- | The name of the action configuration property.
actionConfigurationProperty_name :: Lens.Lens' ActionConfigurationProperty Prelude.Text
actionConfigurationProperty_name :: (Text -> f Text)
-> ActionConfigurationProperty -> f ActionConfigurationProperty
actionConfigurationProperty_name = (ActionConfigurationProperty -> Text)
-> (ActionConfigurationProperty
    -> Text -> ActionConfigurationProperty)
-> Lens
     ActionConfigurationProperty ActionConfigurationProperty Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActionConfigurationProperty' {Text
name :: Text
$sel:name:ActionConfigurationProperty' :: ActionConfigurationProperty -> Text
name} -> Text
name) (\s :: ActionConfigurationProperty
s@ActionConfigurationProperty' {} Text
a -> ActionConfigurationProperty
s {$sel:name:ActionConfigurationProperty' :: Text
name = Text
a} :: ActionConfigurationProperty)

-- | Whether the configuration property is a required value.
actionConfigurationProperty_required :: Lens.Lens' ActionConfigurationProperty Prelude.Bool
actionConfigurationProperty_required :: (Bool -> f Bool)
-> ActionConfigurationProperty -> f ActionConfigurationProperty
actionConfigurationProperty_required = (ActionConfigurationProperty -> Bool)
-> (ActionConfigurationProperty
    -> Bool -> ActionConfigurationProperty)
-> Lens
     ActionConfigurationProperty ActionConfigurationProperty Bool Bool
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActionConfigurationProperty' {Bool
required :: Bool
$sel:required:ActionConfigurationProperty' :: ActionConfigurationProperty -> Bool
required} -> Bool
required) (\s :: ActionConfigurationProperty
s@ActionConfigurationProperty' {} Bool
a -> ActionConfigurationProperty
s {$sel:required:ActionConfigurationProperty' :: Bool
required = Bool
a} :: ActionConfigurationProperty)

-- | Whether the configuration property is a key.
actionConfigurationProperty_key :: Lens.Lens' ActionConfigurationProperty Prelude.Bool
actionConfigurationProperty_key :: (Bool -> f Bool)
-> ActionConfigurationProperty -> f ActionConfigurationProperty
actionConfigurationProperty_key = (ActionConfigurationProperty -> Bool)
-> (ActionConfigurationProperty
    -> Bool -> ActionConfigurationProperty)
-> Lens
     ActionConfigurationProperty ActionConfigurationProperty Bool Bool
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActionConfigurationProperty' {Bool
key :: Bool
$sel:key:ActionConfigurationProperty' :: ActionConfigurationProperty -> Bool
key} -> Bool
key) (\s :: ActionConfigurationProperty
s@ActionConfigurationProperty' {} Bool
a -> ActionConfigurationProperty
s {$sel:key:ActionConfigurationProperty' :: Bool
key = Bool
a} :: ActionConfigurationProperty)

-- | Whether the configuration property is secret. Secrets are hidden from
-- all calls except for @GetJobDetails@, @GetThirdPartyJobDetails@,
-- @PollForJobs@, and @PollForThirdPartyJobs@.
--
-- When updating a pipeline, passing * * * * * without changing any other
-- values of the action preserves the previous value of the secret.
actionConfigurationProperty_secret :: Lens.Lens' ActionConfigurationProperty Prelude.Bool
actionConfigurationProperty_secret :: (Bool -> f Bool)
-> ActionConfigurationProperty -> f ActionConfigurationProperty
actionConfigurationProperty_secret = (ActionConfigurationProperty -> Bool)
-> (ActionConfigurationProperty
    -> Bool -> ActionConfigurationProperty)
-> Lens
     ActionConfigurationProperty ActionConfigurationProperty Bool Bool
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ActionConfigurationProperty' {Bool
secret :: Bool
$sel:secret:ActionConfigurationProperty' :: ActionConfigurationProperty -> Bool
secret} -> Bool
secret) (\s :: ActionConfigurationProperty
s@ActionConfigurationProperty' {} Bool
a -> ActionConfigurationProperty
s {$sel:secret:ActionConfigurationProperty' :: Bool
secret = Bool
a} :: ActionConfigurationProperty)

instance Core.FromJSON ActionConfigurationProperty where
  parseJSON :: Value -> Parser ActionConfigurationProperty
parseJSON =
    String
-> (Object -> Parser ActionConfigurationProperty)
-> Value
-> Parser ActionConfigurationProperty
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"ActionConfigurationProperty"
      ( \Object
x ->
          Maybe Bool
-> Maybe ActionConfigurationPropertyType
-> Maybe Text
-> Text
-> Bool
-> Bool
-> Bool
-> ActionConfigurationProperty
ActionConfigurationProperty'
            (Maybe Bool
 -> Maybe ActionConfigurationPropertyType
 -> Maybe Text
 -> Text
 -> Bool
 -> Bool
 -> Bool
 -> ActionConfigurationProperty)
-> Parser (Maybe Bool)
-> Parser
     (Maybe ActionConfigurationPropertyType
      -> Maybe Text
      -> Text
      -> Bool
      -> Bool
      -> Bool
      -> ActionConfigurationProperty)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"queryable")
            Parser
  (Maybe ActionConfigurationPropertyType
   -> Maybe Text
   -> Text
   -> Bool
   -> Bool
   -> Bool
   -> ActionConfigurationProperty)
-> Parser (Maybe ActionConfigurationPropertyType)
-> Parser
     (Maybe Text
      -> Text -> Bool -> Bool -> Bool -> ActionConfigurationProperty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ActionConfigurationPropertyType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"type")
            Parser
  (Maybe Text
   -> Text -> Bool -> Bool -> Bool -> ActionConfigurationProperty)
-> Parser (Maybe Text)
-> Parser
     (Text -> Bool -> Bool -> Bool -> ActionConfigurationProperty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"description")
            Parser
  (Text -> Bool -> Bool -> Bool -> ActionConfigurationProperty)
-> Parser Text
-> Parser (Bool -> Bool -> Bool -> ActionConfigurationProperty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"name")
            Parser (Bool -> Bool -> Bool -> ActionConfigurationProperty)
-> Parser Bool
-> Parser (Bool -> Bool -> ActionConfigurationProperty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Bool
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"required")
            Parser (Bool -> Bool -> ActionConfigurationProperty)
-> Parser Bool -> Parser (Bool -> ActionConfigurationProperty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Bool
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"key")
            Parser (Bool -> ActionConfigurationProperty)
-> Parser Bool -> Parser ActionConfigurationProperty
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Bool
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"secret")
      )

instance Prelude.Hashable ActionConfigurationProperty

instance Prelude.NFData ActionConfigurationProperty

instance Core.ToJSON ActionConfigurationProperty where
  toJSON :: ActionConfigurationProperty -> Value
toJSON ActionConfigurationProperty' {Bool
Maybe Bool
Maybe Text
Maybe ActionConfigurationPropertyType
Text
secret :: Bool
key :: Bool
required :: Bool
name :: Text
description :: Maybe Text
type' :: Maybe ActionConfigurationPropertyType
queryable :: Maybe Bool
$sel:secret:ActionConfigurationProperty' :: ActionConfigurationProperty -> Bool
$sel:key:ActionConfigurationProperty' :: ActionConfigurationProperty -> Bool
$sel:required:ActionConfigurationProperty' :: ActionConfigurationProperty -> Bool
$sel:name:ActionConfigurationProperty' :: ActionConfigurationProperty -> Text
$sel:description:ActionConfigurationProperty' :: ActionConfigurationProperty -> Maybe Text
$sel:type':ActionConfigurationProperty' :: ActionConfigurationProperty
-> Maybe ActionConfigurationPropertyType
$sel:queryable:ActionConfigurationProperty' :: ActionConfigurationProperty -> Maybe Bool
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"queryable" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
queryable,
            (Text
"type" Text -> ActionConfigurationPropertyType -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (ActionConfigurationPropertyType -> Pair)
-> Maybe ActionConfigurationPropertyType -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ActionConfigurationPropertyType
type',
            (Text
"description" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
description,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
name),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"required" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Bool
required),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"key" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Bool
key),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"secret" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Bool
secret)
          ]
      )