github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/servicecatalog/getLaunchPaths.go (about) 1 // Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT. 2 // *** WARNING: Do not edit by hand unless you're certain you know what you are doing! *** 3 4 package servicecatalog 5 6 import ( 7 "context" 8 "reflect" 9 10 "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal" 11 "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 12 ) 13 14 // Lists the paths to the specified product. A path is how the user has access to a specified product, and is necessary when provisioning a product. A path also determines the constraints put on the product. 15 // 16 // ## Example Usage 17 // 18 // ### Basic Usage 19 // 20 // <!--Start PulumiCodeChooser --> 21 // ```go 22 // package main 23 // 24 // import ( 25 // 26 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/servicecatalog" 27 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 28 // 29 // ) 30 // 31 // func main() { 32 // pulumi.Run(func(ctx *pulumi.Context) error { 33 // _, err := servicecatalog.GetLaunchPaths(ctx, &servicecatalog.GetLaunchPathsArgs{ 34 // ProductId: "prod-yakog5pdriver", 35 // }, nil) 36 // if err != nil { 37 // return err 38 // } 39 // return nil 40 // }) 41 // } 42 // 43 // ``` 44 // <!--End PulumiCodeChooser --> 45 func GetLaunchPaths(ctx *pulumi.Context, args *GetLaunchPathsArgs, opts ...pulumi.InvokeOption) (*GetLaunchPathsResult, error) { 46 opts = internal.PkgInvokeDefaultOpts(opts) 47 var rv GetLaunchPathsResult 48 err := ctx.Invoke("aws:servicecatalog/getLaunchPaths:getLaunchPaths", args, &rv, opts...) 49 if err != nil { 50 return nil, err 51 } 52 return &rv, nil 53 } 54 55 // A collection of arguments for invoking getLaunchPaths. 56 type GetLaunchPathsArgs struct { 57 // Language code. Valid values: `en` (English), `jp` (Japanese), `zh` (Chinese). Default value is `en`. 58 AcceptLanguage *string `pulumi:"acceptLanguage"` 59 // Product identifier. 60 // 61 // The following arguments are optional: 62 ProductId string `pulumi:"productId"` 63 } 64 65 // A collection of values returned by getLaunchPaths. 66 type GetLaunchPathsResult struct { 67 AcceptLanguage *string `pulumi:"acceptLanguage"` 68 // The provider-assigned unique ID for this managed resource. 69 Id string `pulumi:"id"` 70 ProductId string `pulumi:"productId"` 71 // Block with information about the launch path. See details below. 72 Summaries []GetLaunchPathsSummary `pulumi:"summaries"` 73 } 74 75 func GetLaunchPathsOutput(ctx *pulumi.Context, args GetLaunchPathsOutputArgs, opts ...pulumi.InvokeOption) GetLaunchPathsResultOutput { 76 return pulumi.ToOutputWithContext(context.Background(), args). 77 ApplyT(func(v interface{}) (GetLaunchPathsResult, error) { 78 args := v.(GetLaunchPathsArgs) 79 r, err := GetLaunchPaths(ctx, &args, opts...) 80 var s GetLaunchPathsResult 81 if r != nil { 82 s = *r 83 } 84 return s, err 85 }).(GetLaunchPathsResultOutput) 86 } 87 88 // A collection of arguments for invoking getLaunchPaths. 89 type GetLaunchPathsOutputArgs struct { 90 // Language code. Valid values: `en` (English), `jp` (Japanese), `zh` (Chinese). Default value is `en`. 91 AcceptLanguage pulumi.StringPtrInput `pulumi:"acceptLanguage"` 92 // Product identifier. 93 // 94 // The following arguments are optional: 95 ProductId pulumi.StringInput `pulumi:"productId"` 96 } 97 98 func (GetLaunchPathsOutputArgs) ElementType() reflect.Type { 99 return reflect.TypeOf((*GetLaunchPathsArgs)(nil)).Elem() 100 } 101 102 // A collection of values returned by getLaunchPaths. 103 type GetLaunchPathsResultOutput struct{ *pulumi.OutputState } 104 105 func (GetLaunchPathsResultOutput) ElementType() reflect.Type { 106 return reflect.TypeOf((*GetLaunchPathsResult)(nil)).Elem() 107 } 108 109 func (o GetLaunchPathsResultOutput) ToGetLaunchPathsResultOutput() GetLaunchPathsResultOutput { 110 return o 111 } 112 113 func (o GetLaunchPathsResultOutput) ToGetLaunchPathsResultOutputWithContext(ctx context.Context) GetLaunchPathsResultOutput { 114 return o 115 } 116 117 func (o GetLaunchPathsResultOutput) AcceptLanguage() pulumi.StringPtrOutput { 118 return o.ApplyT(func(v GetLaunchPathsResult) *string { return v.AcceptLanguage }).(pulumi.StringPtrOutput) 119 } 120 121 // The provider-assigned unique ID for this managed resource. 122 func (o GetLaunchPathsResultOutput) Id() pulumi.StringOutput { 123 return o.ApplyT(func(v GetLaunchPathsResult) string { return v.Id }).(pulumi.StringOutput) 124 } 125 126 func (o GetLaunchPathsResultOutput) ProductId() pulumi.StringOutput { 127 return o.ApplyT(func(v GetLaunchPathsResult) string { return v.ProductId }).(pulumi.StringOutput) 128 } 129 130 // Block with information about the launch path. See details below. 131 func (o GetLaunchPathsResultOutput) Summaries() GetLaunchPathsSummaryArrayOutput { 132 return o.ApplyT(func(v GetLaunchPathsResult) []GetLaunchPathsSummary { return v.Summaries }).(GetLaunchPathsSummaryArrayOutput) 133 } 134 135 func init() { 136 pulumi.RegisterOutputType(GetLaunchPathsResultOutput{}) 137 }