# coding=utf-8
# *** WARNING: this file was generated by pulumi-language-python. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import builtins as _builtins
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__ = [
    'GetMetricsPolicyResult',
    'AwaitableGetMetricsPolicyResult',
    'get_metrics_policy',
    'get_metrics_policy_output',
]

@pulumi.output_type
class GetMetricsPolicyResult:
    """
    A collection of values returned by getMetricsPolicy.
    """
    def __init__(__self__, customer=None, id=None, policy_rules=None, updated_epoch_millis=None, updater_id=None):
        if customer and not isinstance(customer, str):
            raise TypeError("Expected argument 'customer' to be a str")
        pulumi.set(__self__, "customer", customer)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if policy_rules and not isinstance(policy_rules, list):
            raise TypeError("Expected argument 'policy_rules' to be a list")
        pulumi.set(__self__, "policy_rules", policy_rules)
        if updated_epoch_millis and not isinstance(updated_epoch_millis, int):
            raise TypeError("Expected argument 'updated_epoch_millis' to be a int")
        pulumi.set(__self__, "updated_epoch_millis", updated_epoch_millis)
        if updater_id and not isinstance(updater_id, str):
            raise TypeError("Expected argument 'updater_id' to be a str")
        pulumi.set(__self__, "updater_id", updater_id)

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

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

    @_builtins.property
    @pulumi.getter(name="policyRules")
    def policy_rules(self) -> Sequence['outputs.GetMetricsPolicyPolicyRuleResult']:
        return pulumi.get(self, "policy_rules")

    @_builtins.property
    @pulumi.getter(name="updatedEpochMillis")
    def updated_epoch_millis(self) -> _builtins.int:
        return pulumi.get(self, "updated_epoch_millis")

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


class AwaitableGetMetricsPolicyResult(GetMetricsPolicyResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetMetricsPolicyResult(
            customer=self.customer,
            id=self.id,
            policy_rules=self.policy_rules,
            updated_epoch_millis=self.updated_epoch_millis,
            updater_id=self.updater_id)


def get_metrics_policy(opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetMetricsPolicyResult:
    """
    Use this data source to access information about an existing resource.
    """
    __args__ = dict()
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('wavefront:index/getMetricsPolicy:getMetricsPolicy', __args__, opts=opts, typ=GetMetricsPolicyResult).value

    return AwaitableGetMetricsPolicyResult(
        customer=pulumi.get(__ret__, 'customer'),
        id=pulumi.get(__ret__, 'id'),
        policy_rules=pulumi.get(__ret__, 'policy_rules'),
        updated_epoch_millis=pulumi.get(__ret__, 'updated_epoch_millis'),
        updater_id=pulumi.get(__ret__, 'updater_id'))
def get_metrics_policy_output(opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetMetricsPolicyResult]:
    """
    Use this data source to access information about an existing resource.
    """
    __args__ = dict()
    opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke_output('wavefront:index/getMetricsPolicy:getMetricsPolicy', __args__, opts=opts, typ=GetMetricsPolicyResult)
    return __ret__.apply(lambda __response__: GetMetricsPolicyResult(
        customer=pulumi.get(__response__, 'customer'),
        id=pulumi.get(__response__, 'id'),
        policy_rules=pulumi.get(__response__, 'policy_rules'),
        updated_epoch_millis=pulumi.get(__response__, 'updated_epoch_millis'),
        updater_id=pulumi.get(__response__, 'updater_id')))
