Skip to content

Commit

Permalink
Regenerating CertificateManager from latest service definition
Browse files Browse the repository at this point in the history
  • Loading branch information
brendanhay committed May 4, 2016
1 parent 71203d6 commit 513fab6
Show file tree
Hide file tree
Showing 20 changed files with 650 additions and 16 deletions.
3 changes: 3 additions & 0 deletions amazonka-certificatemanager/amazonka-certificatemanager.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,13 @@ library

exposed-modules:
Network.AWS.CertificateManager
, Network.AWS.CertificateManager.AddTagsToCertificate
, Network.AWS.CertificateManager.DeleteCertificate
, Network.AWS.CertificateManager.DescribeCertificate
, Network.AWS.CertificateManager.GetCertificate
, Network.AWS.CertificateManager.ListCertificates
, Network.AWS.CertificateManager.ListTagsForCertificate
, Network.AWS.CertificateManager.RemoveTagsFromCertificate
, Network.AWS.CertificateManager.RequestCertificate
, Network.AWS.CertificateManager.ResendValidationEmail
, Network.AWS.CertificateManager.Types
Expand Down
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
24 changes: 24 additions & 0 deletions amazonka-certificatemanager/gen/Network/AWS/CertificateManager.hs
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,15 @@ module Network.AWS.CertificateManager
-- * Errors
-- $errors

-- ** InvalidTagException
, _InvalidTagException

-- ** InvalidDomainValidationOptionsException
, _InvalidDomainValidationOptionsException

-- ** TooManyTagsException
, _TooManyTagsException

-- ** RequestInProgressException
, _RequestInProgressException

Expand Down Expand Up @@ -60,9 +66,15 @@ module Network.AWS.CertificateManager
-- ** ResendValidationEmail
, module Network.AWS.CertificateManager.ResendValidationEmail

-- ** ListTagsForCertificate
, module Network.AWS.CertificateManager.ListTagsForCertificate

-- ** GetCertificate
, module Network.AWS.CertificateManager.GetCertificate

-- ** AddTagsToCertificate
, module Network.AWS.CertificateManager.AddTagsToCertificate

-- ** RequestCertificate
, module Network.AWS.CertificateManager.RequestCertificate

Expand All @@ -72,6 +84,9 @@ module Network.AWS.CertificateManager
-- ** DeleteCertificate
, module Network.AWS.CertificateManager.DeleteCertificate

-- ** RemoveTagsFromCertificate
, module Network.AWS.CertificateManager.RemoveTagsFromCertificate

-- ** DescribeCertificate
, module Network.AWS.CertificateManager.DescribeCertificate

Expand Down Expand Up @@ -125,12 +140,21 @@ module Network.AWS.CertificateManager
, domainValidationOption
, dvoDomainName
, dvoValidationDomain

-- ** Tag
, Tag
, tag
, tagValue
, tagKey
) where

import Network.AWS.CertificateManager.AddTagsToCertificate
import Network.AWS.CertificateManager.DeleteCertificate
import Network.AWS.CertificateManager.DescribeCertificate
import Network.AWS.CertificateManager.GetCertificate
import Network.AWS.CertificateManager.ListCertificates
import Network.AWS.CertificateManager.ListTagsForCertificate
import Network.AWS.CertificateManager.RemoveTagsFromCertificate
import Network.AWS.CertificateManager.RequestCertificate
import Network.AWS.CertificateManager.ResendValidationEmail
import Network.AWS.CertificateManager.Types
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,144 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}

{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module : Network.AWS.CertificateManager.AddTagsToCertificate
-- Copyright : (c) 2013-2016 Brendan Hay
-- License : Mozilla Public License, v. 2.0.
-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
-- Stability : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Adds one or more tags to an ACM Certificate. Tags are labels that you
-- can use to identify and organize your AWS resources. Each tag consists
-- of a 'key' and an optional 'value'. You specify the certificate on input
-- by its Amazon Resource Name (ARN). You specify the tag by using a
-- key-value pair.
--
-- You can apply a tag to just one certificate if you want to identify a
-- specific characteristic of that certificate, or you can apply the same
-- tag to multiple certificates if you want to filter for a common
-- relationship among those certificates. Similarly, you can apply the same
-- tag to multiple resources if you want to specify a relationship among
-- those resources. For example, you can add the same tag to an ACM
-- Certificate and an Elastic Load Balancing load balancer to indicate that
-- they are both used by the same website. For more information, see
-- <http://docs.aws.amazon.com/acm/latest/userguide/tags.html Tagging ACM Certificates>.
--
-- To remove one or more tags, use the < RemoveTagsFromCertificate> action.
-- To view all of the tags that have been applied to the certificate, use
-- the < ListTagsForCertificate> action.
module Network.AWS.CertificateManager.AddTagsToCertificate
(
-- * Creating a Request
addTagsToCertificate
, AddTagsToCertificate
-- * Request Lenses
, attcCertificateARN
, attcTags

-- * Destructuring the Response
, addTagsToCertificateResponse
, AddTagsToCertificateResponse
) where

import Network.AWS.CertificateManager.Types
import Network.AWS.CertificateManager.Types.Product
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response

-- |
--
-- /See:/ 'addTagsToCertificate' smart constructor.
data AddTagsToCertificate = AddTagsToCertificate'
{ _attcCertificateARN :: !Text
, _attcTags :: !(List1 Tag)
} deriving (Eq,Read,Show,Data,Typeable,Generic)

-- | Creates a value of 'AddTagsToCertificate' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'attcCertificateARN'
--
-- * 'attcTags'
addTagsToCertificate
:: Text -- ^ 'attcCertificateARN'
-> NonEmpty Tag -- ^ 'attcTags'
-> AddTagsToCertificate
addTagsToCertificate pCertificateARN_ pTags_ =
AddTagsToCertificate'
{ _attcCertificateARN = pCertificateARN_
, _attcTags = _List1 # pTags_
}

-- | String that contains the ARN of the ACM Certificate to which the tag is
-- to be applied. This must be of the form:
--
-- 'arn:aws:acm:region:123456789012:certificate\/12345678-1234-1234-1234-123456789012'
--
-- For more information about ARNs, see
-- <http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html Amazon Resource Names (ARNs) and AWS Service Namespaces>.
attcCertificateARN :: Lens' AddTagsToCertificate Text
attcCertificateARN = lens _attcCertificateARN (\ s a -> s{_attcCertificateARN = a});

-- | The key-value pair that defines the tag. The tag value is optional.
attcTags :: Lens' AddTagsToCertificate (NonEmpty Tag)
attcTags = lens _attcTags (\ s a -> s{_attcTags = a}) . _List1;

instance AWSRequest AddTagsToCertificate where
type Rs AddTagsToCertificate =
AddTagsToCertificateResponse
request = postJSON certificateManager
response = receiveNull AddTagsToCertificateResponse'

instance Hashable AddTagsToCertificate

instance NFData AddTagsToCertificate

instance ToHeaders AddTagsToCertificate where
toHeaders
= const
(mconcat
["X-Amz-Target" =#
("CertificateManager.AddTagsToCertificate" ::
ByteString),
"Content-Type" =#
("application/x-amz-json-1.1" :: ByteString)])

instance ToJSON AddTagsToCertificate where
toJSON AddTagsToCertificate'{..}
= object
(catMaybes
[Just ("CertificateArn" .= _attcCertificateARN),
Just ("Tags" .= _attcTags)])

instance ToPath AddTagsToCertificate where
toPath = const "/"

instance ToQuery AddTagsToCertificate where
toQuery = const mempty

-- | /See:/ 'addTagsToCertificateResponse' smart constructor.
data AddTagsToCertificateResponse =
AddTagsToCertificateResponse'
deriving (Eq,Read,Show,Data,Typeable,Generic)

-- | Creates a value of 'AddTagsToCertificateResponse' with the minimum fields required to make a request.
--
addTagsToCertificateResponse
:: AddTagsToCertificateResponse
addTagsToCertificateResponse = AddTagsToCertificateResponse'

instance NFData AddTagsToCertificateResponse
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response

-- | /See:/ 'deleteCertificate' smart constructor.
-- |
--
-- /See:/ 'deleteCertificate' smart constructor.
newtype DeleteCertificate = DeleteCertificate'
{ _dcCertificateARN :: Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
-- Returns a list of the fields contained in the specified ACM Certificate.
-- For example, this action returns the certificate status, a flag that
-- indicates whether the certificate is associated with any other AWS
-- service, and the date at which the certificate request was created. The
-- ACM Certificate is specified on input by its Amazon Resource Name (ARN).
-- service, and the date at which the certificate request was created. You
-- specify the ACM Certificate on input by its Amazon Resource Name (ARN).
module Network.AWS.CertificateManager.DescribeCertificate
(
-- * Creating a Request
Expand All @@ -46,7 +46,9 @@ import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response

-- | /See:/ 'describeCertificate' smart constructor.
-- |
--
-- /See:/ 'describeCertificate' smart constructor.
newtype DescribeCertificate = DescribeCertificate'
{ _dCertificateARN :: Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
Expand Down Expand Up @@ -110,7 +112,9 @@ instance ToPath DescribeCertificate where
instance ToQuery DescribeCertificate where
toQuery = const mempty

-- | /See:/ 'describeCertificateResponse' smart constructor.
-- |
--
-- /See:/ 'describeCertificateResponse' smart constructor.
data DescribeCertificateResponse = DescribeCertificateResponse'
{ _dcrsCertificate :: !(Maybe CertificateDetail)
, _dcrsResponseStatus :: !Int
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@ import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response

-- | /See:/ 'getCertificate' smart constructor.
-- |
--
-- /See:/ 'getCertificate' smart constructor.
newtype GetCertificate = GetCertificate'
{ _gcCertificateARN :: Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
Expand Down Expand Up @@ -113,7 +115,9 @@ instance ToPath GetCertificate where
instance ToQuery GetCertificate where
toQuery = const mempty

-- | /See:/ 'getCertificateResponse' smart constructor.
-- |
--
-- /See:/ 'getCertificateResponse' smart constructor.
data GetCertificateResponse = GetCertificateResponse'
{ _gcrsCertificate :: !(Maybe Text)
, _gcrsCertificateChain :: !(Maybe Text)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@ import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response

-- | /See:/ 'listCertificates' smart constructor.
-- |
--
-- /See:/ 'listCertificates' smart constructor.
data ListCertificates = ListCertificates'
{ _lcCertificateStatuses :: !(Maybe [CertificateStatus])
, _lcNextToken :: !(Maybe Text)
Expand Down Expand Up @@ -80,12 +82,19 @@ listCertificates =
-- retrieve the ARNs. This can be one or more of the following values:
--
-- - 'PENDING_VALIDATION'
--
-- - 'ISSUED'
--
-- - 'INACTIVE'
--
-- - 'EXPIRED'
--
-- - 'VALIDATION_TIMED_OUT'
--
-- - 'REVOKED'
--
-- - 'FAILED'
--
lcCertificateStatuses :: Lens' ListCertificates [CertificateStatus]
lcCertificateStatuses = lens _lcCertificateStatuses (\ s a -> s{_lcCertificateStatuses = a}) . _Default . _Coerce;

Expand Down Expand Up @@ -146,7 +155,9 @@ instance ToPath ListCertificates where
instance ToQuery ListCertificates where
toQuery = const mempty

-- | /See:/ 'listCertificatesResponse' smart constructor.
-- |
--
-- /See:/ 'listCertificatesResponse' smart constructor.
data ListCertificatesResponse = ListCertificatesResponse'
{ _lcrsCertificateSummaryList :: !(Maybe [CertificateSummary])
, _lcrsNextToken :: !(Maybe Text)
Expand Down
Loading

0 comments on commit 513fab6

Please sign in to comment.