unkai-storage-0.1.0.1: gen/Unkai/Storage/RapidCaches/List.hs
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DerivingStrategies #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE ImportQualifiedPost #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
{-# OPTIONS_GHC -fno-warn-name-shadowing #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
-- |
-- Module : Unkai.Storage.RapidCaches.List
-- Copyright : (c) 2015-2025 Brendan Hay
-- License : Mozilla Public License, v. 2.0.
-- Maintainer : Nadeem Bitar <nadeem@gmail.com>
-- Stability : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Returns a list of Rapid Cache instances of the bucket.
--
-- /See:/ <https://developers.google.com/storage/docs/json_api/ Cloud Storage JSON API Reference> for @storage.rapidCaches.list@.
module Unkai.Storage.RapidCaches.List
( -- * Resource
StorageRapidCachesListResource,
-- ** Constructing a Request
StorageRapidCachesList (..),
newStorageRapidCachesList,
)
where
import Unkai.Prelude qualified as Core
import Unkai.Storage.Types
-- | A resource alias for @storage.rapidCaches.list@ method which the
-- 'StorageRapidCachesList' request conforms to.
type StorageRapidCachesListResource =
"storage"
Core.:> "v1"
Core.:> "b"
Core.:> Core.Capture "bucket" Core.Text
Core.:> "rapidCaches"
Core.:> Core.QueryParam "pageSize" Core.Int32
Core.:> Core.QueryParam "pageToken" Core.Text
Core.:> Core.QueryParam "alt" Core.AltJSON
Core.:> Core.Get '[Core.JSON] RapidCaches
-- | Returns a list of Rapid Cache instances of the bucket.
--
-- /See:/ 'newStorageRapidCachesList' smart constructor.
data StorageRapidCachesList = StorageRapidCachesList
{ -- | Name of the parent bucket.
bucket :: Core.Text,
-- | Maximum number of items to return in a single page of responses.
pageSize :: (Core.Maybe Core.Int32),
-- | A previously-returned page token representing part of the larger set of results to view.
pageToken :: (Core.Maybe Core.Text)
}
deriving stock (Core.Eq, Core.Show, Core.Generic)
-- | Creates a value of 'StorageRapidCachesList' with the minimum fields required to make a request.
newStorageRapidCachesList ::
-- | Name of the parent bucket. See 'bucket'.
Core.Text ->
StorageRapidCachesList
newStorageRapidCachesList bucket =
StorageRapidCachesList
{ bucket = bucket,
pageSize = Core.Nothing,
pageToken = Core.Nothing
}
instance Core.GoogleRequest StorageRapidCachesList where
type Rs StorageRapidCachesList = RapidCaches
type
Scopes StorageRapidCachesList =
'[ CloudPlatform'FullControl,
CloudPlatform'ReadOnly,
Devstorage'FullControl,
Devstorage'ReadOnly,
Devstorage'ReadWrite
]
requestClient StorageRapidCachesList {..} =
go
bucket
pageSize
pageToken
(Core.Just Core.AltJSON)
storageService
where
go =
Core.buildClient
(Core.Proxy :: Core.Proxy StorageRapidCachesListResource)
Core.mempty