github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/connect/getRoutingProfile.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 connect
     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  // Provides details about a specific Amazon Connect Routing Profile.
    15  //
    16  // ## Example Usage
    17  //
    18  // By `name`
    19  //
    20  // <!--Start PulumiCodeChooser -->
    21  // ```go
    22  // package main
    23  //
    24  // import (
    25  //
    26  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/connect"
    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 := connect.LookupRoutingProfile(ctx, &connect.LookupRoutingProfileArgs{
    34  //				InstanceId: "aaaaaaaa-bbbb-cccc-dddd-111111111111",
    35  //				Name:       pulumi.StringRef("Example"),
    36  //			}, nil)
    37  //			if err != nil {
    38  //				return err
    39  //			}
    40  //			return nil
    41  //		})
    42  //	}
    43  //
    44  // ```
    45  // <!--End PulumiCodeChooser -->
    46  //
    47  // By `routingProfileId`
    48  //
    49  // <!--Start PulumiCodeChooser -->
    50  // ```go
    51  // package main
    52  //
    53  // import (
    54  //
    55  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/connect"
    56  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    57  //
    58  // )
    59  //
    60  //	func main() {
    61  //		pulumi.Run(func(ctx *pulumi.Context) error {
    62  //			_, err := connect.LookupRoutingProfile(ctx, &connect.LookupRoutingProfileArgs{
    63  //				InstanceId:       "aaaaaaaa-bbbb-cccc-dddd-111111111111",
    64  //				RoutingProfileId: pulumi.StringRef("cccccccc-bbbb-cccc-dddd-111111111111"),
    65  //			}, nil)
    66  //			if err != nil {
    67  //				return err
    68  //			}
    69  //			return nil
    70  //		})
    71  //	}
    72  //
    73  // ```
    74  // <!--End PulumiCodeChooser -->
    75  func LookupRoutingProfile(ctx *pulumi.Context, args *LookupRoutingProfileArgs, opts ...pulumi.InvokeOption) (*LookupRoutingProfileResult, error) {
    76  	opts = internal.PkgInvokeDefaultOpts(opts)
    77  	var rv LookupRoutingProfileResult
    78  	err := ctx.Invoke("aws:connect/getRoutingProfile:getRoutingProfile", args, &rv, opts...)
    79  	if err != nil {
    80  		return nil, err
    81  	}
    82  	return &rv, nil
    83  }
    84  
    85  // A collection of arguments for invoking getRoutingProfile.
    86  type LookupRoutingProfileArgs struct {
    87  	// Reference to the hosting Amazon Connect Instance
    88  	InstanceId string `pulumi:"instanceId"`
    89  	// Returns information on a specific Routing Profile by name
    90  	Name *string `pulumi:"name"`
    91  	// Returns information on a specific Routing Profile by Routing Profile id
    92  	RoutingProfileId *string `pulumi:"routingProfileId"`
    93  	// Map of tags to assign to the Routing Profile.
    94  	Tags map[string]string `pulumi:"tags"`
    95  }
    96  
    97  // A collection of values returned by getRoutingProfile.
    98  type LookupRoutingProfileResult struct {
    99  	// ARN of the Routing Profile.
   100  	Arn string `pulumi:"arn"`
   101  	// Specifies the default outbound queue for the Routing Profile.
   102  	DefaultOutboundQueueId string `pulumi:"defaultOutboundQueueId"`
   103  	// Description of the Routing Profile.
   104  	Description string `pulumi:"description"`
   105  	// The provider-assigned unique ID for this managed resource.
   106  	Id         string `pulumi:"id"`
   107  	InstanceId string `pulumi:"instanceId"`
   108  	// One or more `mediaConcurrencies` blocks that specify the channels that agents can handle in the Contact Control Panel (CCP) for this Routing Profile. The `mediaConcurrencies` block is documented below.
   109  	MediaConcurrencies []GetRoutingProfileMediaConcurrency `pulumi:"mediaConcurrencies"`
   110  	Name               string                              `pulumi:"name"`
   111  	// One or more `queueConfigs` blocks that specify the inbound queues associated with the routing profile. If no queue is added, the agent only can make outbound calls. The `queueConfigs` block is documented below.
   112  	QueueConfigs     []GetRoutingProfileQueueConfig `pulumi:"queueConfigs"`
   113  	RoutingProfileId string                         `pulumi:"routingProfileId"`
   114  	// Map of tags to assign to the Routing Profile.
   115  	Tags map[string]string `pulumi:"tags"`
   116  }
   117  
   118  func LookupRoutingProfileOutput(ctx *pulumi.Context, args LookupRoutingProfileOutputArgs, opts ...pulumi.InvokeOption) LookupRoutingProfileResultOutput {
   119  	return pulumi.ToOutputWithContext(context.Background(), args).
   120  		ApplyT(func(v interface{}) (LookupRoutingProfileResult, error) {
   121  			args := v.(LookupRoutingProfileArgs)
   122  			r, err := LookupRoutingProfile(ctx, &args, opts...)
   123  			var s LookupRoutingProfileResult
   124  			if r != nil {
   125  				s = *r
   126  			}
   127  			return s, err
   128  		}).(LookupRoutingProfileResultOutput)
   129  }
   130  
   131  // A collection of arguments for invoking getRoutingProfile.
   132  type LookupRoutingProfileOutputArgs struct {
   133  	// Reference to the hosting Amazon Connect Instance
   134  	InstanceId pulumi.StringInput `pulumi:"instanceId"`
   135  	// Returns information on a specific Routing Profile by name
   136  	Name pulumi.StringPtrInput `pulumi:"name"`
   137  	// Returns information on a specific Routing Profile by Routing Profile id
   138  	RoutingProfileId pulumi.StringPtrInput `pulumi:"routingProfileId"`
   139  	// Map of tags to assign to the Routing Profile.
   140  	Tags pulumi.StringMapInput `pulumi:"tags"`
   141  }
   142  
   143  func (LookupRoutingProfileOutputArgs) ElementType() reflect.Type {
   144  	return reflect.TypeOf((*LookupRoutingProfileArgs)(nil)).Elem()
   145  }
   146  
   147  // A collection of values returned by getRoutingProfile.
   148  type LookupRoutingProfileResultOutput struct{ *pulumi.OutputState }
   149  
   150  func (LookupRoutingProfileResultOutput) ElementType() reflect.Type {
   151  	return reflect.TypeOf((*LookupRoutingProfileResult)(nil)).Elem()
   152  }
   153  
   154  func (o LookupRoutingProfileResultOutput) ToLookupRoutingProfileResultOutput() LookupRoutingProfileResultOutput {
   155  	return o
   156  }
   157  
   158  func (o LookupRoutingProfileResultOutput) ToLookupRoutingProfileResultOutputWithContext(ctx context.Context) LookupRoutingProfileResultOutput {
   159  	return o
   160  }
   161  
   162  // ARN of the Routing Profile.
   163  func (o LookupRoutingProfileResultOutput) Arn() pulumi.StringOutput {
   164  	return o.ApplyT(func(v LookupRoutingProfileResult) string { return v.Arn }).(pulumi.StringOutput)
   165  }
   166  
   167  // Specifies the default outbound queue for the Routing Profile.
   168  func (o LookupRoutingProfileResultOutput) DefaultOutboundQueueId() pulumi.StringOutput {
   169  	return o.ApplyT(func(v LookupRoutingProfileResult) string { return v.DefaultOutboundQueueId }).(pulumi.StringOutput)
   170  }
   171  
   172  // Description of the Routing Profile.
   173  func (o LookupRoutingProfileResultOutput) Description() pulumi.StringOutput {
   174  	return o.ApplyT(func(v LookupRoutingProfileResult) string { return v.Description }).(pulumi.StringOutput)
   175  }
   176  
   177  // The provider-assigned unique ID for this managed resource.
   178  func (o LookupRoutingProfileResultOutput) Id() pulumi.StringOutput {
   179  	return o.ApplyT(func(v LookupRoutingProfileResult) string { return v.Id }).(pulumi.StringOutput)
   180  }
   181  
   182  func (o LookupRoutingProfileResultOutput) InstanceId() pulumi.StringOutput {
   183  	return o.ApplyT(func(v LookupRoutingProfileResult) string { return v.InstanceId }).(pulumi.StringOutput)
   184  }
   185  
   186  // One or more `mediaConcurrencies` blocks that specify the channels that agents can handle in the Contact Control Panel (CCP) for this Routing Profile. The `mediaConcurrencies` block is documented below.
   187  func (o LookupRoutingProfileResultOutput) MediaConcurrencies() GetRoutingProfileMediaConcurrencyArrayOutput {
   188  	return o.ApplyT(func(v LookupRoutingProfileResult) []GetRoutingProfileMediaConcurrency { return v.MediaConcurrencies }).(GetRoutingProfileMediaConcurrencyArrayOutput)
   189  }
   190  
   191  func (o LookupRoutingProfileResultOutput) Name() pulumi.StringOutput {
   192  	return o.ApplyT(func(v LookupRoutingProfileResult) string { return v.Name }).(pulumi.StringOutput)
   193  }
   194  
   195  // One or more `queueConfigs` blocks that specify the inbound queues associated with the routing profile. If no queue is added, the agent only can make outbound calls. The `queueConfigs` block is documented below.
   196  func (o LookupRoutingProfileResultOutput) QueueConfigs() GetRoutingProfileQueueConfigArrayOutput {
   197  	return o.ApplyT(func(v LookupRoutingProfileResult) []GetRoutingProfileQueueConfig { return v.QueueConfigs }).(GetRoutingProfileQueueConfigArrayOutput)
   198  }
   199  
   200  func (o LookupRoutingProfileResultOutput) RoutingProfileId() pulumi.StringOutput {
   201  	return o.ApplyT(func(v LookupRoutingProfileResult) string { return v.RoutingProfileId }).(pulumi.StringOutput)
   202  }
   203  
   204  // Map of tags to assign to the Routing Profile.
   205  func (o LookupRoutingProfileResultOutput) Tags() pulumi.StringMapOutput {
   206  	return o.ApplyT(func(v LookupRoutingProfileResult) map[string]string { return v.Tags }).(pulumi.StringMapOutput)
   207  }
   208  
   209  func init() {
   210  	pulumi.RegisterOutputType(LookupRoutingProfileResultOutput{})
   211  }