From d110522a8374afbd7e9327f40d31d10544571376 Mon Sep 17 00:00:00 2001 From: jihochang Date: Sun, 8 Nov 2020 18:23:21 -0800 Subject: [PATCH] Fix Swagger Issues for Microsoft.AAD/DomainServices (#11178) * Update domainservices.json Add GET/PROVIDERS/MICROSOFT.AAD/SUBSCRIPTIONS/RESOURCEGROUPS/PROVIDERS/MICROSOFT.AAD/DOMAINSERVICES operation * Update domainservices.json * Update domainservice.json for 2017-01-01 Add DeploymentId property to DomainServiceProperties * Update domainservice.json for 2017-06-01 Fix swagger correctness issues * Update domainservices.json Add description for default error type * Update DomainService 2017-06-01 Ran Prettier * Update oucontainer.json for 2017-06-01 * Update oucontainer.json for 2020-01-01 * Update domainservice.json for 2020-01-01 * Fix linting issues in domainservice.json 2020-01-01 * Fix spell check error on domainservice.json 2020-01-01 * Update domainservices.json Remove incorrect GET * Update domainservices.json Add x-ms-secret metadata for ResourceForest property * Update domainservices.json Change format back to date-time * update format back to date-time * Update domainservices.json * Update domainservices.json * Update domainservices.json * Update domainservices.json * Update domainservices.json * Update domainservices.json * Update domainservices.json * Update domainservices.json --- .../stable/2017-01-01/domainservices.json | 7 +- .../stable/2017-06-01/domainservices.json | 200 +++++++++++++++++- .../stable/2017-06-01/oucontainer.json | 5 + .../stable/2020-01-01/domainservices.json | 80 ++++++- .../stable/2020-01-01/oucontainer.json | 5 + 5 files changed, 289 insertions(+), 8 deletions(-) diff --git a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-01-01/domainservices.json b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-01-01/domainservices.json index a5b0b3dbd478..c3f00d6fa28b 100644 --- a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-01-01/domainservices.json +++ b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-01-01/domainservices.json @@ -395,6 +395,11 @@ "type": "string", "description": "The name of the Azure domain that the user would like to deploy Domain Services to." }, + "deploymentId": { + "readOnly": true, + "type": "string", + "description": "Deployment Id" + }, "vnetSiteId": { "readOnly": true, "type": "string", @@ -411,7 +416,7 @@ "healthLastEvaluated": { "readOnly": true, "type": "string", - "format": "date-time", + "format": "date-time-rfc1123", "description": "Last domain evaluation run DateTime" }, "healthMonitors": { diff --git a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/domainservices.json b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/domainservices.json index 13a151d5ea2a..e735091e6d3c 100644 --- a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/domainservices.json +++ b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/domainservices.json @@ -45,6 +45,12 @@ "schema": { "$ref": "#/definitions/OperationEntityListResult" } + }, + "default": { + "description": "Domain Service error response.", + "schema": { + "$ref": "#/definitions/DefaultErrorResponse" + } } }, "x-ms-examples": { @@ -79,6 +85,12 @@ "schema": { "$ref": "#/definitions/DomainServiceListResult" } + }, + "default": { + "description": "Domain Service error response.", + "schema": { + "$ref": "#/definitions/DefaultErrorResponse" + } } }, "x-ms-examples": { @@ -116,6 +128,12 @@ "schema": { "$ref": "#/definitions/DomainServiceListResult" } + }, + "default": { + "description": "Domain Service error response.", + "schema": { + "$ref": "#/definitions/DefaultErrorResponse" + } } }, "x-ms-examples": { @@ -177,6 +195,12 @@ "schema": { "$ref": "#/definitions/DomainService" } + }, + "default": { + "description": "Domain Service error response.", + "schema": { + "$ref": "#/definitions/DefaultErrorResponse" + } } }, "x-ms-long-running-operation": true, @@ -213,6 +237,12 @@ "schema": { "$ref": "#/definitions/DomainService" } + }, + "default": { + "description": "Domain Service error response.", + "schema": { + "$ref": "#/definitions/DefaultErrorResponse" + } } }, "x-ms-examples": { @@ -248,6 +278,12 @@ }, "204": { "description": "HTTP 204 (Not Content) should be used if the resource does not exist and the request is well formed." + }, + "default": { + "description": "Domain Service error response.", + "schema": { + "$ref": "#/definitions/DefaultErrorResponse" + } } }, "x-ms-long-running-operation": true, @@ -299,6 +335,12 @@ "schema": { "$ref": "#/definitions/DomainService" } + }, + "default": { + "description": "Domain Service error response.", + "schema": { + "$ref": "#/definitions/DefaultErrorResponse" + } } }, "x-ms-long-running-operation": true, @@ -386,15 +428,25 @@ "DomainServiceProperties": { "description": "Properties of the Domain Service.", "properties": { + "version": { + "readOnly": true, + "type": "integer", + "description": "Data Model Version" + }, "tenantId": { "readOnly": true, "type": "string", - "description": "Azure Active Directory tenant id" + "description": "Azure Active Directory Tenant Id" }, "domainName": { "type": "string", "description": "The name of the Azure domain that the user would like to deploy Domain Services to." }, + "deploymentId": { + "readOnly": true, + "type": "string", + "description": "Deployment Id" + }, "vnetSiteId": { "readOnly": true, "type": "string", @@ -408,10 +460,26 @@ "$ref": "#/definitions/LdapsSettings", "description": "Secure LDAP Settings" }, + "domainSecuritySettings": { + "$ref": "#/definitions/DomainSecuritySettings", + "description": "DomainSecurity Settings" + }, + "resourceForestSettings": { + "$ref": "#/definitions/ResourceForestSettings", + "description": "Resource Forest Settings" + }, + "domainConfigurationType": { + "type": "string", + "description": "Domain Configuration Type" + }, + "sku": { + "type": "string", + "description": "Sku Type" + }, "healthLastEvaluated": { "readOnly": true, "type": "string", - "format": "date-time", + "format": "date-time-rfc1123", "description": "Last domain evaluation run DateTime" }, "healthMonitors": { @@ -436,10 +504,6 @@ "$ref": "#/definitions/NotificationSettings", "description": "Notification Settings" }, - "domainSecuritySettings": { - "$ref": "#/definitions/DomainSecuritySettings", - "description": "DomainSecurity Settings" - }, "filteredSync": { "type": "string", "enum": [ @@ -630,6 +694,48 @@ } } }, + "ResourceForestSettings": { + "description": "Settings for Resource Forest", + "properties": { + "settings": { + "type": "array", + "items": { + "$ref": "#/definitions/ForestTrust" + }, + "description": "List of settings for Resource Forest" + }, + "resourceForest": { + "type": "string", + "description": "Resource Forest" + } + } + }, + "ForestTrust": { + "description": "Forest Trust Setting", + "properties": { + "trustedDomainFqdn": { + "type": "string", + "description": "Trusted Domain FQDN" + }, + "trustDirection": { + "type": "string", + "description": "Trust Direction" + }, + "friendlyName": { + "type": "string", + "description": "Friendly Name" + }, + "remoteDnsIps": { + "type": "string", + "description": "Remote Dns ips" + }, + "trustPassword": { + "type": "string", + "description": "Trust Password", + "x-ms-secret": true + } + } + }, "DomainSecuritySettings": { "description": "Domain Security Settings", "properties": { @@ -668,6 +774,30 @@ "name": "SyncNtlmPasswords", "modelAsString": true } + }, + "syncKerberosPasswords": { + "type": "string", + "enum": [ + "Enabled", + "Disabled" + ], + "description": "A flag to determine whether or not SyncKerberosPasswords is enabled or disabled.", + "x-ms-enum": { + "name": "SyncKerberosPasswords", + "modelAsString": true + } + }, + "syncOnPremPasswords": { + "type": "string", + "enum": [ + "Enabled", + "Disabled" + ], + "description": "A flag to determine whether or not SyncOnPremPasswords is enabled or disabled.", + "x-ms-enum": { + "name": "SyncOnPremPasswords", + "modelAsString": true + } } } }, @@ -728,6 +858,64 @@ "type": "string" } } + }, + "DefaultErrorResponse": { + "description": "Domain Service error response.", + "type": "object", + "properties": { + "error": { + "description": "Error model.", + "type": "object", + "properties": { + "code": { + "description": "Standardized string to programmatically identify the error.", + "type": "string", + "readOnly": true + }, + "message": { + "description": "Detailed error description and debugging information.", + "type": "string", + "readOnly": true + }, + "target": { + "description": "Detailed error description and debugging information.", + "type": "string", + "readOnly": true + }, + "details": { + "description": "Error details.", + "type": "array", + "items": { + "description": "Detailed errors.", + "properties": { + "code": { + "description": "Standardized string to programmatically identify the error.", + "type": "string", + "readOnly": true + }, + "message": { + "description": "Detailed error description and debugging information.", + "type": "string", + "readOnly": true + }, + "target": { + "description": "Detailed error description and debugging information.", + "type": "string", + "readOnly": true + } + }, + "readOnly": true + } + }, + "innererror": { + "description": "More information to debug error.", + "type": "string", + "readOnly": true + } + }, + "readOnly": true + } + } } }, "parameters": { diff --git a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/oucontainer.json b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/oucontainer.json index 6a2aed422bab..8db2f96a631f 100644 --- a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/oucontainer.json +++ b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2017-06-01/oucontainer.json @@ -439,6 +439,11 @@ "type": "string", "description": "Status of OuContainer instance" }, + "distinguishedName": { + "readOnly": true, + "type": "string", + "description": "Distinguished Name of OuContainer instance" + }, "provisioningState": { "readOnly": true, "type": "string", diff --git a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/domainservices.json b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/domainservices.json index 5654c5f25f55..33481b688f97 100644 --- a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/domainservices.json +++ b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/domainservices.json @@ -464,10 +464,22 @@ "$ref": "#/definitions/LdapsSettings", "description": "Secure LDAP Settings" }, + "resourceForestSettings": { + "$ref": "#/definitions/ResourceForestSettings", + "description": "Resource Forest Settings" + }, "domainSecuritySettings": { "$ref": "#/definitions/DomainSecuritySettings", "description": "DomainSecurity Settings" }, + "domainConfigurationType": { + "type": "string", + "description": "Domain Configuration Type" + }, + "sku": { + "type": "string", + "description": "Sku Type" + }, "filteredSync": { "type": "string", "enum": [ @@ -534,7 +546,7 @@ "healthLastEvaluated": { "readOnly": true, "type": "string", - "format": "date-time", + "format": "date-time-rfc1123", "description": "Last domain evaluation run DateTime" }, "healthMonitors": { @@ -709,6 +721,48 @@ } } }, + "ResourceForestSettings": { + "description": "Settings for Resource Forest", + "properties": { + "settings": { + "type": "array", + "items": { + "$ref": "#/definitions/ForestTrust" + }, + "description": "List of settings for Resource Forest" + }, + "resourceForest": { + "type": "string", + "description": "Resource Forest" + } + } + }, + "ForestTrust": { + "description": "Forest Trust Setting", + "properties": { + "trustedDomainFqdn": { + "type": "string", + "description": "Trusted Domain FQDN" + }, + "trustDirection": { + "type": "string", + "description": "Trust Direction" + }, + "friendlyName": { + "type": "string", + "description": "Friendly Name" + }, + "remoteDnsIps": { + "type": "string", + "description": "Remote Dns ips" + }, + "trustPassword": { + "type": "string", + "description": "Trust Password", + "x-ms-secret": true + } + } + }, "DomainSecuritySettings": { "description": "Domain Security Settings", "properties": { @@ -747,6 +801,30 @@ "name": "SyncNtlmPasswords", "modelAsString": true } + }, + "syncKerberosPasswords": { + "type": "string", + "enum": [ + "Enabled", + "Disabled" + ], + "description": "A flag to determine whether or not SyncKerberosPasswords is enabled or disabled.", + "x-ms-enum": { + "name": "SyncKerberosPasswords", + "modelAsString": true + } + }, + "syncOnPremPasswords": { + "type": "string", + "enum": [ + "Enabled", + "Disabled" + ], + "description": "A flag to determine whether or not SyncOnPremPasswords is enabled or disabled.", + "x-ms-enum": { + "name": "SyncOnPremPasswords", + "modelAsString": true + } } } }, diff --git a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/oucontainer.json b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/oucontainer.json index 84bf755c076f..c61923ab2617 100644 --- a/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/oucontainer.json +++ b/specification/domainservices/resource-manager/Microsoft.AAD/stable/2020-01-01/oucontainer.json @@ -439,6 +439,11 @@ "type": "string", "description": "Status of OuContainer instance" }, + "distinguishedName": { + "readOnly": true, + "type": "string", + "description": "Distinguished Name of OuContainer instance" + }, "provisioningState": { "readOnly": true, "type": "string",