{-# 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.CustomerProfiles.ListProfileObjectTypeTemplates
-- 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)
--
-- Lists all of the template information for object types.
module Amazonka.CustomerProfiles.ListProfileObjectTypeTemplates
  ( -- * Creating a Request
    ListProfileObjectTypeTemplates (..),
    newListProfileObjectTypeTemplates,

    -- * Request Lenses
    listProfileObjectTypeTemplates_nextToken,
    listProfileObjectTypeTemplates_maxResults,

    -- * Destructuring the Response
    ListProfileObjectTypeTemplatesResponse (..),
    newListProfileObjectTypeTemplatesResponse,

    -- * Response Lenses
    listProfileObjectTypeTemplatesResponse_items,
    listProfileObjectTypeTemplatesResponse_nextToken,
    listProfileObjectTypeTemplatesResponse_httpStatus,
  )
where

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

-- | /See:/ 'newListProfileObjectTypeTemplates' smart constructor.
data ListProfileObjectTypeTemplates = ListProfileObjectTypeTemplates'
  { -- | The pagination token from the previous ListObjectTypeTemplates API call.
    ListProfileObjectTypeTemplates -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The maximum number of objects returned per page.
    ListProfileObjectTypeTemplates -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural
  }
  deriving (ListProfileObjectTypeTemplates
-> ListProfileObjectTypeTemplates -> Bool
(ListProfileObjectTypeTemplates
 -> ListProfileObjectTypeTemplates -> Bool)
-> (ListProfileObjectTypeTemplates
    -> ListProfileObjectTypeTemplates -> Bool)
-> Eq ListProfileObjectTypeTemplates
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListProfileObjectTypeTemplates
-> ListProfileObjectTypeTemplates -> Bool
$c/= :: ListProfileObjectTypeTemplates
-> ListProfileObjectTypeTemplates -> Bool
== :: ListProfileObjectTypeTemplates
-> ListProfileObjectTypeTemplates -> Bool
$c== :: ListProfileObjectTypeTemplates
-> ListProfileObjectTypeTemplates -> Bool
Prelude.Eq, ReadPrec [ListProfileObjectTypeTemplates]
ReadPrec ListProfileObjectTypeTemplates
Int -> ReadS ListProfileObjectTypeTemplates
ReadS [ListProfileObjectTypeTemplates]
(Int -> ReadS ListProfileObjectTypeTemplates)
-> ReadS [ListProfileObjectTypeTemplates]
-> ReadPrec ListProfileObjectTypeTemplates
-> ReadPrec [ListProfileObjectTypeTemplates]
-> Read ListProfileObjectTypeTemplates
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListProfileObjectTypeTemplates]
$creadListPrec :: ReadPrec [ListProfileObjectTypeTemplates]
readPrec :: ReadPrec ListProfileObjectTypeTemplates
$creadPrec :: ReadPrec ListProfileObjectTypeTemplates
readList :: ReadS [ListProfileObjectTypeTemplates]
$creadList :: ReadS [ListProfileObjectTypeTemplates]
readsPrec :: Int -> ReadS ListProfileObjectTypeTemplates
$creadsPrec :: Int -> ReadS ListProfileObjectTypeTemplates
Prelude.Read, Int -> ListProfileObjectTypeTemplates -> ShowS
[ListProfileObjectTypeTemplates] -> ShowS
ListProfileObjectTypeTemplates -> String
(Int -> ListProfileObjectTypeTemplates -> ShowS)
-> (ListProfileObjectTypeTemplates -> String)
-> ([ListProfileObjectTypeTemplates] -> ShowS)
-> Show ListProfileObjectTypeTemplates
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListProfileObjectTypeTemplates] -> ShowS
$cshowList :: [ListProfileObjectTypeTemplates] -> ShowS
show :: ListProfileObjectTypeTemplates -> String
$cshow :: ListProfileObjectTypeTemplates -> String
showsPrec :: Int -> ListProfileObjectTypeTemplates -> ShowS
$cshowsPrec :: Int -> ListProfileObjectTypeTemplates -> ShowS
Prelude.Show, (forall x.
 ListProfileObjectTypeTemplates
 -> Rep ListProfileObjectTypeTemplates x)
-> (forall x.
    Rep ListProfileObjectTypeTemplates x
    -> ListProfileObjectTypeTemplates)
-> Generic ListProfileObjectTypeTemplates
forall x.
Rep ListProfileObjectTypeTemplates x
-> ListProfileObjectTypeTemplates
forall x.
ListProfileObjectTypeTemplates
-> Rep ListProfileObjectTypeTemplates x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListProfileObjectTypeTemplates x
-> ListProfileObjectTypeTemplates
$cfrom :: forall x.
ListProfileObjectTypeTemplates
-> Rep ListProfileObjectTypeTemplates x
Prelude.Generic)

-- |
-- Create a value of 'ListProfileObjectTypeTemplates' 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:
--
-- 'nextToken', 'listProfileObjectTypeTemplates_nextToken' - The pagination token from the previous ListObjectTypeTemplates API call.
--
-- 'maxResults', 'listProfileObjectTypeTemplates_maxResults' - The maximum number of objects returned per page.
newListProfileObjectTypeTemplates ::
  ListProfileObjectTypeTemplates
newListProfileObjectTypeTemplates :: ListProfileObjectTypeTemplates
newListProfileObjectTypeTemplates =
  ListProfileObjectTypeTemplates' :: Maybe Text -> Maybe Natural -> ListProfileObjectTypeTemplates
ListProfileObjectTypeTemplates'
    { $sel:nextToken:ListProfileObjectTypeTemplates' :: Maybe Text
nextToken =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:maxResults:ListProfileObjectTypeTemplates' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing
    }

-- | The pagination token from the previous ListObjectTypeTemplates API call.
listProfileObjectTypeTemplates_nextToken :: Lens.Lens' ListProfileObjectTypeTemplates (Prelude.Maybe Prelude.Text)
listProfileObjectTypeTemplates_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListProfileObjectTypeTemplates
-> f ListProfileObjectTypeTemplates
listProfileObjectTypeTemplates_nextToken = (ListProfileObjectTypeTemplates -> Maybe Text)
-> (ListProfileObjectTypeTemplates
    -> Maybe Text -> ListProfileObjectTypeTemplates)
-> Lens
     ListProfileObjectTypeTemplates
     ListProfileObjectTypeTemplates
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProfileObjectTypeTemplates' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListProfileObjectTypeTemplates' :: ListProfileObjectTypeTemplates -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListProfileObjectTypeTemplates
s@ListProfileObjectTypeTemplates' {} Maybe Text
a -> ListProfileObjectTypeTemplates
s {$sel:nextToken:ListProfileObjectTypeTemplates' :: Maybe Text
nextToken = Maybe Text
a} :: ListProfileObjectTypeTemplates)

-- | The maximum number of objects returned per page.
listProfileObjectTypeTemplates_maxResults :: Lens.Lens' ListProfileObjectTypeTemplates (Prelude.Maybe Prelude.Natural)
listProfileObjectTypeTemplates_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListProfileObjectTypeTemplates
-> f ListProfileObjectTypeTemplates
listProfileObjectTypeTemplates_maxResults = (ListProfileObjectTypeTemplates -> Maybe Natural)
-> (ListProfileObjectTypeTemplates
    -> Maybe Natural -> ListProfileObjectTypeTemplates)
-> Lens
     ListProfileObjectTypeTemplates
     ListProfileObjectTypeTemplates
     (Maybe Natural)
     (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProfileObjectTypeTemplates' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListProfileObjectTypeTemplates' :: ListProfileObjectTypeTemplates -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListProfileObjectTypeTemplates
s@ListProfileObjectTypeTemplates' {} Maybe Natural
a -> ListProfileObjectTypeTemplates
s {$sel:maxResults:ListProfileObjectTypeTemplates' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListProfileObjectTypeTemplates)

instance
  Core.AWSRequest
    ListProfileObjectTypeTemplates
  where
  type
    AWSResponse ListProfileObjectTypeTemplates =
      ListProfileObjectTypeTemplatesResponse
  request :: ListProfileObjectTypeTemplates
-> Request ListProfileObjectTypeTemplates
request = Service
-> ListProfileObjectTypeTemplates
-> Request ListProfileObjectTypeTemplates
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
  response :: Logger
-> Service
-> Proxy ListProfileObjectTypeTemplates
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse ListProfileObjectTypeTemplates)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse ListProfileObjectTypeTemplates))
-> Logger
-> Service
-> Proxy ListProfileObjectTypeTemplates
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse ListProfileObjectTypeTemplates)))
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 [ListProfileObjectTypeTemplateItem]
-> Maybe Text -> Int -> ListProfileObjectTypeTemplatesResponse
ListProfileObjectTypeTemplatesResponse'
            (Maybe [ListProfileObjectTypeTemplateItem]
 -> Maybe Text -> Int -> ListProfileObjectTypeTemplatesResponse)
-> Either String (Maybe [ListProfileObjectTypeTemplateItem])
-> Either
     String
     (Maybe Text -> Int -> ListProfileObjectTypeTemplatesResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object
-> Text
-> Either
     String (Maybe (Maybe [ListProfileObjectTypeTemplateItem]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Items" Either String (Maybe (Maybe [ListProfileObjectTypeTemplateItem]))
-> Maybe [ListProfileObjectTypeTemplateItem]
-> Either String (Maybe [ListProfileObjectTypeTemplateItem])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [ListProfileObjectTypeTemplateItem]
forall a. Monoid a => a
Prelude.mempty)
            Either
  String
  (Maybe Text -> Int -> ListProfileObjectTypeTemplatesResponse)
-> Either String (Maybe Text)
-> Either String (Int -> ListProfileObjectTypeTemplatesResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"NextToken")
            Either String (Int -> ListProfileObjectTypeTemplatesResponse)
-> Either String Int
-> Either String ListProfileObjectTypeTemplatesResponse
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
    ListProfileObjectTypeTemplates

instance
  Prelude.NFData
    ListProfileObjectTypeTemplates

instance
  Core.ToHeaders
    ListProfileObjectTypeTemplates
  where
  toHeaders :: ListProfileObjectTypeTemplates -> ResponseHeaders
toHeaders =
    ResponseHeaders
-> ListProfileObjectTypeTemplates -> 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.ToPath ListProfileObjectTypeTemplates where
  toPath :: ListProfileObjectTypeTemplates -> ByteString
toPath = ByteString -> ListProfileObjectTypeTemplates -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/templates"

instance Core.ToQuery ListProfileObjectTypeTemplates where
  toQuery :: ListProfileObjectTypeTemplates -> QueryString
toQuery ListProfileObjectTypeTemplates' {Maybe Natural
Maybe Text
maxResults :: Maybe Natural
nextToken :: Maybe Text
$sel:maxResults:ListProfileObjectTypeTemplates' :: ListProfileObjectTypeTemplates -> Maybe Natural
$sel:nextToken:ListProfileObjectTypeTemplates' :: ListProfileObjectTypeTemplates -> Maybe Text
..} =
    [QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"next-token" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
nextToken,
        ByteString
"max-results" ByteString -> Maybe Natural -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Natural
maxResults
      ]

-- | /See:/ 'newListProfileObjectTypeTemplatesResponse' smart constructor.
data ListProfileObjectTypeTemplatesResponse = ListProfileObjectTypeTemplatesResponse'
  { -- | The list of ListProfileObjectType template instances.
    ListProfileObjectTypeTemplatesResponse
-> Maybe [ListProfileObjectTypeTemplateItem]
items :: Prelude.Maybe [ListProfileObjectTypeTemplateItem],
    -- | The pagination token from the previous ListObjectTypeTemplates API call.
    ListProfileObjectTypeTemplatesResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListProfileObjectTypeTemplatesResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListProfileObjectTypeTemplatesResponse
-> ListProfileObjectTypeTemplatesResponse -> Bool
(ListProfileObjectTypeTemplatesResponse
 -> ListProfileObjectTypeTemplatesResponse -> Bool)
-> (ListProfileObjectTypeTemplatesResponse
    -> ListProfileObjectTypeTemplatesResponse -> Bool)
-> Eq ListProfileObjectTypeTemplatesResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListProfileObjectTypeTemplatesResponse
-> ListProfileObjectTypeTemplatesResponse -> Bool
$c/= :: ListProfileObjectTypeTemplatesResponse
-> ListProfileObjectTypeTemplatesResponse -> Bool
== :: ListProfileObjectTypeTemplatesResponse
-> ListProfileObjectTypeTemplatesResponse -> Bool
$c== :: ListProfileObjectTypeTemplatesResponse
-> ListProfileObjectTypeTemplatesResponse -> Bool
Prelude.Eq, ReadPrec [ListProfileObjectTypeTemplatesResponse]
ReadPrec ListProfileObjectTypeTemplatesResponse
Int -> ReadS ListProfileObjectTypeTemplatesResponse
ReadS [ListProfileObjectTypeTemplatesResponse]
(Int -> ReadS ListProfileObjectTypeTemplatesResponse)
-> ReadS [ListProfileObjectTypeTemplatesResponse]
-> ReadPrec ListProfileObjectTypeTemplatesResponse
-> ReadPrec [ListProfileObjectTypeTemplatesResponse]
-> Read ListProfileObjectTypeTemplatesResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListProfileObjectTypeTemplatesResponse]
$creadListPrec :: ReadPrec [ListProfileObjectTypeTemplatesResponse]
readPrec :: ReadPrec ListProfileObjectTypeTemplatesResponse
$creadPrec :: ReadPrec ListProfileObjectTypeTemplatesResponse
readList :: ReadS [ListProfileObjectTypeTemplatesResponse]
$creadList :: ReadS [ListProfileObjectTypeTemplatesResponse]
readsPrec :: Int -> ReadS ListProfileObjectTypeTemplatesResponse
$creadsPrec :: Int -> ReadS ListProfileObjectTypeTemplatesResponse
Prelude.Read, Int -> ListProfileObjectTypeTemplatesResponse -> ShowS
[ListProfileObjectTypeTemplatesResponse] -> ShowS
ListProfileObjectTypeTemplatesResponse -> String
(Int -> ListProfileObjectTypeTemplatesResponse -> ShowS)
-> (ListProfileObjectTypeTemplatesResponse -> String)
-> ([ListProfileObjectTypeTemplatesResponse] -> ShowS)
-> Show ListProfileObjectTypeTemplatesResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListProfileObjectTypeTemplatesResponse] -> ShowS
$cshowList :: [ListProfileObjectTypeTemplatesResponse] -> ShowS
show :: ListProfileObjectTypeTemplatesResponse -> String
$cshow :: ListProfileObjectTypeTemplatesResponse -> String
showsPrec :: Int -> ListProfileObjectTypeTemplatesResponse -> ShowS
$cshowsPrec :: Int -> ListProfileObjectTypeTemplatesResponse -> ShowS
Prelude.Show, (forall x.
 ListProfileObjectTypeTemplatesResponse
 -> Rep ListProfileObjectTypeTemplatesResponse x)
-> (forall x.
    Rep ListProfileObjectTypeTemplatesResponse x
    -> ListProfileObjectTypeTemplatesResponse)
-> Generic ListProfileObjectTypeTemplatesResponse
forall x.
Rep ListProfileObjectTypeTemplatesResponse x
-> ListProfileObjectTypeTemplatesResponse
forall x.
ListProfileObjectTypeTemplatesResponse
-> Rep ListProfileObjectTypeTemplatesResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListProfileObjectTypeTemplatesResponse x
-> ListProfileObjectTypeTemplatesResponse
$cfrom :: forall x.
ListProfileObjectTypeTemplatesResponse
-> Rep ListProfileObjectTypeTemplatesResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListProfileObjectTypeTemplatesResponse' 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:
--
-- 'items', 'listProfileObjectTypeTemplatesResponse_items' - The list of ListProfileObjectType template instances.
--
-- 'nextToken', 'listProfileObjectTypeTemplatesResponse_nextToken' - The pagination token from the previous ListObjectTypeTemplates API call.
--
-- 'httpStatus', 'listProfileObjectTypeTemplatesResponse_httpStatus' - The response's http status code.
newListProfileObjectTypeTemplatesResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListProfileObjectTypeTemplatesResponse
newListProfileObjectTypeTemplatesResponse :: Int -> ListProfileObjectTypeTemplatesResponse
newListProfileObjectTypeTemplatesResponse
  Int
pHttpStatus_ =
    ListProfileObjectTypeTemplatesResponse' :: Maybe [ListProfileObjectTypeTemplateItem]
-> Maybe Text -> Int -> ListProfileObjectTypeTemplatesResponse
ListProfileObjectTypeTemplatesResponse'
      { $sel:items:ListProfileObjectTypeTemplatesResponse' :: Maybe [ListProfileObjectTypeTemplateItem]
items =
          Maybe [ListProfileObjectTypeTemplateItem]
forall a. Maybe a
Prelude.Nothing,
        $sel:nextToken:ListProfileObjectTypeTemplatesResponse' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:ListProfileObjectTypeTemplatesResponse' :: Int
httpStatus = Int
pHttpStatus_
      }

-- | The list of ListProfileObjectType template instances.
listProfileObjectTypeTemplatesResponse_items :: Lens.Lens' ListProfileObjectTypeTemplatesResponse (Prelude.Maybe [ListProfileObjectTypeTemplateItem])
listProfileObjectTypeTemplatesResponse_items :: (Maybe [ListProfileObjectTypeTemplateItem]
 -> f (Maybe [ListProfileObjectTypeTemplateItem]))
-> ListProfileObjectTypeTemplatesResponse
-> f ListProfileObjectTypeTemplatesResponse
listProfileObjectTypeTemplatesResponse_items = (ListProfileObjectTypeTemplatesResponse
 -> Maybe [ListProfileObjectTypeTemplateItem])
-> (ListProfileObjectTypeTemplatesResponse
    -> Maybe [ListProfileObjectTypeTemplateItem]
    -> ListProfileObjectTypeTemplatesResponse)
-> Lens
     ListProfileObjectTypeTemplatesResponse
     ListProfileObjectTypeTemplatesResponse
     (Maybe [ListProfileObjectTypeTemplateItem])
     (Maybe [ListProfileObjectTypeTemplateItem])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProfileObjectTypeTemplatesResponse' {Maybe [ListProfileObjectTypeTemplateItem]
items :: Maybe [ListProfileObjectTypeTemplateItem]
$sel:items:ListProfileObjectTypeTemplatesResponse' :: ListProfileObjectTypeTemplatesResponse
-> Maybe [ListProfileObjectTypeTemplateItem]
items} -> Maybe [ListProfileObjectTypeTemplateItem]
items) (\s :: ListProfileObjectTypeTemplatesResponse
s@ListProfileObjectTypeTemplatesResponse' {} Maybe [ListProfileObjectTypeTemplateItem]
a -> ListProfileObjectTypeTemplatesResponse
s {$sel:items:ListProfileObjectTypeTemplatesResponse' :: Maybe [ListProfileObjectTypeTemplateItem]
items = Maybe [ListProfileObjectTypeTemplateItem]
a} :: ListProfileObjectTypeTemplatesResponse) ((Maybe [ListProfileObjectTypeTemplateItem]
  -> f (Maybe [ListProfileObjectTypeTemplateItem]))
 -> ListProfileObjectTypeTemplatesResponse
 -> f ListProfileObjectTypeTemplatesResponse)
-> ((Maybe [ListProfileObjectTypeTemplateItem]
     -> f (Maybe [ListProfileObjectTypeTemplateItem]))
    -> Maybe [ListProfileObjectTypeTemplateItem]
    -> f (Maybe [ListProfileObjectTypeTemplateItem]))
-> (Maybe [ListProfileObjectTypeTemplateItem]
    -> f (Maybe [ListProfileObjectTypeTemplateItem]))
-> ListProfileObjectTypeTemplatesResponse
-> f ListProfileObjectTypeTemplatesResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [ListProfileObjectTypeTemplateItem]
  [ListProfileObjectTypeTemplateItem]
  [ListProfileObjectTypeTemplateItem]
  [ListProfileObjectTypeTemplateItem]
-> Iso
     (Maybe [ListProfileObjectTypeTemplateItem])
     (Maybe [ListProfileObjectTypeTemplateItem])
     (Maybe [ListProfileObjectTypeTemplateItem])
     (Maybe [ListProfileObjectTypeTemplateItem])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  [ListProfileObjectTypeTemplateItem]
  [ListProfileObjectTypeTemplateItem]
  [ListProfileObjectTypeTemplateItem]
  [ListProfileObjectTypeTemplateItem]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The pagination token from the previous ListObjectTypeTemplates API call.
listProfileObjectTypeTemplatesResponse_nextToken :: Lens.Lens' ListProfileObjectTypeTemplatesResponse (Prelude.Maybe Prelude.Text)
listProfileObjectTypeTemplatesResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListProfileObjectTypeTemplatesResponse
-> f ListProfileObjectTypeTemplatesResponse
listProfileObjectTypeTemplatesResponse_nextToken = (ListProfileObjectTypeTemplatesResponse -> Maybe Text)
-> (ListProfileObjectTypeTemplatesResponse
    -> Maybe Text -> ListProfileObjectTypeTemplatesResponse)
-> Lens
     ListProfileObjectTypeTemplatesResponse
     ListProfileObjectTypeTemplatesResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProfileObjectTypeTemplatesResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListProfileObjectTypeTemplatesResponse' :: ListProfileObjectTypeTemplatesResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListProfileObjectTypeTemplatesResponse
s@ListProfileObjectTypeTemplatesResponse' {} Maybe Text
a -> ListProfileObjectTypeTemplatesResponse
s {$sel:nextToken:ListProfileObjectTypeTemplatesResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListProfileObjectTypeTemplatesResponse)

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

instance
  Prelude.NFData
    ListProfileObjectTypeTemplatesResponse