# 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

__all__ = [
    'GetKubeNodePoolNodesResult',
    'AwaitableGetKubeNodePoolNodesResult',
    'get_kube_node_pool_nodes',
    'get_kube_node_pool_nodes_output',
]

@pulumi.output_type
class GetKubeNodePoolNodesResult:
    """
    A collection of values returned by getKubeNodePoolNodes.
    """
    def __init__(__self__, id=None, kube_id=None, name=None, nodes=None, service_name=None):
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if kube_id and not isinstance(kube_id, str):
            raise TypeError("Expected argument 'kube_id' to be a str")
        pulumi.set(__self__, "kube_id", kube_id)
        if name and not isinstance(name, str):
            raise TypeError("Expected argument 'name' to be a str")
        pulumi.set(__self__, "name", name)
        if nodes and not isinstance(nodes, list):
            raise TypeError("Expected argument 'nodes' to be a list")
        pulumi.set(__self__, "nodes", nodes)
        if service_name and not isinstance(service_name, str):
            raise TypeError("Expected argument 'service_name' to be a str")
        pulumi.set(__self__, "service_name", service_name)

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

    @property
    @pulumi.getter(name="kubeId")
    def kube_id(self) -> builtins.str:
        """
        See Argument Reference above.
        """
        return pulumi.get(self, "kube_id")

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

    @property
    @pulumi.getter
    def nodes(self) -> Sequence['outputs.GetKubeNodePoolNodesNodeResult']:
        """
        List of all nodes composing the kubernetes cluster.
        """
        return pulumi.get(self, "nodes")

    @property
    @pulumi.getter(name="serviceName")
    def service_name(self) -> builtins.str:
        """
        See Argument Reference above.
        """
        return pulumi.get(self, "service_name")


class AwaitableGetKubeNodePoolNodesResult(GetKubeNodePoolNodesResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetKubeNodePoolNodesResult(
            id=self.id,
            kube_id=self.kube_id,
            name=self.name,
            nodes=self.nodes,
            service_name=self.service_name)


def get_kube_node_pool_nodes(kube_id: Optional[builtins.str] = None,
                             name: Optional[builtins.str] = None,
                             service_name: Optional[builtins.str] = None,
                             opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetKubeNodePoolNodesResult:
    """
    Use this data source to get a list of OVHcloud Managed Kubernetes nodes in a specific node pool.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_ovh as ovh

    nodes = ovh.CloudProject.get_kube_node_pool_nodes(service_name="XXXXXX",
        kube_id="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx",
        name="XXXXXX")
    pulumi.export("nodes", nodes)
    ```


    :param builtins.str kube_id: The ID of the managed kubernetes cluster.
    :param builtins.str name: Name of the node pool from which we want the nodes.
    :param builtins.str service_name: The ID of the public cloud project. If omitted, the `OVH_CLOUD_PROJECT_SERVICE` environment variable is used.
    """
    __args__ = dict()
    __args__['kubeId'] = kube_id
    __args__['name'] = name
    __args__['serviceName'] = service_name
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('ovh:CloudProject/getKubeNodePoolNodes:getKubeNodePoolNodes', __args__, opts=opts, typ=GetKubeNodePoolNodesResult).value

    return AwaitableGetKubeNodePoolNodesResult(
        id=pulumi.get(__ret__, 'id'),
        kube_id=pulumi.get(__ret__, 'kube_id'),
        name=pulumi.get(__ret__, 'name'),
        nodes=pulumi.get(__ret__, 'nodes'),
        service_name=pulumi.get(__ret__, 'service_name'))
def get_kube_node_pool_nodes_output(kube_id: Optional[pulumi.Input[builtins.str]] = None,
                                    name: Optional[pulumi.Input[builtins.str]] = None,
                                    service_name: Optional[pulumi.Input[builtins.str]] = None,
                                    opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetKubeNodePoolNodesResult]:
    """
    Use this data source to get a list of OVHcloud Managed Kubernetes nodes in a specific node pool.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_ovh as ovh

    nodes = ovh.CloudProject.get_kube_node_pool_nodes(service_name="XXXXXX",
        kube_id="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx",
        name="XXXXXX")
    pulumi.export("nodes", nodes)
    ```


    :param builtins.str kube_id: The ID of the managed kubernetes cluster.
    :param builtins.str name: Name of the node pool from which we want the nodes.
    :param builtins.str service_name: The ID of the public cloud project. If omitted, the `OVH_CLOUD_PROJECT_SERVICE` environment variable is used.
    """
    __args__ = dict()
    __args__['kubeId'] = kube_id
    __args__['name'] = name
    __args__['serviceName'] = service_name
    opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke_output('ovh:CloudProject/getKubeNodePoolNodes:getKubeNodePoolNodes', __args__, opts=opts, typ=GetKubeNodePoolNodesResult)
    return __ret__.apply(lambda __response__: GetKubeNodePoolNodesResult(
        id=pulumi.get(__response__, 'id'),
        kube_id=pulumi.get(__response__, 'kube_id'),
        name=pulumi.get(__response__, 'name'),
        nodes=pulumi.get(__response__, 'nodes'),
        service_name=pulumi.get(__response__, 'service_name')))
