use std::error::Error;
use std::fmt;
use async_trait::async_trait;
use rusoto_core::credential::ProvideAwsCredentials;
use rusoto_core::region;
use rusoto_core::request::{BufferedHttpResponse, DispatchSignedRequest};
use rusoto_core::{Client, RusotoError};
use rusoto_core::proto;
use rusoto_core::request::HttpResponse;
use rusoto_core::signature::SignedRequest;
#[allow(unused_imports)]
use serde::{Deserialize, Serialize};
impl CodePipelineClient {
fn new_signed_request(&self, http_method: &str, request_uri: &str) -> SignedRequest {
let mut request =
SignedRequest::new(http_method, "codepipeline", &self.region, request_uri);
request.set_content_type("application/x-amz-json-1.1".to_owned());
request
}
async fn sign_and_dispatch<E>(
&self,
request: SignedRequest,
from_response: fn(BufferedHttpResponse) -> RusotoError<E>,
) -> Result<HttpResponse, RusotoError<E>> {
let mut response = self.client.sign_and_dispatch(request).await?;
if !response.status.is_success() {
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
return Err(from_response(response));
}
Ok(response)
}
}
use serde_json;
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct AWSSessionCredentials {
#[serde(rename = "accessKeyId")]
pub access_key_id: String,
#[serde(rename = "secretAccessKey")]
pub secret_access_key: String,
#[serde(rename = "sessionToken")]
pub session_token: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct AcknowledgeJobInput {
#[serde(rename = "jobId")]
pub job_id: String,
#[serde(rename = "nonce")]
pub nonce: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct AcknowledgeJobOutput {
#[serde(rename = "status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct AcknowledgeThirdPartyJobInput {
#[serde(rename = "clientToken")]
pub client_token: String,
#[serde(rename = "jobId")]
pub job_id: String,
#[serde(rename = "nonce")]
pub nonce: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct AcknowledgeThirdPartyJobOutput {
#[serde(rename = "status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionConfiguration {
#[serde(rename = "configuration")]
#[serde(skip_serializing_if = "Option::is_none")]
pub configuration: Option<::std::collections::HashMap<String, String>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct ActionConfigurationProperty {
#[serde(rename = "description")]
#[serde(skip_serializing_if = "Option::is_none")]
pub description: Option<String>,
#[serde(rename = "key")]
pub key: bool,
#[serde(rename = "name")]
pub name: String,
#[serde(rename = "queryable")]
#[serde(skip_serializing_if = "Option::is_none")]
pub queryable: Option<bool>,
#[serde(rename = "required")]
pub required: bool,
#[serde(rename = "secret")]
pub secret: bool,
#[serde(rename = "type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionContext {
#[serde(rename = "actionExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_execution_id: Option<String>,
#[serde(rename = "name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct ActionDeclaration {
#[serde(rename = "actionTypeId")]
pub action_type_id: ActionTypeId,
#[serde(rename = "configuration")]
#[serde(skip_serializing_if = "Option::is_none")]
pub configuration: Option<::std::collections::HashMap<String, String>>,
#[serde(rename = "inputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub input_artifacts: Option<Vec<InputArtifact>>,
#[serde(rename = "name")]
pub name: String,
#[serde(rename = "namespace")]
#[serde(skip_serializing_if = "Option::is_none")]
pub namespace: Option<String>,
#[serde(rename = "outputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub output_artifacts: Option<Vec<OutputArtifact>>,
#[serde(rename = "region")]
#[serde(skip_serializing_if = "Option::is_none")]
pub region: Option<String>,
#[serde(rename = "roleArn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub role_arn: Option<String>,
#[serde(rename = "runOrder")]
#[serde(skip_serializing_if = "Option::is_none")]
pub run_order: Option<i64>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionExecution {
#[serde(rename = "errorDetails")]
#[serde(skip_serializing_if = "Option::is_none")]
pub error_details: Option<ErrorDetails>,
#[serde(rename = "externalExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub external_execution_id: Option<String>,
#[serde(rename = "externalExecutionUrl")]
#[serde(skip_serializing_if = "Option::is_none")]
pub external_execution_url: Option<String>,
#[serde(rename = "lastStatusChange")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_status_change: Option<f64>,
#[serde(rename = "lastUpdatedBy")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_updated_by: Option<String>,
#[serde(rename = "percentComplete")]
#[serde(skip_serializing_if = "Option::is_none")]
pub percent_complete: Option<i64>,
#[serde(rename = "status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
#[serde(rename = "summary")]
#[serde(skip_serializing_if = "Option::is_none")]
pub summary: Option<String>,
#[serde(rename = "token")]
#[serde(skip_serializing_if = "Option::is_none")]
pub token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionExecutionDetail {
#[serde(rename = "actionExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_execution_id: Option<String>,
#[serde(rename = "actionName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_name: Option<String>,
#[serde(rename = "input")]
#[serde(skip_serializing_if = "Option::is_none")]
pub input: Option<ActionExecutionInput>,
#[serde(rename = "lastUpdateTime")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_update_time: Option<f64>,
#[serde(rename = "output")]
#[serde(skip_serializing_if = "Option::is_none")]
pub output: Option<ActionExecutionOutput>,
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
#[serde(rename = "pipelineVersion")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_version: Option<i64>,
#[serde(rename = "stageName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub stage_name: Option<String>,
#[serde(rename = "startTime")]
#[serde(skip_serializing_if = "Option::is_none")]
pub start_time: Option<f64>,
#[serde(rename = "status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ActionExecutionFilter {
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionExecutionInput {
#[serde(rename = "actionTypeId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_type_id: Option<ActionTypeId>,
#[serde(rename = "configuration")]
#[serde(skip_serializing_if = "Option::is_none")]
pub configuration: Option<::std::collections::HashMap<String, String>>,
#[serde(rename = "inputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub input_artifacts: Option<Vec<ArtifactDetail>>,
#[serde(rename = "namespace")]
#[serde(skip_serializing_if = "Option::is_none")]
pub namespace: Option<String>,
#[serde(rename = "region")]
#[serde(skip_serializing_if = "Option::is_none")]
pub region: Option<String>,
#[serde(rename = "resolvedConfiguration")]
#[serde(skip_serializing_if = "Option::is_none")]
pub resolved_configuration: Option<::std::collections::HashMap<String, String>>,
#[serde(rename = "roleArn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub role_arn: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionExecutionOutput {
#[serde(rename = "executionResult")]
#[serde(skip_serializing_if = "Option::is_none")]
pub execution_result: Option<ActionExecutionResult>,
#[serde(rename = "outputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub output_artifacts: Option<Vec<ArtifactDetail>>,
#[serde(rename = "outputVariables")]
#[serde(skip_serializing_if = "Option::is_none")]
pub output_variables: Option<::std::collections::HashMap<String, String>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionExecutionResult {
#[serde(rename = "externalExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub external_execution_id: Option<String>,
#[serde(rename = "externalExecutionSummary")]
#[serde(skip_serializing_if = "Option::is_none")]
pub external_execution_summary: Option<String>,
#[serde(rename = "externalExecutionUrl")]
#[serde(skip_serializing_if = "Option::is_none")]
pub external_execution_url: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct ActionRevision {
#[serde(rename = "created")]
pub created: Option<f64>,
#[serde(rename = "revisionChangeId")]
pub revision_change_id: Option<String>,
#[serde(rename = "revisionId")]
pub revision_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionState {
#[serde(rename = "actionName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_name: Option<String>,
#[serde(rename = "currentRevision")]
#[serde(skip_serializing_if = "Option::is_none")]
pub current_revision: Option<ActionRevision>,
#[serde(rename = "entityUrl")]
#[serde(skip_serializing_if = "Option::is_none")]
pub entity_url: Option<String>,
#[serde(rename = "latestExecution")]
#[serde(skip_serializing_if = "Option::is_none")]
pub latest_execution: Option<ActionExecution>,
#[serde(rename = "revisionUrl")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_url: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ActionType {
#[serde(rename = "actionConfigurationProperties")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_configuration_properties: Option<Vec<ActionConfigurationProperty>>,
#[serde(rename = "id")]
pub id: ActionTypeId,
#[serde(rename = "inputArtifactDetails")]
pub input_artifact_details: ArtifactDetails,
#[serde(rename = "outputArtifactDetails")]
pub output_artifact_details: ArtifactDetails,
#[serde(rename = "settings")]
#[serde(skip_serializing_if = "Option::is_none")]
pub settings: Option<ActionTypeSettings>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct ActionTypeId {
#[serde(rename = "category")]
pub category: String,
#[serde(rename = "owner")]
pub owner: String,
#[serde(rename = "provider")]
pub provider: String,
#[serde(rename = "version")]
pub version: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct ActionTypeSettings {
#[serde(rename = "entityUrlTemplate")]
#[serde(skip_serializing_if = "Option::is_none")]
pub entity_url_template: Option<String>,
#[serde(rename = "executionUrlTemplate")]
#[serde(skip_serializing_if = "Option::is_none")]
pub execution_url_template: Option<String>,
#[serde(rename = "revisionUrlTemplate")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_url_template: Option<String>,
#[serde(rename = "thirdPartyConfigurationUrl")]
#[serde(skip_serializing_if = "Option::is_none")]
pub third_party_configuration_url: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ApprovalResult {
#[serde(rename = "status")]
pub status: String,
#[serde(rename = "summary")]
pub summary: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Artifact {
#[serde(rename = "location")]
#[serde(skip_serializing_if = "Option::is_none")]
pub location: Option<ArtifactLocation>,
#[serde(rename = "name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
#[serde(rename = "revision")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ArtifactDetail {
#[serde(rename = "name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
#[serde(rename = "s3location")]
#[serde(skip_serializing_if = "Option::is_none")]
pub s_3location: Option<S3Location>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct ArtifactDetails {
#[serde(rename = "maximumCount")]
pub maximum_count: i64,
#[serde(rename = "minimumCount")]
pub minimum_count: i64,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ArtifactLocation {
#[serde(rename = "s3Location")]
#[serde(skip_serializing_if = "Option::is_none")]
pub s_3_location: Option<S3ArtifactLocation>,
#[serde(rename = "type")]
#[serde(skip_serializing_if = "Option::is_none")]
pub type_: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ArtifactRevision {
#[serde(rename = "created")]
#[serde(skip_serializing_if = "Option::is_none")]
pub created: Option<f64>,
#[serde(rename = "name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
#[serde(rename = "revisionChangeIdentifier")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_change_identifier: Option<String>,
#[serde(rename = "revisionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_id: Option<String>,
#[serde(rename = "revisionSummary")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_summary: Option<String>,
#[serde(rename = "revisionUrl")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_url: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct ArtifactStore {
#[serde(rename = "encryptionKey")]
#[serde(skip_serializing_if = "Option::is_none")]
pub encryption_key: Option<EncryptionKey>,
#[serde(rename = "location")]
pub location: String,
#[serde(rename = "type")]
pub type_: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct BlockerDeclaration {
#[serde(rename = "name")]
pub name: String,
#[serde(rename = "type")]
pub type_: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CreateCustomActionTypeInput {
#[serde(rename = "category")]
pub category: String,
#[serde(rename = "configurationProperties")]
#[serde(skip_serializing_if = "Option::is_none")]
pub configuration_properties: Option<Vec<ActionConfigurationProperty>>,
#[serde(rename = "inputArtifactDetails")]
pub input_artifact_details: ArtifactDetails,
#[serde(rename = "outputArtifactDetails")]
pub output_artifact_details: ArtifactDetails,
#[serde(rename = "provider")]
pub provider: String,
#[serde(rename = "settings")]
#[serde(skip_serializing_if = "Option::is_none")]
pub settings: Option<ActionTypeSettings>,
#[serde(rename = "tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
#[serde(rename = "version")]
pub version: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreateCustomActionTypeOutput {
#[serde(rename = "actionType")]
pub action_type: ActionType,
#[serde(rename = "tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CreatePipelineInput {
#[serde(rename = "pipeline")]
pub pipeline: PipelineDeclaration,
#[serde(rename = "tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct CreatePipelineOutput {
#[serde(rename = "pipeline")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline: Option<PipelineDeclaration>,
#[serde(rename = "tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct CurrentRevision {
#[serde(rename = "changeIdentifier")]
pub change_identifier: String,
#[serde(rename = "created")]
#[serde(skip_serializing_if = "Option::is_none")]
pub created: Option<f64>,
#[serde(rename = "revision")]
pub revision: String,
#[serde(rename = "revisionSummary")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_summary: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeleteCustomActionTypeInput {
#[serde(rename = "category")]
pub category: String,
#[serde(rename = "provider")]
pub provider: String,
#[serde(rename = "version")]
pub version: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeletePipelineInput {
#[serde(rename = "name")]
pub name: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeleteWebhookInput {
#[serde(rename = "name")]
pub name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DeleteWebhookOutput {}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DeregisterWebhookWithThirdPartyInput {
#[serde(rename = "webhookName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub webhook_name: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct DeregisterWebhookWithThirdPartyOutput {}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct DisableStageTransitionInput {
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
#[serde(rename = "reason")]
pub reason: String,
#[serde(rename = "stageName")]
pub stage_name: String,
#[serde(rename = "transitionType")]
pub transition_type: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct EnableStageTransitionInput {
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
#[serde(rename = "stageName")]
pub stage_name: String,
#[serde(rename = "transitionType")]
pub transition_type: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct EncryptionKey {
#[serde(rename = "id")]
pub id: String,
#[serde(rename = "type")]
pub type_: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ErrorDetails {
#[serde(rename = "code")]
#[serde(skip_serializing_if = "Option::is_none")]
pub code: Option<String>,
#[serde(rename = "message")]
#[serde(skip_serializing_if = "Option::is_none")]
pub message: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ExecutionDetails {
#[serde(rename = "externalExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub external_execution_id: Option<String>,
#[serde(rename = "percentComplete")]
#[serde(skip_serializing_if = "Option::is_none")]
pub percent_complete: Option<i64>,
#[serde(rename = "summary")]
#[serde(skip_serializing_if = "Option::is_none")]
pub summary: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ExecutionTrigger {
#[serde(rename = "triggerDetail")]
#[serde(skip_serializing_if = "Option::is_none")]
pub trigger_detail: Option<String>,
#[serde(rename = "triggerType")]
#[serde(skip_serializing_if = "Option::is_none")]
pub trigger_type: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct FailureDetails {
#[serde(rename = "externalExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub external_execution_id: Option<String>,
#[serde(rename = "message")]
pub message: String,
#[serde(rename = "type")]
pub type_: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct GetJobDetailsInput {
#[serde(rename = "jobId")]
pub job_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct GetJobDetailsOutput {
#[serde(rename = "jobDetails")]
#[serde(skip_serializing_if = "Option::is_none")]
pub job_details: Option<JobDetails>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct GetPipelineExecutionInput {
#[serde(rename = "pipelineExecutionId")]
pub pipeline_execution_id: String,
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct GetPipelineExecutionOutput {
#[serde(rename = "pipelineExecution")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution: Option<PipelineExecution>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct GetPipelineInput {
#[serde(rename = "name")]
pub name: String,
#[serde(rename = "version")]
#[serde(skip_serializing_if = "Option::is_none")]
pub version: Option<i64>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct GetPipelineOutput {
#[serde(rename = "metadata")]
#[serde(skip_serializing_if = "Option::is_none")]
pub metadata: Option<PipelineMetadata>,
#[serde(rename = "pipeline")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline: Option<PipelineDeclaration>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct GetPipelineStateInput {
#[serde(rename = "name")]
pub name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct GetPipelineStateOutput {
#[serde(rename = "created")]
#[serde(skip_serializing_if = "Option::is_none")]
pub created: Option<f64>,
#[serde(rename = "pipelineName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_name: Option<String>,
#[serde(rename = "pipelineVersion")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_version: Option<i64>,
#[serde(rename = "stageStates")]
#[serde(skip_serializing_if = "Option::is_none")]
pub stage_states: Option<Vec<StageState>>,
#[serde(rename = "updated")]
#[serde(skip_serializing_if = "Option::is_none")]
pub updated: Option<f64>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct GetThirdPartyJobDetailsInput {
#[serde(rename = "clientToken")]
pub client_token: String,
#[serde(rename = "jobId")]
pub job_id: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct GetThirdPartyJobDetailsOutput {
#[serde(rename = "jobDetails")]
#[serde(skip_serializing_if = "Option::is_none")]
pub job_details: Option<ThirdPartyJobDetails>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct InputArtifact {
#[serde(rename = "name")]
pub name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct Job {
#[serde(rename = "accountId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub account_id: Option<String>,
#[serde(rename = "data")]
#[serde(skip_serializing_if = "Option::is_none")]
pub data: Option<JobData>,
#[serde(rename = "id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
#[serde(rename = "nonce")]
#[serde(skip_serializing_if = "Option::is_none")]
pub nonce: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct JobData {
#[serde(rename = "actionConfiguration")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_configuration: Option<ActionConfiguration>,
#[serde(rename = "actionTypeId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_type_id: Option<ActionTypeId>,
#[serde(rename = "artifactCredentials")]
#[serde(skip_serializing_if = "Option::is_none")]
pub artifact_credentials: Option<AWSSessionCredentials>,
#[serde(rename = "continuationToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub continuation_token: Option<String>,
#[serde(rename = "encryptionKey")]
#[serde(skip_serializing_if = "Option::is_none")]
pub encryption_key: Option<EncryptionKey>,
#[serde(rename = "inputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub input_artifacts: Option<Vec<Artifact>>,
#[serde(rename = "outputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub output_artifacts: Option<Vec<Artifact>>,
#[serde(rename = "pipelineContext")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_context: Option<PipelineContext>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct JobDetails {
#[serde(rename = "accountId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub account_id: Option<String>,
#[serde(rename = "data")]
#[serde(skip_serializing_if = "Option::is_none")]
pub data: Option<JobData>,
#[serde(rename = "id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListActionExecutionsInput {
#[serde(rename = "filter")]
#[serde(skip_serializing_if = "Option::is_none")]
pub filter: Option<ActionExecutionFilter>,
#[serde(rename = "maxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListActionExecutionsOutput {
#[serde(rename = "actionExecutionDetails")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_execution_details: Option<Vec<ActionExecutionDetail>>,
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListActionTypesInput {
#[serde(rename = "actionOwnerFilter")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_owner_filter: Option<String>,
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListActionTypesOutput {
#[serde(rename = "actionTypes")]
pub action_types: Vec<ActionType>,
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListPipelineExecutionsInput {
#[serde(rename = "maxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListPipelineExecutionsOutput {
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
#[serde(rename = "pipelineExecutionSummaries")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_summaries: Option<Vec<PipelineExecutionSummary>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListPipelinesInput {
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListPipelinesOutput {
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
#[serde(rename = "pipelines")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipelines: Option<Vec<PipelineSummary>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListTagsForResourceInput {
#[serde(rename = "maxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
#[serde(rename = "resourceArn")]
pub resource_arn: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListTagsForResourceOutput {
#[serde(rename = "nextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
#[serde(rename = "tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListWebhookItem {
#[serde(rename = "arn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub arn: Option<String>,
#[serde(rename = "definition")]
pub definition: WebhookDefinition,
#[serde(rename = "errorCode")]
#[serde(skip_serializing_if = "Option::is_none")]
pub error_code: Option<String>,
#[serde(rename = "errorMessage")]
#[serde(skip_serializing_if = "Option::is_none")]
pub error_message: Option<String>,
#[serde(rename = "lastTriggered")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_triggered: Option<f64>,
#[serde(rename = "tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
#[serde(rename = "url")]
pub url: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct ListWebhooksInput {
#[serde(rename = "MaxResults")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_results: Option<i64>,
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ListWebhooksOutput {
#[serde(rename = "NextToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub next_token: Option<String>,
#[serde(rename = "webhooks")]
#[serde(skip_serializing_if = "Option::is_none")]
pub webhooks: Option<Vec<ListWebhookItem>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct OutputArtifact {
#[serde(rename = "name")]
pub name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PipelineContext {
#[serde(rename = "action")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action: Option<ActionContext>,
#[serde(rename = "pipelineArn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_arn: Option<String>,
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
#[serde(rename = "pipelineName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_name: Option<String>,
#[serde(rename = "stage")]
#[serde(skip_serializing_if = "Option::is_none")]
pub stage: Option<StageContext>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct PipelineDeclaration {
#[serde(rename = "artifactStore")]
#[serde(skip_serializing_if = "Option::is_none")]
pub artifact_store: Option<ArtifactStore>,
#[serde(rename = "artifactStores")]
#[serde(skip_serializing_if = "Option::is_none")]
pub artifact_stores: Option<::std::collections::HashMap<String, ArtifactStore>>,
#[serde(rename = "name")]
pub name: String,
#[serde(rename = "roleArn")]
pub role_arn: String,
#[serde(rename = "stages")]
pub stages: Vec<StageDeclaration>,
#[serde(rename = "version")]
#[serde(skip_serializing_if = "Option::is_none")]
pub version: Option<i64>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PipelineExecution {
#[serde(rename = "artifactRevisions")]
#[serde(skip_serializing_if = "Option::is_none")]
pub artifact_revisions: Option<Vec<ArtifactRevision>>,
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
#[serde(rename = "pipelineName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_name: Option<String>,
#[serde(rename = "pipelineVersion")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_version: Option<i64>,
#[serde(rename = "status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PipelineExecutionSummary {
#[serde(rename = "lastUpdateTime")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_update_time: Option<f64>,
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
#[serde(rename = "sourceRevisions")]
#[serde(skip_serializing_if = "Option::is_none")]
pub source_revisions: Option<Vec<SourceRevision>>,
#[serde(rename = "startTime")]
#[serde(skip_serializing_if = "Option::is_none")]
pub start_time: Option<f64>,
#[serde(rename = "status")]
#[serde(skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
#[serde(rename = "stopTrigger")]
#[serde(skip_serializing_if = "Option::is_none")]
pub stop_trigger: Option<StopExecutionTrigger>,
#[serde(rename = "trigger")]
#[serde(skip_serializing_if = "Option::is_none")]
pub trigger: Option<ExecutionTrigger>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PipelineMetadata {
#[serde(rename = "created")]
#[serde(skip_serializing_if = "Option::is_none")]
pub created: Option<f64>,
#[serde(rename = "pipelineArn")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_arn: Option<String>,
#[serde(rename = "updated")]
#[serde(skip_serializing_if = "Option::is_none")]
pub updated: Option<f64>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PipelineSummary {
#[serde(rename = "created")]
#[serde(skip_serializing_if = "Option::is_none")]
pub created: Option<f64>,
#[serde(rename = "name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
#[serde(rename = "updated")]
#[serde(skip_serializing_if = "Option::is_none")]
pub updated: Option<f64>,
#[serde(rename = "version")]
#[serde(skip_serializing_if = "Option::is_none")]
pub version: Option<i64>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PollForJobsInput {
#[serde(rename = "actionTypeId")]
pub action_type_id: ActionTypeId,
#[serde(rename = "maxBatchSize")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_batch_size: Option<i64>,
#[serde(rename = "queryParam")]
#[serde(skip_serializing_if = "Option::is_none")]
pub query_param: Option<::std::collections::HashMap<String, String>>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PollForJobsOutput {
#[serde(rename = "jobs")]
#[serde(skip_serializing_if = "Option::is_none")]
pub jobs: Option<Vec<Job>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PollForThirdPartyJobsInput {
#[serde(rename = "actionTypeId")]
pub action_type_id: ActionTypeId,
#[serde(rename = "maxBatchSize")]
#[serde(skip_serializing_if = "Option::is_none")]
pub max_batch_size: Option<i64>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PollForThirdPartyJobsOutput {
#[serde(rename = "jobs")]
#[serde(skip_serializing_if = "Option::is_none")]
pub jobs: Option<Vec<ThirdPartyJob>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PutActionRevisionInput {
#[serde(rename = "actionName")]
pub action_name: String,
#[serde(rename = "actionRevision")]
pub action_revision: ActionRevision,
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
#[serde(rename = "stageName")]
pub stage_name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PutActionRevisionOutput {
#[serde(rename = "newRevision")]
#[serde(skip_serializing_if = "Option::is_none")]
pub new_revision: Option<bool>,
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PutApprovalResultInput {
#[serde(rename = "actionName")]
pub action_name: String,
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
#[serde(rename = "result")]
pub result: ApprovalResult,
#[serde(rename = "stageName")]
pub stage_name: String,
#[serde(rename = "token")]
pub token: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PutApprovalResultOutput {
#[serde(rename = "approvedAt")]
#[serde(skip_serializing_if = "Option::is_none")]
pub approved_at: Option<f64>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PutJobFailureResultInput {
#[serde(rename = "failureDetails")]
pub failure_details: FailureDetails,
#[serde(rename = "jobId")]
pub job_id: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PutJobSuccessResultInput {
#[serde(rename = "continuationToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub continuation_token: Option<String>,
#[serde(rename = "currentRevision")]
#[serde(skip_serializing_if = "Option::is_none")]
pub current_revision: Option<CurrentRevision>,
#[serde(rename = "executionDetails")]
#[serde(skip_serializing_if = "Option::is_none")]
pub execution_details: Option<ExecutionDetails>,
#[serde(rename = "jobId")]
pub job_id: String,
#[serde(rename = "outputVariables")]
#[serde(skip_serializing_if = "Option::is_none")]
pub output_variables: Option<::std::collections::HashMap<String, String>>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PutThirdPartyJobFailureResultInput {
#[serde(rename = "clientToken")]
pub client_token: String,
#[serde(rename = "failureDetails")]
pub failure_details: FailureDetails,
#[serde(rename = "jobId")]
pub job_id: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PutThirdPartyJobSuccessResultInput {
#[serde(rename = "clientToken")]
pub client_token: String,
#[serde(rename = "continuationToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub continuation_token: Option<String>,
#[serde(rename = "currentRevision")]
#[serde(skip_serializing_if = "Option::is_none")]
pub current_revision: Option<CurrentRevision>,
#[serde(rename = "executionDetails")]
#[serde(skip_serializing_if = "Option::is_none")]
pub execution_details: Option<ExecutionDetails>,
#[serde(rename = "jobId")]
pub job_id: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct PutWebhookInput {
#[serde(rename = "tags")]
#[serde(skip_serializing_if = "Option::is_none")]
pub tags: Option<Vec<Tag>>,
#[serde(rename = "webhook")]
pub webhook: WebhookDefinition,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct PutWebhookOutput {
#[serde(rename = "webhook")]
#[serde(skip_serializing_if = "Option::is_none")]
pub webhook: Option<ListWebhookItem>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct RegisterWebhookWithThirdPartyInput {
#[serde(rename = "webhookName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub webhook_name: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct RegisterWebhookWithThirdPartyOutput {}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct RetryStageExecutionInput {
#[serde(rename = "pipelineExecutionId")]
pub pipeline_execution_id: String,
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
#[serde(rename = "retryMode")]
pub retry_mode: String,
#[serde(rename = "stageName")]
pub stage_name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct RetryStageExecutionOutput {
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct S3ArtifactLocation {
#[serde(rename = "bucketName")]
pub bucket_name: String,
#[serde(rename = "objectKey")]
pub object_key: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct S3Location {
#[serde(rename = "bucket")]
#[serde(skip_serializing_if = "Option::is_none")]
pub bucket: Option<String>,
#[serde(rename = "key")]
#[serde(skip_serializing_if = "Option::is_none")]
pub key: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct SourceRevision {
#[serde(rename = "actionName")]
pub action_name: String,
#[serde(rename = "revisionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_id: Option<String>,
#[serde(rename = "revisionSummary")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_summary: Option<String>,
#[serde(rename = "revisionUrl")]
#[serde(skip_serializing_if = "Option::is_none")]
pub revision_url: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct StageContext {
#[serde(rename = "name")]
#[serde(skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct StageDeclaration {
#[serde(rename = "actions")]
pub actions: Vec<ActionDeclaration>,
#[serde(rename = "blockers")]
#[serde(skip_serializing_if = "Option::is_none")]
pub blockers: Option<Vec<BlockerDeclaration>>,
#[serde(rename = "name")]
pub name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct StageExecution {
#[serde(rename = "pipelineExecutionId")]
pub pipeline_execution_id: String,
#[serde(rename = "status")]
pub status: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct StageState {
#[serde(rename = "actionStates")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_states: Option<Vec<ActionState>>,
#[serde(rename = "inboundTransitionState")]
#[serde(skip_serializing_if = "Option::is_none")]
pub inbound_transition_state: Option<TransitionState>,
#[serde(rename = "latestExecution")]
#[serde(skip_serializing_if = "Option::is_none")]
pub latest_execution: Option<StageExecution>,
#[serde(rename = "stageName")]
#[serde(skip_serializing_if = "Option::is_none")]
pub stage_name: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct StartPipelineExecutionInput {
#[serde(rename = "clientRequestToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub client_request_token: Option<String>,
#[serde(rename = "name")]
pub name: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct StartPipelineExecutionOutput {
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct StopExecutionTrigger {
#[serde(rename = "reason")]
#[serde(skip_serializing_if = "Option::is_none")]
pub reason: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct StopPipelineExecutionInput {
#[serde(rename = "abandon")]
#[serde(skip_serializing_if = "Option::is_none")]
pub abandon: Option<bool>,
#[serde(rename = "pipelineExecutionId")]
pub pipeline_execution_id: String,
#[serde(rename = "pipelineName")]
pub pipeline_name: String,
#[serde(rename = "reason")]
#[serde(skip_serializing_if = "Option::is_none")]
pub reason: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct StopPipelineExecutionOutput {
#[serde(rename = "pipelineExecutionId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_execution_id: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct Tag {
#[serde(rename = "key")]
pub key: String,
#[serde(rename = "value")]
pub value: String,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct TagResourceInput {
#[serde(rename = "resourceArn")]
pub resource_arn: String,
#[serde(rename = "tags")]
pub tags: Vec<Tag>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct TagResourceOutput {}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ThirdPartyJob {
#[serde(rename = "clientId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub client_id: Option<String>,
#[serde(rename = "jobId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub job_id: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ThirdPartyJobData {
#[serde(rename = "actionConfiguration")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_configuration: Option<ActionConfiguration>,
#[serde(rename = "actionTypeId")]
#[serde(skip_serializing_if = "Option::is_none")]
pub action_type_id: Option<ActionTypeId>,
#[serde(rename = "artifactCredentials")]
#[serde(skip_serializing_if = "Option::is_none")]
pub artifact_credentials: Option<AWSSessionCredentials>,
#[serde(rename = "continuationToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub continuation_token: Option<String>,
#[serde(rename = "encryptionKey")]
#[serde(skip_serializing_if = "Option::is_none")]
pub encryption_key: Option<EncryptionKey>,
#[serde(rename = "inputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub input_artifacts: Option<Vec<Artifact>>,
#[serde(rename = "outputArtifacts")]
#[serde(skip_serializing_if = "Option::is_none")]
pub output_artifacts: Option<Vec<Artifact>>,
#[serde(rename = "pipelineContext")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline_context: Option<PipelineContext>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct ThirdPartyJobDetails {
#[serde(rename = "data")]
#[serde(skip_serializing_if = "Option::is_none")]
pub data: Option<ThirdPartyJobData>,
#[serde(rename = "id")]
#[serde(skip_serializing_if = "Option::is_none")]
pub id: Option<String>,
#[serde(rename = "nonce")]
#[serde(skip_serializing_if = "Option::is_none")]
pub nonce: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct TransitionState {
#[serde(rename = "disabledReason")]
#[serde(skip_serializing_if = "Option::is_none")]
pub disabled_reason: Option<String>,
#[serde(rename = "enabled")]
#[serde(skip_serializing_if = "Option::is_none")]
pub enabled: Option<bool>,
#[serde(rename = "lastChangedAt")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_changed_at: Option<f64>,
#[serde(rename = "lastChangedBy")]
#[serde(skip_serializing_if = "Option::is_none")]
pub last_changed_by: Option<String>,
}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct UntagResourceInput {
#[serde(rename = "resourceArn")]
pub resource_arn: String,
#[serde(rename = "tagKeys")]
pub tag_keys: Vec<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct UntagResourceOutput {}
#[derive(Clone, Debug, Default, PartialEq, Serialize)]
#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
pub struct UpdatePipelineInput {
#[serde(rename = "pipeline")]
pub pipeline: PipelineDeclaration,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
pub struct UpdatePipelineOutput {
#[serde(rename = "pipeline")]
#[serde(skip_serializing_if = "Option::is_none")]
pub pipeline: Option<PipelineDeclaration>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct WebhookAuthConfiguration {
#[serde(rename = "AllowedIPRange")]
#[serde(skip_serializing_if = "Option::is_none")]
pub allowed_ip_range: Option<String>,
#[serde(rename = "SecretToken")]
#[serde(skip_serializing_if = "Option::is_none")]
pub secret_token: Option<String>,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct WebhookDefinition {
#[serde(rename = "authentication")]
pub authentication: String,
#[serde(rename = "authenticationConfiguration")]
pub authentication_configuration: WebhookAuthConfiguration,
#[serde(rename = "filters")]
pub filters: Vec<WebhookFilterRule>,
#[serde(rename = "name")]
pub name: String,
#[serde(rename = "targetAction")]
pub target_action: String,
#[serde(rename = "targetPipeline")]
pub target_pipeline: String,
}
#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
pub struct WebhookFilterRule {
#[serde(rename = "jsonPath")]
pub json_path: String,
#[serde(rename = "matchEquals")]
#[serde(skip_serializing_if = "Option::is_none")]
pub match_equals: Option<String>,
}
#[derive(Debug, PartialEq)]
pub enum AcknowledgeJobError {
InvalidNonce(String),
JobNotFound(String),
}
impl AcknowledgeJobError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<AcknowledgeJobError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidNonceException" => {
return RusotoError::Service(AcknowledgeJobError::InvalidNonce(err.msg))
}
"JobNotFoundException" => {
return RusotoError::Service(AcknowledgeJobError::JobNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for AcknowledgeJobError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
AcknowledgeJobError::InvalidNonce(ref cause) => write!(f, "{}", cause),
AcknowledgeJobError::JobNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for AcknowledgeJobError {}
#[derive(Debug, PartialEq)]
pub enum AcknowledgeThirdPartyJobError {
InvalidClientToken(String),
InvalidNonce(String),
JobNotFound(String),
}
impl AcknowledgeThirdPartyJobError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<AcknowledgeThirdPartyJobError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidClientTokenException" => {
return RusotoError::Service(AcknowledgeThirdPartyJobError::InvalidClientToken(
err.msg,
))
}
"InvalidNonceException" => {
return RusotoError::Service(AcknowledgeThirdPartyJobError::InvalidNonce(
err.msg,
))
}
"JobNotFoundException" => {
return RusotoError::Service(AcknowledgeThirdPartyJobError::JobNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for AcknowledgeThirdPartyJobError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
AcknowledgeThirdPartyJobError::InvalidClientToken(ref cause) => write!(f, "{}", cause),
AcknowledgeThirdPartyJobError::InvalidNonce(ref cause) => write!(f, "{}", cause),
AcknowledgeThirdPartyJobError::JobNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for AcknowledgeThirdPartyJobError {}
#[derive(Debug, PartialEq)]
pub enum CreateCustomActionTypeError {
ConcurrentModification(String),
InvalidTags(String),
LimitExceeded(String),
TooManyTags(String),
}
impl CreateCustomActionTypeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateCustomActionTypeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(
CreateCustomActionTypeError::ConcurrentModification(err.msg),
)
}
"InvalidTagsException" => {
return RusotoError::Service(CreateCustomActionTypeError::InvalidTags(err.msg))
}
"LimitExceededException" => {
return RusotoError::Service(CreateCustomActionTypeError::LimitExceeded(
err.msg,
))
}
"TooManyTagsException" => {
return RusotoError::Service(CreateCustomActionTypeError::TooManyTags(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CreateCustomActionTypeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CreateCustomActionTypeError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
CreateCustomActionTypeError::InvalidTags(ref cause) => write!(f, "{}", cause),
CreateCustomActionTypeError::LimitExceeded(ref cause) => write!(f, "{}", cause),
CreateCustomActionTypeError::TooManyTags(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CreateCustomActionTypeError {}
#[derive(Debug, PartialEq)]
pub enum CreatePipelineError {
ConcurrentModification(String),
InvalidActionDeclaration(String),
InvalidBlockerDeclaration(String),
InvalidStageDeclaration(String),
InvalidStructure(String),
InvalidTags(String),
LimitExceeded(String),
PipelineNameInUse(String),
TooManyTags(String),
}
impl CreatePipelineError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreatePipelineError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(CreatePipelineError::ConcurrentModification(
err.msg,
))
}
"InvalidActionDeclarationException" => {
return RusotoError::Service(CreatePipelineError::InvalidActionDeclaration(
err.msg,
))
}
"InvalidBlockerDeclarationException" => {
return RusotoError::Service(CreatePipelineError::InvalidBlockerDeclaration(
err.msg,
))
}
"InvalidStageDeclarationException" => {
return RusotoError::Service(CreatePipelineError::InvalidStageDeclaration(
err.msg,
))
}
"InvalidStructureException" => {
return RusotoError::Service(CreatePipelineError::InvalidStructure(err.msg))
}
"InvalidTagsException" => {
return RusotoError::Service(CreatePipelineError::InvalidTags(err.msg))
}
"LimitExceededException" => {
return RusotoError::Service(CreatePipelineError::LimitExceeded(err.msg))
}
"PipelineNameInUseException" => {
return RusotoError::Service(CreatePipelineError::PipelineNameInUse(err.msg))
}
"TooManyTagsException" => {
return RusotoError::Service(CreatePipelineError::TooManyTags(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for CreatePipelineError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
CreatePipelineError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
CreatePipelineError::InvalidActionDeclaration(ref cause) => write!(f, "{}", cause),
CreatePipelineError::InvalidBlockerDeclaration(ref cause) => write!(f, "{}", cause),
CreatePipelineError::InvalidStageDeclaration(ref cause) => write!(f, "{}", cause),
CreatePipelineError::InvalidStructure(ref cause) => write!(f, "{}", cause),
CreatePipelineError::InvalidTags(ref cause) => write!(f, "{}", cause),
CreatePipelineError::LimitExceeded(ref cause) => write!(f, "{}", cause),
CreatePipelineError::PipelineNameInUse(ref cause) => write!(f, "{}", cause),
CreatePipelineError::TooManyTags(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for CreatePipelineError {}
#[derive(Debug, PartialEq)]
pub enum DeleteCustomActionTypeError {
ConcurrentModification(String),
}
impl DeleteCustomActionTypeError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteCustomActionTypeError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(
DeleteCustomActionTypeError::ConcurrentModification(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeleteCustomActionTypeError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeleteCustomActionTypeError::ConcurrentModification(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for DeleteCustomActionTypeError {}
#[derive(Debug, PartialEq)]
pub enum DeletePipelineError {
ConcurrentModification(String),
}
impl DeletePipelineError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeletePipelineError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(DeletePipelineError::ConcurrentModification(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeletePipelineError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeletePipelineError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DeletePipelineError {}
#[derive(Debug, PartialEq)]
pub enum DeleteWebhookError {
ConcurrentModification(String),
}
impl DeleteWebhookError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteWebhookError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(DeleteWebhookError::ConcurrentModification(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeleteWebhookError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeleteWebhookError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DeleteWebhookError {}
#[derive(Debug, PartialEq)]
pub enum DeregisterWebhookWithThirdPartyError {
WebhookNotFound(String),
}
impl DeregisterWebhookWithThirdPartyError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<DeregisterWebhookWithThirdPartyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"WebhookNotFoundException" => {
return RusotoError::Service(
DeregisterWebhookWithThirdPartyError::WebhookNotFound(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DeregisterWebhookWithThirdPartyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DeregisterWebhookWithThirdPartyError::WebhookNotFound(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for DeregisterWebhookWithThirdPartyError {}
#[derive(Debug, PartialEq)]
pub enum DisableStageTransitionError {
PipelineNotFound(String),
StageNotFound(String),
}
impl DisableStageTransitionError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DisableStageTransitionError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"PipelineNotFoundException" => {
return RusotoError::Service(DisableStageTransitionError::PipelineNotFound(
err.msg,
))
}
"StageNotFoundException" => {
return RusotoError::Service(DisableStageTransitionError::StageNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for DisableStageTransitionError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
DisableStageTransitionError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
DisableStageTransitionError::StageNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for DisableStageTransitionError {}
#[derive(Debug, PartialEq)]
pub enum EnableStageTransitionError {
PipelineNotFound(String),
StageNotFound(String),
}
impl EnableStageTransitionError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<EnableStageTransitionError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"PipelineNotFoundException" => {
return RusotoError::Service(EnableStageTransitionError::PipelineNotFound(
err.msg,
))
}
"StageNotFoundException" => {
return RusotoError::Service(EnableStageTransitionError::StageNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for EnableStageTransitionError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
EnableStageTransitionError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
EnableStageTransitionError::StageNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for EnableStageTransitionError {}
#[derive(Debug, PartialEq)]
pub enum GetJobDetailsError {
JobNotFound(String),
}
impl GetJobDetailsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetJobDetailsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"JobNotFoundException" => {
return RusotoError::Service(GetJobDetailsError::JobNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for GetJobDetailsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
GetJobDetailsError::JobNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for GetJobDetailsError {}
#[derive(Debug, PartialEq)]
pub enum GetPipelineError {
PipelineNotFound(String),
PipelineVersionNotFound(String),
}
impl GetPipelineError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetPipelineError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"PipelineNotFoundException" => {
return RusotoError::Service(GetPipelineError::PipelineNotFound(err.msg))
}
"PipelineVersionNotFoundException" => {
return RusotoError::Service(GetPipelineError::PipelineVersionNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for GetPipelineError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
GetPipelineError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
GetPipelineError::PipelineVersionNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for GetPipelineError {}
#[derive(Debug, PartialEq)]
pub enum GetPipelineExecutionError {
PipelineExecutionNotFound(String),
PipelineNotFound(String),
}
impl GetPipelineExecutionError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetPipelineExecutionError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"PipelineExecutionNotFoundException" => {
return RusotoError::Service(
GetPipelineExecutionError::PipelineExecutionNotFound(err.msg),
)
}
"PipelineNotFoundException" => {
return RusotoError::Service(GetPipelineExecutionError::PipelineNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for GetPipelineExecutionError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
GetPipelineExecutionError::PipelineExecutionNotFound(ref cause) => {
write!(f, "{}", cause)
}
GetPipelineExecutionError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for GetPipelineExecutionError {}
#[derive(Debug, PartialEq)]
pub enum GetPipelineStateError {
PipelineNotFound(String),
}
impl GetPipelineStateError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetPipelineStateError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"PipelineNotFoundException" => {
return RusotoError::Service(GetPipelineStateError::PipelineNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for GetPipelineStateError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
GetPipelineStateError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for GetPipelineStateError {}
#[derive(Debug, PartialEq)]
pub enum GetThirdPartyJobDetailsError {
InvalidClientToken(String),
InvalidJob(String),
JobNotFound(String),
}
impl GetThirdPartyJobDetailsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetThirdPartyJobDetailsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidClientTokenException" => {
return RusotoError::Service(GetThirdPartyJobDetailsError::InvalidClientToken(
err.msg,
))
}
"InvalidJobException" => {
return RusotoError::Service(GetThirdPartyJobDetailsError::InvalidJob(err.msg))
}
"JobNotFoundException" => {
return RusotoError::Service(GetThirdPartyJobDetailsError::JobNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for GetThirdPartyJobDetailsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
GetThirdPartyJobDetailsError::InvalidClientToken(ref cause) => write!(f, "{}", cause),
GetThirdPartyJobDetailsError::InvalidJob(ref cause) => write!(f, "{}", cause),
GetThirdPartyJobDetailsError::JobNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for GetThirdPartyJobDetailsError {}
#[derive(Debug, PartialEq)]
pub enum ListActionExecutionsError {
InvalidNextToken(String),
PipelineExecutionNotFound(String),
PipelineNotFound(String),
}
impl ListActionExecutionsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListActionExecutionsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidNextTokenException" => {
return RusotoError::Service(ListActionExecutionsError::InvalidNextToken(
err.msg,
))
}
"PipelineExecutionNotFoundException" => {
return RusotoError::Service(
ListActionExecutionsError::PipelineExecutionNotFound(err.msg),
)
}
"PipelineNotFoundException" => {
return RusotoError::Service(ListActionExecutionsError::PipelineNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListActionExecutionsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListActionExecutionsError::InvalidNextToken(ref cause) => write!(f, "{}", cause),
ListActionExecutionsError::PipelineExecutionNotFound(ref cause) => {
write!(f, "{}", cause)
}
ListActionExecutionsError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListActionExecutionsError {}
#[derive(Debug, PartialEq)]
pub enum ListActionTypesError {
InvalidNextToken(String),
}
impl ListActionTypesError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListActionTypesError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidNextTokenException" => {
return RusotoError::Service(ListActionTypesError::InvalidNextToken(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListActionTypesError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListActionTypesError::InvalidNextToken(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListActionTypesError {}
#[derive(Debug, PartialEq)]
pub enum ListPipelineExecutionsError {
InvalidNextToken(String),
PipelineNotFound(String),
}
impl ListPipelineExecutionsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListPipelineExecutionsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidNextTokenException" => {
return RusotoError::Service(ListPipelineExecutionsError::InvalidNextToken(
err.msg,
))
}
"PipelineNotFoundException" => {
return RusotoError::Service(ListPipelineExecutionsError::PipelineNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListPipelineExecutionsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListPipelineExecutionsError::InvalidNextToken(ref cause) => write!(f, "{}", cause),
ListPipelineExecutionsError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListPipelineExecutionsError {}
#[derive(Debug, PartialEq)]
pub enum ListPipelinesError {
InvalidNextToken(String),
}
impl ListPipelinesError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListPipelinesError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidNextTokenException" => {
return RusotoError::Service(ListPipelinesError::InvalidNextToken(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListPipelinesError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListPipelinesError::InvalidNextToken(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListPipelinesError {}
#[derive(Debug, PartialEq)]
pub enum ListTagsForResourceError {
InvalidArn(String),
InvalidNextToken(String),
ResourceNotFound(String),
}
impl ListTagsForResourceError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListTagsForResourceError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidArnException" => {
return RusotoError::Service(ListTagsForResourceError::InvalidArn(err.msg))
}
"InvalidNextTokenException" => {
return RusotoError::Service(ListTagsForResourceError::InvalidNextToken(
err.msg,
))
}
"ResourceNotFoundException" => {
return RusotoError::Service(ListTagsForResourceError::ResourceNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListTagsForResourceError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListTagsForResourceError::InvalidArn(ref cause) => write!(f, "{}", cause),
ListTagsForResourceError::InvalidNextToken(ref cause) => write!(f, "{}", cause),
ListTagsForResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListTagsForResourceError {}
#[derive(Debug, PartialEq)]
pub enum ListWebhooksError {
InvalidNextToken(String),
}
impl ListWebhooksError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListWebhooksError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidNextTokenException" => {
return RusotoError::Service(ListWebhooksError::InvalidNextToken(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for ListWebhooksError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
ListWebhooksError::InvalidNextToken(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for ListWebhooksError {}
#[derive(Debug, PartialEq)]
pub enum PollForJobsError {
ActionTypeNotFound(String),
}
impl PollForJobsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PollForJobsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ActionTypeNotFoundException" => {
return RusotoError::Service(PollForJobsError::ActionTypeNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PollForJobsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PollForJobsError::ActionTypeNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PollForJobsError {}
#[derive(Debug, PartialEq)]
pub enum PollForThirdPartyJobsError {
ActionTypeNotFound(String),
}
impl PollForThirdPartyJobsError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PollForThirdPartyJobsError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ActionTypeNotFoundException" => {
return RusotoError::Service(PollForThirdPartyJobsError::ActionTypeNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PollForThirdPartyJobsError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PollForThirdPartyJobsError::ActionTypeNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PollForThirdPartyJobsError {}
#[derive(Debug, PartialEq)]
pub enum PutActionRevisionError {
ActionNotFound(String),
PipelineNotFound(String),
StageNotFound(String),
}
impl PutActionRevisionError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutActionRevisionError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ActionNotFoundException" => {
return RusotoError::Service(PutActionRevisionError::ActionNotFound(err.msg))
}
"PipelineNotFoundException" => {
return RusotoError::Service(PutActionRevisionError::PipelineNotFound(err.msg))
}
"StageNotFoundException" => {
return RusotoError::Service(PutActionRevisionError::StageNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PutActionRevisionError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PutActionRevisionError::ActionNotFound(ref cause) => write!(f, "{}", cause),
PutActionRevisionError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
PutActionRevisionError::StageNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PutActionRevisionError {}
#[derive(Debug, PartialEq)]
pub enum PutApprovalResultError {
ActionNotFound(String),
ApprovalAlreadyCompleted(String),
InvalidApprovalToken(String),
PipelineNotFound(String),
StageNotFound(String),
}
impl PutApprovalResultError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutApprovalResultError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ActionNotFoundException" => {
return RusotoError::Service(PutApprovalResultError::ActionNotFound(err.msg))
}
"ApprovalAlreadyCompletedException" => {
return RusotoError::Service(PutApprovalResultError::ApprovalAlreadyCompleted(
err.msg,
))
}
"InvalidApprovalTokenException" => {
return RusotoError::Service(PutApprovalResultError::InvalidApprovalToken(
err.msg,
))
}
"PipelineNotFoundException" => {
return RusotoError::Service(PutApprovalResultError::PipelineNotFound(err.msg))
}
"StageNotFoundException" => {
return RusotoError::Service(PutApprovalResultError::StageNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PutApprovalResultError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PutApprovalResultError::ActionNotFound(ref cause) => write!(f, "{}", cause),
PutApprovalResultError::ApprovalAlreadyCompleted(ref cause) => write!(f, "{}", cause),
PutApprovalResultError::InvalidApprovalToken(ref cause) => write!(f, "{}", cause),
PutApprovalResultError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
PutApprovalResultError::StageNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PutApprovalResultError {}
#[derive(Debug, PartialEq)]
pub enum PutJobFailureResultError {
InvalidJobState(String),
JobNotFound(String),
}
impl PutJobFailureResultError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutJobFailureResultError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidJobStateException" => {
return RusotoError::Service(PutJobFailureResultError::InvalidJobState(err.msg))
}
"JobNotFoundException" => {
return RusotoError::Service(PutJobFailureResultError::JobNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PutJobFailureResultError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PutJobFailureResultError::InvalidJobState(ref cause) => write!(f, "{}", cause),
PutJobFailureResultError::JobNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PutJobFailureResultError {}
#[derive(Debug, PartialEq)]
pub enum PutJobSuccessResultError {
InvalidJobState(String),
JobNotFound(String),
OutputVariablesSizeExceeded(String),
}
impl PutJobSuccessResultError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutJobSuccessResultError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidJobStateException" => {
return RusotoError::Service(PutJobSuccessResultError::InvalidJobState(err.msg))
}
"JobNotFoundException" => {
return RusotoError::Service(PutJobSuccessResultError::JobNotFound(err.msg))
}
"OutputVariablesSizeExceededException" => {
return RusotoError::Service(
PutJobSuccessResultError::OutputVariablesSizeExceeded(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PutJobSuccessResultError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PutJobSuccessResultError::InvalidJobState(ref cause) => write!(f, "{}", cause),
PutJobSuccessResultError::JobNotFound(ref cause) => write!(f, "{}", cause),
PutJobSuccessResultError::OutputVariablesSizeExceeded(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for PutJobSuccessResultError {}
#[derive(Debug, PartialEq)]
pub enum PutThirdPartyJobFailureResultError {
InvalidClientToken(String),
InvalidJobState(String),
JobNotFound(String),
}
impl PutThirdPartyJobFailureResultError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<PutThirdPartyJobFailureResultError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidClientTokenException" => {
return RusotoError::Service(
PutThirdPartyJobFailureResultError::InvalidClientToken(err.msg),
)
}
"InvalidJobStateException" => {
return RusotoError::Service(
PutThirdPartyJobFailureResultError::InvalidJobState(err.msg),
)
}
"JobNotFoundException" => {
return RusotoError::Service(PutThirdPartyJobFailureResultError::JobNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PutThirdPartyJobFailureResultError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PutThirdPartyJobFailureResultError::InvalidClientToken(ref cause) => {
write!(f, "{}", cause)
}
PutThirdPartyJobFailureResultError::InvalidJobState(ref cause) => {
write!(f, "{}", cause)
}
PutThirdPartyJobFailureResultError::JobNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PutThirdPartyJobFailureResultError {}
#[derive(Debug, PartialEq)]
pub enum PutThirdPartyJobSuccessResultError {
InvalidClientToken(String),
InvalidJobState(String),
JobNotFound(String),
}
impl PutThirdPartyJobSuccessResultError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<PutThirdPartyJobSuccessResultError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidClientTokenException" => {
return RusotoError::Service(
PutThirdPartyJobSuccessResultError::InvalidClientToken(err.msg),
)
}
"InvalidJobStateException" => {
return RusotoError::Service(
PutThirdPartyJobSuccessResultError::InvalidJobState(err.msg),
)
}
"JobNotFoundException" => {
return RusotoError::Service(PutThirdPartyJobSuccessResultError::JobNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PutThirdPartyJobSuccessResultError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PutThirdPartyJobSuccessResultError::InvalidClientToken(ref cause) => {
write!(f, "{}", cause)
}
PutThirdPartyJobSuccessResultError::InvalidJobState(ref cause) => {
write!(f, "{}", cause)
}
PutThirdPartyJobSuccessResultError::JobNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PutThirdPartyJobSuccessResultError {}
#[derive(Debug, PartialEq)]
pub enum PutWebhookError {
ConcurrentModification(String),
InvalidTags(String),
InvalidWebhookAuthenticationParameters(String),
InvalidWebhookFilterPattern(String),
LimitExceeded(String),
PipelineNotFound(String),
TooManyTags(String),
}
impl PutWebhookError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutWebhookError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(PutWebhookError::ConcurrentModification(err.msg))
}
"InvalidTagsException" => {
return RusotoError::Service(PutWebhookError::InvalidTags(err.msg))
}
"InvalidWebhookAuthenticationParametersException" => {
return RusotoError::Service(
PutWebhookError::InvalidWebhookAuthenticationParameters(err.msg),
)
}
"InvalidWebhookFilterPatternException" => {
return RusotoError::Service(PutWebhookError::InvalidWebhookFilterPattern(
err.msg,
))
}
"LimitExceededException" => {
return RusotoError::Service(PutWebhookError::LimitExceeded(err.msg))
}
"PipelineNotFoundException" => {
return RusotoError::Service(PutWebhookError::PipelineNotFound(err.msg))
}
"TooManyTagsException" => {
return RusotoError::Service(PutWebhookError::TooManyTags(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for PutWebhookError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
PutWebhookError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
PutWebhookError::InvalidTags(ref cause) => write!(f, "{}", cause),
PutWebhookError::InvalidWebhookAuthenticationParameters(ref cause) => {
write!(f, "{}", cause)
}
PutWebhookError::InvalidWebhookFilterPattern(ref cause) => write!(f, "{}", cause),
PutWebhookError::LimitExceeded(ref cause) => write!(f, "{}", cause),
PutWebhookError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
PutWebhookError::TooManyTags(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for PutWebhookError {}
#[derive(Debug, PartialEq)]
pub enum RegisterWebhookWithThirdPartyError {
WebhookNotFound(String),
}
impl RegisterWebhookWithThirdPartyError {
pub fn from_response(
res: BufferedHttpResponse,
) -> RusotoError<RegisterWebhookWithThirdPartyError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"WebhookNotFoundException" => {
return RusotoError::Service(
RegisterWebhookWithThirdPartyError::WebhookNotFound(err.msg),
)
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for RegisterWebhookWithThirdPartyError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
RegisterWebhookWithThirdPartyError::WebhookNotFound(ref cause) => {
write!(f, "{}", cause)
}
}
}
}
impl Error for RegisterWebhookWithThirdPartyError {}
#[derive(Debug, PartialEq)]
pub enum RetryStageExecutionError {
NotLatestPipelineExecution(String),
PipelineNotFound(String),
StageNotFound(String),
StageNotRetryable(String),
}
impl RetryStageExecutionError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<RetryStageExecutionError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"NotLatestPipelineExecutionException" => {
return RusotoError::Service(
RetryStageExecutionError::NotLatestPipelineExecution(err.msg),
)
}
"PipelineNotFoundException" => {
return RusotoError::Service(RetryStageExecutionError::PipelineNotFound(
err.msg,
))
}
"StageNotFoundException" => {
return RusotoError::Service(RetryStageExecutionError::StageNotFound(err.msg))
}
"StageNotRetryableException" => {
return RusotoError::Service(RetryStageExecutionError::StageNotRetryable(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for RetryStageExecutionError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
RetryStageExecutionError::NotLatestPipelineExecution(ref cause) => {
write!(f, "{}", cause)
}
RetryStageExecutionError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
RetryStageExecutionError::StageNotFound(ref cause) => write!(f, "{}", cause),
RetryStageExecutionError::StageNotRetryable(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for RetryStageExecutionError {}
#[derive(Debug, PartialEq)]
pub enum StartPipelineExecutionError {
PipelineNotFound(String),
}
impl StartPipelineExecutionError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<StartPipelineExecutionError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"PipelineNotFoundException" => {
return RusotoError::Service(StartPipelineExecutionError::PipelineNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for StartPipelineExecutionError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
StartPipelineExecutionError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for StartPipelineExecutionError {}
#[derive(Debug, PartialEq)]
pub enum StopPipelineExecutionError {
DuplicatedStopRequest(String),
PipelineExecutionNotStoppable(String),
PipelineNotFound(String),
}
impl StopPipelineExecutionError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<StopPipelineExecutionError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"DuplicatedStopRequestException" => {
return RusotoError::Service(StopPipelineExecutionError::DuplicatedStopRequest(
err.msg,
))
}
"PipelineExecutionNotStoppableException" => {
return RusotoError::Service(
StopPipelineExecutionError::PipelineExecutionNotStoppable(err.msg),
)
}
"PipelineNotFoundException" => {
return RusotoError::Service(StopPipelineExecutionError::PipelineNotFound(
err.msg,
))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for StopPipelineExecutionError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
StopPipelineExecutionError::DuplicatedStopRequest(ref cause) => write!(f, "{}", cause),
StopPipelineExecutionError::PipelineExecutionNotStoppable(ref cause) => {
write!(f, "{}", cause)
}
StopPipelineExecutionError::PipelineNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for StopPipelineExecutionError {}
#[derive(Debug, PartialEq)]
pub enum TagResourceError {
ConcurrentModification(String),
InvalidArn(String),
InvalidTags(String),
ResourceNotFound(String),
TooManyTags(String),
}
impl TagResourceError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<TagResourceError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(TagResourceError::ConcurrentModification(err.msg))
}
"InvalidArnException" => {
return RusotoError::Service(TagResourceError::InvalidArn(err.msg))
}
"InvalidTagsException" => {
return RusotoError::Service(TagResourceError::InvalidTags(err.msg))
}
"ResourceNotFoundException" => {
return RusotoError::Service(TagResourceError::ResourceNotFound(err.msg))
}
"TooManyTagsException" => {
return RusotoError::Service(TagResourceError::TooManyTags(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for TagResourceError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
TagResourceError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
TagResourceError::InvalidArn(ref cause) => write!(f, "{}", cause),
TagResourceError::InvalidTags(ref cause) => write!(f, "{}", cause),
TagResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
TagResourceError::TooManyTags(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for TagResourceError {}
#[derive(Debug, PartialEq)]
pub enum UntagResourceError {
ConcurrentModification(String),
InvalidArn(String),
InvalidTags(String),
ResourceNotFound(String),
}
impl UntagResourceError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UntagResourceError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"ConcurrentModificationException" => {
return RusotoError::Service(UntagResourceError::ConcurrentModification(
err.msg,
))
}
"InvalidArnException" => {
return RusotoError::Service(UntagResourceError::InvalidArn(err.msg))
}
"InvalidTagsException" => {
return RusotoError::Service(UntagResourceError::InvalidTags(err.msg))
}
"ResourceNotFoundException" => {
return RusotoError::Service(UntagResourceError::ResourceNotFound(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for UntagResourceError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
UntagResourceError::ConcurrentModification(ref cause) => write!(f, "{}", cause),
UntagResourceError::InvalidArn(ref cause) => write!(f, "{}", cause),
UntagResourceError::InvalidTags(ref cause) => write!(f, "{}", cause),
UntagResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for UntagResourceError {}
#[derive(Debug, PartialEq)]
pub enum UpdatePipelineError {
InvalidActionDeclaration(String),
InvalidBlockerDeclaration(String),
InvalidStageDeclaration(String),
InvalidStructure(String),
LimitExceeded(String),
}
impl UpdatePipelineError {
pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdatePipelineError> {
if let Some(err) = proto::json::Error::parse(&res) {
match err.typ.as_str() {
"InvalidActionDeclarationException" => {
return RusotoError::Service(UpdatePipelineError::InvalidActionDeclaration(
err.msg,
))
}
"InvalidBlockerDeclarationException" => {
return RusotoError::Service(UpdatePipelineError::InvalidBlockerDeclaration(
err.msg,
))
}
"InvalidStageDeclarationException" => {
return RusotoError::Service(UpdatePipelineError::InvalidStageDeclaration(
err.msg,
))
}
"InvalidStructureException" => {
return RusotoError::Service(UpdatePipelineError::InvalidStructure(err.msg))
}
"LimitExceededException" => {
return RusotoError::Service(UpdatePipelineError::LimitExceeded(err.msg))
}
"ValidationException" => return RusotoError::Validation(err.msg),
_ => {}
}
}
RusotoError::Unknown(res)
}
}
impl fmt::Display for UpdatePipelineError {
#[allow(unused_variables)]
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
UpdatePipelineError::InvalidActionDeclaration(ref cause) => write!(f, "{}", cause),
UpdatePipelineError::InvalidBlockerDeclaration(ref cause) => write!(f, "{}", cause),
UpdatePipelineError::InvalidStageDeclaration(ref cause) => write!(f, "{}", cause),
UpdatePipelineError::InvalidStructure(ref cause) => write!(f, "{}", cause),
UpdatePipelineError::LimitExceeded(ref cause) => write!(f, "{}", cause),
}
}
}
impl Error for UpdatePipelineError {}
#[async_trait]
pub trait CodePipeline {
async fn acknowledge_job(
&self,
input: AcknowledgeJobInput,
) -> Result<AcknowledgeJobOutput, RusotoError<AcknowledgeJobError>>;
async fn acknowledge_third_party_job(
&self,
input: AcknowledgeThirdPartyJobInput,
) -> Result<AcknowledgeThirdPartyJobOutput, RusotoError<AcknowledgeThirdPartyJobError>>;
async fn create_custom_action_type(
&self,
input: CreateCustomActionTypeInput,
) -> Result<CreateCustomActionTypeOutput, RusotoError<CreateCustomActionTypeError>>;
async fn create_pipeline(
&self,
input: CreatePipelineInput,
) -> Result<CreatePipelineOutput, RusotoError<CreatePipelineError>>;
async fn delete_custom_action_type(
&self,
input: DeleteCustomActionTypeInput,
) -> Result<(), RusotoError<DeleteCustomActionTypeError>>;
async fn delete_pipeline(
&self,
input: DeletePipelineInput,
) -> Result<(), RusotoError<DeletePipelineError>>;
async fn delete_webhook(
&self,
input: DeleteWebhookInput,
) -> Result<DeleteWebhookOutput, RusotoError<DeleteWebhookError>>;
async fn deregister_webhook_with_third_party(
&self,
input: DeregisterWebhookWithThirdPartyInput,
) -> Result<
DeregisterWebhookWithThirdPartyOutput,
RusotoError<DeregisterWebhookWithThirdPartyError>,
>;
async fn disable_stage_transition(
&self,
input: DisableStageTransitionInput,
) -> Result<(), RusotoError<DisableStageTransitionError>>;
async fn enable_stage_transition(
&self,
input: EnableStageTransitionInput,
) -> Result<(), RusotoError<EnableStageTransitionError>>;
async fn get_job_details(
&self,
input: GetJobDetailsInput,
) -> Result<GetJobDetailsOutput, RusotoError<GetJobDetailsError>>;
async fn get_pipeline(
&self,
input: GetPipelineInput,
) -> Result<GetPipelineOutput, RusotoError<GetPipelineError>>;
async fn get_pipeline_execution(
&self,
input: GetPipelineExecutionInput,
) -> Result<GetPipelineExecutionOutput, RusotoError<GetPipelineExecutionError>>;
async fn get_pipeline_state(
&self,
input: GetPipelineStateInput,
) -> Result<GetPipelineStateOutput, RusotoError<GetPipelineStateError>>;
async fn get_third_party_job_details(
&self,
input: GetThirdPartyJobDetailsInput,
) -> Result<GetThirdPartyJobDetailsOutput, RusotoError<GetThirdPartyJobDetailsError>>;
async fn list_action_executions(
&self,
input: ListActionExecutionsInput,
) -> Result<ListActionExecutionsOutput, RusotoError<ListActionExecutionsError>>;
async fn list_action_types(
&self,
input: ListActionTypesInput,
) -> Result<ListActionTypesOutput, RusotoError<ListActionTypesError>>;
async fn list_pipeline_executions(
&self,
input: ListPipelineExecutionsInput,
) -> Result<ListPipelineExecutionsOutput, RusotoError<ListPipelineExecutionsError>>;
async fn list_pipelines(
&self,
input: ListPipelinesInput,
) -> Result<ListPipelinesOutput, RusotoError<ListPipelinesError>>;
async fn list_tags_for_resource(
&self,
input: ListTagsForResourceInput,
) -> Result<ListTagsForResourceOutput, RusotoError<ListTagsForResourceError>>;
async fn list_webhooks(
&self,
input: ListWebhooksInput,
) -> Result<ListWebhooksOutput, RusotoError<ListWebhooksError>>;
async fn poll_for_jobs(
&self,
input: PollForJobsInput,
) -> Result<PollForJobsOutput, RusotoError<PollForJobsError>>;
async fn poll_for_third_party_jobs(
&self,
input: PollForThirdPartyJobsInput,
) -> Result<PollForThirdPartyJobsOutput, RusotoError<PollForThirdPartyJobsError>>;
async fn put_action_revision(
&self,
input: PutActionRevisionInput,
) -> Result<PutActionRevisionOutput, RusotoError<PutActionRevisionError>>;
async fn put_approval_result(
&self,
input: PutApprovalResultInput,
) -> Result<PutApprovalResultOutput, RusotoError<PutApprovalResultError>>;
async fn put_job_failure_result(
&self,
input: PutJobFailureResultInput,
) -> Result<(), RusotoError<PutJobFailureResultError>>;
async fn put_job_success_result(
&self,
input: PutJobSuccessResultInput,
) -> Result<(), RusotoError<PutJobSuccessResultError>>;
async fn put_third_party_job_failure_result(
&self,
input: PutThirdPartyJobFailureResultInput,
) -> Result<(), RusotoError<PutThirdPartyJobFailureResultError>>;
async fn put_third_party_job_success_result(
&self,
input: PutThirdPartyJobSuccessResultInput,
) -> Result<(), RusotoError<PutThirdPartyJobSuccessResultError>>;
async fn put_webhook(
&self,
input: PutWebhookInput,
) -> Result<PutWebhookOutput, RusotoError<PutWebhookError>>;
async fn register_webhook_with_third_party(
&self,
input: RegisterWebhookWithThirdPartyInput,
) -> Result<RegisterWebhookWithThirdPartyOutput, RusotoError<RegisterWebhookWithThirdPartyError>>;
async fn retry_stage_execution(
&self,
input: RetryStageExecutionInput,
) -> Result<RetryStageExecutionOutput, RusotoError<RetryStageExecutionError>>;
async fn start_pipeline_execution(
&self,
input: StartPipelineExecutionInput,
) -> Result<StartPipelineExecutionOutput, RusotoError<StartPipelineExecutionError>>;
async fn stop_pipeline_execution(
&self,
input: StopPipelineExecutionInput,
) -> Result<StopPipelineExecutionOutput, RusotoError<StopPipelineExecutionError>>;
async fn tag_resource(
&self,
input: TagResourceInput,
) -> Result<TagResourceOutput, RusotoError<TagResourceError>>;
async fn untag_resource(
&self,
input: UntagResourceInput,
) -> Result<UntagResourceOutput, RusotoError<UntagResourceError>>;
async fn update_pipeline(
&self,
input: UpdatePipelineInput,
) -> Result<UpdatePipelineOutput, RusotoError<UpdatePipelineError>>;
}
#[derive(Clone)]
pub struct CodePipelineClient {
client: Client,
region: region::Region,
}
impl CodePipelineClient {
pub fn new(region: region::Region) -> CodePipelineClient {
CodePipelineClient {
client: Client::shared(),
region,
}
}
pub fn new_with<P, D>(
request_dispatcher: D,
credentials_provider: P,
region: region::Region,
) -> CodePipelineClient
where
P: ProvideAwsCredentials + Send + Sync + 'static,
D: DispatchSignedRequest + Send + Sync + 'static,
{
CodePipelineClient {
client: Client::new_with(credentials_provider, request_dispatcher),
region,
}
}
pub fn new_with_client(client: Client, region: region::Region) -> CodePipelineClient {
CodePipelineClient { client, region }
}
}
#[async_trait]
impl CodePipeline for CodePipelineClient {
async fn acknowledge_job(
&self,
input: AcknowledgeJobInput,
) -> Result<AcknowledgeJobOutput, RusotoError<AcknowledgeJobError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.AcknowledgeJob");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, AcknowledgeJobError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<AcknowledgeJobOutput, _>()
}
async fn acknowledge_third_party_job(
&self,
input: AcknowledgeThirdPartyJobInput,
) -> Result<AcknowledgeThirdPartyJobOutput, RusotoError<AcknowledgeThirdPartyJobError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.AcknowledgeThirdPartyJob",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, AcknowledgeThirdPartyJobError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<AcknowledgeThirdPartyJobOutput, _>()
}
async fn create_custom_action_type(
&self,
input: CreateCustomActionTypeInput,
) -> Result<CreateCustomActionTypeOutput, RusotoError<CreateCustomActionTypeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.CreateCustomActionType",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CreateCustomActionTypeError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<CreateCustomActionTypeOutput, _>()
}
async fn create_pipeline(
&self,
input: CreatePipelineInput,
) -> Result<CreatePipelineOutput, RusotoError<CreatePipelineError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.CreatePipeline");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, CreatePipelineError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<CreatePipelineOutput, _>()
}
async fn delete_custom_action_type(
&self,
input: DeleteCustomActionTypeInput,
) -> Result<(), RusotoError<DeleteCustomActionTypeError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.DeleteCustomActionType",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DeleteCustomActionTypeError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn delete_pipeline(
&self,
input: DeletePipelineInput,
) -> Result<(), RusotoError<DeletePipelineError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.DeletePipeline");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DeletePipelineError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn delete_webhook(
&self,
input: DeleteWebhookInput,
) -> Result<DeleteWebhookOutput, RusotoError<DeleteWebhookError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.DeleteWebhook");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DeleteWebhookError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<DeleteWebhookOutput, _>()
}
async fn deregister_webhook_with_third_party(
&self,
input: DeregisterWebhookWithThirdPartyInput,
) -> Result<
DeregisterWebhookWithThirdPartyOutput,
RusotoError<DeregisterWebhookWithThirdPartyError>,
> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.DeregisterWebhookWithThirdParty",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DeregisterWebhookWithThirdPartyError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<DeregisterWebhookWithThirdPartyOutput, _>()
}
async fn disable_stage_transition(
&self,
input: DisableStageTransitionInput,
) -> Result<(), RusotoError<DisableStageTransitionError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.DisableStageTransition",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, DisableStageTransitionError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn enable_stage_transition(
&self,
input: EnableStageTransitionInput,
) -> Result<(), RusotoError<EnableStageTransitionError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.EnableStageTransition",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, EnableStageTransitionError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn get_job_details(
&self,
input: GetJobDetailsInput,
) -> Result<GetJobDetailsOutput, RusotoError<GetJobDetailsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.GetJobDetails");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, GetJobDetailsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<GetJobDetailsOutput, _>()
}
async fn get_pipeline(
&self,
input: GetPipelineInput,
) -> Result<GetPipelineOutput, RusotoError<GetPipelineError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.GetPipeline");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, GetPipelineError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<GetPipelineOutput, _>()
}
async fn get_pipeline_execution(
&self,
input: GetPipelineExecutionInput,
) -> Result<GetPipelineExecutionOutput, RusotoError<GetPipelineExecutionError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.GetPipelineExecution");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, GetPipelineExecutionError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<GetPipelineExecutionOutput, _>()
}
async fn get_pipeline_state(
&self,
input: GetPipelineStateInput,
) -> Result<GetPipelineStateOutput, RusotoError<GetPipelineStateError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.GetPipelineState");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, GetPipelineStateError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<GetPipelineStateOutput, _>()
}
async fn get_third_party_job_details(
&self,
input: GetThirdPartyJobDetailsInput,
) -> Result<GetThirdPartyJobDetailsOutput, RusotoError<GetThirdPartyJobDetailsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.GetThirdPartyJobDetails",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, GetThirdPartyJobDetailsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<GetThirdPartyJobDetailsOutput, _>()
}
async fn list_action_executions(
&self,
input: ListActionExecutionsInput,
) -> Result<ListActionExecutionsOutput, RusotoError<ListActionExecutionsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.ListActionExecutions");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListActionExecutionsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListActionExecutionsOutput, _>()
}
async fn list_action_types(
&self,
input: ListActionTypesInput,
) -> Result<ListActionTypesOutput, RusotoError<ListActionTypesError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.ListActionTypes");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListActionTypesError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListActionTypesOutput, _>()
}
async fn list_pipeline_executions(
&self,
input: ListPipelineExecutionsInput,
) -> Result<ListPipelineExecutionsOutput, RusotoError<ListPipelineExecutionsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.ListPipelineExecutions",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListPipelineExecutionsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<ListPipelineExecutionsOutput, _>()
}
async fn list_pipelines(
&self,
input: ListPipelinesInput,
) -> Result<ListPipelinesOutput, RusotoError<ListPipelinesError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.ListPipelines");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListPipelinesError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListPipelinesOutput, _>()
}
async fn list_tags_for_resource(
&self,
input: ListTagsForResourceInput,
) -> Result<ListTagsForResourceOutput, RusotoError<ListTagsForResourceError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.ListTagsForResource");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListTagsForResourceError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListTagsForResourceOutput, _>()
}
async fn list_webhooks(
&self,
input: ListWebhooksInput,
) -> Result<ListWebhooksOutput, RusotoError<ListWebhooksError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.ListWebhooks");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, ListWebhooksError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<ListWebhooksOutput, _>()
}
async fn poll_for_jobs(
&self,
input: PollForJobsInput,
) -> Result<PollForJobsOutput, RusotoError<PollForJobsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.PollForJobs");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PollForJobsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<PollForJobsOutput, _>()
}
async fn poll_for_third_party_jobs(
&self,
input: PollForThirdPartyJobsInput,
) -> Result<PollForThirdPartyJobsOutput, RusotoError<PollForThirdPartyJobsError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.PollForThirdPartyJobs",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PollForThirdPartyJobsError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<PollForThirdPartyJobsOutput, _>()
}
async fn put_action_revision(
&self,
input: PutActionRevisionInput,
) -> Result<PutActionRevisionOutput, RusotoError<PutActionRevisionError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.PutActionRevision");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PutActionRevisionError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<PutActionRevisionOutput, _>()
}
async fn put_approval_result(
&self,
input: PutApprovalResultInput,
) -> Result<PutApprovalResultOutput, RusotoError<PutApprovalResultError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.PutApprovalResult");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PutApprovalResultError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<PutApprovalResultOutput, _>()
}
async fn put_job_failure_result(
&self,
input: PutJobFailureResultInput,
) -> Result<(), RusotoError<PutJobFailureResultError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.PutJobFailureResult");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PutJobFailureResultError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn put_job_success_result(
&self,
input: PutJobSuccessResultInput,
) -> Result<(), RusotoError<PutJobSuccessResultError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.PutJobSuccessResult");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PutJobSuccessResultError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn put_third_party_job_failure_result(
&self,
input: PutThirdPartyJobFailureResultInput,
) -> Result<(), RusotoError<PutThirdPartyJobFailureResultError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.PutThirdPartyJobFailureResult",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PutThirdPartyJobFailureResultError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn put_third_party_job_success_result(
&self,
input: PutThirdPartyJobSuccessResultInput,
) -> Result<(), RusotoError<PutThirdPartyJobSuccessResultError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.PutThirdPartyJobSuccessResult",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PutThirdPartyJobSuccessResultError::from_response)
.await?;
std::mem::drop(response);
Ok(())
}
async fn put_webhook(
&self,
input: PutWebhookInput,
) -> Result<PutWebhookOutput, RusotoError<PutWebhookError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.PutWebhook");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, PutWebhookError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<PutWebhookOutput, _>()
}
async fn register_webhook_with_third_party(
&self,
input: RegisterWebhookWithThirdPartyInput,
) -> Result<RegisterWebhookWithThirdPartyOutput, RusotoError<RegisterWebhookWithThirdPartyError>>
{
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.RegisterWebhookWithThirdParty",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, RegisterWebhookWithThirdPartyError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<RegisterWebhookWithThirdPartyOutput, _>()
}
async fn retry_stage_execution(
&self,
input: RetryStageExecutionInput,
) -> Result<RetryStageExecutionOutput, RusotoError<RetryStageExecutionError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.RetryStageExecution");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, RetryStageExecutionError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<RetryStageExecutionOutput, _>()
}
async fn start_pipeline_execution(
&self,
input: StartPipelineExecutionInput,
) -> Result<StartPipelineExecutionOutput, RusotoError<StartPipelineExecutionError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.StartPipelineExecution",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, StartPipelineExecutionError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response)
.deserialize::<StartPipelineExecutionOutput, _>()
}
async fn stop_pipeline_execution(
&self,
input: StopPipelineExecutionInput,
) -> Result<StopPipelineExecutionOutput, RusotoError<StopPipelineExecutionError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header(
"x-amz-target",
"CodePipeline_20150709.StopPipelineExecution",
);
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, StopPipelineExecutionError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<StopPipelineExecutionOutput, _>()
}
async fn tag_resource(
&self,
input: TagResourceInput,
) -> Result<TagResourceOutput, RusotoError<TagResourceError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.TagResource");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, TagResourceError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<TagResourceOutput, _>()
}
async fn untag_resource(
&self,
input: UntagResourceInput,
) -> Result<UntagResourceOutput, RusotoError<UntagResourceError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.UntagResource");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, UntagResourceError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<UntagResourceOutput, _>()
}
async fn update_pipeline(
&self,
input: UpdatePipelineInput,
) -> Result<UpdatePipelineOutput, RusotoError<UpdatePipelineError>> {
let mut request = self.new_signed_request("POST", "/");
request.add_header("x-amz-target", "CodePipeline_20150709.UpdatePipeline");
let encoded = serde_json::to_string(&input).unwrap();
request.set_payload(Some(encoded));
let response = self
.sign_and_dispatch(request, UpdatePipelineError::from_response)
.await?;
let mut response = response;
let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
proto::json::ResponsePayload::new(&response).deserialize::<UpdatePipelineOutput, _>()
}
}