From 4bfc609caa9a16134e0e15d8ed0e1fc0b8c55850 Mon Sep 17 00:00:00 2001 From: Sebastian Graef Date: Sun, 11 Feb 2024 18:40:18 +1000 Subject: [PATCH] feat: `avm/res/cognites-services/account` added missing OpenAI kind and updated api --- avm/res/cognitive-services/account/README.md | 11 +++++++++-- avm/res/cognitive-services/account/main.bicep | 11 +++++++++-- avm/res/cognitive-services/account/main.json | 17 ++++++++++++----- 3 files changed, 30 insertions(+), 9 deletions(-) diff --git a/avm/res/cognitive-services/account/README.md b/avm/res/cognitive-services/account/README.md index b729ea0521..78540ea849 100644 --- a/avm/res/cognitive-services/account/README.md +++ b/avm/res/cognitive-services/account/README.md @@ -17,7 +17,7 @@ This module deploys a Cognitive Service. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.CognitiveServices/accounts` | [2022-12-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.CognitiveServices/2022-12-01/accounts) | +| `Microsoft.CognitiveServices/accounts` | [2023-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.CognitiveServices/2023-05-01/accounts) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | | `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | | `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | @@ -847,6 +847,7 @@ Kind of the Cognitive Services. Use 'Get-AzCognitiveServicesAccountSku' to deter - Allowed: ```Bicep [ + 'AIServices' 'AnomalyDetector' 'Bing.Autosuggest.v7' 'Bing.CustomSearch' @@ -856,16 +857,22 @@ Kind of the Cognitive Services. Use 'Get-AzCognitiveServicesAccountSku' to deter 'CognitiveServices' 'ComputerVision' 'ContentModerator' + 'ContentSafety' + 'ConversationalLanguageUnderstanding' 'CustomVision.Prediction' 'CustomVision.Training' 'Face' 'FormRecognizer' + 'HealthInsights' 'ImmersiveReader' 'Internal.AllInOne' + 'LanguageAuthoring' 'LUIS' 'LUIS.Authoring' + 'MetricsAdvisor' + 'OpenAI' 'Personalizer' - 'QnAMaker' + 'QnAMaker.v2' 'SpeechServices' 'TextAnalytics' 'TextTranslation' diff --git a/avm/res/cognitive-services/account/main.bicep b/avm/res/cognitive-services/account/main.bicep index 0f81a209c5..69bd4db2cf 100644 --- a/avm/res/cognitive-services/account/main.bicep +++ b/avm/res/cognitive-services/account/main.bicep @@ -7,6 +7,7 @@ param name string @description('Required. Kind of the Cognitive Services. Use \'Get-AzCognitiveServicesAccountSku\' to determine a valid combinations of \'kind\' and \'SKU\' for your Azure region.') @allowed([ + 'AIServices' 'AnomalyDetector' 'Bing.Autosuggest.v7' 'Bing.CustomSearch' @@ -16,16 +17,22 @@ param name string 'CognitiveServices' 'ComputerVision' 'ContentModerator' + 'ContentSafety' + 'ConversationalLanguageUnderstanding' 'CustomVision.Prediction' 'CustomVision.Training' 'Face' 'FormRecognizer' + 'HealthInsights' 'ImmersiveReader' 'Internal.AllInOne' 'LUIS' 'LUIS.Authoring' + 'LanguageAuthoring' + 'MetricsAdvisor' + 'OpenAI' 'Personalizer' - 'QnAMaker' + 'QnAMaker.v2' 'SpeechServices' 'TextAnalytics' 'TextTranslation' @@ -189,7 +196,7 @@ resource cMKUserAssignedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentiti scope: resourceGroup(split((customerManagedKey.?userAssignedIdentityResourceId ?? '//'), '/')[2], split((customerManagedKey.?userAssignedIdentityResourceId ?? '////'), '/')[4]) } -resource cognitiveService 'Microsoft.CognitiveServices/accounts@2022-12-01' = { +resource cognitiveService 'Microsoft.CognitiveServices/accounts@2023-05-01' = { name: name kind: kind identity: identity diff --git a/avm/res/cognitive-services/account/main.json b/avm/res/cognitive-services/account/main.json index 6595a1a7b1..0112b8d8f8 100644 --- a/avm/res/cognitive-services/account/main.json +++ b/avm/res/cognitive-services/account/main.json @@ -6,7 +6,7 @@ "_generator": { "name": "bicep", "version": "0.24.24.22086", - "templateHash": "13697179912910947708" + "templateHash": "14501144781393850379" }, "name": "Cognitive Services", "description": "This module deploys a Cognitive Service.", @@ -452,6 +452,7 @@ "kind": { "type": "string", "allowedValues": [ + "AIServices", "AnomalyDetector", "Bing.Autosuggest.v7", "Bing.CustomSearch", @@ -461,16 +462,22 @@ "CognitiveServices", "ComputerVision", "ContentModerator", + "ContentSafety", + "ConversationalLanguageUnderstanding", "CustomVision.Prediction", "CustomVision.Training", "Face", "FormRecognizer", + "HealthInsights", "ImmersiveReader", "Internal.AllInOne", "LUIS", "LUIS.Authoring", + "LanguageAuthoring", + "MetricsAdvisor", + "OpenAI", "Personalizer", - "QnAMaker", + "QnAMaker.v2", "SpeechServices", "TextAnalytics", "TextTranslation" @@ -733,7 +740,7 @@ }, "cognitiveService": { "type": "Microsoft.CognitiveServices/accounts", - "apiVersion": "2022-12-01", + "apiVersion": "2023-05-01", "name": "[parameters('name')]", "kind": "[parameters('kind')]", "identity": "[variables('identity')]", @@ -1523,14 +1530,14 @@ "metadata": { "description": "The principal ID of the system assigned identity." }, - "value": "[coalesce(tryGet(tryGet(reference('cognitiveService', '2022-12-01', 'full'), 'identity'), 'principalId'), '')]" + "value": "[coalesce(tryGet(tryGet(reference('cognitiveService', '2023-05-01', 'full'), 'identity'), 'principalId'), '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference('cognitiveService', '2022-12-01', 'full').location]" + "value": "[reference('cognitiveService', '2023-05-01', 'full').location]" } } } \ No newline at end of file