diff --git a/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ClusterExtensionType_Get.json b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ClusterExtensionType_Get.json new file mode 100644 index 000000000000..00d08509e4b8 --- /dev/null +++ b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ClusterExtensionType_Get.json @@ -0,0 +1,43 @@ +{ + "parameters": { + "subscriptionId": "aaaaaaaaaa", + "resourceGroupName": "rgextensionTypes", + "clusterRp": "Microsoft.ContainerService", + "clusterType": "managedClusters", + "clusterName": "aaaaaaaaaaaaaaaaaaaaa", + "api-version": "2021-05-01-preview", + "extensionTypeName": "aaaaaa" + }, + "responses": { + "200": { + "body": { + "properties": { + "releaseTrains": [ + "aaaaaaaaaaaaaaaaaaaaaa" + ], + "clusterTypes": "connectedClusters", + "supportedScopes": { + "defaultScope": "aaaaaaaaaaa", + "clusterScopeSettings": { + "properties": { + "allowMultipleInstances": true, + "defaultReleaseNamespace": "aaaaaaaaaaaaaaaaaaaaaaa" + }, + "id": "aaaaaaaaaaaaaaaa", + "name": "aaaaaaaaaa", + "type": "aaaaaaaaaaaaaaaaaaa" + } + } + }, + "systemData": { + "createdBy": "aaaaaaaa", + "createdByType": "User", + "createdAt": "2021-04-14T22:44:27.144Z", + "lastModifiedBy": "aaaaaaaaa", + "lastModifiedByType": "User", + "lastModifiedAt": "2021-04-14T22:44:27.144Z" + } + } + } + } +} diff --git a/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ClusterExtensionTypes_List.json b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ClusterExtensionTypes_List.json new file mode 100644 index 000000000000..36c86047383c --- /dev/null +++ b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ClusterExtensionTypes_List.json @@ -0,0 +1,46 @@ +{ + "parameters": { + "subscriptionId": "aaaaaaaaaa", + "resourceGroupName": "rgextensionTypes", + "clusterRp": "Microsoft.ContainerService", + "clusterName": "aaaaaaaaaaaaaaaaaaaaa", + "api-version": "2021-05-01-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "properties": { + "releaseTrains": [ + "aaaaaaaaaaaaaaaaaaaaaa" + ], + "clusterTypes": "connectedClusters", + "supportedScopes": { + "defaultScope": "aaaaaaaaaaa", + "clusterScopeSettings": { + "properties": { + "allowMultipleInstances": true, + "defaultReleaseNamespace": "aaaaaaaaaaaaaaaaaaaaaaa" + }, + "id": "aaaaaaaaaaaaaaaa", + "name": "aaaaaaaaaa", + "type": "aaaaaaaaaaaaaaaaaaa" + } + } + }, + "systemData": { + "createdBy": "aaaaaaaa", + "createdByType": "User", + "createdAt": "2021-04-14T22:44:27.144Z", + "lastModifiedBy": "aaaaaaaaa", + "lastModifiedByType": "User", + "lastModifiedAt": "2021-04-14T22:44:27.144Z" + } + } + ], + "nextLink": "aaaaaaaaaaaaaaaaaaaaa" + } + } + } +} diff --git a/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ExtensionTypeVersions_List.json b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ExtensionTypeVersions_List.json new file mode 100644 index 000000000000..de2110441dc5 --- /dev/null +++ b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/ExtensionTypeVersions_List.json @@ -0,0 +1,31 @@ +{ + "parameters": { + "subscriptionId": "aaaaaaaaaa", + "location": "aaaaaa", + "extensionTypeName": "aaaaaa", + "api-version": "2021-05-01-preview" + }, + "responses": { + "200": { + "body": { + "versions": [ + { + "releaseTrain": "aaaa", + "versions": [ + "aaaaaaaaaaaaaa" + ] + } + ], + "nextLink": "aaa", + "systemData": { + "createdBy": "aaaaaaaa", + "createdByType": "User", + "createdAt": "2021-04-14T22:44:27.144Z", + "lastModifiedBy": "aaaaaaaaa", + "lastModifiedByType": "User", + "lastModifiedAt": "2021-04-14T22:44:27.144Z" + } + } + } + } +} diff --git a/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/LocationExtensionTypes_List.json b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/LocationExtensionTypes_List.json new file mode 100644 index 000000000000..27eee20dca0a --- /dev/null +++ b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/LocationExtensionTypes_List.json @@ -0,0 +1,44 @@ +{ + "parameters": { + "subscriptionId": "aaaaaaaaaa", + "location": "aaaaaa", + "api-version": "2021-05-01-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "properties": { + "releaseTrains": [ + "aaaaaaaaaaaaaaaaaaaaaa" + ], + "clusterTypes": "connectedClusters", + "supportedScopes": { + "defaultScope": "aaaaaaaaaaa", + "clusterScopeSettings": { + "properties": { + "allowMultipleInstances": true, + "defaultReleaseNamespace": "aaaaaaaaaaaaaaaaaaaaaaa" + }, + "id": "aaaaaaaaaaaaaaaa", + "name": "aaaaaaaaaa", + "type": "aaaaaaaaaaaaaaaaaaa" + } + } + }, + "systemData": { + "createdBy": "aaaaaaaa", + "createdByType": "User", + "createdAt": "2021-04-14T22:44:27.144Z", + "lastModifiedBy": "aaaaaaaaa", + "lastModifiedByType": "User", + "lastModifiedAt": "2021-04-14T22:44:27.144Z" + } + } + ], + "nextLink": "aaaaaaaaaaaaaaaaaaaaa" + } + } + } +} diff --git a/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/OperationsList.json b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/OperationsList.json index b63a0d376b56..ef15e52b5903 100644 --- a/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/OperationsList.json +++ b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/examples/OperationsList.json @@ -92,6 +92,17 @@ }, "isDataAction": false, "origin": "user,system" + }, + { + "name": "Microsoft.KubernetesConfiguration/extensionTypes/read", + "display": { + "provider": "Microsoft.KubernetesConfiguration", + "resource": "extensionTypes", + "operation": "Get Kubernetes Configuration Available Extensions", + " provider": "Microsoft Kuberntes Configuration" + }, + "isDataAction": false, + "origin": "user,system" } ] } diff --git a/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/extensionTypes.json b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/extensionTypes.json new file mode 100644 index 000000000000..ef25065a4138 --- /dev/null +++ b/specification/kubernetesconfiguration/resource-manager/Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/extensionTypes.json @@ -0,0 +1,412 @@ +{ + "swagger": "2.0", + "info": { + "version": "2021-05-01-preview", + "title": "ExtensionTypes", + "description": "Use these APIs to create extension resources through ARM, for Kubernetes Clusters." + }, + "host": "management.azure.com", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "security": [ + { + "azure_auth": [ + "user_impersonation" + ] + } + ], + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "flow": "implicit", + "description": "Azure Active Directory OAuth2 Flow", + "scopes": { + "user_impersonation": "impersonate your user account" + } + } + }, + "paths": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{clusterRp}/{clusterType}/{clusterName}/providers/Microsoft.KubernetesConfiguration/extensionTypes/{extensionTypeName}": { + "get": { + "description": "Get Extension Type details", + "operationId": "ClusterExtensionType_Get", + "x-ms-examples": { + "ClusterExtensionType_Get_MaximumSet_Gen": { + "$ref": "./examples/ClusterExtensionType_Get.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "#/parameters/ClusterRpParameter" + }, + { + "$ref": "#/parameters/ClusterTypeParameter" + }, + { + "$ref": "#/parameters/ClusterNameParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/ExtensionTypeNameParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ExtensionType" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{clusterRp}/connectedClusters/{clusterName}/providers/Microsoft.KubernetesConfiguration/extensionTypes": { + "get": { + "description": "Get Extension Types", + "operationId": "ClusterExtensionTypes_List", + "x-ms-examples": { + "ClusterExtensionTypes_List_MaximumSet_Gen": { + "$ref": "./examples/ClusterExtensionTypes_List.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "#/parameters/ClusterRpParameter" + }, + { + "$ref": "#/parameters/ClusterNameParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ExtensionTypeList" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.KubernetesConfiguration/locations/{location}/extensionTypes/{extensionTypeName}/versions": { + "get": { + "description": "List available versions for an Extension Type", + "operationId": "ExtensionTypeVersions_List", + "x-ms-examples": { + "ExtensionTypeVersions_List_MaximumSet_Gen": { + "$ref": "./examples/ExtensionTypeVersions_List.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ExtensionLocationParameter" + }, + { + "$ref": "#/parameters/ExtensionTypeNameParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ExtensionVersionList" + } + }, + "default": { + "description": "Error response describing why the operation failed", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink", + "itemName": "versions" + } + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.KubernetesConfiguration/locations/{location}/extensionTypes": { + "get": { + "tags": [ + "ExtensionType" + ], + "description": "List all Extension Types", + "operationId": "LocationExtensionTypes_List", + "x-ms-examples": { + "LocationExtensionTypes_List_MaximumSet_Gen": { + "$ref": "./examples/LocationExtensionTypes_List.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ExtensionLocationParameter" + }, + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ExtensionTypeList" + } + }, + "default": { + "description": "Error response describing why the operation failed", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + } + }, + "definitions": { + "ExtensionTypeList": { + "description": "List Extension Types", + "type": "object", + "properties": { + "value": { + "description": "The list of Extension Types", + "type": "array", + "items": { + "$ref": "#/definitions/ExtensionType" + } + }, + "nextLink": { + "description": "The link to fetch the next page of Extension Types", + "type": "string" + } + } + }, + "ExtensionType": { + "type": "object", + "description": "Represents an Extension Type.", + "required": [ + "properties" + ], + "properties": { + "properties": { + "x-ms-client-flatten": true, + "$ref": "#/definitions/ExtensionTypeProperties", + "description": "Describes the Resource Type properties." + }, + "systemData": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/systemData", + "readOnly": true, + "description": "Metadata pertaining to creation and last modification of the resource." + } + } + }, + "ExtensionTypeProperties": { + "description": "Properties of the connected cluster.", + "type": "object", + "properties": { + "releaseTrains": { + "readOnly": true, + "type": "array", + "items": { + "type": "string" + }, + "description": "Extension release train: preview or stable" + }, + "clusterTypes": { + "description": "Cluster types", + "readOnly": true, + "type": "string", + "enum": [ + "connectedClusters", + "managedClusters" + ], + "x-ms-enum": { + "name": "clusterTypes", + "modelAsString": false + } + }, + "supportedScopes": { + "readOnly": true, + "type": "object", + "description": "Extension scopes", + "$ref": "#/definitions/SupportedScopes" + } + } + }, + "ExtensionVersionList": { + "description": "List versions for an Extension", + "type": "object", + "properties": { + "versions": { + "description": "Versions available for this Extension Type", + "type": "array", + "items": { + "type": "object", + "properties": { + "releaseTrain": { + "description": "The release train for this Extension Type", + "type": "string" + }, + "versions": { + "type": "array", + "description": "Versions available for this Extension Type and release train", + "items": { + "type": "string" + } + } + } + } + }, + "nextLink": { + "description": "The link to fetch the next page of Extension Types", + "type": "string" + }, + "systemData": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/systemData", + "readOnly": true, + "description": "Metadata pertaining to creation and last modification of the resource." + } + } + }, + "SupportedScopes": { + "type": "object", + "description": "Extension scopes", + "properties": { + "defaultScope": { + "type": "string", + "description": "Default extension scopes: cluster or namespace" + }, + "clusterScopeSettings": { + "description": "Scope settings", + "$ref": "#/definitions/ClusterScopeSettings" + } + } + }, + "ClusterScopeSettings": { + "type": "object", + "description": "Extension scope settings", + "properties": { + "properties": { + "type": "object", + "x-ms-client-flatten": true, + "description": "Extension scope settings", + "properties": { + "allowMultipleInstances": { + "type": "boolean", + "description": "Describes if multiple instances of the extension are allowed" + }, + "defaultReleaseNamespace": { + "type": "string", + "description": "Default extension release namespace" + } + } + } + }, + "allOf": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ProxyResource" + } + ] + } + }, + "parameters": { + "ClusterRpParameter": { + "name": "clusterRp", + "in": "path", + "required": true, + "type": "string", + "enum": [ + "Microsoft.ContainerService", + "Microsoft.Kubernetes" + ], + "description": "The Kubernetes cluster RP - either Microsoft.ContainerService (for AKS clusters) or Microsoft.Kubernetes (for OnPrem K8S clusters).", + "x-ms-parameter-location": "method" + }, + "ClusterTypeParameter": { + "name": "clusterType", + "in": "path", + "required": true, + "type": "string", + "enum": [ + "managedClusters", + "connectedClusters" + ], + "description": "The Kubernetes cluster resource name - either managedClusters (for AKS clusters) or connectedClusters (for OnPrem K8S clusters).", + "x-ms-parameter-location": "method" + }, + "ClusterNameParameter": { + "name": "clusterName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the kubernetes cluster.", + "x-ms-parameter-location": "method" + }, + "ExtensionLocationParameter": { + "name": "location", + "in": "path", + "description": "extension location", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "ExtensionTypeNameParameter": { + "name": "extensionTypeName", + "in": "path", + "required": true, + "type": "string", + "description": "Extension type name", + "x-ms-parameter-location": "method" + } + } +} diff --git a/specification/kubernetesconfiguration/resource-manager/readme.go.md b/specification/kubernetesconfiguration/resource-manager/readme.go.md index 94001cc33664..04446f7a0fca 100644 --- a/specification/kubernetesconfiguration/resource-manager/readme.go.md +++ b/specification/kubernetesconfiguration/resource-manager/readme.go.md @@ -56,4 +56,4 @@ These settings apply only when `--tag=package-2020-07-01-preview --go` is specif Please also specify `--go-sdks-folder=`. ```yaml $(tag) == 'package-2020-07-01-preview' && $(go) namespace: kubernetesconfiguration -output-folder: $(go-sdk-folder)/services/preview/$(namespace)/mgmt/2020-07-01-preview/$(namespace) \ No newline at end of file +output-folder: $(go-sdk-folder)/services/preview/$(namespace)/mgmt/2020-07-01-preview/$(namespace) diff --git a/specification/kubernetesconfiguration/resource-manager/readme.md b/specification/kubernetesconfiguration/resource-manager/readme.md index a37c0c3eee19..7c4056b6dab7 100644 --- a/specification/kubernetesconfiguration/resource-manager/readme.md +++ b/specification/kubernetesconfiguration/resource-manager/readme.md @@ -39,6 +39,7 @@ These settings apply only when `--tag=package-preview-2021-05` is specified on t ```yaml $(tag) == 'package-preview-2021-05' input-file: - Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/extensions.json + - Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/extensionTypes.json - Microsoft.KubernetesConfiguration/preview/2021-05-01-preview/kubernetesconfiguration.json ``` ### Tag: package-2021-03