/
account.go
708 lines (636 loc) · 49 KB
/
account.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
// Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package cognitive
import (
"context"
"reflect"
"errors"
"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/internal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Manages a Cognitive Services Account.
//
// > **Note:** Version v2.65.0 of the Azure Provider and later will attempt to Purge the Cognitive Account during deletion. This feature can be disabled using the `features` block within the `provider` block, see the provider documentation on the features block for more information.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/cognitive"
// "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
// Name: pulumi.String("example-resources"),
// Location: pulumi.String("West Europe"),
// })
// if err != nil {
// return err
// }
// _, err = cognitive.NewAccount(ctx, "example", &cognitive.AccountArgs{
// Name: pulumi.String("example-account"),
// Location: example.Location,
// ResourceGroupName: example.Name,
// Kind: pulumi.String("Face"),
// SkuName: pulumi.String("S0"),
// Tags: pulumi.StringMap{
// "Acceptance": pulumi.String("Test"),
// },
// })
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
//
// ## Import
//
// Cognitive Service Accounts can be imported using the `resource id`, e.g.
//
// ```sh
// $ pulumi import azure:cognitive/account:Account account1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.CognitiveServices/accounts/account1
// ```
type Account struct {
pulumi.CustomResourceState
// If `kind` is `TextAnalytics` this specifies the ID of the Search service.
CustomQuestionAnsweringSearchServiceId pulumi.StringPtrOutput `pulumi:"customQuestionAnsweringSearchServiceId"`
// If `kind` is `TextAnalytics` this specifies the key of the Search service.
//
// > **NOTE:** `customQuestionAnsweringSearchServiceId` and `customQuestionAnsweringSearchServiceKey` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qnaRuntimeEndpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
CustomQuestionAnsweringSearchServiceKey pulumi.StringPtrOutput `pulumi:"customQuestionAnsweringSearchServiceKey"`
// The subdomain name used for token-based authentication. This property is required when `networkAcls` is specified. Changing this forces a new resource to be created.
CustomSubdomainName pulumi.StringPtrOutput `pulumi:"customSubdomainName"`
// A `customerManagedKey` block as documented below.
CustomerManagedKey AccountCustomerManagedKeyTypePtrOutput `pulumi:"customerManagedKey"`
// Whether to enable the dynamic throttling for this Cognitive Service Account.
DynamicThrottlingEnabled pulumi.BoolPtrOutput `pulumi:"dynamicThrottlingEnabled"`
// The endpoint used to connect to the Cognitive Service Account.
Endpoint pulumi.StringOutput `pulumi:"endpoint"`
// List of FQDNs allowed for the Cognitive Account.
Fqdns pulumi.StringArrayOutput `pulumi:"fqdns"`
// An `identity` block as defined below.
Identity AccountIdentityPtrOutput `pulumi:"identity"`
// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `ContentSafety`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`, `FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `MetricsAdvisor`, `OpenAI`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
//
// > **NOTE:** New Bing Search resources cannot be created as their APIs are moving from Cognitive Services Platform to new surface area under Microsoft.com. Starting from October 30, 2020, existing instances of Bing Search APIs provisioned via Cognitive Services will be continuously supported for next 3 years or till the end of respective Enterprise Agreement, whichever happens first.
//
// > **NOTE:** You must create your first Face, Text Analytics, or Computer Vision resources from the Azure portal to review and acknowledge the terms and conditions. In Azure Portal, the checkbox to accept terms and conditions is only displayed when a US region is selected. More information on [Prerequisites](https://docs.microsoft.com/azure/cognitive-services/cognitive-services-apis-create-account-cli?tabs=windows#prerequisites).
Kind pulumi.StringOutput `pulumi:"kind"`
// Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
LocalAuthEnabled pulumi.BoolPtrOutput `pulumi:"localAuthEnabled"`
// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
Location pulumi.StringOutput `pulumi:"location"`
// The Azure AD Client ID (Application ID). This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadClientId pulumi.StringPtrOutput `pulumi:"metricsAdvisorAadClientId"`
// The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadTenantId pulumi.StringPtrOutput `pulumi:"metricsAdvisorAadTenantId"`
// The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorSuperUserName pulumi.StringPtrOutput `pulumi:"metricsAdvisorSuperUserName"`
// The website name of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
//
// > **NOTE:** This URL is mandatory if the `kind` is set to `QnAMaker`.
MetricsAdvisorWebsiteName pulumi.StringPtrOutput `pulumi:"metricsAdvisorWebsiteName"`
// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
Name pulumi.StringOutput `pulumi:"name"`
// A `networkAcls` block as defined below. When this property is specified, `customSubdomainName` is also required to be set.
NetworkAcls AccountNetworkAclsPtrOutput `pulumi:"networkAcls"`
// Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
OutboundNetworkAccessRestricted pulumi.BoolPtrOutput `pulumi:"outboundNetworkAccessRestricted"`
// A primary access key which can be used to connect to the Cognitive Service Account.
PrimaryAccessKey pulumi.StringOutput `pulumi:"primaryAccessKey"`
// Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
PublicNetworkAccessEnabled pulumi.BoolPtrOutput `pulumi:"publicNetworkAccessEnabled"`
// A URL to link a QnAMaker cognitive account to a QnA runtime.
QnaRuntimeEndpoint pulumi.StringPtrOutput `pulumi:"qnaRuntimeEndpoint"`
// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
ResourceGroupName pulumi.StringOutput `pulumi:"resourceGroupName"`
// The secondary access key which can be used to connect to the Cognitive Service Account.
SecondaryAccessKey pulumi.StringOutput `pulumi:"secondaryAccessKey"`
// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S0`, `S`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, `P2`, `E0` and `DC0`.
//
// > **NOTE:** SKU `DC0` is the commitment tier for Cognitive Services containers running in disconnected environments. You must obtain approval from Microsoft by submitting the [request form](https://aka.ms/csdisconnectedcontainers) first, before you can use this SKU. More information on [Purchase a commitment plan to use containers in disconnected environments](https://learn.microsoft.com/en-us/azure/cognitive-services/containers/disconnected-containers?tabs=stt#purchase-a-commitment-plan-to-use-containers-in-disconnected-environments).
SkuName pulumi.StringOutput `pulumi:"skuName"`
// A `storage` block as defined below.
Storages AccountStorageArrayOutput `pulumi:"storages"`
// A mapping of tags to assign to the resource.
Tags pulumi.StringMapOutput `pulumi:"tags"`
}
// NewAccount registers a new resource with the given unique name, arguments, and options.
func NewAccount(ctx *pulumi.Context,
name string, args *AccountArgs, opts ...pulumi.ResourceOption) (*Account, error) {
if args == nil {
return nil, errors.New("missing one or more required arguments")
}
if args.Kind == nil {
return nil, errors.New("invalid value for required argument 'Kind'")
}
if args.ResourceGroupName == nil {
return nil, errors.New("invalid value for required argument 'ResourceGroupName'")
}
if args.SkuName == nil {
return nil, errors.New("invalid value for required argument 'SkuName'")
}
if args.CustomQuestionAnsweringSearchServiceKey != nil {
args.CustomQuestionAnsweringSearchServiceKey = pulumi.ToSecret(args.CustomQuestionAnsweringSearchServiceKey).(pulumi.StringPtrInput)
}
secrets := pulumi.AdditionalSecretOutputs([]string{
"customQuestionAnsweringSearchServiceKey",
"primaryAccessKey",
"secondaryAccessKey",
})
opts = append(opts, secrets)
opts = internal.PkgResourceDefaultOpts(opts)
var resource Account
err := ctx.RegisterResource("azure:cognitive/account:Account", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetAccount gets an existing Account resource's state with the given name, ID, and optional
// state properties that are used to uniquely qualify the lookup (nil if not required).
func GetAccount(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *AccountState, opts ...pulumi.ResourceOption) (*Account, error) {
var resource Account
err := ctx.ReadResource("azure:cognitive/account:Account", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering Account resources.
type accountState struct {
// If `kind` is `TextAnalytics` this specifies the ID of the Search service.
CustomQuestionAnsweringSearchServiceId *string `pulumi:"customQuestionAnsweringSearchServiceId"`
// If `kind` is `TextAnalytics` this specifies the key of the Search service.
//
// > **NOTE:** `customQuestionAnsweringSearchServiceId` and `customQuestionAnsweringSearchServiceKey` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qnaRuntimeEndpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
CustomQuestionAnsweringSearchServiceKey *string `pulumi:"customQuestionAnsweringSearchServiceKey"`
// The subdomain name used for token-based authentication. This property is required when `networkAcls` is specified. Changing this forces a new resource to be created.
CustomSubdomainName *string `pulumi:"customSubdomainName"`
// A `customerManagedKey` block as documented below.
CustomerManagedKey *AccountCustomerManagedKeyType `pulumi:"customerManagedKey"`
// Whether to enable the dynamic throttling for this Cognitive Service Account.
DynamicThrottlingEnabled *bool `pulumi:"dynamicThrottlingEnabled"`
// The endpoint used to connect to the Cognitive Service Account.
Endpoint *string `pulumi:"endpoint"`
// List of FQDNs allowed for the Cognitive Account.
Fqdns []string `pulumi:"fqdns"`
// An `identity` block as defined below.
Identity *AccountIdentity `pulumi:"identity"`
// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `ContentSafety`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`, `FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `MetricsAdvisor`, `OpenAI`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
//
// > **NOTE:** New Bing Search resources cannot be created as their APIs are moving from Cognitive Services Platform to new surface area under Microsoft.com. Starting from October 30, 2020, existing instances of Bing Search APIs provisioned via Cognitive Services will be continuously supported for next 3 years or till the end of respective Enterprise Agreement, whichever happens first.
//
// > **NOTE:** You must create your first Face, Text Analytics, or Computer Vision resources from the Azure portal to review and acknowledge the terms and conditions. In Azure Portal, the checkbox to accept terms and conditions is only displayed when a US region is selected. More information on [Prerequisites](https://docs.microsoft.com/azure/cognitive-services/cognitive-services-apis-create-account-cli?tabs=windows#prerequisites).
Kind *string `pulumi:"kind"`
// Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
LocalAuthEnabled *bool `pulumi:"localAuthEnabled"`
// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
Location *string `pulumi:"location"`
// The Azure AD Client ID (Application ID). This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadClientId *string `pulumi:"metricsAdvisorAadClientId"`
// The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadTenantId *string `pulumi:"metricsAdvisorAadTenantId"`
// The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorSuperUserName *string `pulumi:"metricsAdvisorSuperUserName"`
// The website name of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
//
// > **NOTE:** This URL is mandatory if the `kind` is set to `QnAMaker`.
MetricsAdvisorWebsiteName *string `pulumi:"metricsAdvisorWebsiteName"`
// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
Name *string `pulumi:"name"`
// A `networkAcls` block as defined below. When this property is specified, `customSubdomainName` is also required to be set.
NetworkAcls *AccountNetworkAcls `pulumi:"networkAcls"`
// Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
OutboundNetworkAccessRestricted *bool `pulumi:"outboundNetworkAccessRestricted"`
// A primary access key which can be used to connect to the Cognitive Service Account.
PrimaryAccessKey *string `pulumi:"primaryAccessKey"`
// Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
PublicNetworkAccessEnabled *bool `pulumi:"publicNetworkAccessEnabled"`
// A URL to link a QnAMaker cognitive account to a QnA runtime.
QnaRuntimeEndpoint *string `pulumi:"qnaRuntimeEndpoint"`
// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
ResourceGroupName *string `pulumi:"resourceGroupName"`
// The secondary access key which can be used to connect to the Cognitive Service Account.
SecondaryAccessKey *string `pulumi:"secondaryAccessKey"`
// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S0`, `S`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, `P2`, `E0` and `DC0`.
//
// > **NOTE:** SKU `DC0` is the commitment tier for Cognitive Services containers running in disconnected environments. You must obtain approval from Microsoft by submitting the [request form](https://aka.ms/csdisconnectedcontainers) first, before you can use this SKU. More information on [Purchase a commitment plan to use containers in disconnected environments](https://learn.microsoft.com/en-us/azure/cognitive-services/containers/disconnected-containers?tabs=stt#purchase-a-commitment-plan-to-use-containers-in-disconnected-environments).
SkuName *string `pulumi:"skuName"`
// A `storage` block as defined below.
Storages []AccountStorage `pulumi:"storages"`
// A mapping of tags to assign to the resource.
Tags map[string]string `pulumi:"tags"`
}
type AccountState struct {
// If `kind` is `TextAnalytics` this specifies the ID of the Search service.
CustomQuestionAnsweringSearchServiceId pulumi.StringPtrInput
// If `kind` is `TextAnalytics` this specifies the key of the Search service.
//
// > **NOTE:** `customQuestionAnsweringSearchServiceId` and `customQuestionAnsweringSearchServiceKey` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qnaRuntimeEndpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
CustomQuestionAnsweringSearchServiceKey pulumi.StringPtrInput
// The subdomain name used for token-based authentication. This property is required when `networkAcls` is specified. Changing this forces a new resource to be created.
CustomSubdomainName pulumi.StringPtrInput
// A `customerManagedKey` block as documented below.
CustomerManagedKey AccountCustomerManagedKeyTypePtrInput
// Whether to enable the dynamic throttling for this Cognitive Service Account.
DynamicThrottlingEnabled pulumi.BoolPtrInput
// The endpoint used to connect to the Cognitive Service Account.
Endpoint pulumi.StringPtrInput
// List of FQDNs allowed for the Cognitive Account.
Fqdns pulumi.StringArrayInput
// An `identity` block as defined below.
Identity AccountIdentityPtrInput
// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `ContentSafety`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`, `FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `MetricsAdvisor`, `OpenAI`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
//
// > **NOTE:** New Bing Search resources cannot be created as their APIs are moving from Cognitive Services Platform to new surface area under Microsoft.com. Starting from October 30, 2020, existing instances of Bing Search APIs provisioned via Cognitive Services will be continuously supported for next 3 years or till the end of respective Enterprise Agreement, whichever happens first.
//
// > **NOTE:** You must create your first Face, Text Analytics, or Computer Vision resources from the Azure portal to review and acknowledge the terms and conditions. In Azure Portal, the checkbox to accept terms and conditions is only displayed when a US region is selected. More information on [Prerequisites](https://docs.microsoft.com/azure/cognitive-services/cognitive-services-apis-create-account-cli?tabs=windows#prerequisites).
Kind pulumi.StringPtrInput
// Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
LocalAuthEnabled pulumi.BoolPtrInput
// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
Location pulumi.StringPtrInput
// The Azure AD Client ID (Application ID). This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadClientId pulumi.StringPtrInput
// The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadTenantId pulumi.StringPtrInput
// The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorSuperUserName pulumi.StringPtrInput
// The website name of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
//
// > **NOTE:** This URL is mandatory if the `kind` is set to `QnAMaker`.
MetricsAdvisorWebsiteName pulumi.StringPtrInput
// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
Name pulumi.StringPtrInput
// A `networkAcls` block as defined below. When this property is specified, `customSubdomainName` is also required to be set.
NetworkAcls AccountNetworkAclsPtrInput
// Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
OutboundNetworkAccessRestricted pulumi.BoolPtrInput
// A primary access key which can be used to connect to the Cognitive Service Account.
PrimaryAccessKey pulumi.StringPtrInput
// Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
PublicNetworkAccessEnabled pulumi.BoolPtrInput
// A URL to link a QnAMaker cognitive account to a QnA runtime.
QnaRuntimeEndpoint pulumi.StringPtrInput
// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
ResourceGroupName pulumi.StringPtrInput
// The secondary access key which can be used to connect to the Cognitive Service Account.
SecondaryAccessKey pulumi.StringPtrInput
// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S0`, `S`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, `P2`, `E0` and `DC0`.
//
// > **NOTE:** SKU `DC0` is the commitment tier for Cognitive Services containers running in disconnected environments. You must obtain approval from Microsoft by submitting the [request form](https://aka.ms/csdisconnectedcontainers) first, before you can use this SKU. More information on [Purchase a commitment plan to use containers in disconnected environments](https://learn.microsoft.com/en-us/azure/cognitive-services/containers/disconnected-containers?tabs=stt#purchase-a-commitment-plan-to-use-containers-in-disconnected-environments).
SkuName pulumi.StringPtrInput
// A `storage` block as defined below.
Storages AccountStorageArrayInput
// A mapping of tags to assign to the resource.
Tags pulumi.StringMapInput
}
func (AccountState) ElementType() reflect.Type {
return reflect.TypeOf((*accountState)(nil)).Elem()
}
type accountArgs struct {
// If `kind` is `TextAnalytics` this specifies the ID of the Search service.
CustomQuestionAnsweringSearchServiceId *string `pulumi:"customQuestionAnsweringSearchServiceId"`
// If `kind` is `TextAnalytics` this specifies the key of the Search service.
//
// > **NOTE:** `customQuestionAnsweringSearchServiceId` and `customQuestionAnsweringSearchServiceKey` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qnaRuntimeEndpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
CustomQuestionAnsweringSearchServiceKey *string `pulumi:"customQuestionAnsweringSearchServiceKey"`
// The subdomain name used for token-based authentication. This property is required when `networkAcls` is specified. Changing this forces a new resource to be created.
CustomSubdomainName *string `pulumi:"customSubdomainName"`
// A `customerManagedKey` block as documented below.
CustomerManagedKey *AccountCustomerManagedKeyType `pulumi:"customerManagedKey"`
// Whether to enable the dynamic throttling for this Cognitive Service Account.
DynamicThrottlingEnabled *bool `pulumi:"dynamicThrottlingEnabled"`
// List of FQDNs allowed for the Cognitive Account.
Fqdns []string `pulumi:"fqdns"`
// An `identity` block as defined below.
Identity *AccountIdentity `pulumi:"identity"`
// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `ContentSafety`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`, `FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `MetricsAdvisor`, `OpenAI`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
//
// > **NOTE:** New Bing Search resources cannot be created as their APIs are moving from Cognitive Services Platform to new surface area under Microsoft.com. Starting from October 30, 2020, existing instances of Bing Search APIs provisioned via Cognitive Services will be continuously supported for next 3 years or till the end of respective Enterprise Agreement, whichever happens first.
//
// > **NOTE:** You must create your first Face, Text Analytics, or Computer Vision resources from the Azure portal to review and acknowledge the terms and conditions. In Azure Portal, the checkbox to accept terms and conditions is only displayed when a US region is selected. More information on [Prerequisites](https://docs.microsoft.com/azure/cognitive-services/cognitive-services-apis-create-account-cli?tabs=windows#prerequisites).
Kind string `pulumi:"kind"`
// Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
LocalAuthEnabled *bool `pulumi:"localAuthEnabled"`
// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
Location *string `pulumi:"location"`
// The Azure AD Client ID (Application ID). This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadClientId *string `pulumi:"metricsAdvisorAadClientId"`
// The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadTenantId *string `pulumi:"metricsAdvisorAadTenantId"`
// The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorSuperUserName *string `pulumi:"metricsAdvisorSuperUserName"`
// The website name of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
//
// > **NOTE:** This URL is mandatory if the `kind` is set to `QnAMaker`.
MetricsAdvisorWebsiteName *string `pulumi:"metricsAdvisorWebsiteName"`
// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
Name *string `pulumi:"name"`
// A `networkAcls` block as defined below. When this property is specified, `customSubdomainName` is also required to be set.
NetworkAcls *AccountNetworkAcls `pulumi:"networkAcls"`
// Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
OutboundNetworkAccessRestricted *bool `pulumi:"outboundNetworkAccessRestricted"`
// Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
PublicNetworkAccessEnabled *bool `pulumi:"publicNetworkAccessEnabled"`
// A URL to link a QnAMaker cognitive account to a QnA runtime.
QnaRuntimeEndpoint *string `pulumi:"qnaRuntimeEndpoint"`
// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
ResourceGroupName string `pulumi:"resourceGroupName"`
// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S0`, `S`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, `P2`, `E0` and `DC0`.
//
// > **NOTE:** SKU `DC0` is the commitment tier for Cognitive Services containers running in disconnected environments. You must obtain approval from Microsoft by submitting the [request form](https://aka.ms/csdisconnectedcontainers) first, before you can use this SKU. More information on [Purchase a commitment plan to use containers in disconnected environments](https://learn.microsoft.com/en-us/azure/cognitive-services/containers/disconnected-containers?tabs=stt#purchase-a-commitment-plan-to-use-containers-in-disconnected-environments).
SkuName string `pulumi:"skuName"`
// A `storage` block as defined below.
Storages []AccountStorage `pulumi:"storages"`
// A mapping of tags to assign to the resource.
Tags map[string]string `pulumi:"tags"`
}
// The set of arguments for constructing a Account resource.
type AccountArgs struct {
// If `kind` is `TextAnalytics` this specifies the ID of the Search service.
CustomQuestionAnsweringSearchServiceId pulumi.StringPtrInput
// If `kind` is `TextAnalytics` this specifies the key of the Search service.
//
// > **NOTE:** `customQuestionAnsweringSearchServiceId` and `customQuestionAnsweringSearchServiceKey` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qnaRuntimeEndpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
CustomQuestionAnsweringSearchServiceKey pulumi.StringPtrInput
// The subdomain name used for token-based authentication. This property is required when `networkAcls` is specified. Changing this forces a new resource to be created.
CustomSubdomainName pulumi.StringPtrInput
// A `customerManagedKey` block as documented below.
CustomerManagedKey AccountCustomerManagedKeyTypePtrInput
// Whether to enable the dynamic throttling for this Cognitive Service Account.
DynamicThrottlingEnabled pulumi.BoolPtrInput
// List of FQDNs allowed for the Cognitive Account.
Fqdns pulumi.StringArrayInput
// An `identity` block as defined below.
Identity AccountIdentityPtrInput
// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `ContentSafety`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`, `FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `MetricsAdvisor`, `OpenAI`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
//
// > **NOTE:** New Bing Search resources cannot be created as their APIs are moving from Cognitive Services Platform to new surface area under Microsoft.com. Starting from October 30, 2020, existing instances of Bing Search APIs provisioned via Cognitive Services will be continuously supported for next 3 years or till the end of respective Enterprise Agreement, whichever happens first.
//
// > **NOTE:** You must create your first Face, Text Analytics, or Computer Vision resources from the Azure portal to review and acknowledge the terms and conditions. In Azure Portal, the checkbox to accept terms and conditions is only displayed when a US region is selected. More information on [Prerequisites](https://docs.microsoft.com/azure/cognitive-services/cognitive-services-apis-create-account-cli?tabs=windows#prerequisites).
Kind pulumi.StringInput
// Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
LocalAuthEnabled pulumi.BoolPtrInput
// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
Location pulumi.StringPtrInput
// The Azure AD Client ID (Application ID). This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadClientId pulumi.StringPtrInput
// The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorAadTenantId pulumi.StringPtrInput
// The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
MetricsAdvisorSuperUserName pulumi.StringPtrInput
// The website name of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
//
// > **NOTE:** This URL is mandatory if the `kind` is set to `QnAMaker`.
MetricsAdvisorWebsiteName pulumi.StringPtrInput
// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
Name pulumi.StringPtrInput
// A `networkAcls` block as defined below. When this property is specified, `customSubdomainName` is also required to be set.
NetworkAcls AccountNetworkAclsPtrInput
// Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
OutboundNetworkAccessRestricted pulumi.BoolPtrInput
// Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
PublicNetworkAccessEnabled pulumi.BoolPtrInput
// A URL to link a QnAMaker cognitive account to a QnA runtime.
QnaRuntimeEndpoint pulumi.StringPtrInput
// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
ResourceGroupName pulumi.StringInput
// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S0`, `S`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, `P2`, `E0` and `DC0`.
//
// > **NOTE:** SKU `DC0` is the commitment tier for Cognitive Services containers running in disconnected environments. You must obtain approval from Microsoft by submitting the [request form](https://aka.ms/csdisconnectedcontainers) first, before you can use this SKU. More information on [Purchase a commitment plan to use containers in disconnected environments](https://learn.microsoft.com/en-us/azure/cognitive-services/containers/disconnected-containers?tabs=stt#purchase-a-commitment-plan-to-use-containers-in-disconnected-environments).
SkuName pulumi.StringInput
// A `storage` block as defined below.
Storages AccountStorageArrayInput
// A mapping of tags to assign to the resource.
Tags pulumi.StringMapInput
}
func (AccountArgs) ElementType() reflect.Type {
return reflect.TypeOf((*accountArgs)(nil)).Elem()
}
type AccountInput interface {
pulumi.Input
ToAccountOutput() AccountOutput
ToAccountOutputWithContext(ctx context.Context) AccountOutput
}
func (*Account) ElementType() reflect.Type {
return reflect.TypeOf((**Account)(nil)).Elem()
}
func (i *Account) ToAccountOutput() AccountOutput {
return i.ToAccountOutputWithContext(context.Background())
}
func (i *Account) ToAccountOutputWithContext(ctx context.Context) AccountOutput {
return pulumi.ToOutputWithContext(ctx, i).(AccountOutput)
}
// AccountArrayInput is an input type that accepts AccountArray and AccountArrayOutput values.
// You can construct a concrete instance of `AccountArrayInput` via:
//
// AccountArray{ AccountArgs{...} }
type AccountArrayInput interface {
pulumi.Input
ToAccountArrayOutput() AccountArrayOutput
ToAccountArrayOutputWithContext(context.Context) AccountArrayOutput
}
type AccountArray []AccountInput
func (AccountArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*Account)(nil)).Elem()
}
func (i AccountArray) ToAccountArrayOutput() AccountArrayOutput {
return i.ToAccountArrayOutputWithContext(context.Background())
}
func (i AccountArray) ToAccountArrayOutputWithContext(ctx context.Context) AccountArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(AccountArrayOutput)
}
// AccountMapInput is an input type that accepts AccountMap and AccountMapOutput values.
// You can construct a concrete instance of `AccountMapInput` via:
//
// AccountMap{ "key": AccountArgs{...} }
type AccountMapInput interface {
pulumi.Input
ToAccountMapOutput() AccountMapOutput
ToAccountMapOutputWithContext(context.Context) AccountMapOutput
}
type AccountMap map[string]AccountInput
func (AccountMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*Account)(nil)).Elem()
}
func (i AccountMap) ToAccountMapOutput() AccountMapOutput {
return i.ToAccountMapOutputWithContext(context.Background())
}
func (i AccountMap) ToAccountMapOutputWithContext(ctx context.Context) AccountMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(AccountMapOutput)
}
type AccountOutput struct{ *pulumi.OutputState }
func (AccountOutput) ElementType() reflect.Type {
return reflect.TypeOf((**Account)(nil)).Elem()
}
func (o AccountOutput) ToAccountOutput() AccountOutput {
return o
}
func (o AccountOutput) ToAccountOutputWithContext(ctx context.Context) AccountOutput {
return o
}
// If `kind` is `TextAnalytics` this specifies the ID of the Search service.
func (o AccountOutput) CustomQuestionAnsweringSearchServiceId() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.CustomQuestionAnsweringSearchServiceId }).(pulumi.StringPtrOutput)
}
// If `kind` is `TextAnalytics` this specifies the key of the Search service.
//
// > **NOTE:** `customQuestionAnsweringSearchServiceId` and `customQuestionAnsweringSearchServiceKey` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qnaRuntimeEndpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
func (o AccountOutput) CustomQuestionAnsweringSearchServiceKey() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.CustomQuestionAnsweringSearchServiceKey }).(pulumi.StringPtrOutput)
}
// The subdomain name used for token-based authentication. This property is required when `networkAcls` is specified. Changing this forces a new resource to be created.
func (o AccountOutput) CustomSubdomainName() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.CustomSubdomainName }).(pulumi.StringPtrOutput)
}
// A `customerManagedKey` block as documented below.
func (o AccountOutput) CustomerManagedKey() AccountCustomerManagedKeyTypePtrOutput {
return o.ApplyT(func(v *Account) AccountCustomerManagedKeyTypePtrOutput { return v.CustomerManagedKey }).(AccountCustomerManagedKeyTypePtrOutput)
}
// Whether to enable the dynamic throttling for this Cognitive Service Account.
func (o AccountOutput) DynamicThrottlingEnabled() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Account) pulumi.BoolPtrOutput { return v.DynamicThrottlingEnabled }).(pulumi.BoolPtrOutput)
}
// The endpoint used to connect to the Cognitive Service Account.
func (o AccountOutput) Endpoint() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.Endpoint }).(pulumi.StringOutput)
}
// List of FQDNs allowed for the Cognitive Account.
func (o AccountOutput) Fqdns() pulumi.StringArrayOutput {
return o.ApplyT(func(v *Account) pulumi.StringArrayOutput { return v.Fqdns }).(pulumi.StringArrayOutput)
}
// An `identity` block as defined below.
func (o AccountOutput) Identity() AccountIdentityPtrOutput {
return o.ApplyT(func(v *Account) AccountIdentityPtrOutput { return v.Identity }).(AccountIdentityPtrOutput)
}
// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `ContentSafety`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`, `FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `MetricsAdvisor`, `OpenAI`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
//
// > **NOTE:** New Bing Search resources cannot be created as their APIs are moving from Cognitive Services Platform to new surface area under Microsoft.com. Starting from October 30, 2020, existing instances of Bing Search APIs provisioned via Cognitive Services will be continuously supported for next 3 years or till the end of respective Enterprise Agreement, whichever happens first.
//
// > **NOTE:** You must create your first Face, Text Analytics, or Computer Vision resources from the Azure portal to review and acknowledge the terms and conditions. In Azure Portal, the checkbox to accept terms and conditions is only displayed when a US region is selected. More information on [Prerequisites](https://docs.microsoft.com/azure/cognitive-services/cognitive-services-apis-create-account-cli?tabs=windows#prerequisites).
func (o AccountOutput) Kind() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.Kind }).(pulumi.StringOutput)
}
// Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
func (o AccountOutput) LocalAuthEnabled() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Account) pulumi.BoolPtrOutput { return v.LocalAuthEnabled }).(pulumi.BoolPtrOutput)
}
// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
func (o AccountOutput) Location() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.Location }).(pulumi.StringOutput)
}
// The Azure AD Client ID (Application ID). This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
func (o AccountOutput) MetricsAdvisorAadClientId() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.MetricsAdvisorAadClientId }).(pulumi.StringPtrOutput)
}
// The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
func (o AccountOutput) MetricsAdvisorAadTenantId() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.MetricsAdvisorAadTenantId }).(pulumi.StringPtrOutput)
}
// The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
func (o AccountOutput) MetricsAdvisorSuperUserName() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.MetricsAdvisorSuperUserName }).(pulumi.StringPtrOutput)
}
// The website name of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
//
// > **NOTE:** This URL is mandatory if the `kind` is set to `QnAMaker`.
func (o AccountOutput) MetricsAdvisorWebsiteName() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.MetricsAdvisorWebsiteName }).(pulumi.StringPtrOutput)
}
// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
func (o AccountOutput) Name() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput)
}
// A `networkAcls` block as defined below. When this property is specified, `customSubdomainName` is also required to be set.
func (o AccountOutput) NetworkAcls() AccountNetworkAclsPtrOutput {
return o.ApplyT(func(v *Account) AccountNetworkAclsPtrOutput { return v.NetworkAcls }).(AccountNetworkAclsPtrOutput)
}
// Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
func (o AccountOutput) OutboundNetworkAccessRestricted() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Account) pulumi.BoolPtrOutput { return v.OutboundNetworkAccessRestricted }).(pulumi.BoolPtrOutput)
}
// A primary access key which can be used to connect to the Cognitive Service Account.
func (o AccountOutput) PrimaryAccessKey() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.PrimaryAccessKey }).(pulumi.StringOutput)
}
// Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
func (o AccountOutput) PublicNetworkAccessEnabled() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *Account) pulumi.BoolPtrOutput { return v.PublicNetworkAccessEnabled }).(pulumi.BoolPtrOutput)
}
// A URL to link a QnAMaker cognitive account to a QnA runtime.
func (o AccountOutput) QnaRuntimeEndpoint() pulumi.StringPtrOutput {
return o.ApplyT(func(v *Account) pulumi.StringPtrOutput { return v.QnaRuntimeEndpoint }).(pulumi.StringPtrOutput)
}
// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
func (o AccountOutput) ResourceGroupName() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.ResourceGroupName }).(pulumi.StringOutput)
}
// The secondary access key which can be used to connect to the Cognitive Service Account.
func (o AccountOutput) SecondaryAccessKey() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.SecondaryAccessKey }).(pulumi.StringOutput)
}
// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S0`, `S`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, `P2`, `E0` and `DC0`.
//
// > **NOTE:** SKU `DC0` is the commitment tier for Cognitive Services containers running in disconnected environments. You must obtain approval from Microsoft by submitting the [request form](https://aka.ms/csdisconnectedcontainers) first, before you can use this SKU. More information on [Purchase a commitment plan to use containers in disconnected environments](https://learn.microsoft.com/en-us/azure/cognitive-services/containers/disconnected-containers?tabs=stt#purchase-a-commitment-plan-to-use-containers-in-disconnected-environments).
func (o AccountOutput) SkuName() pulumi.StringOutput {
return o.ApplyT(func(v *Account) pulumi.StringOutput { return v.SkuName }).(pulumi.StringOutput)
}
// A `storage` block as defined below.
func (o AccountOutput) Storages() AccountStorageArrayOutput {
return o.ApplyT(func(v *Account) AccountStorageArrayOutput { return v.Storages }).(AccountStorageArrayOutput)
}
// A mapping of tags to assign to the resource.
func (o AccountOutput) Tags() pulumi.StringMapOutput {
return o.ApplyT(func(v *Account) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput)
}
type AccountArrayOutput struct{ *pulumi.OutputState }
func (AccountArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*Account)(nil)).Elem()
}
func (o AccountArrayOutput) ToAccountArrayOutput() AccountArrayOutput {
return o
}
func (o AccountArrayOutput) ToAccountArrayOutputWithContext(ctx context.Context) AccountArrayOutput {
return o
}
func (o AccountArrayOutput) Index(i pulumi.IntInput) AccountOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *Account {
return vs[0].([]*Account)[vs[1].(int)]
}).(AccountOutput)
}
type AccountMapOutput struct{ *pulumi.OutputState }
func (AccountMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*Account)(nil)).Elem()
}
func (o AccountMapOutput) ToAccountMapOutput() AccountMapOutput {
return o
}
func (o AccountMapOutput) ToAccountMapOutputWithContext(ctx context.Context) AccountMapOutput {
return o
}
func (o AccountMapOutput) MapIndex(k pulumi.StringInput) AccountOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *Account {
return vs[0].(map[string]*Account)[vs[1].(string)]
}).(AccountOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*AccountInput)(nil)).Elem(), &Account{})
pulumi.RegisterInputType(reflect.TypeOf((*AccountArrayInput)(nil)).Elem(), AccountArray{})
pulumi.RegisterInputType(reflect.TypeOf((*AccountMapInput)(nil)).Elem(), AccountMap{})
pulumi.RegisterOutputType(AccountOutput{})
pulumi.RegisterOutputType(AccountArrayOutput{})
pulumi.RegisterOutputType(AccountMapOutput{})
}