module Network.AWS.CloudFront.DeleteCloudFrontOriginAccessIdentity
(
deleteCloudFrontOriginAccessIdentity
, DeleteCloudFrontOriginAccessIdentity
, dcfoaiIfMatch
, dcfoaiId
, deleteCloudFrontOriginAccessIdentityResponse
, DeleteCloudFrontOriginAccessIdentityResponse
) where
import Network.AWS.CloudFront.Types
import Network.AWS.CloudFront.Types.Product
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response
data DeleteCloudFrontOriginAccessIdentity = DeleteCloudFrontOriginAccessIdentity'
{ _dcfoaiIfMatch :: !(Maybe Text)
, _dcfoaiId :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
deleteCloudFrontOriginAccessIdentity
:: Text
-> DeleteCloudFrontOriginAccessIdentity
deleteCloudFrontOriginAccessIdentity pId_ =
DeleteCloudFrontOriginAccessIdentity'
{ _dcfoaiIfMatch = Nothing
, _dcfoaiId = pId_
}
dcfoaiIfMatch :: Lens' DeleteCloudFrontOriginAccessIdentity (Maybe Text)
dcfoaiIfMatch = lens _dcfoaiIfMatch (\ s a -> s{_dcfoaiIfMatch = a});
dcfoaiId :: Lens' DeleteCloudFrontOriginAccessIdentity Text
dcfoaiId = lens _dcfoaiId (\ s a -> s{_dcfoaiId = a});
instance AWSRequest
DeleteCloudFrontOriginAccessIdentity where
type Rs DeleteCloudFrontOriginAccessIdentity =
DeleteCloudFrontOriginAccessIdentityResponse
request = delete cloudFront
response
= receiveNull
DeleteCloudFrontOriginAccessIdentityResponse'
instance ToHeaders
DeleteCloudFrontOriginAccessIdentity where
toHeaders DeleteCloudFrontOriginAccessIdentity'{..}
= mconcat ["If-Match" =# _dcfoaiIfMatch]
instance ToPath DeleteCloudFrontOriginAccessIdentity
where
toPath DeleteCloudFrontOriginAccessIdentity'{..}
= mconcat
["/2015-04-17/origin-access-identity/cloudfront/",
toBS _dcfoaiId]
instance ToQuery DeleteCloudFrontOriginAccessIdentity
where
toQuery = const mempty
data DeleteCloudFrontOriginAccessIdentityResponse =
DeleteCloudFrontOriginAccessIdentityResponse'
deriving (Eq,Read,Show,Data,Typeable,Generic)
deleteCloudFrontOriginAccessIdentityResponse
:: DeleteCloudFrontOriginAccessIdentityResponse
deleteCloudFrontOriginAccessIdentityResponse =
DeleteCloudFrontOriginAccessIdentityResponse'