# 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 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

__all__ = [
    'GetCloudOrganizationResult',
    'AwaitableGetCloudOrganizationResult',
    'get_cloud_organization',
    'get_cloud_organization_output',
]

warnings.warn("""grafana.index/getcloudorganization.getCloudOrganization has been deprecated in favor of grafana.cloud/getorganization.getOrganization""", DeprecationWarning)

@pulumi.output_type
class GetCloudOrganizationResult:
    """
    A collection of values returned by getCloudOrganization.
    """
    def __init__(__self__, created_at=None, id=None, name=None, slug=None, updated_at=None, url=None):
        if created_at and not isinstance(created_at, str):
            raise TypeError("Expected argument 'created_at' to be a str")
        pulumi.set(__self__, "created_at", created_at)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if name and not isinstance(name, str):
            raise TypeError("Expected argument 'name' to be a str")
        pulumi.set(__self__, "name", name)
        if slug and not isinstance(slug, str):
            raise TypeError("Expected argument 'slug' to be a str")
        pulumi.set(__self__, "slug", slug)
        if updated_at and not isinstance(updated_at, str):
            raise TypeError("Expected argument 'updated_at' to be a str")
        pulumi.set(__self__, "updated_at", updated_at)
        if url and not isinstance(url, str):
            raise TypeError("Expected argument 'url' to be a str")
        pulumi.set(__self__, "url", url)

    @property
    @pulumi.getter(name="createdAt")
    def created_at(self) -> str:
        return pulumi.get(self, "created_at")

    @property
    @pulumi.getter
    def id(self) -> str:
        """
        The ID of this resource.
        """
        return pulumi.get(self, "id")

    @property
    @pulumi.getter
    def name(self) -> str:
        return pulumi.get(self, "name")

    @property
    @pulumi.getter
    def slug(self) -> str:
        return pulumi.get(self, "slug")

    @property
    @pulumi.getter(name="updatedAt")
    def updated_at(self) -> str:
        return pulumi.get(self, "updated_at")

    @property
    @pulumi.getter
    def url(self) -> str:
        return pulumi.get(self, "url")


class AwaitableGetCloudOrganizationResult(GetCloudOrganizationResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetCloudOrganizationResult(
            created_at=self.created_at,
            id=self.id,
            name=self.name,
            slug=self.slug,
            updated_at=self.updated_at,
            url=self.url)


def get_cloud_organization(id: Optional[str] = None,
                           slug: Optional[str] = None,
                           opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetCloudOrganizationResult:
    """
    ## Example Usage

    ```python
    import pulumi
    import pulumi_grafana as grafana

    test = grafana.cloud.get_organization(slug="my-org")
    ```


    :param str id: The ID of this resource.
    """
    pulumi.log.warn("""get_cloud_organization is deprecated: grafana.index/getcloudorganization.getCloudOrganization has been deprecated in favor of grafana.cloud/getorganization.getOrganization""")
    __args__ = dict()
    __args__['id'] = id
    __args__['slug'] = slug
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('grafana:index/getCloudOrganization:getCloudOrganization', __args__, opts=opts, typ=GetCloudOrganizationResult).value

    return AwaitableGetCloudOrganizationResult(
        created_at=pulumi.get(__ret__, 'created_at'),
        id=pulumi.get(__ret__, 'id'),
        name=pulumi.get(__ret__, 'name'),
        slug=pulumi.get(__ret__, 'slug'),
        updated_at=pulumi.get(__ret__, 'updated_at'),
        url=pulumi.get(__ret__, 'url'))
def get_cloud_organization_output(id: Optional[pulumi.Input[Optional[str]]] = None,
                                  slug: Optional[pulumi.Input[Optional[str]]] = None,
                                  opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetCloudOrganizationResult]:
    """
    ## Example Usage

    ```python
    import pulumi
    import pulumi_grafana as grafana

    test = grafana.cloud.get_organization(slug="my-org")
    ```


    :param str id: The ID of this resource.
    """
    pulumi.log.warn("""get_cloud_organization is deprecated: grafana.index/getcloudorganization.getCloudOrganization has been deprecated in favor of grafana.cloud/getorganization.getOrganization""")
    __args__ = dict()
    __args__['id'] = id
    __args__['slug'] = slug
    opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke_output('grafana:index/getCloudOrganization:getCloudOrganization', __args__, opts=opts, typ=GetCloudOrganizationResult)
    return __ret__.apply(lambda __response__: GetCloudOrganizationResult(
        created_at=pulumi.get(__response__, 'created_at'),
        id=pulumi.get(__response__, 'id'),
        name=pulumi.get(__response__, 'name'),
        slug=pulumi.get(__response__, 'slug'),
        updated_at=pulumi.get(__response__, 'updated_at'),
        url=pulumi.get(__response__, 'url')))
