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

__all__ = [
    'GetConstraintResult',
    'AwaitableGetConstraintResult',
    'get_constraint',
]

@pulumi.output_type
class GetConstraintResult:
    """
    A collection of values returned by getConstraint.
    """
    def __init__(__self__, accept_language=None, description=None, id=None, owner=None, parameters=None, portfolio_id=None, product_id=None, status=None, type=None):
        if accept_language and not isinstance(accept_language, str):
            raise TypeError("Expected argument 'accept_language' to be a str")
        pulumi.set(__self__, "accept_language", accept_language)
        if description and not isinstance(description, str):
            raise TypeError("Expected argument 'description' to be a str")
        pulumi.set(__self__, "description", description)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if owner and not isinstance(owner, str):
            raise TypeError("Expected argument 'owner' to be a str")
        pulumi.set(__self__, "owner", owner)
        if parameters and not isinstance(parameters, str):
            raise TypeError("Expected argument 'parameters' to be a str")
        pulumi.set(__self__, "parameters", parameters)
        if portfolio_id and not isinstance(portfolio_id, str):
            raise TypeError("Expected argument 'portfolio_id' to be a str")
        pulumi.set(__self__, "portfolio_id", portfolio_id)
        if product_id and not isinstance(product_id, str):
            raise TypeError("Expected argument 'product_id' to be a str")
        pulumi.set(__self__, "product_id", product_id)
        if status and not isinstance(status, str):
            raise TypeError("Expected argument 'status' to be a str")
        pulumi.set(__self__, "status", status)
        if type and not isinstance(type, str):
            raise TypeError("Expected argument 'type' to be a str")
        pulumi.set(__self__, "type", type)

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

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

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

    @property
    @pulumi.getter
    def owner(self) -> str:
        """
        Owner of the constraint.
        """
        return pulumi.get(self, "owner")

    @property
    @pulumi.getter
    def parameters(self) -> str:
        """
        Constraint parameters in JSON format.
        """
        return pulumi.get(self, "parameters")

    @property
    @pulumi.getter(name="portfolioId")
    def portfolio_id(self) -> str:
        """
        Portfolio identifier.
        """
        return pulumi.get(self, "portfolio_id")

    @property
    @pulumi.getter(name="productId")
    def product_id(self) -> str:
        """
        Product identifier.
        """
        return pulumi.get(self, "product_id")

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

    @property
    @pulumi.getter
    def type(self) -> str:
        """
        Type of constraint. Valid values are `LAUNCH`, `NOTIFICATION`, `RESOURCE_UPDATE`, `STACKSET`, and `TEMPLATE`.
        """
        return pulumi.get(self, "type")


class AwaitableGetConstraintResult(GetConstraintResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetConstraintResult(
            accept_language=self.accept_language,
            description=self.description,
            id=self.id,
            owner=self.owner,
            parameters=self.parameters,
            portfolio_id=self.portfolio_id,
            product_id=self.product_id,
            status=self.status,
            type=self.type)


def get_constraint(accept_language: Optional[str] = None,
                   description: Optional[str] = None,
                   id: Optional[str] = None,
                   opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetConstraintResult:
    """
    Provides information on a Service Catalog Constraint.

    ## Example Usage
    ### Basic Usage

    ```python
    import pulumi
    import pulumi_aws as aws

    example = aws.servicecatalog.get_constraint(accept_language="en",
        id="cons-hrvy0335")
    ```


    :param str accept_language: Language code. Valid values: `en` (English), `jp` (Japanese), `zh` (Chinese). Default value is `en`.
    :param str description: Description of the constraint.
    :param str id: Constraint identifier.
    """
    __args__ = dict()
    __args__['acceptLanguage'] = accept_language
    __args__['description'] = description
    __args__['id'] = id
    if opts is None:
        opts = pulumi.InvokeOptions()
    if opts.version is None:
        opts.version = _utilities.get_version()
    __ret__ = pulumi.runtime.invoke('aws:servicecatalog/getConstraint:getConstraint', __args__, opts=opts, typ=GetConstraintResult).value

    return AwaitableGetConstraintResult(
        accept_language=__ret__.accept_language,
        description=__ret__.description,
        id=__ret__.id,
        owner=__ret__.owner,
        parameters=__ret__.parameters,
        portfolio_id=__ret__.portfolio_id,
        product_id=__ret__.product_id,
        status=__ret__.status,
        type=__ret__.type)
