All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azure.cognitive.kotlin.AccountArgs.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.cognitive.kotlin

import com.pulumi.azure.cognitive.AccountArgs.builder
import com.pulumi.azure.cognitive.kotlin.inputs.AccountCustomerManagedKeyArgs
import com.pulumi.azure.cognitive.kotlin.inputs.AccountCustomerManagedKeyArgsBuilder
import com.pulumi.azure.cognitive.kotlin.inputs.AccountIdentityArgs
import com.pulumi.azure.cognitive.kotlin.inputs.AccountIdentityArgsBuilder
import com.pulumi.azure.cognitive.kotlin.inputs.AccountNetworkAclsArgs
import com.pulumi.azure.cognitive.kotlin.inputs.AccountNetworkAclsArgsBuilder
import com.pulumi.azure.cognitive.kotlin.inputs.AccountStorageArgs
import com.pulumi.azure.cognitive.kotlin.inputs.AccountStorageArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 * 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
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 * const example = new azure.core.ResourceGroup("example", {
 *     name: "example-resources",
 *     location: "West Europe",
 * });
 * const exampleAccount = new azure.cognitive.Account("example", {
 *     name: "example-account",
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     kind: "Face",
 *     skuName: "S0",
 *     tags: {
 *         Acceptance: "Test",
 *     },
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_azure as azure
 * example = azure.core.ResourceGroup("example",
 *     name="example-resources",
 *     location="West Europe")
 * example_account = azure.cognitive.Account("example",
 *     name="example-account",
 *     location=example.location,
 *     resource_group_name=example.name,
 *     kind="Face",
 *     sku_name="S0",
 *     tags={
 *         "Acceptance": "Test",
 *     })
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Azure = Pulumi.Azure;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Azure.Core.ResourceGroup("example", new()
 *     {
 *         Name = "example-resources",
 *         Location = "West Europe",
 *     });
 *     var exampleAccount = new Azure.Cognitive.Account("example", new()
 *     {
 *         Name = "example-account",
 *         Location = example.Location,
 *         ResourceGroupName = example.Name,
 *         Kind = "Face",
 *         SkuName = "S0",
 *         Tags =
 *         {
 *             { "Acceptance", "Test" },
 *         },
 *     });
 * });
 * ```
 * ```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
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azure.core.ResourceGroup;
 * import com.pulumi.azure.core.ResourceGroupArgs;
 * import com.pulumi.azure.cognitive.Account;
 * import com.pulumi.azure.cognitive.AccountArgs;
 * 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) {
 *         var example = new ResourceGroup("example", ResourceGroupArgs.builder()
 *             .name("example-resources")
 *             .location("West Europe")
 *             .build());
 *         var exampleAccount = new Account("exampleAccount", AccountArgs.builder()
 *             .name("example-account")
 *             .location(example.location())
 *             .resourceGroupName(example.name())
 *             .kind("Face")
 *             .skuName("S0")
 *             .tags(Map.of("Acceptance", "Test"))
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: azure:core:ResourceGroup
 *     properties:
 *       name: example-resources
 *       location: West Europe
 *   exampleAccount:
 *     type: azure:cognitive:Account
 *     name: example
 *     properties:
 *       name: example-account
 *       location: ${example.location}
 *       resourceGroupName: ${example.name}
 *       kind: Face
 *       skuName: S0
 *       tags:
 *         Acceptance: Test
 * ```
 * 
 * ## 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
 * ```
 * @property customQuestionAnsweringSearchServiceId If `kind` is `TextAnalytics` this specifies the ID of the Search service.
 * @property customQuestionAnsweringSearchServiceKey If `kind` is `TextAnalytics` this specifies the key of the Search service.
 * > **NOTE:** `custom_question_answering_search_service_id` and `custom_question_answering_search_service_key` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qna_runtime_endpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
 * @property customSubdomainName The subdomain name used for token-based authentication. This property is required when `network_acls` is specified. This property is also required when using the OpenAI service with libraries which assume the Azure OpenAI endpoint is a subdomain on `https://openai.azure.com/`, eg. `https://.openai.azure.com/`.  Changing this forces a new resource to be created.
 * @property customerManagedKey A `customer_managed_key` block as documented below.
 * @property dynamicThrottlingEnabled Whether to enable the dynamic throttling for this Cognitive Service Account.
 * @property fqdns List of FQDNs allowed for the Cognitive Account.
 * @property identity An `identity` block as defined below.
 * @property kind 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).
 * @property localAuthEnabled Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
 * @property location Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
 * @property metricsAdvisorAadClientId 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.
 * @property metricsAdvisorAadTenantId The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
 * @property metricsAdvisorSuperUserName The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
 * @property metricsAdvisorWebsiteName 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`.
 * @property name Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
 * @property networkAcls A `network_acls` block as defined below. When this property is specified, `custom_subdomain_name` is also required to be set.
 * @property outboundNetworkAccessRestricted Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
 * @property publicNetworkAccessEnabled Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
 * @property qnaRuntimeEndpoint A URL to link a QnAMaker cognitive account to a QnA runtime.
 * @property resourceGroupName The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
 * @property skuName 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).
 * @property storages A `storage` block as defined below.
 * @property tags A mapping of tags to assign to the resource.
 */
public data class AccountArgs(
    public val customQuestionAnsweringSearchServiceId: Output? = null,
    public val customQuestionAnsweringSearchServiceKey: Output? = null,
    public val customSubdomainName: Output? = null,
    public val customerManagedKey: Output? = null,
    public val dynamicThrottlingEnabled: Output? = null,
    public val fqdns: Output>? = null,
    public val identity: Output? = null,
    public val kind: Output? = null,
    public val localAuthEnabled: Output? = null,
    public val location: Output? = null,
    public val metricsAdvisorAadClientId: Output? = null,
    public val metricsAdvisorAadTenantId: Output? = null,
    public val metricsAdvisorSuperUserName: Output? = null,
    public val metricsAdvisorWebsiteName: Output? = null,
    public val name: Output? = null,
    public val networkAcls: Output? = null,
    public val outboundNetworkAccessRestricted: Output? = null,
    public val publicNetworkAccessEnabled: Output? = null,
    public val qnaRuntimeEndpoint: Output? = null,
    public val resourceGroupName: Output? = null,
    public val skuName: Output? = null,
    public val storages: Output>? = null,
    public val tags: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.cognitive.AccountArgs =
        com.pulumi.azure.cognitive.AccountArgs.builder()
            .customQuestionAnsweringSearchServiceId(
                customQuestionAnsweringSearchServiceId?.applyValue({ args0 ->
                    args0
                }),
            )
            .customQuestionAnsweringSearchServiceKey(
                customQuestionAnsweringSearchServiceKey?.applyValue({ args0 ->
                    args0
                }),
            )
            .customSubdomainName(customSubdomainName?.applyValue({ args0 -> args0 }))
            .customerManagedKey(
                customerManagedKey?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .dynamicThrottlingEnabled(dynamicThrottlingEnabled?.applyValue({ args0 -> args0 }))
            .fqdns(fqdns?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .identity(identity?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .kind(kind?.applyValue({ args0 -> args0 }))
            .localAuthEnabled(localAuthEnabled?.applyValue({ args0 -> args0 }))
            .location(location?.applyValue({ args0 -> args0 }))
            .metricsAdvisorAadClientId(metricsAdvisorAadClientId?.applyValue({ args0 -> args0 }))
            .metricsAdvisorAadTenantId(metricsAdvisorAadTenantId?.applyValue({ args0 -> args0 }))
            .metricsAdvisorSuperUserName(metricsAdvisorSuperUserName?.applyValue({ args0 -> args0 }))
            .metricsAdvisorWebsiteName(metricsAdvisorWebsiteName?.applyValue({ args0 -> args0 }))
            .name(name?.applyValue({ args0 -> args0 }))
            .networkAcls(networkAcls?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .outboundNetworkAccessRestricted(outboundNetworkAccessRestricted?.applyValue({ args0 -> args0 }))
            .publicNetworkAccessEnabled(publicNetworkAccessEnabled?.applyValue({ args0 -> args0 }))
            .qnaRuntimeEndpoint(qnaRuntimeEndpoint?.applyValue({ args0 -> args0 }))
            .resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
            .skuName(skuName?.applyValue({ args0 -> args0 }))
            .storages(
                storages?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .tags(
                tags?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            ).build()
}

/**
 * Builder for [AccountArgs].
 */
@PulumiTagMarker
public class AccountArgsBuilder internal constructor() {
    private var customQuestionAnsweringSearchServiceId: Output? = null

    private var customQuestionAnsweringSearchServiceKey: Output? = null

    private var customSubdomainName: Output? = null

    private var customerManagedKey: Output? = null

    private var dynamicThrottlingEnabled: Output? = null

    private var fqdns: Output>? = null

    private var identity: Output? = null

    private var kind: Output? = null

    private var localAuthEnabled: Output? = null

    private var location: Output? = null

    private var metricsAdvisorAadClientId: Output? = null

    private var metricsAdvisorAadTenantId: Output? = null

    private var metricsAdvisorSuperUserName: Output? = null

    private var metricsAdvisorWebsiteName: Output? = null

    private var name: Output? = null

    private var networkAcls: Output? = null

    private var outboundNetworkAccessRestricted: Output? = null

    private var publicNetworkAccessEnabled: Output? = null

    private var qnaRuntimeEndpoint: Output? = null

    private var resourceGroupName: Output? = null

    private var skuName: Output? = null

    private var storages: Output>? = null

    private var tags: Output>? = null

    /**
     * @param value If `kind` is `TextAnalytics` this specifies the ID of the Search service.
     */
    @JvmName("uxwrpbevepcbalyb")
    public suspend fun customQuestionAnsweringSearchServiceId(`value`: Output) {
        this.customQuestionAnsweringSearchServiceId = value
    }

    /**
     * @param value If `kind` is `TextAnalytics` this specifies the key of the Search service.
     * > **NOTE:** `custom_question_answering_search_service_id` and `custom_question_answering_search_service_key` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qna_runtime_endpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
     */
    @JvmName("vnphfwgocmwscnml")
    public suspend fun customQuestionAnsweringSearchServiceKey(`value`: Output) {
        this.customQuestionAnsweringSearchServiceKey = value
    }

    /**
     * @param value The subdomain name used for token-based authentication. This property is required when `network_acls` is specified. This property is also required when using the OpenAI service with libraries which assume the Azure OpenAI endpoint is a subdomain on `https://openai.azure.com/`, eg. `https://.openai.azure.com/`.  Changing this forces a new resource to be created.
     */
    @JvmName("kklelyupqeqpdfxd")
    public suspend fun customSubdomainName(`value`: Output) {
        this.customSubdomainName = value
    }

    /**
     * @param value A `customer_managed_key` block as documented below.
     */
    @JvmName("pskggyyftjtrlnii")
    public suspend fun customerManagedKey(`value`: Output) {
        this.customerManagedKey = value
    }

    /**
     * @param value Whether to enable the dynamic throttling for this Cognitive Service Account.
     */
    @JvmName("fglchrmhnfogirym")
    public suspend fun dynamicThrottlingEnabled(`value`: Output) {
        this.dynamicThrottlingEnabled = value
    }

    /**
     * @param value List of FQDNs allowed for the Cognitive Account.
     */
    @JvmName("mryjjlkmxkemaynt")
    public suspend fun fqdns(`value`: Output>) {
        this.fqdns = value
    }

    @JvmName("twrchmchmujdxjar")
    public suspend fun fqdns(vararg values: Output) {
        this.fqdns = Output.all(values.asList())
    }

    /**
     * @param values List of FQDNs allowed for the Cognitive Account.
     */
    @JvmName("bpqvwskjsasuvvbk")
    public suspend fun fqdns(values: List>) {
        this.fqdns = Output.all(values)
    }

    /**
     * @param value An `identity` block as defined below.
     */
    @JvmName("valdcghrdhqbwapu")
    public suspend fun identity(`value`: Output) {
        this.identity = value
    }

    /**
     * @param value 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).
     */
    @JvmName("jkolmalgpxfqkgpx")
    public suspend fun kind(`value`: Output) {
        this.kind = value
    }

    /**
     * @param value Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
     */
    @JvmName("jpvjeuvqmsuudkod")
    public suspend fun localAuthEnabled(`value`: Output) {
        this.localAuthEnabled = value
    }

    /**
     * @param value Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
     */
    @JvmName("cfrrnjkubhtxwhqr")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value 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.
     */
    @JvmName("qrsvenyhsskbynck")
    public suspend fun metricsAdvisorAadClientId(`value`: Output) {
        this.metricsAdvisorAadClientId = value
    }

    /**
     * @param value The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
     */
    @JvmName("svvpwkggaphraaqj")
    public suspend fun metricsAdvisorAadTenantId(`value`: Output) {
        this.metricsAdvisorAadTenantId = value
    }

    /**
     * @param value The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
     */
    @JvmName("mrdjfrnwwikcvwjo")
    public suspend fun metricsAdvisorSuperUserName(`value`: Output) {
        this.metricsAdvisorSuperUserName = value
    }

    /**
     * @param value 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`.
     */
    @JvmName("sjyudukmwsokydcq")
    public suspend fun metricsAdvisorWebsiteName(`value`: Output) {
        this.metricsAdvisorWebsiteName = value
    }

    /**
     * @param value Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
     */
    @JvmName("cwvjkxbjnavfdwmo")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value A `network_acls` block as defined below. When this property is specified, `custom_subdomain_name` is also required to be set.
     */
    @JvmName("ajwmlcktcqhqotfg")
    public suspend fun networkAcls(`value`: Output) {
        this.networkAcls = value
    }

    /**
     * @param value Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
     */
    @JvmName("ktytrlnhldcpquox")
    public suspend fun outboundNetworkAccessRestricted(`value`: Output) {
        this.outboundNetworkAccessRestricted = value
    }

    /**
     * @param value Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
     */
    @JvmName("bfuyaatbqenorbjm")
    public suspend fun publicNetworkAccessEnabled(`value`: Output) {
        this.publicNetworkAccessEnabled = value
    }

    /**
     * @param value A URL to link a QnAMaker cognitive account to a QnA runtime.
     */
    @JvmName("crdbafiqghxvwhsv")
    public suspend fun qnaRuntimeEndpoint(`value`: Output) {
        this.qnaRuntimeEndpoint = value
    }

    /**
     * @param value The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
     */
    @JvmName("jdbgicmckovqaqhs")
    public suspend fun resourceGroupName(`value`: Output) {
        this.resourceGroupName = value
    }

    /**
     * @param value 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).
     */
    @JvmName("ybfunarniqjyoyda")
    public suspend fun skuName(`value`: Output) {
        this.skuName = value
    }

    /**
     * @param value A `storage` block as defined below.
     */
    @JvmName("qflneashlceqwuqo")
    public suspend fun storages(`value`: Output>) {
        this.storages = value
    }

    @JvmName("lmieqccinqsxqqxc")
    public suspend fun storages(vararg values: Output) {
        this.storages = Output.all(values.asList())
    }

    /**
     * @param values A `storage` block as defined below.
     */
    @JvmName("ufhqqavcqgrkiyix")
    public suspend fun storages(values: List>) {
        this.storages = Output.all(values)
    }

    /**
     * @param value A mapping of tags to assign to the resource.
     */
    @JvmName("cqpqbjawfpitbyvk")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value If `kind` is `TextAnalytics` this specifies the ID of the Search service.
     */
    @JvmName("vhxkbwoayhjyryds")
    public suspend fun customQuestionAnsweringSearchServiceId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.customQuestionAnsweringSearchServiceId = mapped
    }

    /**
     * @param value If `kind` is `TextAnalytics` this specifies the key of the Search service.
     * > **NOTE:** `custom_question_answering_search_service_id` and `custom_question_answering_search_service_key` are used for [Custom Question Answering, the renamed version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/custom-question-answering), while `qna_runtime_endpoint` is used for [the old version of QnA Maker](https://docs.microsoft.com/azure/cognitive-services/qnamaker/overview/overview)
     */
    @JvmName("wvlnhhlxkomenorv")
    public suspend fun customQuestionAnsweringSearchServiceKey(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.customQuestionAnsweringSearchServiceKey = mapped
    }

    /**
     * @param value The subdomain name used for token-based authentication. This property is required when `network_acls` is specified. This property is also required when using the OpenAI service with libraries which assume the Azure OpenAI endpoint is a subdomain on `https://openai.azure.com/`, eg. `https://.openai.azure.com/`.  Changing this forces a new resource to be created.
     */
    @JvmName("atwbecuvhebkjavi")
    public suspend fun customSubdomainName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.customSubdomainName = mapped
    }

    /**
     * @param value A `customer_managed_key` block as documented below.
     */
    @JvmName("lnrcolwvcbukgdgj")
    public suspend fun customerManagedKey(`value`: AccountCustomerManagedKeyArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.customerManagedKey = mapped
    }

    /**
     * @param argument A `customer_managed_key` block as documented below.
     */
    @JvmName("wqwaqxxugowsqewd")
    public suspend fun customerManagedKey(argument: suspend AccountCustomerManagedKeyArgsBuilder.() -> Unit) {
        val toBeMapped = AccountCustomerManagedKeyArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.customerManagedKey = mapped
    }

    /**
     * @param value Whether to enable the dynamic throttling for this Cognitive Service Account.
     */
    @JvmName("wtdgvgipokrjfcas")
    public suspend fun dynamicThrottlingEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.dynamicThrottlingEnabled = mapped
    }

    /**
     * @param value List of FQDNs allowed for the Cognitive Account.
     */
    @JvmName("ureudrgkgukkilkq")
    public suspend fun fqdns(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.fqdns = mapped
    }

    /**
     * @param values List of FQDNs allowed for the Cognitive Account.
     */
    @JvmName("jjxtmqmjulktoyvi")
    public suspend fun fqdns(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.fqdns = mapped
    }

    /**
     * @param value An `identity` block as defined below.
     */
    @JvmName("rpdsvxowvsdcxeeb")
    public suspend fun identity(`value`: AccountIdentityArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.identity = mapped
    }

    /**
     * @param argument An `identity` block as defined below.
     */
    @JvmName("clnxablcdksfpkso")
    public suspend fun identity(argument: suspend AccountIdentityArgsBuilder.() -> Unit) {
        val toBeMapped = AccountIdentityArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.identity = mapped
    }

    /**
     * @param value 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).
     */
    @JvmName("wgdgvothbijeymxy")
    public suspend fun kind(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.kind = mapped
    }

    /**
     * @param value Whether local authentication methods is enabled for the Cognitive Account. Defaults to `true`.
     */
    @JvmName("esjyrkkrsabtjvnk")
    public suspend fun localAuthEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.localAuthEnabled = mapped
    }

    /**
     * @param value Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
     */
    @JvmName("hyablpnmwuxcxvaw")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value 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.
     */
    @JvmName("leqnwfdkrywosjrv")
    public suspend fun metricsAdvisorAadClientId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.metricsAdvisorAadClientId = mapped
    }

    /**
     * @param value The Azure AD Tenant ID. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
     */
    @JvmName("avlmnvcgxowsxooa")
    public suspend fun metricsAdvisorAadTenantId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.metricsAdvisorAadTenantId = mapped
    }

    /**
     * @param value The super user of Metrics Advisor. This attribute is only set when kind is `MetricsAdvisor`. Changing this forces a new resource to be created.
     */
    @JvmName("odlujplkgjprfirj")
    public suspend fun metricsAdvisorSuperUserName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.metricsAdvisorSuperUserName = mapped
    }

    /**
     * @param value 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`.
     */
    @JvmName("ianxgpeingwgnwvv")
    public suspend fun metricsAdvisorWebsiteName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.metricsAdvisorWebsiteName = mapped
    }

    /**
     * @param value Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
     */
    @JvmName("smshyxpgfxmmnajp")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value A `network_acls` block as defined below. When this property is specified, `custom_subdomain_name` is also required to be set.
     */
    @JvmName("wedckvjmjnxacnia")
    public suspend fun networkAcls(`value`: AccountNetworkAclsArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.networkAcls = mapped
    }

    /**
     * @param argument A `network_acls` block as defined below. When this property is specified, `custom_subdomain_name` is also required to be set.
     */
    @JvmName("msmsscdipavwxtca")
    public suspend fun networkAcls(argument: suspend AccountNetworkAclsArgsBuilder.() -> Unit) {
        val toBeMapped = AccountNetworkAclsArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.networkAcls = mapped
    }

    /**
     * @param value Whether outbound network access is restricted for the Cognitive Account. Defaults to `false`.
     */
    @JvmName("wvawjcsrcemqxiln")
    public suspend fun outboundNetworkAccessRestricted(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.outboundNetworkAccessRestricted = mapped
    }

    /**
     * @param value Whether public network access is allowed for the Cognitive Account. Defaults to `true`.
     */
    @JvmName("uspxnjjcnkksqiqg")
    public suspend fun publicNetworkAccessEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.publicNetworkAccessEnabled = mapped
    }

    /**
     * @param value A URL to link a QnAMaker cognitive account to a QnA runtime.
     */
    @JvmName("encflmcuxituovfn")
    public suspend fun qnaRuntimeEndpoint(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.qnaRuntimeEndpoint = mapped
    }

    /**
     * @param value The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
     */
    @JvmName("yksbjihrdemicyki")
    public suspend fun resourceGroupName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceGroupName = mapped
    }

    /**
     * @param value 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).
     */
    @JvmName("sceotmomdmplqlyp")
    public suspend fun skuName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.skuName = mapped
    }

    /**
     * @param value A `storage` block as defined below.
     */
    @JvmName("vyalfqumtpypxowq")
    public suspend fun storages(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.storages = mapped
    }

    /**
     * @param argument A `storage` block as defined below.
     */
    @JvmName("dryqgroailgvrrxt")
    public suspend fun storages(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            AccountStorageArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.storages = mapped
    }

    /**
     * @param argument A `storage` block as defined below.
     */
    @JvmName("kpadddddexetfmnb")
    public suspend fun storages(vararg argument: suspend AccountStorageArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            AccountStorageArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.storages = mapped
    }

    /**
     * @param argument A `storage` block as defined below.
     */
    @JvmName("wxjqhdvkogdqcvoh")
    public suspend fun storages(argument: suspend AccountStorageArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(AccountStorageArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.storages = mapped
    }

    /**
     * @param values A `storage` block as defined below.
     */
    @JvmName("mshfhsfprntolxub")
    public suspend fun storages(vararg values: AccountStorageArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.storages = mapped
    }

    /**
     * @param value A mapping of tags to assign to the resource.
     */
    @JvmName("gdppriirkjdmicbn")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values A mapping of tags to assign to the resource.
     */
    @JvmName("skerpervyijjihpa")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    internal fun build(): AccountArgs = AccountArgs(
        customQuestionAnsweringSearchServiceId = customQuestionAnsweringSearchServiceId,
        customQuestionAnsweringSearchServiceKey = customQuestionAnsweringSearchServiceKey,
        customSubdomainName = customSubdomainName,
        customerManagedKey = customerManagedKey,
        dynamicThrottlingEnabled = dynamicThrottlingEnabled,
        fqdns = fqdns,
        identity = identity,
        kind = kind,
        localAuthEnabled = localAuthEnabled,
        location = location,
        metricsAdvisorAadClientId = metricsAdvisorAadClientId,
        metricsAdvisorAadTenantId = metricsAdvisorAadTenantId,
        metricsAdvisorSuperUserName = metricsAdvisorSuperUserName,
        metricsAdvisorWebsiteName = metricsAdvisorWebsiteName,
        name = name,
        networkAcls = networkAcls,
        outboundNetworkAccessRestricted = outboundNetworkAccessRestricted,
        publicNetworkAccessEnabled = publicNetworkAccessEnabled,
        qnaRuntimeEndpoint = qnaRuntimeEndpoint,
        resourceGroupName = resourceGroupName,
        skuName = skuName,
        storages = storages,
        tags = tags,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy