{-# LANGUAGE DisambiguateRecordFields #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.KinesisVideo.Types
(
defaultService,
_AccessDeniedException,
_AccountChannelLimitExceededException,
_AccountStreamLimitExceededException,
_ClientLimitExceededException,
_DeviceStreamLimitExceededException,
_InvalidArgumentException,
_InvalidDeviceException,
_InvalidResourceFormatException,
_NoDataRetentionException,
_NotAuthorizedException,
_ResourceInUseException,
_ResourceNotFoundException,
_StreamEdgeConfigurationNotFoundException,
_TagsPerResourceExceededLimitException,
_VersionMismatchException,
APIName (..),
ChannelProtocol (..),
ChannelRole (..),
ChannelType (..),
ComparisonOperator (..),
ConfigurationStatus (..),
Format (..),
FormatConfigKey (..),
ImageSelectorType (..),
MediaStorageConfigurationStatus (..),
MediaUriType (..),
StrategyOnFullSize (..),
StreamStatus (..),
SyncStatus (..),
UpdateDataRetentionOperation (..),
ChannelInfo (..),
newChannelInfo,
channelInfo_channelARN,
channelInfo_channelName,
channelInfo_channelStatus,
channelInfo_channelType,
channelInfo_creationTime,
channelInfo_singleMasterConfiguration,
channelInfo_version,
ChannelNameCondition (..),
newChannelNameCondition,
channelNameCondition_comparisonOperator,
channelNameCondition_comparisonValue,
DeletionConfig (..),
newDeletionConfig,
deletionConfig_deleteAfterUpload,
deletionConfig_edgeRetentionInHours,
deletionConfig_localSizeConfig,
EdgeConfig (..),
newEdgeConfig,
edgeConfig_deletionConfig,
edgeConfig_uploaderConfig,
edgeConfig_hubDeviceArn,
edgeConfig_recorderConfig,
ImageGenerationConfiguration (..),
newImageGenerationConfiguration,
imageGenerationConfiguration_formatConfig,
imageGenerationConfiguration_heightPixels,
imageGenerationConfiguration_widthPixels,
imageGenerationConfiguration_status,
imageGenerationConfiguration_imageSelectorType,
imageGenerationConfiguration_destinationConfig,
imageGenerationConfiguration_samplingInterval,
imageGenerationConfiguration_format,
ImageGenerationDestinationConfig (..),
newImageGenerationDestinationConfig,
imageGenerationDestinationConfig_uri,
imageGenerationDestinationConfig_destinationRegion,
LocalSizeConfig (..),
newLocalSizeConfig,
localSizeConfig_maxLocalMediaSizeInMB,
localSizeConfig_strategyOnFullSize,
MappedResourceConfigurationListItem (..),
newMappedResourceConfigurationListItem,
mappedResourceConfigurationListItem_arn,
mappedResourceConfigurationListItem_type,
MediaSourceConfig (..),
newMediaSourceConfig,
mediaSourceConfig_mediaUriSecretArn,
mediaSourceConfig_mediaUriType,
MediaStorageConfiguration (..),
newMediaStorageConfiguration,
mediaStorageConfiguration_streamARN,
mediaStorageConfiguration_status,
NotificationConfiguration (..),
newNotificationConfiguration,
notificationConfiguration_status,
notificationConfiguration_destinationConfig,
NotificationDestinationConfig (..),
newNotificationDestinationConfig,
notificationDestinationConfig_uri,
RecorderConfig (..),
newRecorderConfig,
recorderConfig_scheduleConfig,
recorderConfig_mediaSourceConfig,
ResourceEndpointListItem (..),
newResourceEndpointListItem,
resourceEndpointListItem_protocol,
resourceEndpointListItem_resourceEndpoint,
ScheduleConfig (..),
newScheduleConfig,
scheduleConfig_scheduleExpression,
scheduleConfig_durationInSeconds,
SingleMasterChannelEndpointConfiguration (..),
newSingleMasterChannelEndpointConfiguration,
singleMasterChannelEndpointConfiguration_protocols,
singleMasterChannelEndpointConfiguration_role,
SingleMasterConfiguration (..),
newSingleMasterConfiguration,
singleMasterConfiguration_messageTtlSeconds,
StreamInfo (..),
newStreamInfo,
streamInfo_creationTime,
streamInfo_dataRetentionInHours,
streamInfo_deviceName,
streamInfo_kmsKeyId,
streamInfo_mediaType,
streamInfo_status,
streamInfo_streamARN,
streamInfo_streamName,
streamInfo_version,
StreamNameCondition (..),
newStreamNameCondition,
streamNameCondition_comparisonOperator,
streamNameCondition_comparisonValue,
Tag (..),
newTag,
tag_key,
tag_value,
UploaderConfig (..),
newUploaderConfig,
uploaderConfig_scheduleConfig,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import Amazonka.KinesisVideo.Types.APIName
import Amazonka.KinesisVideo.Types.ChannelInfo
import Amazonka.KinesisVideo.Types.ChannelNameCondition
import Amazonka.KinesisVideo.Types.ChannelProtocol
import Amazonka.KinesisVideo.Types.ChannelRole
import Amazonka.KinesisVideo.Types.ChannelType
import Amazonka.KinesisVideo.Types.ComparisonOperator
import Amazonka.KinesisVideo.Types.ConfigurationStatus
import Amazonka.KinesisVideo.Types.DeletionConfig
import Amazonka.KinesisVideo.Types.EdgeConfig
import Amazonka.KinesisVideo.Types.Format
import Amazonka.KinesisVideo.Types.FormatConfigKey
import Amazonka.KinesisVideo.Types.ImageGenerationConfiguration
import Amazonka.KinesisVideo.Types.ImageGenerationDestinationConfig
import Amazonka.KinesisVideo.Types.ImageSelectorType
import Amazonka.KinesisVideo.Types.LocalSizeConfig
import Amazonka.KinesisVideo.Types.MappedResourceConfigurationListItem
import Amazonka.KinesisVideo.Types.MediaSourceConfig
import Amazonka.KinesisVideo.Types.MediaStorageConfiguration
import Amazonka.KinesisVideo.Types.MediaStorageConfigurationStatus
import Amazonka.KinesisVideo.Types.MediaUriType
import Amazonka.KinesisVideo.Types.NotificationConfiguration
import Amazonka.KinesisVideo.Types.NotificationDestinationConfig
import Amazonka.KinesisVideo.Types.RecorderConfig
import Amazonka.KinesisVideo.Types.ResourceEndpointListItem
import Amazonka.KinesisVideo.Types.ScheduleConfig
import Amazonka.KinesisVideo.Types.SingleMasterChannelEndpointConfiguration
import Amazonka.KinesisVideo.Types.SingleMasterConfiguration
import Amazonka.KinesisVideo.Types.StrategyOnFullSize
import Amazonka.KinesisVideo.Types.StreamInfo
import Amazonka.KinesisVideo.Types.StreamNameCondition
import Amazonka.KinesisVideo.Types.StreamStatus
import Amazonka.KinesisVideo.Types.SyncStatus
import Amazonka.KinesisVideo.Types.Tag
import Amazonka.KinesisVideo.Types.UpdateDataRetentionOperation
import Amazonka.KinesisVideo.Types.UploaderConfig
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Sign.V4 as Sign
defaultService :: Core.Service
defaultService :: Service
defaultService =
Core.Service
{ $sel:abbrev:Service :: Abbrev
Core.abbrev = Abbrev
"KinesisVideo",
$sel:signer:Service :: Signer
Core.signer = Signer
Sign.v4,
$sel:endpointPrefix:Service :: ByteString
Core.endpointPrefix = ByteString
"kinesisvideo",
$sel:signingName:Service :: ByteString
Core.signingName = ByteString
"kinesisvideo",
$sel:version:Service :: ByteString
Core.version = ByteString
"2017-09-30",
$sel:s3AddressingStyle:Service :: S3AddressingStyle
Core.s3AddressingStyle = S3AddressingStyle
Core.S3AddressingStyleAuto,
$sel:endpoint:Service :: Region -> Endpoint
Core.endpoint = Service -> Region -> Endpoint
Core.defaultEndpoint Service
defaultService,
$sel:timeout:Service :: Maybe Seconds
Core.timeout = forall a. a -> Maybe a
Prelude.Just Seconds
70,
$sel:check:Service :: Status -> Bool
Core.check = Status -> Bool
Core.statusSuccess,
$sel:error:Service :: Status -> [Header] -> ByteStringLazy -> Error
Core.error = Abbrev -> Status -> [Header] -> ByteStringLazy -> Error
Core.parseJSONError Abbrev
"KinesisVideo",
$sel:retry:Service :: Retry
Core.retry = Retry
retry
}
where
retry :: Retry
retry =
Core.Exponential
{ $sel:base:Exponential :: Double
Core.base = Double
5.0e-2,
$sel:growth:Exponential :: Int
Core.growth = Int
2,
$sel:attempts:Exponential :: Int
Core.attempts = Int
5,
$sel:check:Exponential :: ServiceError -> Maybe Text
Core.check = forall {a}. IsString a => ServiceError -> Maybe a
check
}
check :: ServiceError -> Maybe a
check ServiceError
e
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
502) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"bad_gateway"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
504) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"gateway_timeout"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
500) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"general_server_error"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
509) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"limit_exceeded"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"RequestThrottledException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"request_throttled_exception"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
503) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"service_unavailable"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"ThrottledException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throttled_exception"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"Throttling"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throttling"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode ErrorCode
"ThrottlingException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throttling_exception"
| forall s a. Getting Any s a -> s -> Bool
Lens.has
( forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
ErrorCode -> Optic' p f ServiceError ServiceError
Core.hasCode
ErrorCode
"ProvisionedThroughputExceededException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
)
ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"throughput_exceeded"
| forall s a. Getting Any s a -> s -> Bool
Lens.has (forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
429) ServiceError
e =
forall a. a -> Maybe a
Prelude.Just a
"too_many_requests"
| Bool
Prelude.otherwise = forall a. Maybe a
Prelude.Nothing
_AccessDeniedException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_AccessDeniedException :: forall a. AsError a => Fold a ServiceError
_AccessDeniedException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"AccessDeniedException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
401
_AccountChannelLimitExceededException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_AccountChannelLimitExceededException :: forall a. AsError a => Fold a ServiceError
_AccountChannelLimitExceededException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"AccountChannelLimitExceededException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_AccountStreamLimitExceededException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_AccountStreamLimitExceededException :: forall a. AsError a => Fold a ServiceError
_AccountStreamLimitExceededException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"AccountStreamLimitExceededException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_ClientLimitExceededException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ClientLimitExceededException :: forall a. AsError a => Fold a ServiceError
_ClientLimitExceededException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ClientLimitExceededException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_DeviceStreamLimitExceededException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_DeviceStreamLimitExceededException :: forall a. AsError a => Fold a ServiceError
_DeviceStreamLimitExceededException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"DeviceStreamLimitExceededException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_InvalidArgumentException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_InvalidArgumentException :: forall a. AsError a => Fold a ServiceError
_InvalidArgumentException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"InvalidArgumentException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_InvalidDeviceException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_InvalidDeviceException :: forall a. AsError a => Fold a ServiceError
_InvalidDeviceException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"InvalidDeviceException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_InvalidResourceFormatException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_InvalidResourceFormatException :: forall a. AsError a => Fold a ServiceError
_InvalidResourceFormatException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"InvalidResourceFormatException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_NoDataRetentionException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_NoDataRetentionException :: forall a. AsError a => Fold a ServiceError
_NoDataRetentionException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"NoDataRetentionException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_NotAuthorizedException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_NotAuthorizedException :: forall a. AsError a => Fold a ServiceError
_NotAuthorizedException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"NotAuthorizedException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
401
_ResourceInUseException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ResourceInUseException :: forall a. AsError a => Fold a ServiceError
_ResourceInUseException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ResourceInUseException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_ResourceNotFoundException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_ResourceNotFoundException :: forall a. AsError a => Fold a ServiceError
_ResourceNotFoundException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"ResourceNotFoundException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
404
_StreamEdgeConfigurationNotFoundException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_StreamEdgeConfigurationNotFoundException :: forall a. AsError a => Fold a ServiceError
_StreamEdgeConfigurationNotFoundException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"StreamEdgeConfigurationNotFoundException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
404
_TagsPerResourceExceededLimitException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_TagsPerResourceExceededLimitException :: forall a. AsError a => Fold a ServiceError
_TagsPerResourceExceededLimitException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"TagsPerResourceExceededLimitException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400
_VersionMismatchException :: (Core.AsError a) => Lens.Fold a Core.ServiceError
_VersionMismatchException :: forall a. AsError a => Fold a ServiceError
_VersionMismatchException =
forall a. AsError a => Service -> ErrorCode -> Fold a ServiceError
Core._MatchServiceError
Service
defaultService
ErrorCode
"VersionMismatchException"
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (p :: * -> * -> *).
(Applicative f, Choice p) =>
Int -> Optic' p f ServiceError ServiceError
Core.hasStatus Int
400