module Network.AWS.ELB.RemoveTags
(
removeTags
, RemoveTags
, rtLoadBalancerNames
, rtTags
, removeTagsResponse
, RemoveTagsResponse
, rtrsResponseStatus
) where
import Network.AWS.ELB.Types
import Network.AWS.ELB.Types.Product
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response
data RemoveTags = RemoveTags'
{ _rtLoadBalancerNames :: ![Text]
, _rtTags :: !(List1 TagKeyOnly)
} deriving (Eq, Read, Show, Data, Typeable, Generic)
removeTags
:: NonEmpty TagKeyOnly
-> RemoveTags
removeTags pTags_ =
RemoveTags' {_rtLoadBalancerNames = mempty, _rtTags = _List1 # pTags_}
rtLoadBalancerNames :: Lens' RemoveTags [Text]
rtLoadBalancerNames = lens _rtLoadBalancerNames (\ s a -> s{_rtLoadBalancerNames = a}) . _Coerce;
rtTags :: Lens' RemoveTags (NonEmpty TagKeyOnly)
rtTags = lens _rtTags (\ s a -> s{_rtTags = a}) . _List1;
instance AWSRequest RemoveTags where
type Rs RemoveTags = RemoveTagsResponse
request = postQuery elb
response
= receiveXMLWrapper "RemoveTagsResult"
(\ s h x ->
RemoveTagsResponse' <$> (pure (fromEnum s)))
instance Hashable RemoveTags where
instance NFData RemoveTags where
instance ToHeaders RemoveTags where
toHeaders = const mempty
instance ToPath RemoveTags where
toPath = const "/"
instance ToQuery RemoveTags where
toQuery RemoveTags'{..}
= mconcat
["Action" =: ("RemoveTags" :: ByteString),
"Version" =: ("2012-06-01" :: ByteString),
"LoadBalancerNames" =:
toQueryList "member" _rtLoadBalancerNames,
"Tags" =: toQueryList "member" _rtTags]
newtype RemoveTagsResponse = RemoveTagsResponse'
{ _rtrsResponseStatus :: Int
} deriving (Eq, Read, Show, Data, Typeable, Generic)
removeTagsResponse
:: Int
-> RemoveTagsResponse
removeTagsResponse pResponseStatus_ =
RemoveTagsResponse' {_rtrsResponseStatus = pResponseStatus_}
rtrsResponseStatus :: Lens' RemoveTagsResponse Int
rtrsResponseStatus = lens _rtrsResponseStatus (\ s a -> s{_rtrsResponseStatus = a});
instance NFData RemoveTagsResponse where