module Network.AWS.CloudTrail.Types
(
cloudTrail
, _InvalidTimeRangeException
, _InsufficientS3BucketPolicyException
, _MaximumNumberOfTrailsExceededException
, _UnsupportedOperationException
, _KMSKeyDisabledException
, _InsufficientEncryptionPolicyException
, _InsufficientSNSTopicPolicyException
, _InvalidCloudWatchLogsRoleARNException
, _TagsLimitExceededException
, _CloudTrailARNInvalidException
, _InvalidLookupAttributesException
, _InvalidTrailNameException
, _InvalidSNSTopicNameException
, _ResourceTypeNotSupportedException
, _CloudWatchLogsDeliveryUnavailableException
, _KMSKeyNotFoundException
, _TrailNotFoundException
, _TrailNotProvidedException
, _InvalidS3BucketNameException
, _InvalidCloudWatchLogsLogGroupARNException
, _S3BucketDoesNotExistException
, _InvalidNextTokenException
, _InvalidTagParameterException
, _OperationNotPermittedException
, _InvalidTokenException
, _InvalidMaxResultsException
, _TrailAlreadyExistsException
, _InvalidS3PrefixException
, _ResourceNotFoundException
, _InvalidKMSKeyIdException
, LookupAttributeKey (..)
, Event
, event
, eUsername
, eResources
, eEventTime
, eCloudTrailEvent
, eEventName
, eEventId
, LookupAttribute
, lookupAttribute
, laAttributeKey
, laAttributeValue
, PublicKey
, publicKey
, pkFingerprint
, pkValidityEndTime
, pkValue
, pkValidityStartTime
, Resource
, resource
, rResourceType
, rResourceName
, ResourceTag
, resourceTag
, rResourceId
, rTagsList
, Tag
, tag
, tagValue
, tagKey
, Trail
, trail
, tLogFileValidationEnabled
, tTrailARN
, tS3KeyPrefix
, tSNSTopicName
, tCloudWatchLogsLogGroupARN
, tKMSKeyId
, tName
, tIncludeGlobalServiceEvents
, tCloudWatchLogsRoleARN
, tS3BucketName
) where
import Network.AWS.CloudTrail.Types.Product
import Network.AWS.CloudTrail.Types.Sum
import Network.AWS.Prelude
import Network.AWS.Sign.V4
cloudTrail :: Service
cloudTrail =
Service
{ _svcAbbrev = "CloudTrail"
, _svcSigner = v4
, _svcPrefix = "cloudtrail"
, _svcVersion = "2013-11-01"
, _svcEndpoint = defaultEndpoint cloudTrail
, _svcTimeout = Just 70
, _svcCheck = statusSuccess
, _svcError = parseJSONError
, _svcRetry = retry
}
where
retry =
Exponential
{ _retryBase = 5.0e-2
, _retryGrowth = 2
, _retryAttempts = 5
, _retryCheck = check
}
check e
| has (hasCode "ThrottlingException" . hasStatus 400) e =
Just "throttling_exception"
| has (hasCode "Throttling" . hasStatus 400) e = Just "throttling"
| has (hasStatus 503) e = Just "service_unavailable"
| has (hasStatus 500) e = Just "general_server_error"
| has (hasStatus 509) e = Just "limit_exceeded"
| otherwise = Nothing
_InvalidTimeRangeException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidTimeRangeException =
_ServiceError . hasStatus 400 . hasCode "InvalidTimeRange"
_InsufficientS3BucketPolicyException :: AsError a => Getting (First ServiceError) a ServiceError
_InsufficientS3BucketPolicyException =
_ServiceError . hasStatus 403 . hasCode "InsufficientS3BucketPolicy"
_MaximumNumberOfTrailsExceededException :: AsError a => Getting (First ServiceError) a ServiceError
_MaximumNumberOfTrailsExceededException =
_ServiceError . hasStatus 403 . hasCode "MaximumNumberOfTrailsExceeded"
_UnsupportedOperationException :: AsError a => Getting (First ServiceError) a ServiceError
_UnsupportedOperationException =
_ServiceError . hasStatus 400 . hasCode "UnsupportedOperation"
_KMSKeyDisabledException :: AsError a => Getting (First ServiceError) a ServiceError
_KMSKeyDisabledException =
_ServiceError . hasStatus 400 . hasCode "KmsKeyDisabled"
_InsufficientEncryptionPolicyException :: AsError a => Getting (First ServiceError) a ServiceError
_InsufficientEncryptionPolicyException =
_ServiceError . hasStatus 400 . hasCode "InsufficientEncryptionPolicy"
_InsufficientSNSTopicPolicyException :: AsError a => Getting (First ServiceError) a ServiceError
_InsufficientSNSTopicPolicyException =
_ServiceError . hasStatus 403 . hasCode "InsufficientSnsTopicPolicy"
_InvalidCloudWatchLogsRoleARNException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidCloudWatchLogsRoleARNException =
_ServiceError . hasStatus 400 . hasCode "InvalidCloudWatchLogsRoleArn"
_TagsLimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError
_TagsLimitExceededException =
_ServiceError . hasStatus 400 . hasCode "TagsLimitExceeded"
_CloudTrailARNInvalidException :: AsError a => Getting (First ServiceError) a ServiceError
_CloudTrailARNInvalidException =
_ServiceError . hasStatus 400 . hasCode "CloudTrailARNInvalid"
_InvalidLookupAttributesException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidLookupAttributesException =
_ServiceError . hasStatus 400 . hasCode "InvalidLookupAttributes"
_InvalidTrailNameException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidTrailNameException =
_ServiceError . hasStatus 400 . hasCode "InvalidTrailName"
_InvalidSNSTopicNameException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidSNSTopicNameException =
_ServiceError . hasStatus 400 . hasCode "InvalidSnsTopicName"
_ResourceTypeNotSupportedException :: AsError a => Getting (First ServiceError) a ServiceError
_ResourceTypeNotSupportedException =
_ServiceError . hasStatus 400 . hasCode "ResourceTypeNotSupported"
_CloudWatchLogsDeliveryUnavailableException :: AsError a => Getting (First ServiceError) a ServiceError
_CloudWatchLogsDeliveryUnavailableException =
_ServiceError . hasStatus 400 . hasCode "CloudWatchLogsDeliveryUnavailable"
_KMSKeyNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_KMSKeyNotFoundException =
_ServiceError . hasStatus 400 . hasCode "KmsKeyNotFound"
_TrailNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_TrailNotFoundException =
_ServiceError . hasStatus 404 . hasCode "TrailNotFound"
_TrailNotProvidedException :: AsError a => Getting (First ServiceError) a ServiceError
_TrailNotProvidedException =
_ServiceError . hasStatus 404 . hasCode "TrailNotProvided"
_InvalidS3BucketNameException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidS3BucketNameException =
_ServiceError . hasStatus 400 . hasCode "InvalidS3BucketName"
_InvalidCloudWatchLogsLogGroupARNException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidCloudWatchLogsLogGroupARNException =
_ServiceError . hasStatus 400 . hasCode "InvalidCloudWatchLogsLogGroupArn"
_S3BucketDoesNotExistException :: AsError a => Getting (First ServiceError) a ServiceError
_S3BucketDoesNotExistException =
_ServiceError . hasStatus 404 . hasCode "S3BucketDoesNotExist"
_InvalidNextTokenException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidNextTokenException =
_ServiceError . hasStatus 400 . hasCode "InvalidNextToken"
_InvalidTagParameterException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidTagParameterException =
_ServiceError . hasStatus 400 . hasCode "InvalidTagParameter"
_OperationNotPermittedException :: AsError a => Getting (First ServiceError) a ServiceError
_OperationNotPermittedException =
_ServiceError . hasStatus 400 . hasCode "OperationNotPermitted"
_InvalidTokenException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidTokenException = _ServiceError . hasStatus 400 . hasCode "InvalidToken"
_InvalidMaxResultsException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidMaxResultsException =
_ServiceError . hasStatus 400 . hasCode "InvalidMaxResults"
_TrailAlreadyExistsException :: AsError a => Getting (First ServiceError) a ServiceError
_TrailAlreadyExistsException =
_ServiceError . hasStatus 400 . hasCode "TrailAlreadyExists"
_InvalidS3PrefixException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidS3PrefixException =
_ServiceError . hasStatus 400 . hasCode "InvalidS3Prefix"
_ResourceNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
_ResourceNotFoundException =
_ServiceError . hasStatus 400 . hasCode "ResourceNotFound"
_InvalidKMSKeyIdException :: AsError a => Getting (First ServiceError) a ServiceError
_InvalidKMSKeyIdException =
_ServiceError . hasStatus 400 . hasCode "InvalidKmsKeyId"