# Copyright (c) 2012-2025, Mark Peek <mark@peek.org>
# All rights reserved.
#
# See LICENSE file for full license.
#
# *** Do not modify - this file is autogenerated ***


from . import AWSObject, AWSProperty, PropsDictType
from .validators import boolean


class AgentSpace(AWSObject):
    """
    `AgentSpace <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-devopsagent-agentspace.html>`__
    """

    resource_type = "AWS::DevOpsAgent::AgentSpace"

    props: PropsDictType = {
        "Description": (str, False),
        "Name": (str, True),
    }


class AWSResource(AWSProperty):
    """
    `AWSResource <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-awsresource.html>`__
    """

    props: PropsDictType = {
        "ResourceArn": (str, True),
        "ResourceMetadata": (dict, False),
        "ResourceType": (str, False),
    }


class KeyValuePair(AWSProperty):
    """
    `KeyValuePair <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-keyvaluepair.html>`__
    """

    props: PropsDictType = {
        "Key": (str, True),
        "Value": (str, True),
    }


class AWSConfiguration(AWSProperty):
    """
    `AWSConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-awsconfiguration.html>`__
    """

    props: PropsDictType = {
        "AccountId": (str, True),
        "AccountType": (str, True),
        "AssumableRoleArn": (str, True),
        "Resources": ([AWSResource], False),
        "Tags": ([KeyValuePair], False),
    }


class DynatraceConfiguration(AWSProperty):
    """
    `DynatraceConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-dynatraceconfiguration.html>`__
    """

    props: PropsDictType = {
        "EnableWebhookUpdates": (boolean, False),
        "EnvId": (str, True),
        "Resources": ([str], False),
    }


class EventChannelConfiguration(AWSProperty):
    """
    `EventChannelConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-eventchannelconfiguration.html>`__
    """

    props: PropsDictType = {
        "EnableWebhookUpdates": (boolean, False),
    }


class GitHubConfiguration(AWSProperty):
    """
    `GitHubConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-githubconfiguration.html>`__
    """

    props: PropsDictType = {
        "Owner": (str, True),
        "OwnerType": (str, True),
        "RepoId": (str, True),
        "RepoName": (str, True),
    }


class GitLabConfiguration(AWSProperty):
    """
    `GitLabConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-gitlabconfiguration.html>`__
    """

    props: PropsDictType = {
        "EnableWebhookUpdates": (boolean, False),
        "InstanceIdentifier": (str, False),
        "ProjectId": (str, True),
        "ProjectPath": (str, True),
    }


class MCPServerConfiguration(AWSProperty):
    """
    `MCPServerConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-mcpserverconfiguration.html>`__
    """

    props: PropsDictType = {
        "Description": (str, False),
        "EnableWebhookUpdates": (boolean, False),
        "Endpoint": (str, True),
        "Name": (str, True),
        "Tools": ([str], True),
    }


class MCPServerDatadogConfiguration(AWSProperty):
    """
    `MCPServerDatadogConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-mcpserverdatadogconfiguration.html>`__
    """

    props: PropsDictType = {
        "Description": (str, False),
        "EnableWebhookUpdates": (boolean, False),
        "Endpoint": (str, True),
        "Name": (str, True),
    }


class MCPServerNewRelicConfiguration(AWSProperty):
    """
    `MCPServerNewRelicConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-mcpservernewrelicconfiguration.html>`__
    """

    props: PropsDictType = {
        "AccountId": (str, True),
        "Endpoint": (str, True),
    }


class MCPServerSplunkConfiguration(AWSProperty):
    """
    `MCPServerSplunkConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-mcpserversplunkconfiguration.html>`__
    """

    props: PropsDictType = {
        "Description": (str, False),
        "EnableWebhookUpdates": (boolean, False),
        "Endpoint": (str, True),
        "Name": (str, True),
    }


class ServiceNowConfiguration(AWSProperty):
    """
    `ServiceNowConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-servicenowconfiguration.html>`__
    """

    props: PropsDictType = {
        "EnableWebhookUpdates": (boolean, False),
        "InstanceId": (str, False),
    }


class SlackChannel(AWSProperty):
    """
    `SlackChannel <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-slackchannel.html>`__
    """

    props: PropsDictType = {
        "ChannelId": (str, True),
        "ChannelName": (str, False),
    }


class SlackTransmissionTarget(AWSProperty):
    """
    `SlackTransmissionTarget <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-slacktransmissiontarget.html>`__
    """

    props: PropsDictType = {
        "IncidentResponseTarget": (SlackChannel, True),
    }


class SlackConfiguration(AWSProperty):
    """
    `SlackConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-slackconfiguration.html>`__
    """

    props: PropsDictType = {
        "TransmissionTarget": (SlackTransmissionTarget, True),
        "WorkspaceId": (str, True),
        "WorkspaceName": (str, True),
    }


class SourceAwsConfiguration(AWSProperty):
    """
    `SourceAwsConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-sourceawsconfiguration.html>`__
    """

    props: PropsDictType = {
        "AccountId": (str, True),
        "AccountType": (str, True),
        "AssumableRoleArn": (str, True),
        "Resources": ([AWSResource], False),
        "Tags": ([KeyValuePair], False),
    }


class ServiceConfiguration(AWSProperty):
    """
    `ServiceConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-devopsagent-association-serviceconfiguration.html>`__
    """

    props: PropsDictType = {
        "Aws": (AWSConfiguration, False),
        "Dynatrace": (DynatraceConfiguration, False),
        "EventChannel": (EventChannelConfiguration, False),
        "GitHub": (GitHubConfiguration, False),
        "GitLab": (GitLabConfiguration, False),
        "MCPServer": (MCPServerConfiguration, False),
        "MCPServerDatadog": (MCPServerDatadogConfiguration, False),
        "MCPServerNewRelic": (MCPServerNewRelicConfiguration, False),
        "MCPServerSplunk": (MCPServerSplunkConfiguration, False),
        "ServiceNow": (ServiceNowConfiguration, False),
        "Slack": (SlackConfiguration, False),
        "SourceAws": (SourceAwsConfiguration, False),
    }


class Association(AWSObject):
    """
    `Association <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-devopsagent-association.html>`__
    """

    resource_type = "AWS::DevOpsAgent::Association"

    props: PropsDictType = {
        "AgentSpaceId": (str, True),
        "Configuration": (ServiceConfiguration, True),
        "LinkedAssociationIds": ([str], False),
        "ServiceId": (str, True),
    }
