import { SENSITIVE_STRING } from "@smithy/smithy-client";
import { CodePipelineServiceException as __BaseException } from "./CodePipelineServiceException";
export const JobStatus = {
    Created: "Created",
    Dispatched: "Dispatched",
    Failed: "Failed",
    InProgress: "InProgress",
    Queued: "Queued",
    Succeeded: "Succeeded",
    TimedOut: "TimedOut",
};
export class InvalidNonceException extends __BaseException {
    name = "InvalidNonceException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidNonceException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidNonceException.prototype);
    }
}
export class JobNotFoundException extends __BaseException {
    name = "JobNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "JobNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, JobNotFoundException.prototype);
    }
}
export class ValidationException extends __BaseException {
    name = "ValidationException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ValidationException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ValidationException.prototype);
    }
}
export class InvalidClientTokenException extends __BaseException {
    name = "InvalidClientTokenException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidClientTokenException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidClientTokenException.prototype);
    }
}
export const ActionCategory = {
    Approval: "Approval",
    Build: "Build",
    Compute: "Compute",
    Deploy: "Deploy",
    Invoke: "Invoke",
    Source: "Source",
    Test: "Test",
};
export const ActionConfigurationPropertyType = {
    Boolean: "Boolean",
    Number: "Number",
    String: "String",
};
export const ActionOwner = {
    AWS: "AWS",
    Custom: "Custom",
    ThirdParty: "ThirdParty",
};
export const ActionExecutionStatus = {
    Abandoned: "Abandoned",
    Failed: "Failed",
    InProgress: "InProgress",
    Succeeded: "Succeeded",
};
export const StartTimeRange = {
    All: "All",
    Latest: "Latest",
};
export class ActionNotFoundException extends __BaseException {
    name = "ActionNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ActionNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ActionNotFoundException.prototype);
    }
}
export const ExecutorType = {
    JobWorker: "JobWorker",
    Lambda: "Lambda",
};
export class ActionTypeNotFoundException extends __BaseException {
    name = "ActionTypeNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ActionTypeNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ActionTypeNotFoundException.prototype);
    }
}
export class ApprovalAlreadyCompletedException extends __BaseException {
    name = "ApprovalAlreadyCompletedException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ApprovalAlreadyCompletedException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ApprovalAlreadyCompletedException.prototype);
    }
}
export const ApprovalStatus = {
    Approved: "Approved",
    Rejected: "Rejected",
};
export const ArtifactLocationType = {
    S3: "S3",
};
export const EncryptionKeyType = {
    KMS: "KMS",
};
export const ArtifactStoreType = {
    S3: "S3",
};
export const Result = {
    FAIL: "FAIL",
    RETRY: "RETRY",
    ROLLBACK: "ROLLBACK",
    SKIP: "SKIP",
};
export const RuleCategory = {
    Rule: "Rule",
};
export const RuleOwner = {
    AWS: "AWS",
};
export const BlockerType = {
    Schedule: "Schedule",
};
export class ConcurrentModificationException extends __BaseException {
    name = "ConcurrentModificationException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ConcurrentModificationException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ConcurrentModificationException.prototype);
    }
}
export class InvalidTagsException extends __BaseException {
    name = "InvalidTagsException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidTagsException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidTagsException.prototype);
    }
}
export class LimitExceededException extends __BaseException {
    name = "LimitExceededException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "LimitExceededException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, LimitExceededException.prototype);
    }
}
export class TooManyTagsException extends __BaseException {
    name = "TooManyTagsException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "TooManyTagsException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, TooManyTagsException.prototype);
    }
}
export const ExecutionMode = {
    PARALLEL: "PARALLEL",
    QUEUED: "QUEUED",
    SUPERSEDED: "SUPERSEDED",
};
export const PipelineType = {
    V1: "V1",
    V2: "V2",
};
export const StageRetryMode = {
    ALL_ACTIONS: "ALL_ACTIONS",
    FAILED_ACTIONS: "FAILED_ACTIONS",
};
export const GitPullRequestEventType = {
    CLOSED: "CLOSED",
    OPEN: "OPEN",
    UPDATED: "UPDATED",
};
export const PipelineTriggerProviderType = {
    CodeStarSourceConnection: "CodeStarSourceConnection",
};
export class InvalidActionDeclarationException extends __BaseException {
    name = "InvalidActionDeclarationException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidActionDeclarationException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidActionDeclarationException.prototype);
    }
}
export class InvalidBlockerDeclarationException extends __BaseException {
    name = "InvalidBlockerDeclarationException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidBlockerDeclarationException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidBlockerDeclarationException.prototype);
    }
}
export class InvalidStageDeclarationException extends __BaseException {
    name = "InvalidStageDeclarationException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidStageDeclarationException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidStageDeclarationException.prototype);
    }
}
export class InvalidStructureException extends __BaseException {
    name = "InvalidStructureException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidStructureException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidStructureException.prototype);
    }
}
export class PipelineNameInUseException extends __BaseException {
    name = "PipelineNameInUseException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "PipelineNameInUseException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, PipelineNameInUseException.prototype);
    }
}
export class WebhookNotFoundException extends __BaseException {
    name = "WebhookNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "WebhookNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, WebhookNotFoundException.prototype);
    }
}
export const StageTransitionType = {
    Inbound: "Inbound",
    Outbound: "Outbound",
};
export class PipelineNotFoundException extends __BaseException {
    name = "PipelineNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "PipelineNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, PipelineNotFoundException.prototype);
    }
}
export class StageNotFoundException extends __BaseException {
    name = "StageNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "StageNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, StageNotFoundException.prototype);
    }
}
export class PipelineVersionNotFoundException extends __BaseException {
    name = "PipelineVersionNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "PipelineVersionNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, PipelineVersionNotFoundException.prototype);
    }
}
export const ExecutionType = {
    ROLLBACK: "ROLLBACK",
    STANDARD: "STANDARD",
};
export const PipelineExecutionStatus = {
    Cancelled: "Cancelled",
    Failed: "Failed",
    InProgress: "InProgress",
    Stopped: "Stopped",
    Stopping: "Stopping",
    Succeeded: "Succeeded",
    Superseded: "Superseded",
};
export const TriggerType = {
    AutomatedRollback: "AutomatedRollback",
    CloudWatchEvent: "CloudWatchEvent",
    CreatePipeline: "CreatePipeline",
    ManualRollback: "ManualRollback",
    PollForSourceChanges: "PollForSourceChanges",
    PutActionRevision: "PutActionRevision",
    StartPipelineExecution: "StartPipelineExecution",
    Webhook: "Webhook",
    WebhookV2: "WebhookV2",
};
export class PipelineExecutionNotFoundException extends __BaseException {
    name = "PipelineExecutionNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "PipelineExecutionNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, PipelineExecutionNotFoundException.prototype);
    }
}
export const ConditionExecutionStatus = {
    Abandoned: "Abandoned",
    Cancelled: "Cancelled",
    Errored: "Errored",
    Failed: "Failed",
    InProgress: "InProgress",
    Overridden: "Overridden",
    Succeeded: "Succeeded",
};
export const RuleExecutionStatus = {
    Abandoned: "Abandoned",
    Failed: "Failed",
    InProgress: "InProgress",
    Succeeded: "Succeeded",
};
export const StageExecutionStatus = {
    Cancelled: "Cancelled",
    Failed: "Failed",
    InProgress: "InProgress",
    Skipped: "Skipped",
    Stopped: "Stopped",
    Stopping: "Stopping",
    Succeeded: "Succeeded",
};
export const RetryTrigger = {
    AutomatedStageRetry: "AutomatedStageRetry",
    ManualStageRetry: "ManualStageRetry",
};
export class InvalidJobException extends __BaseException {
    name = "InvalidJobException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidJobException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidJobException.prototype);
    }
}
export class InvalidNextTokenException extends __BaseException {
    name = "InvalidNextTokenException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidNextTokenException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidNextTokenException.prototype);
    }
}
export const RuleConfigurationPropertyType = {
    Boolean: "Boolean",
    Number: "Number",
    String: "String",
};
export class InvalidArnException extends __BaseException {
    name = "InvalidArnException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidArnException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidArnException.prototype);
    }
}
export class ResourceNotFoundException extends __BaseException {
    name = "ResourceNotFoundException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ResourceNotFoundException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
    }
}
export const WebhookAuthenticationType = {
    GITHUB_HMAC: "GITHUB_HMAC",
    IP: "IP",
    UNAUTHENTICATED: "UNAUTHENTICATED",
};
export class ConcurrentPipelineExecutionsLimitExceededException extends __BaseException {
    name = "ConcurrentPipelineExecutionsLimitExceededException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ConcurrentPipelineExecutionsLimitExceededException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ConcurrentPipelineExecutionsLimitExceededException.prototype);
    }
}
export class ConditionNotOverridableException extends __BaseException {
    name = "ConditionNotOverridableException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ConditionNotOverridableException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ConditionNotOverridableException.prototype);
    }
}
export class ConflictException extends __BaseException {
    name = "ConflictException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "ConflictException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, ConflictException.prototype);
    }
}
export class NotLatestPipelineExecutionException extends __BaseException {
    name = "NotLatestPipelineExecutionException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "NotLatestPipelineExecutionException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, NotLatestPipelineExecutionException.prototype);
    }
}
export const ConditionType = {
    BEFORE_ENTRY: "BEFORE_ENTRY",
    ON_SUCCESS: "ON_SUCCESS",
};
export class InvalidApprovalTokenException extends __BaseException {
    name = "InvalidApprovalTokenException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidApprovalTokenException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidApprovalTokenException.prototype);
    }
}
export class InvalidJobStateException extends __BaseException {
    name = "InvalidJobStateException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidJobStateException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidJobStateException.prototype);
    }
}
export const FailureType = {
    ConfigurationError: "ConfigurationError",
    JobFailed: "JobFailed",
    PermissionError: "PermissionError",
    RevisionOutOfSync: "RevisionOutOfSync",
    RevisionUnavailable: "RevisionUnavailable",
    SystemUnavailable: "SystemUnavailable",
};
export class OutputVariablesSizeExceededException extends __BaseException {
    name = "OutputVariablesSizeExceededException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "OutputVariablesSizeExceededException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, OutputVariablesSizeExceededException.prototype);
    }
}
export class InvalidWebhookAuthenticationParametersException extends __BaseException {
    name = "InvalidWebhookAuthenticationParametersException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidWebhookAuthenticationParametersException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidWebhookAuthenticationParametersException.prototype);
    }
}
export class InvalidWebhookFilterPatternException extends __BaseException {
    name = "InvalidWebhookFilterPatternException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "InvalidWebhookFilterPatternException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, InvalidWebhookFilterPatternException.prototype);
    }
}
export class StageNotRetryableException extends __BaseException {
    name = "StageNotRetryableException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "StageNotRetryableException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, StageNotRetryableException.prototype);
    }
}
export class PipelineExecutionOutdatedException extends __BaseException {
    name = "PipelineExecutionOutdatedException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "PipelineExecutionOutdatedException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, PipelineExecutionOutdatedException.prototype);
    }
}
export class UnableToRollbackStageException extends __BaseException {
    name = "UnableToRollbackStageException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "UnableToRollbackStageException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, UnableToRollbackStageException.prototype);
    }
}
export const SourceRevisionType = {
    COMMIT_ID: "COMMIT_ID",
    IMAGE_DIGEST: "IMAGE_DIGEST",
    S3_OBJECT_KEY: "S3_OBJECT_KEY",
    S3_OBJECT_VERSION_ID: "S3_OBJECT_VERSION_ID",
};
export class DuplicatedStopRequestException extends __BaseException {
    name = "DuplicatedStopRequestException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "DuplicatedStopRequestException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, DuplicatedStopRequestException.prototype);
    }
}
export class PipelineExecutionNotStoppableException extends __BaseException {
    name = "PipelineExecutionNotStoppableException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "PipelineExecutionNotStoppableException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, PipelineExecutionNotStoppableException.prototype);
    }
}
export class RequestFailedException extends __BaseException {
    name = "RequestFailedException";
    $fault = "client";
    constructor(opts) {
        super({
            name: "RequestFailedException",
            $fault: "client",
            ...opts,
        });
        Object.setPrototypeOf(this, RequestFailedException.prototype);
    }
}
export const AWSSessionCredentialsFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.accessKeyId && { accessKeyId: SENSITIVE_STRING }),
    ...(obj.secretAccessKey && { secretAccessKey: SENSITIVE_STRING }),
    ...(obj.sessionToken && { sessionToken: SENSITIVE_STRING }),
});
export const JobDataFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.artifactCredentials && { artifactCredentials: SENSITIVE_STRING }),
});
export const JobDetailsFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.data && { data: JobDataFilterSensitiveLog(obj.data) }),
});
export const GetJobDetailsOutputFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.jobDetails && { jobDetails: JobDetailsFilterSensitiveLog(obj.jobDetails) }),
});
export const ThirdPartyJobDataFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.artifactCredentials && { artifactCredentials: SENSITIVE_STRING }),
});
export const ThirdPartyJobDetailsFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.data && { data: ThirdPartyJobDataFilterSensitiveLog(obj.data) }),
});
export const GetThirdPartyJobDetailsOutputFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.jobDetails && { jobDetails: ThirdPartyJobDetailsFilterSensitiveLog(obj.jobDetails) }),
});
export const JobFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.data && { data: JobDataFilterSensitiveLog(obj.data) }),
});
export const PollForJobsOutputFilterSensitiveLog = (obj) => ({
    ...obj,
    ...(obj.jobs && { jobs: obj.jobs.map((item) => JobFilterSensitiveLog(item)) }),
});
