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

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

-- |
-- Module      : Amazonka.Wisdom.UpdateKnowledgeBaseTemplateUri
-- 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)
--
-- Updates the template URI of a knowledge base. This is only supported for
-- knowledge bases of type EXTERNAL. Include a single variable in
-- @${variable}@ format; this interpolated by Wisdom using ingested
-- content. For example, if you ingest a Salesforce article, it has an @Id@
-- value, and you can set the template URI to
-- @https:\/\/myInstanceName.lightning.force.com\/lightning\/r\/Knowledge__kav\/*${Id}*\/view@.
module Amazonka.Wisdom.UpdateKnowledgeBaseTemplateUri
  ( -- * Creating a Request
    UpdateKnowledgeBaseTemplateUri (..),
    newUpdateKnowledgeBaseTemplateUri,

    -- * Request Lenses
    updateKnowledgeBaseTemplateUri_knowledgeBaseId,
    updateKnowledgeBaseTemplateUri_templateUri,

    -- * Destructuring the Response
    UpdateKnowledgeBaseTemplateUriResponse (..),
    newUpdateKnowledgeBaseTemplateUriResponse,

    -- * Response Lenses
    updateKnowledgeBaseTemplateUriResponse_knowledgeBase,
    updateKnowledgeBaseTemplateUriResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.Wisdom.Types

-- | /See:/ 'newUpdateKnowledgeBaseTemplateUri' smart constructor.
data UpdateKnowledgeBaseTemplateUri = UpdateKnowledgeBaseTemplateUri'
  { -- | The the identifier of the knowledge base. Can be either the ID or the
    -- ARN. URLs cannot contain the ARN.
    UpdateKnowledgeBaseTemplateUri -> Text
knowledgeBaseId :: Prelude.Text,
    -- | The template URI to update.
    UpdateKnowledgeBaseTemplateUri -> Text
templateUri :: Prelude.Text
  }
  deriving (UpdateKnowledgeBaseTemplateUri
-> UpdateKnowledgeBaseTemplateUri -> Bool
(UpdateKnowledgeBaseTemplateUri
 -> UpdateKnowledgeBaseTemplateUri -> Bool)
-> (UpdateKnowledgeBaseTemplateUri
    -> UpdateKnowledgeBaseTemplateUri -> Bool)
-> Eq UpdateKnowledgeBaseTemplateUri
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateKnowledgeBaseTemplateUri
-> UpdateKnowledgeBaseTemplateUri -> Bool
$c/= :: UpdateKnowledgeBaseTemplateUri
-> UpdateKnowledgeBaseTemplateUri -> Bool
== :: UpdateKnowledgeBaseTemplateUri
-> UpdateKnowledgeBaseTemplateUri -> Bool
$c== :: UpdateKnowledgeBaseTemplateUri
-> UpdateKnowledgeBaseTemplateUri -> Bool
Prelude.Eq, ReadPrec [UpdateKnowledgeBaseTemplateUri]
ReadPrec UpdateKnowledgeBaseTemplateUri
Int -> ReadS UpdateKnowledgeBaseTemplateUri
ReadS [UpdateKnowledgeBaseTemplateUri]
(Int -> ReadS UpdateKnowledgeBaseTemplateUri)
-> ReadS [UpdateKnowledgeBaseTemplateUri]
-> ReadPrec UpdateKnowledgeBaseTemplateUri
-> ReadPrec [UpdateKnowledgeBaseTemplateUri]
-> Read UpdateKnowledgeBaseTemplateUri
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateKnowledgeBaseTemplateUri]
$creadListPrec :: ReadPrec [UpdateKnowledgeBaseTemplateUri]
readPrec :: ReadPrec UpdateKnowledgeBaseTemplateUri
$creadPrec :: ReadPrec UpdateKnowledgeBaseTemplateUri
readList :: ReadS [UpdateKnowledgeBaseTemplateUri]
$creadList :: ReadS [UpdateKnowledgeBaseTemplateUri]
readsPrec :: Int -> ReadS UpdateKnowledgeBaseTemplateUri
$creadsPrec :: Int -> ReadS UpdateKnowledgeBaseTemplateUri
Prelude.Read, Int -> UpdateKnowledgeBaseTemplateUri -> ShowS
[UpdateKnowledgeBaseTemplateUri] -> ShowS
UpdateKnowledgeBaseTemplateUri -> String
(Int -> UpdateKnowledgeBaseTemplateUri -> ShowS)
-> (UpdateKnowledgeBaseTemplateUri -> String)
-> ([UpdateKnowledgeBaseTemplateUri] -> ShowS)
-> Show UpdateKnowledgeBaseTemplateUri
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateKnowledgeBaseTemplateUri] -> ShowS
$cshowList :: [UpdateKnowledgeBaseTemplateUri] -> ShowS
show :: UpdateKnowledgeBaseTemplateUri -> String
$cshow :: UpdateKnowledgeBaseTemplateUri -> String
showsPrec :: Int -> UpdateKnowledgeBaseTemplateUri -> ShowS
$cshowsPrec :: Int -> UpdateKnowledgeBaseTemplateUri -> ShowS
Prelude.Show, (forall x.
 UpdateKnowledgeBaseTemplateUri
 -> Rep UpdateKnowledgeBaseTemplateUri x)
-> (forall x.
    Rep UpdateKnowledgeBaseTemplateUri x
    -> UpdateKnowledgeBaseTemplateUri)
-> Generic UpdateKnowledgeBaseTemplateUri
forall x.
Rep UpdateKnowledgeBaseTemplateUri x
-> UpdateKnowledgeBaseTemplateUri
forall x.
UpdateKnowledgeBaseTemplateUri
-> Rep UpdateKnowledgeBaseTemplateUri x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateKnowledgeBaseTemplateUri x
-> UpdateKnowledgeBaseTemplateUri
$cfrom :: forall x.
UpdateKnowledgeBaseTemplateUri
-> Rep UpdateKnowledgeBaseTemplateUri x
Prelude.Generic)

-- |
-- Create a value of 'UpdateKnowledgeBaseTemplateUri' 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:
--
-- 'knowledgeBaseId', 'updateKnowledgeBaseTemplateUri_knowledgeBaseId' - The the identifier of the knowledge base. Can be either the ID or the
-- ARN. URLs cannot contain the ARN.
--
-- 'templateUri', 'updateKnowledgeBaseTemplateUri_templateUri' - The template URI to update.
newUpdateKnowledgeBaseTemplateUri ::
  -- | 'knowledgeBaseId'
  Prelude.Text ->
  -- | 'templateUri'
  Prelude.Text ->
  UpdateKnowledgeBaseTemplateUri
newUpdateKnowledgeBaseTemplateUri :: Text -> Text -> UpdateKnowledgeBaseTemplateUri
newUpdateKnowledgeBaseTemplateUri
  Text
pKnowledgeBaseId_
  Text
pTemplateUri_ =
    UpdateKnowledgeBaseTemplateUri' :: Text -> Text -> UpdateKnowledgeBaseTemplateUri
UpdateKnowledgeBaseTemplateUri'
      { $sel:knowledgeBaseId:UpdateKnowledgeBaseTemplateUri' :: Text
knowledgeBaseId =
          Text
pKnowledgeBaseId_,
        $sel:templateUri:UpdateKnowledgeBaseTemplateUri' :: Text
templateUri = Text
pTemplateUri_
      }

-- | The the identifier of the knowledge base. Can be either the ID or the
-- ARN. URLs cannot contain the ARN.
updateKnowledgeBaseTemplateUri_knowledgeBaseId :: Lens.Lens' UpdateKnowledgeBaseTemplateUri Prelude.Text
updateKnowledgeBaseTemplateUri_knowledgeBaseId :: (Text -> f Text)
-> UpdateKnowledgeBaseTemplateUri
-> f UpdateKnowledgeBaseTemplateUri
updateKnowledgeBaseTemplateUri_knowledgeBaseId = (UpdateKnowledgeBaseTemplateUri -> Text)
-> (UpdateKnowledgeBaseTemplateUri
    -> Text -> UpdateKnowledgeBaseTemplateUri)
-> Lens
     UpdateKnowledgeBaseTemplateUri
     UpdateKnowledgeBaseTemplateUri
     Text
     Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateKnowledgeBaseTemplateUri' {Text
knowledgeBaseId :: Text
$sel:knowledgeBaseId:UpdateKnowledgeBaseTemplateUri' :: UpdateKnowledgeBaseTemplateUri -> Text
knowledgeBaseId} -> Text
knowledgeBaseId) (\s :: UpdateKnowledgeBaseTemplateUri
s@UpdateKnowledgeBaseTemplateUri' {} Text
a -> UpdateKnowledgeBaseTemplateUri
s {$sel:knowledgeBaseId:UpdateKnowledgeBaseTemplateUri' :: Text
knowledgeBaseId = Text
a} :: UpdateKnowledgeBaseTemplateUri)

-- | The template URI to update.
updateKnowledgeBaseTemplateUri_templateUri :: Lens.Lens' UpdateKnowledgeBaseTemplateUri Prelude.Text
updateKnowledgeBaseTemplateUri_templateUri :: (Text -> f Text)
-> UpdateKnowledgeBaseTemplateUri
-> f UpdateKnowledgeBaseTemplateUri
updateKnowledgeBaseTemplateUri_templateUri = (UpdateKnowledgeBaseTemplateUri -> Text)
-> (UpdateKnowledgeBaseTemplateUri
    -> Text -> UpdateKnowledgeBaseTemplateUri)
-> Lens
     UpdateKnowledgeBaseTemplateUri
     UpdateKnowledgeBaseTemplateUri
     Text
     Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateKnowledgeBaseTemplateUri' {Text
templateUri :: Text
$sel:templateUri:UpdateKnowledgeBaseTemplateUri' :: UpdateKnowledgeBaseTemplateUri -> Text
templateUri} -> Text
templateUri) (\s :: UpdateKnowledgeBaseTemplateUri
s@UpdateKnowledgeBaseTemplateUri' {} Text
a -> UpdateKnowledgeBaseTemplateUri
s {$sel:templateUri:UpdateKnowledgeBaseTemplateUri' :: Text
templateUri = Text
a} :: UpdateKnowledgeBaseTemplateUri)

instance
  Core.AWSRequest
    UpdateKnowledgeBaseTemplateUri
  where
  type
    AWSResponse UpdateKnowledgeBaseTemplateUri =
      UpdateKnowledgeBaseTemplateUriResponse
  request :: UpdateKnowledgeBaseTemplateUri
-> Request UpdateKnowledgeBaseTemplateUri
request = Service
-> UpdateKnowledgeBaseTemplateUri
-> Request UpdateKnowledgeBaseTemplateUri
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy UpdateKnowledgeBaseTemplateUri
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse UpdateKnowledgeBaseTemplateUri)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse UpdateKnowledgeBaseTemplateUri))
-> Logger
-> Service
-> Proxy UpdateKnowledgeBaseTemplateUri
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse UpdateKnowledgeBaseTemplateUri)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe KnowledgeBaseData
-> Int -> UpdateKnowledgeBaseTemplateUriResponse
UpdateKnowledgeBaseTemplateUriResponse'
            (Maybe KnowledgeBaseData
 -> Int -> UpdateKnowledgeBaseTemplateUriResponse)
-> Either String (Maybe KnowledgeBaseData)
-> Either String (Int -> UpdateKnowledgeBaseTemplateUriResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe KnowledgeBaseData)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"knowledgeBase")
            Either String (Int -> UpdateKnowledgeBaseTemplateUriResponse)
-> Either String Int
-> Either String UpdateKnowledgeBaseTemplateUriResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance
  Prelude.Hashable
    UpdateKnowledgeBaseTemplateUri

instance
  Prelude.NFData
    UpdateKnowledgeBaseTemplateUri

instance
  Core.ToHeaders
    UpdateKnowledgeBaseTemplateUri
  where
  toHeaders :: UpdateKnowledgeBaseTemplateUri -> ResponseHeaders
toHeaders =
    ResponseHeaders
-> UpdateKnowledgeBaseTemplateUri -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON UpdateKnowledgeBaseTemplateUri where
  toJSON :: UpdateKnowledgeBaseTemplateUri -> Value
toJSON UpdateKnowledgeBaseTemplateUri' {Text
templateUri :: Text
knowledgeBaseId :: Text
$sel:templateUri:UpdateKnowledgeBaseTemplateUri' :: UpdateKnowledgeBaseTemplateUri -> Text
$sel:knowledgeBaseId:UpdateKnowledgeBaseTemplateUri' :: UpdateKnowledgeBaseTemplateUri -> Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"templateUri" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
templateUri)]
      )

instance Core.ToPath UpdateKnowledgeBaseTemplateUri where
  toPath :: UpdateKnowledgeBaseTemplateUri -> ByteString
toPath UpdateKnowledgeBaseTemplateUri' {Text
templateUri :: Text
knowledgeBaseId :: Text
$sel:templateUri:UpdateKnowledgeBaseTemplateUri' :: UpdateKnowledgeBaseTemplateUri -> Text
$sel:knowledgeBaseId:UpdateKnowledgeBaseTemplateUri' :: UpdateKnowledgeBaseTemplateUri -> Text
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/knowledgeBases/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
knowledgeBaseId,
        ByteString
"/templateUri"
      ]

instance Core.ToQuery UpdateKnowledgeBaseTemplateUri where
  toQuery :: UpdateKnowledgeBaseTemplateUri -> QueryString
toQuery = QueryString -> UpdateKnowledgeBaseTemplateUri -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newUpdateKnowledgeBaseTemplateUriResponse' smart constructor.
data UpdateKnowledgeBaseTemplateUriResponse = UpdateKnowledgeBaseTemplateUriResponse'
  { -- | The knowledge base to update.
    UpdateKnowledgeBaseTemplateUriResponse -> Maybe KnowledgeBaseData
knowledgeBase :: Prelude.Maybe KnowledgeBaseData,
    -- | The response's http status code.
    UpdateKnowledgeBaseTemplateUriResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (UpdateKnowledgeBaseTemplateUriResponse
-> UpdateKnowledgeBaseTemplateUriResponse -> Bool
(UpdateKnowledgeBaseTemplateUriResponse
 -> UpdateKnowledgeBaseTemplateUriResponse -> Bool)
-> (UpdateKnowledgeBaseTemplateUriResponse
    -> UpdateKnowledgeBaseTemplateUriResponse -> Bool)
-> Eq UpdateKnowledgeBaseTemplateUriResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateKnowledgeBaseTemplateUriResponse
-> UpdateKnowledgeBaseTemplateUriResponse -> Bool
$c/= :: UpdateKnowledgeBaseTemplateUriResponse
-> UpdateKnowledgeBaseTemplateUriResponse -> Bool
== :: UpdateKnowledgeBaseTemplateUriResponse
-> UpdateKnowledgeBaseTemplateUriResponse -> Bool
$c== :: UpdateKnowledgeBaseTemplateUriResponse
-> UpdateKnowledgeBaseTemplateUriResponse -> Bool
Prelude.Eq, ReadPrec [UpdateKnowledgeBaseTemplateUriResponse]
ReadPrec UpdateKnowledgeBaseTemplateUriResponse
Int -> ReadS UpdateKnowledgeBaseTemplateUriResponse
ReadS [UpdateKnowledgeBaseTemplateUriResponse]
(Int -> ReadS UpdateKnowledgeBaseTemplateUriResponse)
-> ReadS [UpdateKnowledgeBaseTemplateUriResponse]
-> ReadPrec UpdateKnowledgeBaseTemplateUriResponse
-> ReadPrec [UpdateKnowledgeBaseTemplateUriResponse]
-> Read UpdateKnowledgeBaseTemplateUriResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateKnowledgeBaseTemplateUriResponse]
$creadListPrec :: ReadPrec [UpdateKnowledgeBaseTemplateUriResponse]
readPrec :: ReadPrec UpdateKnowledgeBaseTemplateUriResponse
$creadPrec :: ReadPrec UpdateKnowledgeBaseTemplateUriResponse
readList :: ReadS [UpdateKnowledgeBaseTemplateUriResponse]
$creadList :: ReadS [UpdateKnowledgeBaseTemplateUriResponse]
readsPrec :: Int -> ReadS UpdateKnowledgeBaseTemplateUriResponse
$creadsPrec :: Int -> ReadS UpdateKnowledgeBaseTemplateUriResponse
Prelude.Read, Int -> UpdateKnowledgeBaseTemplateUriResponse -> ShowS
[UpdateKnowledgeBaseTemplateUriResponse] -> ShowS
UpdateKnowledgeBaseTemplateUriResponse -> String
(Int -> UpdateKnowledgeBaseTemplateUriResponse -> ShowS)
-> (UpdateKnowledgeBaseTemplateUriResponse -> String)
-> ([UpdateKnowledgeBaseTemplateUriResponse] -> ShowS)
-> Show UpdateKnowledgeBaseTemplateUriResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateKnowledgeBaseTemplateUriResponse] -> ShowS
$cshowList :: [UpdateKnowledgeBaseTemplateUriResponse] -> ShowS
show :: UpdateKnowledgeBaseTemplateUriResponse -> String
$cshow :: UpdateKnowledgeBaseTemplateUriResponse -> String
showsPrec :: Int -> UpdateKnowledgeBaseTemplateUriResponse -> ShowS
$cshowsPrec :: Int -> UpdateKnowledgeBaseTemplateUriResponse -> ShowS
Prelude.Show, (forall x.
 UpdateKnowledgeBaseTemplateUriResponse
 -> Rep UpdateKnowledgeBaseTemplateUriResponse x)
-> (forall x.
    Rep UpdateKnowledgeBaseTemplateUriResponse x
    -> UpdateKnowledgeBaseTemplateUriResponse)
-> Generic UpdateKnowledgeBaseTemplateUriResponse
forall x.
Rep UpdateKnowledgeBaseTemplateUriResponse x
-> UpdateKnowledgeBaseTemplateUriResponse
forall x.
UpdateKnowledgeBaseTemplateUriResponse
-> Rep UpdateKnowledgeBaseTemplateUriResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateKnowledgeBaseTemplateUriResponse x
-> UpdateKnowledgeBaseTemplateUriResponse
$cfrom :: forall x.
UpdateKnowledgeBaseTemplateUriResponse
-> Rep UpdateKnowledgeBaseTemplateUriResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateKnowledgeBaseTemplateUriResponse' 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:
--
-- 'knowledgeBase', 'updateKnowledgeBaseTemplateUriResponse_knowledgeBase' - The knowledge base to update.
--
-- 'httpStatus', 'updateKnowledgeBaseTemplateUriResponse_httpStatus' - The response's http status code.
newUpdateKnowledgeBaseTemplateUriResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  UpdateKnowledgeBaseTemplateUriResponse
newUpdateKnowledgeBaseTemplateUriResponse :: Int -> UpdateKnowledgeBaseTemplateUriResponse
newUpdateKnowledgeBaseTemplateUriResponse
  Int
pHttpStatus_ =
    UpdateKnowledgeBaseTemplateUriResponse' :: Maybe KnowledgeBaseData
-> Int -> UpdateKnowledgeBaseTemplateUriResponse
UpdateKnowledgeBaseTemplateUriResponse'
      { $sel:knowledgeBase:UpdateKnowledgeBaseTemplateUriResponse' :: Maybe KnowledgeBaseData
knowledgeBase =
          Maybe KnowledgeBaseData
forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:UpdateKnowledgeBaseTemplateUriResponse' :: Int
httpStatus = Int
pHttpStatus_
      }

-- | The knowledge base to update.
updateKnowledgeBaseTemplateUriResponse_knowledgeBase :: Lens.Lens' UpdateKnowledgeBaseTemplateUriResponse (Prelude.Maybe KnowledgeBaseData)
updateKnowledgeBaseTemplateUriResponse_knowledgeBase :: (Maybe KnowledgeBaseData -> f (Maybe KnowledgeBaseData))
-> UpdateKnowledgeBaseTemplateUriResponse
-> f UpdateKnowledgeBaseTemplateUriResponse
updateKnowledgeBaseTemplateUriResponse_knowledgeBase = (UpdateKnowledgeBaseTemplateUriResponse -> Maybe KnowledgeBaseData)
-> (UpdateKnowledgeBaseTemplateUriResponse
    -> Maybe KnowledgeBaseData
    -> UpdateKnowledgeBaseTemplateUriResponse)
-> Lens
     UpdateKnowledgeBaseTemplateUriResponse
     UpdateKnowledgeBaseTemplateUriResponse
     (Maybe KnowledgeBaseData)
     (Maybe KnowledgeBaseData)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateKnowledgeBaseTemplateUriResponse' {Maybe KnowledgeBaseData
knowledgeBase :: Maybe KnowledgeBaseData
$sel:knowledgeBase:UpdateKnowledgeBaseTemplateUriResponse' :: UpdateKnowledgeBaseTemplateUriResponse -> Maybe KnowledgeBaseData
knowledgeBase} -> Maybe KnowledgeBaseData
knowledgeBase) (\s :: UpdateKnowledgeBaseTemplateUriResponse
s@UpdateKnowledgeBaseTemplateUriResponse' {} Maybe KnowledgeBaseData
a -> UpdateKnowledgeBaseTemplateUriResponse
s {$sel:knowledgeBase:UpdateKnowledgeBaseTemplateUriResponse' :: Maybe KnowledgeBaseData
knowledgeBase = Maybe KnowledgeBaseData
a} :: UpdateKnowledgeBaseTemplateUriResponse)

-- | The response's http status code.
updateKnowledgeBaseTemplateUriResponse_httpStatus :: Lens.Lens' UpdateKnowledgeBaseTemplateUriResponse Prelude.Int
updateKnowledgeBaseTemplateUriResponse_httpStatus :: (Int -> f Int)
-> UpdateKnowledgeBaseTemplateUriResponse
-> f UpdateKnowledgeBaseTemplateUriResponse
updateKnowledgeBaseTemplateUriResponse_httpStatus = (UpdateKnowledgeBaseTemplateUriResponse -> Int)
-> (UpdateKnowledgeBaseTemplateUriResponse
    -> Int -> UpdateKnowledgeBaseTemplateUriResponse)
-> Lens
     UpdateKnowledgeBaseTemplateUriResponse
     UpdateKnowledgeBaseTemplateUriResponse
     Int
     Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateKnowledgeBaseTemplateUriResponse' {Int
httpStatus :: Int
$sel:httpStatus:UpdateKnowledgeBaseTemplateUriResponse' :: UpdateKnowledgeBaseTemplateUriResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: UpdateKnowledgeBaseTemplateUriResponse
s@UpdateKnowledgeBaseTemplateUriResponse' {} Int
a -> UpdateKnowledgeBaseTemplateUriResponse
s {$sel:httpStatus:UpdateKnowledgeBaseTemplateUriResponse' :: Int
httpStatus = Int
a} :: UpdateKnowledgeBaseTemplateUriResponse)

instance
  Prelude.NFData
    UpdateKnowledgeBaseTemplateUriResponse