# 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 pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from . import _utilities

__all__ = [
    'GetSiteResult',
    'AwaitableGetSiteResult',
    'get_site',
    'get_site_output',
]

@pulumi.output_type
class GetSiteResult:
    """
    A collection of values returned by getSite.
    """
    def __init__(__self__, asn=None, comments=None, description=None, group_id=None, id=None, name=None, region_id=None, site_id=None, slug=None, status=None, tenant_id=None, time_zone=None):
        if asn and not isinstance(asn, int):
            raise TypeError("Expected argument 'asn' to be a int")
        pulumi.set(__self__, "asn", asn)
        if comments and not isinstance(comments, str):
            raise TypeError("Expected argument 'comments' to be a str")
        pulumi.set(__self__, "comments", comments)
        if description and not isinstance(description, str):
            raise TypeError("Expected argument 'description' to be a str")
        pulumi.set(__self__, "description", description)
        if group_id and not isinstance(group_id, int):
            raise TypeError("Expected argument 'group_id' to be a int")
        pulumi.set(__self__, "group_id", group_id)
        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 region_id and not isinstance(region_id, int):
            raise TypeError("Expected argument 'region_id' to be a int")
        pulumi.set(__self__, "region_id", region_id)
        if site_id and not isinstance(site_id, int):
            raise TypeError("Expected argument 'site_id' to be a int")
        pulumi.set(__self__, "site_id", site_id)
        if slug and not isinstance(slug, str):
            raise TypeError("Expected argument 'slug' to be a str")
        pulumi.set(__self__, "slug", slug)
        if status and not isinstance(status, str):
            raise TypeError("Expected argument 'status' to be a str")
        pulumi.set(__self__, "status", status)
        if tenant_id and not isinstance(tenant_id, int):
            raise TypeError("Expected argument 'tenant_id' to be a int")
        pulumi.set(__self__, "tenant_id", tenant_id)
        if time_zone and not isinstance(time_zone, str):
            raise TypeError("Expected argument 'time_zone' to be a str")
        pulumi.set(__self__, "time_zone", time_zone)

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

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

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

    @property
    @pulumi.getter(name="groupId")
    def group_id(self) -> int:
        return pulumi.get(self, "group_id")

    @property
    @pulumi.getter
    def id(self) -> str:
        """
        The provider-assigned unique ID for this managed resource.
        """
        return pulumi.get(self, "id")

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

    @property
    @pulumi.getter(name="regionId")
    def region_id(self) -> int:
        return pulumi.get(self, "region_id")

    @property
    @pulumi.getter(name="siteId")
    def site_id(self) -> int:
        return pulumi.get(self, "site_id")

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

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

    @property
    @pulumi.getter(name="tenantId")
    def tenant_id(self) -> int:
        return pulumi.get(self, "tenant_id")

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


class AwaitableGetSiteResult(GetSiteResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetSiteResult(
            asn=self.asn,
            comments=self.comments,
            description=self.description,
            group_id=self.group_id,
            id=self.id,
            name=self.name,
            region_id=self.region_id,
            site_id=self.site_id,
            slug=self.slug,
            status=self.status,
            tenant_id=self.tenant_id,
            time_zone=self.time_zone)


def get_site(name: Optional[str] = None,
             slug: Optional[str] = None,
             opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetSiteResult:
    """
    ## Example Usage

    ```python
    import pulumi
    import pulumi_netbox as netbox

    get_by_name = netbox.get_site(name="Example Site 1")
    get_by_slug = netbox.get_site(slug="example-site-1")
    ```
    """
    __args__ = dict()
    __args__['name'] = name
    __args__['slug'] = slug
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('netbox:index/getSite:getSite', __args__, opts=opts, typ=GetSiteResult).value

    return AwaitableGetSiteResult(
        asn=__ret__.asn,
        comments=__ret__.comments,
        description=__ret__.description,
        group_id=__ret__.group_id,
        id=__ret__.id,
        name=__ret__.name,
        region_id=__ret__.region_id,
        site_id=__ret__.site_id,
        slug=__ret__.slug,
        status=__ret__.status,
        tenant_id=__ret__.tenant_id,
        time_zone=__ret__.time_zone)


@_utilities.lift_output_func(get_site)
def get_site_output(name: Optional[pulumi.Input[Optional[str]]] = None,
                    slug: Optional[pulumi.Input[Optional[str]]] = None,
                    opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetSiteResult]:
    """
    ## Example Usage

    ```python
    import pulumi
    import pulumi_netbox as netbox

    get_by_name = netbox.get_site(name="Example Site 1")
    get_by_slug = netbox.get_site(slug="example-site-1")
    ```
    """
    ...
