# coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import builtins
import copy
import warnings
import sys
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
if sys.version_info >= (3, 11):
    from typing import NotRequired, TypedDict, TypeAlias
else:
    from typing_extensions import NotRequired, TypedDict, TypeAlias
from .. import _utilities
from . import outputs
from ._inputs import *

__all__ = ['ProjectArgs', 'Project']

@pulumi.input_type
class ProjectArgs:
    def __init__(__self__, *,
                 project_name: pulumi.Input[builtins.str],
                 description: Optional[pulumi.Input[builtins.str]] = None,
                 iam_project_name: Optional[pulumi.Input[builtins.str]] = None,
                 tags: Optional[pulumi.Input[Sequence[pulumi.Input['ProjectTagArgs']]]] = None):
        """
        The set of arguments for constructing a Project resource.
        :param pulumi.Input[builtins.str] project_name: 日志项目名称。
        :param pulumi.Input[builtins.str] description: 日志项目的简单描述。
        :param pulumi.Input[builtins.str] iam_project_name: 日志项目所属的 IAM 项目。
        """
        pulumi.set(__self__, "project_name", project_name)
        if description is not None:
            pulumi.set(__self__, "description", description)
        if iam_project_name is not None:
            pulumi.set(__self__, "iam_project_name", iam_project_name)
        if tags is not None:
            pulumi.set(__self__, "tags", tags)

    @property
    @pulumi.getter(name="projectName")
    def project_name(self) -> pulumi.Input[builtins.str]:
        """
        日志项目名称。
        """
        return pulumi.get(self, "project_name")

    @project_name.setter
    def project_name(self, value: pulumi.Input[builtins.str]):
        pulumi.set(self, "project_name", value)

    @property
    @pulumi.getter
    def description(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        日志项目的简单描述。
        """
        return pulumi.get(self, "description")

    @description.setter
    def description(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "description", value)

    @property
    @pulumi.getter(name="iamProjectName")
    def iam_project_name(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        日志项目所属的 IAM 项目。
        """
        return pulumi.get(self, "iam_project_name")

    @iam_project_name.setter
    def iam_project_name(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "iam_project_name", value)

    @property
    @pulumi.getter
    def tags(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['ProjectTagArgs']]]]:
        return pulumi.get(self, "tags")

    @tags.setter
    def tags(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['ProjectTagArgs']]]]):
        pulumi.set(self, "tags", value)


@pulumi.input_type
class _ProjectState:
    def __init__(__self__, *,
                 created_time: Optional[pulumi.Input[builtins.str]] = None,
                 description: Optional[pulumi.Input[builtins.str]] = None,
                 iam_project_name: Optional[pulumi.Input[builtins.str]] = None,
                 inner_net_domain: Optional[pulumi.Input[builtins.str]] = None,
                 project_id: Optional[pulumi.Input[builtins.str]] = None,
                 project_name: Optional[pulumi.Input[builtins.str]] = None,
                 tags: Optional[pulumi.Input[Sequence[pulumi.Input['ProjectTagArgs']]]] = None,
                 topic_count: Optional[pulumi.Input[builtins.int]] = None):
        """
        Input properties used for looking up and filtering Project resources.
        :param pulumi.Input[builtins.str] created_time: 日志项目创建时间。
        :param pulumi.Input[builtins.str] description: 日志项目的简单描述。
        :param pulumi.Input[builtins.str] iam_project_name: 日志项目所属的 IAM 项目。
        :param pulumi.Input[builtins.str] inner_net_domain: 私网连接域名。
        :param pulumi.Input[builtins.str] project_id: 日志项目的 ID。
        :param pulumi.Input[builtins.str] project_name: 日志项目名称。
        :param pulumi.Input[builtins.int] topic_count: 当前日志项目下的日志主题数量。
        """
        if created_time is not None:
            pulumi.set(__self__, "created_time", created_time)
        if description is not None:
            pulumi.set(__self__, "description", description)
        if iam_project_name is not None:
            pulumi.set(__self__, "iam_project_name", iam_project_name)
        if inner_net_domain is not None:
            pulumi.set(__self__, "inner_net_domain", inner_net_domain)
        if project_id is not None:
            pulumi.set(__self__, "project_id", project_id)
        if project_name is not None:
            pulumi.set(__self__, "project_name", project_name)
        if tags is not None:
            pulumi.set(__self__, "tags", tags)
        if topic_count is not None:
            pulumi.set(__self__, "topic_count", topic_count)

    @property
    @pulumi.getter(name="createdTime")
    def created_time(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        日志项目创建时间。
        """
        return pulumi.get(self, "created_time")

    @created_time.setter
    def created_time(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "created_time", value)

    @property
    @pulumi.getter
    def description(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        日志项目的简单描述。
        """
        return pulumi.get(self, "description")

    @description.setter
    def description(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "description", value)

    @property
    @pulumi.getter(name="iamProjectName")
    def iam_project_name(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        日志项目所属的 IAM 项目。
        """
        return pulumi.get(self, "iam_project_name")

    @iam_project_name.setter
    def iam_project_name(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "iam_project_name", value)

    @property
    @pulumi.getter(name="innerNetDomain")
    def inner_net_domain(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        私网连接域名。
        """
        return pulumi.get(self, "inner_net_domain")

    @inner_net_domain.setter
    def inner_net_domain(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "inner_net_domain", value)

    @property
    @pulumi.getter(name="projectId")
    def project_id(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        日志项目的 ID。
        """
        return pulumi.get(self, "project_id")

    @project_id.setter
    def project_id(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "project_id", value)

    @property
    @pulumi.getter(name="projectName")
    def project_name(self) -> Optional[pulumi.Input[builtins.str]]:
        """
        日志项目名称。
        """
        return pulumi.get(self, "project_name")

    @project_name.setter
    def project_name(self, value: Optional[pulumi.Input[builtins.str]]):
        pulumi.set(self, "project_name", value)

    @property
    @pulumi.getter
    def tags(self) -> Optional[pulumi.Input[Sequence[pulumi.Input['ProjectTagArgs']]]]:
        return pulumi.get(self, "tags")

    @tags.setter
    def tags(self, value: Optional[pulumi.Input[Sequence[pulumi.Input['ProjectTagArgs']]]]):
        pulumi.set(self, "tags", value)

    @property
    @pulumi.getter(name="topicCount")
    def topic_count(self) -> Optional[pulumi.Input[builtins.int]]:
        """
        当前日志项目下的日志主题数量。
        """
        return pulumi.get(self, "topic_count")

    @topic_count.setter
    def topic_count(self, value: Optional[pulumi.Input[builtins.int]]):
        pulumi.set(self, "topic_count", value)


@pulumi.type_token("bytepluscc:tls/project:Project")
class Project(pulumi.CustomResource):
    @overload
    def __init__(__self__,
                 resource_name: str,
                 opts: Optional[pulumi.ResourceOptions] = None,
                 description: Optional[pulumi.Input[builtins.str]] = None,
                 iam_project_name: Optional[pulumi.Input[builtins.str]] = None,
                 project_name: Optional[pulumi.Input[builtins.str]] = None,
                 tags: Optional[pulumi.Input[Sequence[pulumi.Input[Union['ProjectTagArgs', 'ProjectTagArgsDict']]]]] = None,
                 __props__=None):
        """
        日志项目是数据的项目管理单元，用于租户资源隔离和控制，通常一个日志项目对应一个应用、业务或产品。

        ## Example Usage

        ```python
        import pulumi
        import pulumi_bytepluscc as bytepluscc

        t_ls_project_demo = bytepluscc.tls.Project("TLSProjectDemo",
            project_name="ccapi_test",
            description="ccapi_test",
            iam_project_name="default",
            tags=[{
                "key": "env",
                "value": "test",
            }])
        ```

        ## Import

        ```sh
        $ pulumi import bytepluscc:tls/project:Project example "project_id"
        ```

        :param str resource_name: The name of the resource.
        :param pulumi.ResourceOptions opts: Options for the resource.
        :param pulumi.Input[builtins.str] description: 日志项目的简单描述。
        :param pulumi.Input[builtins.str] iam_project_name: 日志项目所属的 IAM 项目。
        :param pulumi.Input[builtins.str] project_name: 日志项目名称。
        """
        ...
    @overload
    def __init__(__self__,
                 resource_name: str,
                 args: ProjectArgs,
                 opts: Optional[pulumi.ResourceOptions] = None):
        """
        日志项目是数据的项目管理单元，用于租户资源隔离和控制，通常一个日志项目对应一个应用、业务或产品。

        ## Example Usage

        ```python
        import pulumi
        import pulumi_bytepluscc as bytepluscc

        t_ls_project_demo = bytepluscc.tls.Project("TLSProjectDemo",
            project_name="ccapi_test",
            description="ccapi_test",
            iam_project_name="default",
            tags=[{
                "key": "env",
                "value": "test",
            }])
        ```

        ## Import

        ```sh
        $ pulumi import bytepluscc:tls/project:Project example "project_id"
        ```

        :param str resource_name: The name of the resource.
        :param ProjectArgs args: The arguments to use to populate this resource's properties.
        :param pulumi.ResourceOptions opts: Options for the resource.
        """
        ...
    def __init__(__self__, resource_name: str, *args, **kwargs):
        resource_args, opts = _utilities.get_resource_args_opts(ProjectArgs, pulumi.ResourceOptions, *args, **kwargs)
        if resource_args is not None:
            __self__._internal_init(resource_name, opts, **resource_args.__dict__)
        else:
            __self__._internal_init(resource_name, *args, **kwargs)

    def _internal_init(__self__,
                 resource_name: str,
                 opts: Optional[pulumi.ResourceOptions] = None,
                 description: Optional[pulumi.Input[builtins.str]] = None,
                 iam_project_name: Optional[pulumi.Input[builtins.str]] = None,
                 project_name: Optional[pulumi.Input[builtins.str]] = None,
                 tags: Optional[pulumi.Input[Sequence[pulumi.Input[Union['ProjectTagArgs', 'ProjectTagArgsDict']]]]] = None,
                 __props__=None):
        opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
        if not isinstance(opts, pulumi.ResourceOptions):
            raise TypeError('Expected resource options to be a ResourceOptions instance')
        if opts.id is None:
            if __props__ is not None:
                raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
            __props__ = ProjectArgs.__new__(ProjectArgs)

            __props__.__dict__["description"] = description
            __props__.__dict__["iam_project_name"] = iam_project_name
            if project_name is None and not opts.urn:
                raise TypeError("Missing required property 'project_name'")
            __props__.__dict__["project_name"] = project_name
            __props__.__dict__["tags"] = tags
            __props__.__dict__["created_time"] = None
            __props__.__dict__["inner_net_domain"] = None
            __props__.__dict__["project_id"] = None
            __props__.__dict__["topic_count"] = None
        super(Project, __self__).__init__(
            'bytepluscc:tls/project:Project',
            resource_name,
            __props__,
            opts)

    @staticmethod
    def get(resource_name: str,
            id: pulumi.Input[str],
            opts: Optional[pulumi.ResourceOptions] = None,
            created_time: Optional[pulumi.Input[builtins.str]] = None,
            description: Optional[pulumi.Input[builtins.str]] = None,
            iam_project_name: Optional[pulumi.Input[builtins.str]] = None,
            inner_net_domain: Optional[pulumi.Input[builtins.str]] = None,
            project_id: Optional[pulumi.Input[builtins.str]] = None,
            project_name: Optional[pulumi.Input[builtins.str]] = None,
            tags: Optional[pulumi.Input[Sequence[pulumi.Input[Union['ProjectTagArgs', 'ProjectTagArgsDict']]]]] = None,
            topic_count: Optional[pulumi.Input[builtins.int]] = None) -> 'Project':
        """
        Get an existing Project resource's state with the given name, id, and optional extra
        properties used to qualify the lookup.

        :param str resource_name: The unique name of the resulting resource.
        :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
        :param pulumi.ResourceOptions opts: Options for the resource.
        :param pulumi.Input[builtins.str] created_time: 日志项目创建时间。
        :param pulumi.Input[builtins.str] description: 日志项目的简单描述。
        :param pulumi.Input[builtins.str] iam_project_name: 日志项目所属的 IAM 项目。
        :param pulumi.Input[builtins.str] inner_net_domain: 私网连接域名。
        :param pulumi.Input[builtins.str] project_id: 日志项目的 ID。
        :param pulumi.Input[builtins.str] project_name: 日志项目名称。
        :param pulumi.Input[builtins.int] topic_count: 当前日志项目下的日志主题数量。
        """
        opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))

        __props__ = _ProjectState.__new__(_ProjectState)

        __props__.__dict__["created_time"] = created_time
        __props__.__dict__["description"] = description
        __props__.__dict__["iam_project_name"] = iam_project_name
        __props__.__dict__["inner_net_domain"] = inner_net_domain
        __props__.__dict__["project_id"] = project_id
        __props__.__dict__["project_name"] = project_name
        __props__.__dict__["tags"] = tags
        __props__.__dict__["topic_count"] = topic_count
        return Project(resource_name, opts=opts, __props__=__props__)

    @property
    @pulumi.getter(name="createdTime")
    def created_time(self) -> pulumi.Output[builtins.str]:
        """
        日志项目创建时间。
        """
        return pulumi.get(self, "created_time")

    @property
    @pulumi.getter
    def description(self) -> pulumi.Output[builtins.str]:
        """
        日志项目的简单描述。
        """
        return pulumi.get(self, "description")

    @property
    @pulumi.getter(name="iamProjectName")
    def iam_project_name(self) -> pulumi.Output[builtins.str]:
        """
        日志项目所属的 IAM 项目。
        """
        return pulumi.get(self, "iam_project_name")

    @property
    @pulumi.getter(name="innerNetDomain")
    def inner_net_domain(self) -> pulumi.Output[builtins.str]:
        """
        私网连接域名。
        """
        return pulumi.get(self, "inner_net_domain")

    @property
    @pulumi.getter(name="projectId")
    def project_id(self) -> pulumi.Output[builtins.str]:
        """
        日志项目的 ID。
        """
        return pulumi.get(self, "project_id")

    @property
    @pulumi.getter(name="projectName")
    def project_name(self) -> pulumi.Output[builtins.str]:
        """
        日志项目名称。
        """
        return pulumi.get(self, "project_name")

    @property
    @pulumi.getter
    def tags(self) -> pulumi.Output[Sequence['outputs.ProjectTag']]:
        return pulumi.get(self, "tags")

    @property
    @pulumi.getter(name="topicCount")
    def topic_count(self) -> pulumi.Output[builtins.int]:
        """
        当前日志项目下的日志主题数量。
        """
        return pulumi.get(self, "topic_count")

