1. Packages
  2. AWS
  3. API Docs
  4. servicecatalog
  5. getConstraint
AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi

aws.servicecatalog.getConstraint

Explore with Pulumi AI

aws logo
AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi

    Provides information on a Service Catalog Constraint.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = aws.servicecatalog.getConstraint({
        acceptLanguage: "en",
        id: "cons-hrvy0335",
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.servicecatalog.get_constraint(accept_language="en",
        id="cons-hrvy0335")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/servicecatalog"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := servicecatalog.LookupConstraint(ctx, &servicecatalog.LookupConstraintArgs{
    			AcceptLanguage: pulumi.StringRef("en"),
    			Id:             "cons-hrvy0335",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Aws.ServiceCatalog.GetConstraint.Invoke(new()
        {
            AcceptLanguage = "en",
            Id = "cons-hrvy0335",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.servicecatalog.ServicecatalogFunctions;
    import com.pulumi.aws.servicecatalog.inputs.GetConstraintArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = ServicecatalogFunctions.getConstraint(GetConstraintArgs.builder()
                .acceptLanguage("en")
                .id("cons-hrvy0335")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: aws:servicecatalog:getConstraint
          Arguments:
            acceptLanguage: en
            id: cons-hrvy0335
    

    Using getConstraint

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getConstraint(args: GetConstraintArgs, opts?: InvokeOptions): Promise<GetConstraintResult>
    function getConstraintOutput(args: GetConstraintOutputArgs, opts?: InvokeOptions): Output<GetConstraintResult>
    def get_constraint(accept_language: Optional[str] = None,
                       description: Optional[str] = None,
                       id: Optional[str] = None,
                       opts: Optional[InvokeOptions] = None) -> GetConstraintResult
    def get_constraint_output(accept_language: Optional[pulumi.Input[str]] = None,
                       description: Optional[pulumi.Input[str]] = None,
                       id: Optional[pulumi.Input[str]] = None,
                       opts: Optional[InvokeOptions] = None) -> Output[GetConstraintResult]
    func LookupConstraint(ctx *Context, args *LookupConstraintArgs, opts ...InvokeOption) (*LookupConstraintResult, error)
    func LookupConstraintOutput(ctx *Context, args *LookupConstraintOutputArgs, opts ...InvokeOption) LookupConstraintResultOutput

    > Note: This function is named LookupConstraint in the Go SDK.

    public static class GetConstraint 
    {
        public static Task<GetConstraintResult> InvokeAsync(GetConstraintArgs args, InvokeOptions? opts = null)
        public static Output<GetConstraintResult> Invoke(GetConstraintInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetConstraintResult> getConstraint(GetConstraintArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: aws:servicecatalog/getConstraint:getConstraint
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string

    Constraint identifier.

    The following arguments are optional:

    AcceptLanguage string
    Language code. Valid values: en (English), jp (Japanese), zh (Chinese). Default value is en.
    Description string
    Description of the constraint.
    Id string

    Constraint identifier.

    The following arguments are optional:

    AcceptLanguage string
    Language code. Valid values: en (English), jp (Japanese), zh (Chinese). Default value is en.
    Description string
    Description of the constraint.
    id String

    Constraint identifier.

    The following arguments are optional:

    acceptLanguage String
    Language code. Valid values: en (English), jp (Japanese), zh (Chinese). Default value is en.
    description String
    Description of the constraint.
    id string

    Constraint identifier.

    The following arguments are optional:

    acceptLanguage string
    Language code. Valid values: en (English), jp (Japanese), zh (Chinese). Default value is en.
    description string
    Description of the constraint.
    id str

    Constraint identifier.

    The following arguments are optional:

    accept_language str
    Language code. Valid values: en (English), jp (Japanese), zh (Chinese). Default value is en.
    description str
    Description of the constraint.
    id String

    Constraint identifier.

    The following arguments are optional:

    acceptLanguage String
    Language code. Valid values: en (English), jp (Japanese), zh (Chinese). Default value is en.
    description String
    Description of the constraint.

    getConstraint Result

    The following output properties are available:

    Description string
    Description of the constraint.
    Id string
    Owner string
    Owner of the constraint.
    Parameters string
    Constraint parameters in JSON format.
    PortfolioId string
    Portfolio identifier.
    ProductId string
    Product identifier.
    Status string
    Constraint status.
    Type string
    Type of constraint. Valid values are LAUNCH, NOTIFICATION, RESOURCE_UPDATE, STACKSET, and TEMPLATE.
    AcceptLanguage string
    Description string
    Description of the constraint.
    Id string
    Owner string
    Owner of the constraint.
    Parameters string
    Constraint parameters in JSON format.
    PortfolioId string
    Portfolio identifier.
    ProductId string
    Product identifier.
    Status string
    Constraint status.
    Type string
    Type of constraint. Valid values are LAUNCH, NOTIFICATION, RESOURCE_UPDATE, STACKSET, and TEMPLATE.
    AcceptLanguage string
    description String
    Description of the constraint.
    id String
    owner String
    Owner of the constraint.
    parameters String
    Constraint parameters in JSON format.
    portfolioId String
    Portfolio identifier.
    productId String
    Product identifier.
    status String
    Constraint status.
    type String
    Type of constraint. Valid values are LAUNCH, NOTIFICATION, RESOURCE_UPDATE, STACKSET, and TEMPLATE.
    acceptLanguage String
    description string
    Description of the constraint.
    id string
    owner string
    Owner of the constraint.
    parameters string
    Constraint parameters in JSON format.
    portfolioId string
    Portfolio identifier.
    productId string
    Product identifier.
    status string
    Constraint status.
    type string
    Type of constraint. Valid values are LAUNCH, NOTIFICATION, RESOURCE_UPDATE, STACKSET, and TEMPLATE.
    acceptLanguage string
    description str
    Description of the constraint.
    id str
    owner str
    Owner of the constraint.
    parameters str
    Constraint parameters in JSON format.
    portfolio_id str
    Portfolio identifier.
    product_id str
    Product identifier.
    status str
    Constraint status.
    type str
    Type of constraint. Valid values are LAUNCH, NOTIFICATION, RESOURCE_UPDATE, STACKSET, and TEMPLATE.
    accept_language str
    description String
    Description of the constraint.
    id String
    owner String
    Owner of the constraint.
    parameters String
    Constraint parameters in JSON format.
    portfolioId String
    Portfolio identifier.
    productId String
    Product identifier.
    status String
    Constraint status.
    type String
    Type of constraint. Valid values are LAUNCH, NOTIFICATION, RESOURCE_UPDATE, STACKSET, and TEMPLATE.
    acceptLanguage String

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo
    AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi