github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/ssoadmin/application.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 ssoadmin 5 6 import ( 7 "context" 8 "reflect" 9 10 "errors" 11 "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal" 12 "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 13 ) 14 15 // Resource for managing an AWS SSO Admin Application. 16 // 17 // > The `CreateApplication` API only supports custom OAuth 2.0 applications. 18 // Creation of 3rd party SAML or OAuth 2.0 applications require setup to be done through the associated app service or AWS console. 19 // See this issue for additional context. 20 // 21 // ## Example Usage 22 // 23 // ## Import 24 // 25 // Using `pulumi import`, import SSO Admin Application using the `id`. For example: 26 // 27 // ```sh 28 // $ pulumi import aws:ssoadmin/application:Application example arn:aws:sso::012345678901:application/id-12345678 29 // ``` 30 type Application struct { 31 pulumi.CustomResourceState 32 33 // AWS account ID. 34 ApplicationAccount pulumi.StringOutput `pulumi:"applicationAccount"` 35 // ARN of the application. 36 ApplicationArn pulumi.StringOutput `pulumi:"applicationArn"` 37 // ARN of the application provider. 38 ApplicationProviderArn pulumi.StringOutput `pulumi:"applicationProviderArn"` 39 // A unique, case-sensitive ID that you provide to ensure the idempotency of the request. AWS generates a random value when not provided. 40 ClientToken pulumi.StringPtrOutput `pulumi:"clientToken"` 41 // Description of the application. 42 Description pulumi.StringPtrOutput `pulumi:"description"` 43 // ARN of the instance of IAM Identity Center. 44 InstanceArn pulumi.StringOutput `pulumi:"instanceArn"` 45 // Name of the application. 46 // 47 // The following arguments are optional: 48 Name pulumi.StringOutput `pulumi:"name"` 49 // Options for the portal associated with an application. See `portalOptions` below. 50 PortalOptions ApplicationPortalOptionsPtrOutput `pulumi:"portalOptions"` 51 // Status of the application. Valid values are `ENABLED` and `DISABLED`. 52 Status pulumi.StringOutput `pulumi:"status"` 53 // Key-value mapping of resource tags. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 54 Tags pulumi.StringMapOutput `pulumi:"tags"` 55 // Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 56 // 57 // Deprecated: Please use `tags` instead. 58 TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"` 59 } 60 61 // NewApplication registers a new resource with the given unique name, arguments, and options. 62 func NewApplication(ctx *pulumi.Context, 63 name string, args *ApplicationArgs, opts ...pulumi.ResourceOption) (*Application, error) { 64 if args == nil { 65 return nil, errors.New("missing one or more required arguments") 66 } 67 68 if args.ApplicationProviderArn == nil { 69 return nil, errors.New("invalid value for required argument 'ApplicationProviderArn'") 70 } 71 if args.InstanceArn == nil { 72 return nil, errors.New("invalid value for required argument 'InstanceArn'") 73 } 74 opts = internal.PkgResourceDefaultOpts(opts) 75 var resource Application 76 err := ctx.RegisterResource("aws:ssoadmin/application:Application", name, args, &resource, opts...) 77 if err != nil { 78 return nil, err 79 } 80 return &resource, nil 81 } 82 83 // GetApplication gets an existing Application resource's state with the given name, ID, and optional 84 // state properties that are used to uniquely qualify the lookup (nil if not required). 85 func GetApplication(ctx *pulumi.Context, 86 name string, id pulumi.IDInput, state *ApplicationState, opts ...pulumi.ResourceOption) (*Application, error) { 87 var resource Application 88 err := ctx.ReadResource("aws:ssoadmin/application:Application", name, id, state, &resource, opts...) 89 if err != nil { 90 return nil, err 91 } 92 return &resource, nil 93 } 94 95 // Input properties used for looking up and filtering Application resources. 96 type applicationState struct { 97 // AWS account ID. 98 ApplicationAccount *string `pulumi:"applicationAccount"` 99 // ARN of the application. 100 ApplicationArn *string `pulumi:"applicationArn"` 101 // ARN of the application provider. 102 ApplicationProviderArn *string `pulumi:"applicationProviderArn"` 103 // A unique, case-sensitive ID that you provide to ensure the idempotency of the request. AWS generates a random value when not provided. 104 ClientToken *string `pulumi:"clientToken"` 105 // Description of the application. 106 Description *string `pulumi:"description"` 107 // ARN of the instance of IAM Identity Center. 108 InstanceArn *string `pulumi:"instanceArn"` 109 // Name of the application. 110 // 111 // The following arguments are optional: 112 Name *string `pulumi:"name"` 113 // Options for the portal associated with an application. See `portalOptions` below. 114 PortalOptions *ApplicationPortalOptions `pulumi:"portalOptions"` 115 // Status of the application. Valid values are `ENABLED` and `DISABLED`. 116 Status *string `pulumi:"status"` 117 // Key-value mapping of resource tags. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 118 Tags map[string]string `pulumi:"tags"` 119 // Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 120 // 121 // Deprecated: Please use `tags` instead. 122 TagsAll map[string]string `pulumi:"tagsAll"` 123 } 124 125 type ApplicationState struct { 126 // AWS account ID. 127 ApplicationAccount pulumi.StringPtrInput 128 // ARN of the application. 129 ApplicationArn pulumi.StringPtrInput 130 // ARN of the application provider. 131 ApplicationProviderArn pulumi.StringPtrInput 132 // A unique, case-sensitive ID that you provide to ensure the idempotency of the request. AWS generates a random value when not provided. 133 ClientToken pulumi.StringPtrInput 134 // Description of the application. 135 Description pulumi.StringPtrInput 136 // ARN of the instance of IAM Identity Center. 137 InstanceArn pulumi.StringPtrInput 138 // Name of the application. 139 // 140 // The following arguments are optional: 141 Name pulumi.StringPtrInput 142 // Options for the portal associated with an application. See `portalOptions` below. 143 PortalOptions ApplicationPortalOptionsPtrInput 144 // Status of the application. Valid values are `ENABLED` and `DISABLED`. 145 Status pulumi.StringPtrInput 146 // Key-value mapping of resource tags. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 147 Tags pulumi.StringMapInput 148 // Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 149 // 150 // Deprecated: Please use `tags` instead. 151 TagsAll pulumi.StringMapInput 152 } 153 154 func (ApplicationState) ElementType() reflect.Type { 155 return reflect.TypeOf((*applicationState)(nil)).Elem() 156 } 157 158 type applicationArgs struct { 159 // ARN of the application provider. 160 ApplicationProviderArn string `pulumi:"applicationProviderArn"` 161 // A unique, case-sensitive ID that you provide to ensure the idempotency of the request. AWS generates a random value when not provided. 162 ClientToken *string `pulumi:"clientToken"` 163 // Description of the application. 164 Description *string `pulumi:"description"` 165 // ARN of the instance of IAM Identity Center. 166 InstanceArn string `pulumi:"instanceArn"` 167 // Name of the application. 168 // 169 // The following arguments are optional: 170 Name *string `pulumi:"name"` 171 // Options for the portal associated with an application. See `portalOptions` below. 172 PortalOptions *ApplicationPortalOptions `pulumi:"portalOptions"` 173 // Status of the application. Valid values are `ENABLED` and `DISABLED`. 174 Status *string `pulumi:"status"` 175 // Key-value mapping of resource tags. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 176 Tags map[string]string `pulumi:"tags"` 177 } 178 179 // The set of arguments for constructing a Application resource. 180 type ApplicationArgs struct { 181 // ARN of the application provider. 182 ApplicationProviderArn pulumi.StringInput 183 // A unique, case-sensitive ID that you provide to ensure the idempotency of the request. AWS generates a random value when not provided. 184 ClientToken pulumi.StringPtrInput 185 // Description of the application. 186 Description pulumi.StringPtrInput 187 // ARN of the instance of IAM Identity Center. 188 InstanceArn pulumi.StringInput 189 // Name of the application. 190 // 191 // The following arguments are optional: 192 Name pulumi.StringPtrInput 193 // Options for the portal associated with an application. See `portalOptions` below. 194 PortalOptions ApplicationPortalOptionsPtrInput 195 // Status of the application. Valid values are `ENABLED` and `DISABLED`. 196 Status pulumi.StringPtrInput 197 // Key-value mapping of resource tags. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 198 Tags pulumi.StringMapInput 199 } 200 201 func (ApplicationArgs) ElementType() reflect.Type { 202 return reflect.TypeOf((*applicationArgs)(nil)).Elem() 203 } 204 205 type ApplicationInput interface { 206 pulumi.Input 207 208 ToApplicationOutput() ApplicationOutput 209 ToApplicationOutputWithContext(ctx context.Context) ApplicationOutput 210 } 211 212 func (*Application) ElementType() reflect.Type { 213 return reflect.TypeOf((**Application)(nil)).Elem() 214 } 215 216 func (i *Application) ToApplicationOutput() ApplicationOutput { 217 return i.ToApplicationOutputWithContext(context.Background()) 218 } 219 220 func (i *Application) ToApplicationOutputWithContext(ctx context.Context) ApplicationOutput { 221 return pulumi.ToOutputWithContext(ctx, i).(ApplicationOutput) 222 } 223 224 // ApplicationArrayInput is an input type that accepts ApplicationArray and ApplicationArrayOutput values. 225 // You can construct a concrete instance of `ApplicationArrayInput` via: 226 // 227 // ApplicationArray{ ApplicationArgs{...} } 228 type ApplicationArrayInput interface { 229 pulumi.Input 230 231 ToApplicationArrayOutput() ApplicationArrayOutput 232 ToApplicationArrayOutputWithContext(context.Context) ApplicationArrayOutput 233 } 234 235 type ApplicationArray []ApplicationInput 236 237 func (ApplicationArray) ElementType() reflect.Type { 238 return reflect.TypeOf((*[]*Application)(nil)).Elem() 239 } 240 241 func (i ApplicationArray) ToApplicationArrayOutput() ApplicationArrayOutput { 242 return i.ToApplicationArrayOutputWithContext(context.Background()) 243 } 244 245 func (i ApplicationArray) ToApplicationArrayOutputWithContext(ctx context.Context) ApplicationArrayOutput { 246 return pulumi.ToOutputWithContext(ctx, i).(ApplicationArrayOutput) 247 } 248 249 // ApplicationMapInput is an input type that accepts ApplicationMap and ApplicationMapOutput values. 250 // You can construct a concrete instance of `ApplicationMapInput` via: 251 // 252 // ApplicationMap{ "key": ApplicationArgs{...} } 253 type ApplicationMapInput interface { 254 pulumi.Input 255 256 ToApplicationMapOutput() ApplicationMapOutput 257 ToApplicationMapOutputWithContext(context.Context) ApplicationMapOutput 258 } 259 260 type ApplicationMap map[string]ApplicationInput 261 262 func (ApplicationMap) ElementType() reflect.Type { 263 return reflect.TypeOf((*map[string]*Application)(nil)).Elem() 264 } 265 266 func (i ApplicationMap) ToApplicationMapOutput() ApplicationMapOutput { 267 return i.ToApplicationMapOutputWithContext(context.Background()) 268 } 269 270 func (i ApplicationMap) ToApplicationMapOutputWithContext(ctx context.Context) ApplicationMapOutput { 271 return pulumi.ToOutputWithContext(ctx, i).(ApplicationMapOutput) 272 } 273 274 type ApplicationOutput struct{ *pulumi.OutputState } 275 276 func (ApplicationOutput) ElementType() reflect.Type { 277 return reflect.TypeOf((**Application)(nil)).Elem() 278 } 279 280 func (o ApplicationOutput) ToApplicationOutput() ApplicationOutput { 281 return o 282 } 283 284 func (o ApplicationOutput) ToApplicationOutputWithContext(ctx context.Context) ApplicationOutput { 285 return o 286 } 287 288 // AWS account ID. 289 func (o ApplicationOutput) ApplicationAccount() pulumi.StringOutput { 290 return o.ApplyT(func(v *Application) pulumi.StringOutput { return v.ApplicationAccount }).(pulumi.StringOutput) 291 } 292 293 // ARN of the application. 294 func (o ApplicationOutput) ApplicationArn() pulumi.StringOutput { 295 return o.ApplyT(func(v *Application) pulumi.StringOutput { return v.ApplicationArn }).(pulumi.StringOutput) 296 } 297 298 // ARN of the application provider. 299 func (o ApplicationOutput) ApplicationProviderArn() pulumi.StringOutput { 300 return o.ApplyT(func(v *Application) pulumi.StringOutput { return v.ApplicationProviderArn }).(pulumi.StringOutput) 301 } 302 303 // A unique, case-sensitive ID that you provide to ensure the idempotency of the request. AWS generates a random value when not provided. 304 func (o ApplicationOutput) ClientToken() pulumi.StringPtrOutput { 305 return o.ApplyT(func(v *Application) pulumi.StringPtrOutput { return v.ClientToken }).(pulumi.StringPtrOutput) 306 } 307 308 // Description of the application. 309 func (o ApplicationOutput) Description() pulumi.StringPtrOutput { 310 return o.ApplyT(func(v *Application) pulumi.StringPtrOutput { return v.Description }).(pulumi.StringPtrOutput) 311 } 312 313 // ARN of the instance of IAM Identity Center. 314 func (o ApplicationOutput) InstanceArn() pulumi.StringOutput { 315 return o.ApplyT(func(v *Application) pulumi.StringOutput { return v.InstanceArn }).(pulumi.StringOutput) 316 } 317 318 // Name of the application. 319 // 320 // The following arguments are optional: 321 func (o ApplicationOutput) Name() pulumi.StringOutput { 322 return o.ApplyT(func(v *Application) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput) 323 } 324 325 // Options for the portal associated with an application. See `portalOptions` below. 326 func (o ApplicationOutput) PortalOptions() ApplicationPortalOptionsPtrOutput { 327 return o.ApplyT(func(v *Application) ApplicationPortalOptionsPtrOutput { return v.PortalOptions }).(ApplicationPortalOptionsPtrOutput) 328 } 329 330 // Status of the application. Valid values are `ENABLED` and `DISABLED`. 331 func (o ApplicationOutput) Status() pulumi.StringOutput { 332 return o.ApplyT(func(v *Application) pulumi.StringOutput { return v.Status }).(pulumi.StringOutput) 333 } 334 335 // Key-value mapping of resource tags. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 336 func (o ApplicationOutput) Tags() pulumi.StringMapOutput { 337 return o.ApplyT(func(v *Application) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput) 338 } 339 340 // Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 341 // 342 // Deprecated: Please use `tags` instead. 343 func (o ApplicationOutput) TagsAll() pulumi.StringMapOutput { 344 return o.ApplyT(func(v *Application) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput) 345 } 346 347 type ApplicationArrayOutput struct{ *pulumi.OutputState } 348 349 func (ApplicationArrayOutput) ElementType() reflect.Type { 350 return reflect.TypeOf((*[]*Application)(nil)).Elem() 351 } 352 353 func (o ApplicationArrayOutput) ToApplicationArrayOutput() ApplicationArrayOutput { 354 return o 355 } 356 357 func (o ApplicationArrayOutput) ToApplicationArrayOutputWithContext(ctx context.Context) ApplicationArrayOutput { 358 return o 359 } 360 361 func (o ApplicationArrayOutput) Index(i pulumi.IntInput) ApplicationOutput { 362 return pulumi.All(o, i).ApplyT(func(vs []interface{}) *Application { 363 return vs[0].([]*Application)[vs[1].(int)] 364 }).(ApplicationOutput) 365 } 366 367 type ApplicationMapOutput struct{ *pulumi.OutputState } 368 369 func (ApplicationMapOutput) ElementType() reflect.Type { 370 return reflect.TypeOf((*map[string]*Application)(nil)).Elem() 371 } 372 373 func (o ApplicationMapOutput) ToApplicationMapOutput() ApplicationMapOutput { 374 return o 375 } 376 377 func (o ApplicationMapOutput) ToApplicationMapOutputWithContext(ctx context.Context) ApplicationMapOutput { 378 return o 379 } 380 381 func (o ApplicationMapOutput) MapIndex(k pulumi.StringInput) ApplicationOutput { 382 return pulumi.All(o, k).ApplyT(func(vs []interface{}) *Application { 383 return vs[0].(map[string]*Application)[vs[1].(string)] 384 }).(ApplicationOutput) 385 } 386 387 func init() { 388 pulumi.RegisterInputType(reflect.TypeOf((*ApplicationInput)(nil)).Elem(), &Application{}) 389 pulumi.RegisterInputType(reflect.TypeOf((*ApplicationArrayInput)(nil)).Elem(), ApplicationArray{}) 390 pulumi.RegisterInputType(reflect.TypeOf((*ApplicationMapInput)(nil)).Elem(), ApplicationMap{}) 391 pulumi.RegisterOutputType(ApplicationOutput{}) 392 pulumi.RegisterOutputType(ApplicationArrayOutput{}) 393 pulumi.RegisterOutputType(ApplicationMapOutput{}) 394 }