# 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__ = [
    'GetAppResult',
    'AwaitableGetAppResult',
    'get_app',
    'get_app_output',
]

@pulumi.output_type
class GetAppResult:
    """
    A collection of values returned by getApp.
    """
    def __init__(__self__, appurl=None, currentrelease=None, deployed=None, healthchecks=None, hostname=None, id=None, ipaddresses=None, name=None, status=None):
        if appurl and not isinstance(appurl, str):
            raise TypeError("Expected argument 'appurl' to be a str")
        pulumi.set(__self__, "appurl", appurl)
        if currentrelease and not isinstance(currentrelease, str):
            raise TypeError("Expected argument 'currentrelease' to be a str")
        pulumi.set(__self__, "currentrelease", currentrelease)
        if deployed and not isinstance(deployed, bool):
            raise TypeError("Expected argument 'deployed' to be a bool")
        pulumi.set(__self__, "deployed", deployed)
        if healthchecks and not isinstance(healthchecks, list):
            raise TypeError("Expected argument 'healthchecks' to be a list")
        pulumi.set(__self__, "healthchecks", healthchecks)
        if hostname and not isinstance(hostname, str):
            raise TypeError("Expected argument 'hostname' to be a str")
        pulumi.set(__self__, "hostname", hostname)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if ipaddresses and not isinstance(ipaddresses, list):
            raise TypeError("Expected argument 'ipaddresses' to be a list")
        pulumi.set(__self__, "ipaddresses", ipaddresses)
        if name and not isinstance(name, str):
            raise TypeError("Expected argument 'name' to be a str")
        pulumi.set(__self__, "name", name)
        if status and not isinstance(status, str):
            raise TypeError("Expected argument 'status' to be a str")
        pulumi.set(__self__, "status", status)

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

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

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

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

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

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

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

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

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


class AwaitableGetAppResult(GetAppResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetAppResult(
            appurl=self.appurl,
            currentrelease=self.currentrelease,
            deployed=self.deployed,
            healthchecks=self.healthchecks,
            hostname=self.hostname,
            id=self.id,
            ipaddresses=self.ipaddresses,
            name=self.name,
            status=self.status)


def get_app(name: Optional[str] = None,
            opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetAppResult:
    """
    Retrieve info about graphql app

    ## Example Usage


    :param str name: Name of app
    """
    __args__ = dict()
    __args__['name'] = name
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('fly:index/getApp:getApp', __args__, opts=opts, typ=GetAppResult).value

    return AwaitableGetAppResult(
        appurl=__ret__.appurl,
        currentrelease=__ret__.currentrelease,
        deployed=__ret__.deployed,
        healthchecks=__ret__.healthchecks,
        hostname=__ret__.hostname,
        id=__ret__.id,
        ipaddresses=__ret__.ipaddresses,
        name=__ret__.name,
        status=__ret__.status)


@_utilities.lift_output_func(get_app)
def get_app_output(name: Optional[pulumi.Input[str]] = None,
                   opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetAppResult]:
    """
    Retrieve info about graphql app

    ## Example Usage


    :param str name: Name of app
    """
    ...
