Skip to content

Commit

Permalink
Regenerating amazonka-codepipeline from latest service definition
Browse files Browse the repository at this point in the history
  • Loading branch information
brendanhay committed Aug 20, 2017
1 parent 55a0389 commit 3ee4d95
Show file tree
Hide file tree
Showing 16 changed files with 348 additions and 61 deletions.
1 change: 1 addition & 0 deletions amazonka-codepipeline/amazonka-codepipeline.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ library
, Network.AWS.CodePipeline.GetPipelineState
, Network.AWS.CodePipeline.GetThirdPartyJobDetails
, Network.AWS.CodePipeline.ListActionTypes
, Network.AWS.CodePipeline.ListPipelineExecutions
, Network.AWS.CodePipeline.ListPipelines
, Network.AWS.CodePipeline.PollForJobs
, Network.AWS.CodePipeline.PollForThirdPartyJobs
Expand Down
10 changes: 10 additions & 0 deletions amazonka-codepipeline/fixture/ListPipelineExecutions.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
method: POST
headers:
Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/codepipeline/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?
Host: codepipeline.us-east-1.amazonaws.com
Content-Type: application/x-www-form-urlencoded; charset=utf-8
X-Amz-Content-SHA256: abcdef
X-Amz-Date: 20091028T223200Z
body:
''
Empty file.
12 changes: 12 additions & 0 deletions amazonka-codepipeline/gen/Network/AWS/CodePipeline.hs
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,9 @@ module Network.AWS.CodePipeline
-- ** CreateCustomActionType
, module Network.AWS.CodePipeline.CreateCustomActionType

-- ** ListPipelineExecutions
, module Network.AWS.CodePipeline.ListPipelineExecutions

-- * Types

-- ** ActionCategory
Expand Down Expand Up @@ -536,6 +539,14 @@ module Network.AWS.CodePipeline
, pePipelineExecutionId
, peArtifactRevisions

-- ** PipelineExecutionSummary
, PipelineExecutionSummary
, pipelineExecutionSummary
, pesStatus
, pesStartTime
, pesPipelineExecutionId
, pesLastUpdateTime

-- ** PipelineSummary
, PipelineSummary
, pipelineSummary
Expand Down Expand Up @@ -624,6 +635,7 @@ import Network.AWS.CodePipeline.GetPipelineExecution
import Network.AWS.CodePipeline.GetPipelineState
import Network.AWS.CodePipeline.GetThirdPartyJobDetails
import Network.AWS.CodePipeline.ListActionTypes
import Network.AWS.CodePipeline.ListPipelineExecutions
import Network.AWS.CodePipeline.ListPipelines
import Network.AWS.CodePipeline.PollForJobs
import Network.AWS.CodePipeline.PollForThirdPartyJobs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ data CreateCustomActionType = CreateCustomActionType'
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'ccatSettings' - Undocumented member.
-- * 'ccatSettings' - Returns information about the settings for an action type.
--
-- * 'ccatConfigurationProperties' - The configuration properties for the custom action.
--
Expand All @@ -79,9 +79,9 @@ data CreateCustomActionType = CreateCustomActionType'
--
-- * 'ccatVersion' - The version identifier of the custom action.
--
-- * 'ccatInputArtifactDetails' - Undocumented member.
-- * 'ccatInputArtifactDetails' - The details of the input artifact for the action, such as its commit ID.
--
-- * 'ccatOutputArtifactDetails' - Undocumented member.
-- * 'ccatOutputArtifactDetails' - The details of the output artifact of the action, such as its commit ID.
createCustomActionType
:: ActionCategory -- ^ 'ccatCategory'
-> Text -- ^ 'ccatProvider'
Expand All @@ -100,7 +100,7 @@ createCustomActionType pCategory_ pProvider_ pVersion_ pInputArtifactDetails_ pO
, _ccatOutputArtifactDetails = pOutputArtifactDetails_
}

-- | Undocumented member.
-- | Returns information about the settings for an action type.
ccatSettings :: Lens' CreateCustomActionType (Maybe ActionTypeSettings)
ccatSettings = lens _ccatSettings (\ s a -> s{_ccatSettings = a});

Expand All @@ -120,11 +120,11 @@ ccatProvider = lens _ccatProvider (\ s a -> s{_ccatProvider = a});
ccatVersion :: Lens' CreateCustomActionType Text
ccatVersion = lens _ccatVersion (\ s a -> s{_ccatVersion = a});

-- | Undocumented member.
-- | The details of the input artifact for the action, such as its commit ID.
ccatInputArtifactDetails :: Lens' CreateCustomActionType ArtifactDetails
ccatInputArtifactDetails = lens _ccatInputArtifactDetails (\ s a -> s{_ccatInputArtifactDetails = a});

-- | Undocumented member.
-- | The details of the output artifact of the action, such as its commit ID.
ccatOutputArtifactDetails :: Lens' CreateCustomActionType ArtifactDetails
ccatOutputArtifactDetails = lens _ccatOutputArtifactDetails (\ s a -> s{_ccatOutputArtifactDetails = a});

Expand Down Expand Up @@ -191,7 +191,7 @@ data CreateCustomActionTypeResponse = CreateCustomActionTypeResponse'
--
-- * 'ccatrsResponseStatus' - -- | The response status code.
--
-- * 'ccatrsActionType' - Undocumented member.
-- * 'ccatrsActionType' - Returns information about the details of an action type.
createCustomActionTypeResponse
:: Int -- ^ 'ccatrsResponseStatus'
-> ActionType -- ^ 'ccatrsActionType'
Expand All @@ -206,7 +206,7 @@ createCustomActionTypeResponse pResponseStatus_ pActionType_ =
ccatrsResponseStatus :: Lens' CreateCustomActionTypeResponse Int
ccatrsResponseStatus = lens _ccatrsResponseStatus (\ s a -> s{_ccatrsResponseStatus = a});

-- | Undocumented member.
-- | Returns information about the details of an action type.
ccatrsActionType :: Lens' CreateCustomActionTypeResponse ActionType
ccatrsActionType = lens _ccatrsActionType (\ s a -> s{_ccatrsActionType = a});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ newtype CreatePipeline = CreatePipeline'
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cpPipeline' - Undocumented member.
-- * 'cpPipeline' - Represents the structure of actions and stages to be performed in the pipeline.
createPipeline
:: PipelineDeclaration -- ^ 'cpPipeline'
-> CreatePipeline
Expand All @@ -66,7 +66,7 @@ createPipeline pPipeline_ =
{ _cpPipeline = pPipeline_
}

-- | Undocumented member.
-- | Represents the structure of actions and stages to be performed in the pipeline.
cpPipeline :: Lens' CreatePipeline PipelineDeclaration
cpPipeline = lens _cpPipeline (\ s a -> s{_cpPipeline = a});

Expand Down Expand Up @@ -118,7 +118,7 @@ data CreatePipelineResponse = CreatePipelineResponse'
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'cprsPipeline' - Undocumented member.
-- * 'cprsPipeline' - Represents the structure of actions and stages to be performed in the pipeline.
--
-- * 'cprsResponseStatus' - -- | The response status code.
createPipelineResponse
Expand All @@ -130,7 +130,7 @@ createPipelineResponse pResponseStatus_ =
, _cprsResponseStatus = pResponseStatus_
}

-- | Undocumented member.
-- | Represents the structure of actions and stages to be performed in the pipeline.
cprsPipeline :: Lens' CreatePipelineResponse (Maybe PipelineDeclaration)
cprsPipeline = lens _cprsPipeline (\ s a -> s{_cprsPipeline = a});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ data GetPipelineResponse = GetPipelineResponse'
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'gprsPipeline' - Undocumented member.
-- * 'gprsPipeline' - Represents the structure of actions and stages to be performed in the pipeline.
--
-- * 'gprsResponseStatus' - -- | The response status code.
getPipelineResponse
Expand All @@ -140,7 +140,7 @@ getPipelineResponse pResponseStatus_ =
, _gprsResponseStatus = pResponseStatus_
}

-- | Undocumented member.
-- | Represents the structure of actions and stages to be performed in the pipeline.
gprsPipeline :: Lens' GetPipelineResponse (Maybe PipelineDeclaration)
gprsPipeline = lens _gprsPipeline (\ s a -> s{_gprsPipeline = a});

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,174 @@
{-# 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.CodePipeline.ListPipelineExecutions
-- Copyright : (c) 2013-2016 Brendan Hay
-- License : Mozilla Public License, v. 2.0.
-- Maintainer : Brendan Hay <[email protected]>
-- Stability : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Gets a summary of the most recent executions for a pipeline.
--
--
module Network.AWS.CodePipeline.ListPipelineExecutions
(
-- * Creating a Request
listPipelineExecutions
, ListPipelineExecutions
-- * Request Lenses
, lpeNextToken
, lpeMaxResults
, lpePipelineName

-- * Destructuring the Response
, listPipelineExecutionsResponse
, ListPipelineExecutionsResponse
-- * Response Lenses
, lpersNextToken
, lpersPipelineExecutionSummaries
, lpersResponseStatus
) where

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

-- | Represents the input of a list pipeline executions action.
--
--
--
-- /See:/ 'listPipelineExecutions' smart constructor.
data ListPipelineExecutions = ListPipelineExecutions'
{ _lpeNextToken :: !(Maybe Text)
, _lpeMaxResults :: !(Maybe Nat)
, _lpePipelineName :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)

-- | Creates a value of 'ListPipelineExecutions' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'lpeNextToken' - The token that was returned from the previous list pipeline executions call, which can be used to return the next set of pipeline executions in the list.
--
-- * 'lpeMaxResults' - The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned nextToken value. The available pipeline execution history is limited to the most recent 12 months, based on pipeline execution start times. Default value is 100.
--
-- * 'lpePipelineName' - The name of the pipeline for which you want to get execution summary information.
listPipelineExecutions
:: Text -- ^ 'lpePipelineName'
-> ListPipelineExecutions
listPipelineExecutions pPipelineName_ =
ListPipelineExecutions'
{ _lpeNextToken = Nothing
, _lpeMaxResults = Nothing
, _lpePipelineName = pPipelineName_
}

-- | The token that was returned from the previous list pipeline executions call, which can be used to return the next set of pipeline executions in the list.
lpeNextToken :: Lens' ListPipelineExecutions (Maybe Text)
lpeNextToken = lens _lpeNextToken (\ s a -> s{_lpeNextToken = a});

-- | The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned nextToken value. The available pipeline execution history is limited to the most recent 12 months, based on pipeline execution start times. Default value is 100.
lpeMaxResults :: Lens' ListPipelineExecutions (Maybe Natural)
lpeMaxResults = lens _lpeMaxResults (\ s a -> s{_lpeMaxResults = a}) . mapping _Nat;

-- | The name of the pipeline for which you want to get execution summary information.
lpePipelineName :: Lens' ListPipelineExecutions Text
lpePipelineName = lens _lpePipelineName (\ s a -> s{_lpePipelineName = a});

instance AWSRequest ListPipelineExecutions where
type Rs ListPipelineExecutions =
ListPipelineExecutionsResponse
request = postJSON codePipeline
response
= receiveJSON
(\ s h x ->
ListPipelineExecutionsResponse' <$>
(x .?> "nextToken") <*>
(x .?> "pipelineExecutionSummaries" .!@ mempty)
<*> (pure (fromEnum s)))

instance Hashable ListPipelineExecutions

instance NFData ListPipelineExecutions

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

instance ToJSON ListPipelineExecutions where
toJSON ListPipelineExecutions'{..}
= object
(catMaybes
[("nextToken" .=) <$> _lpeNextToken,
("maxResults" .=) <$> _lpeMaxResults,
Just ("pipelineName" .= _lpePipelineName)])

instance ToPath ListPipelineExecutions where
toPath = const "/"

instance ToQuery ListPipelineExecutions where
toQuery = const mempty

-- | Represents the output of a list pipeline executions action.
--
--
--
-- /See:/ 'listPipelineExecutionsResponse' smart constructor.
data ListPipelineExecutionsResponse = ListPipelineExecutionsResponse'
{ _lpersNextToken :: !(Maybe Text)
, _lpersPipelineExecutionSummaries :: !(Maybe [PipelineExecutionSummary])
, _lpersResponseStatus :: !Int
} deriving (Eq,Read,Show,Data,Typeable,Generic)

-- | Creates a value of 'ListPipelineExecutionsResponse' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'lpersNextToken' - A token that can be used in the next list pipeline executions call to return the next set of pipeline executions. To view all items in the list, continue to call this operation with each subsequent token until no more nextToken values are returned.
--
-- * 'lpersPipelineExecutionSummaries' - A list of executions in the history of a pipeline.
--
-- * 'lpersResponseStatus' - -- | The response status code.
listPipelineExecutionsResponse
:: Int -- ^ 'lpersResponseStatus'
-> ListPipelineExecutionsResponse
listPipelineExecutionsResponse pResponseStatus_ =
ListPipelineExecutionsResponse'
{ _lpersNextToken = Nothing
, _lpersPipelineExecutionSummaries = Nothing
, _lpersResponseStatus = pResponseStatus_
}

-- | A token that can be used in the next list pipeline executions call to return the next set of pipeline executions. To view all items in the list, continue to call this operation with each subsequent token until no more nextToken values are returned.
lpersNextToken :: Lens' ListPipelineExecutionsResponse (Maybe Text)
lpersNextToken = lens _lpersNextToken (\ s a -> s{_lpersNextToken = a});

-- | A list of executions in the history of a pipeline.
lpersPipelineExecutionSummaries :: Lens' ListPipelineExecutionsResponse [PipelineExecutionSummary]
lpersPipelineExecutionSummaries = lens _lpersPipelineExecutionSummaries (\ s a -> s{_lpersPipelineExecutionSummaries = a}) . _Default . _Coerce;

-- | -- | The response status code.
lpersResponseStatus :: Lens' ListPipelineExecutionsResponse Int
lpersResponseStatus = lens _lpersResponseStatus (\ s a -> s{_lpersResponseStatus = a});

instance NFData ListPipelineExecutionsResponse
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ data PollForJobs = PollForJobs'
--
-- * 'pfjQueryParam' - A map of property names and values. For an action type with no queryable properties, this value must be null or an empty map. For an action type with a queryable property, you must supply that property as a key in the map. Only jobs whose action configuration matches the mapped value will be returned.
--
-- * 'pfjActionTypeId' - Undocumented member.
-- * 'pfjActionTypeId' - Represents information about an action type.
pollForJobs
:: ActionTypeId -- ^ 'pfjActionTypeId'
-> PollForJobs
Expand All @@ -86,7 +86,7 @@ pfjMaxBatchSize = lens _pfjMaxBatchSize (\ s a -> s{_pfjMaxBatchSize = a}) . map
pfjQueryParam :: Lens' PollForJobs (HashMap Text Text)
pfjQueryParam = lens _pfjQueryParam (\ s a -> s{_pfjQueryParam = a}) . _Default . _Map;

-- | Undocumented member.
-- | Represents information about an action type.
pfjActionTypeId :: Lens' PollForJobs ActionTypeId
pfjActionTypeId = lens _pfjActionTypeId (\ s a -> s{_pfjActionTypeId = a});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ data PollForThirdPartyJobs = PollForThirdPartyJobs'
--
-- * 'pftpjMaxBatchSize' - The maximum number of jobs to return in a poll for jobs call.
--
-- * 'pftpjActionTypeId' - Undocumented member.
-- * 'pftpjActionTypeId' - Represents information about an action type.
pollForThirdPartyJobs
:: ActionTypeId -- ^ 'pftpjActionTypeId'
-> PollForThirdPartyJobs
Expand All @@ -77,7 +77,7 @@ pollForThirdPartyJobs pActionTypeId_ =
pftpjMaxBatchSize :: Lens' PollForThirdPartyJobs (Maybe Natural)
pftpjMaxBatchSize = lens _pftpjMaxBatchSize (\ s a -> s{_pftpjMaxBatchSize = a}) . mapping _Nat;

-- | Undocumented member.
-- | Represents information about an action type.
pftpjActionTypeId :: Lens' PollForThirdPartyJobs ActionTypeId
pftpjActionTypeId = lens _pftpjActionTypeId (\ s a -> s{_pftpjActionTypeId = a});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ data PutActionRevision = PutActionRevision'
--
-- * 'pActionName' - The name of the action that will process the revision.
--
-- * 'pActionRevision' - Undocumented member.
-- * 'pActionRevision' - Represents information about the version (or revision) of an action.
putActionRevision
:: Text -- ^ 'pPipelineName'
-> Text -- ^ 'pStageName'
Expand All @@ -97,7 +97,7 @@ pStageName = lens _pStageName (\ s a -> s{_pStageName = a});
pActionName :: Lens' PutActionRevision Text
pActionName = lens _pActionName (\ s a -> s{_pActionName = a});

-- | Undocumented member.
-- | Represents information about the version (or revision) of an action.
pActionRevision :: Lens' PutActionRevision ActionRevision
pActionRevision = lens _pActionRevision (\ s a -> s{_pActionRevision = a});

Expand Down
Loading

0 comments on commit 3ee4d95

Please sign in to comment.