diff --git a/custom-words.txt b/custom-words.txt index feae94dffa27..f322d671619c 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -682,6 +682,7 @@ exceptiontype exfiltrate Exfiltration experimentids +expiresin Explainability explicitlist exportconfiguration diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsDeleteDefault.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsDeleteDefault.json new file mode 100644 index 000000000000..164e62932f70 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsDeleteDefault.json @@ -0,0 +1,11 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview", + "endpointName": "default" + }, + "responses": { + "200": {}, + "204": {} + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsGetCustom.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsGetCustom.json new file mode 100644 index 000000000000..2c9d1e3a37da --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsGetCustom.json @@ -0,0 +1,20 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview", + "endpointName": "custom" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine/providers/Microsoft.HybridConnectivity/endpoints/custom", + "name": "custom", + "type": "Microsoft.HybridConnectivity/endpoints", + "properties": { + "type": "custom", + "resourceId": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.Relay/namespaces/custom-relay-namespace" + } + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsGetDefault.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsGetDefault.json new file mode 100644 index 000000000000..a433bad56209 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsGetDefault.json @@ -0,0 +1,19 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview", + "endpointName": "default" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine/providers/Microsoft.HybridConnectivity/endpoints/default", + "name": "default", + "type": "Microsoft.HybridConnectivity/endpoints", + "properties": { + "type": "default" + } + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsList.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsList.json new file mode 100644 index 000000000000..e201956d09e2 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsList.json @@ -0,0 +1,31 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine/providers/Microsoft.HybridConnectivity/endpoints/default", + "name": "default", + "type": "Microsoft.HybridConnectivity/endpoints", + "properties": { + "type": "default" + } + }, + { + "id": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine/providers/Microsoft.HybridConnectivity/endpoints/custom", + "name": "custom", + "type": "Microsoft.HybridConnectivity/endpoints", + "properties": { + "type": "custom", + "resourceId": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.Relay/namespaces/custom-relay-namespace" + } + } + ] + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPatchDefault.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPatchDefault.json new file mode 100644 index 000000000000..dc850d159a30 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPatchDefault.json @@ -0,0 +1,25 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview", + "endpointName": "default", + "EndpointResource": { + "properties": { + "type": "default" + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine/providers/Microsoft.HybridConnectivity/endpoints/default", + "name": "default", + "type": "Microsoft.HybridConnectivity/endpoints", + "properties": { + "type": "default", + "provisioningState": "Succeeded" + } + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPostListCredentials.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPostListCredentials.json new file mode 100644 index 000000000000..64333cd9116b --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPostListCredentials.json @@ -0,0 +1,21 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview", + "endpointName": "default", + "expiresin": 10800 + }, + "responses": { + "200": { + "body": { + "relay": { + "namespaceName": "azgnrelay-eastus-l1", + "namespaceNameSuffix": "servicebus.windows.net", + "hybridConnectionName": "microsoft.kubernetes/connectedclusters/a0e1fd7d1d974ddf6b11a952d67679c9f12c006eee16861857a8268da4eb1498/1619989456957411072", + "accessKey": "SharedAccessSignature sr=http%3A%2F%2Fazgnrelay-eastus-l1.servicebus.windows.net%2Fmicrosoft.kubernetes%2Fconnectedclusters%2Fa0e1fd7d1d974ddf6b11a952d67679c9f12c006eee16861857a8268da4eb1498%2F1619989456957411072%2F&sig=WxDwPF6AmmODaMHNnBGDSm773UG%2B%2Be", + "expiresOn": 1620000256 + } + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPutCustom.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPutCustom.json new file mode 100644 index 000000000000..a1fc54c17bb8 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPutCustom.json @@ -0,0 +1,27 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview", + "endpointName": "custom", + "EndpointResource": { + "properties": { + "type": "custom", + "resourceId": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.Relay/namespaces/custom-relay-namespace" + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine/providers/Microsoft.HybridConnectivity/endpoints/custom", + "name": "custom", + "type": "Microsoft.HybridConnectivity/endpoints", + "properties": { + "type": "custom", + "resourceId": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.Relay/namespaces/custom-relay-namespace", + "provisioningState": "Succeeded" + } + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPutDefault.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPutDefault.json new file mode 100644 index 000000000000..dc850d159a30 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/EndpointsPutDefault.json @@ -0,0 +1,25 @@ +{ + "parameters": { + "resourceUri": "subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine", + "api-version": "2021-10-06-preview", + "endpointName": "default", + "EndpointResource": { + "properties": { + "type": "default" + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/f5bcc1d9-23af-4ae9-aca1-041d0f593a63/resourceGroups/hybridRG/providers/Microsoft.HybridCompute/machines/testMachine/providers/Microsoft.HybridConnectivity/endpoints/default", + "name": "default", + "type": "Microsoft.HybridConnectivity/endpoints", + "properties": { + "type": "default", + "provisioningState": "Succeeded" + } + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/OperationsList.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/OperationsList.json new file mode 100644 index 000000000000..929b2d9e3772 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/examples/OperationsList.json @@ -0,0 +1,83 @@ +{ + "parameters": { + "api-version": "2021-10-06-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "name": "Microsoft.HybridConnectivity/operations/read", + "isDataAction": false, + "display": { + "provider": "Microsoft.HybridConnectivity", + "resource": "Operations", + "operation": "Get operations", + "description": "Get the list of Operations" + } + }, + { + "name": "Microsoft.HybridConnectivity/endpoints/read", + "isDataAction": false, + "display": { + "provider": "Microsoft.HybridConnectivity", + "resource": "endpoints", + "operation": "Get/List endpoints", + "description": "Get or list of endpoints to the target resource." + } + }, + { + "name": "Microsoft.HybridConnectivity/endpoints/write", + "isDataAction": false, + "display": { + "provider": "Microsoft.HybridConnectivity", + "resource": "endpoints", + "operation": "Create/Update endpoint", + "description": "Create or update the endpoint to the target resource." + } + }, + { + "name": "Microsoft.HybridConnectivity/endpoints/delete", + "isDataAction": false, + "display": { + "provider": "Microsoft.HybridConnectivity", + "resource": "endpoints", + "operation": "Delete endpoint", + "description": "Deletes the endpoint access to the target resource." + } + }, + { + "name": "Microsoft.HybridConnectivity/endpoints/listCredentials/action", + "isDataAction": false, + "display": { + "provider": "Microsoft.HybridConnectivity", + "resource": "endpoints", + "operation": "List credentials for endpoint access", + "description": "List the endpoint access credentials to the resource." + } + }, + { + "name": "Microsoft.HybridConnectivity/register/action", + "isDataAction": false, + "display": { + "provider": "Microsoft.HybridConnectivity", + "resource": "Microsoft.HybridConnectivity", + "operation": "Register the Microsoft.HybridConnectivity", + "description": "Register the subscription for Microsoft.HybridConnectivity" + } + }, + { + "name": "Microsoft.HybridConnectivity/unregister/action", + "isDataAction": false, + "display": { + "provider": "Microsoft.HybridConnectivity", + "resource": "Microsoft.HybridConnectivity", + "operation": "Unregister the Microsoft.HybridConnectivity", + "description": "Unregister the subscription for Microsoft.HybridConnectivity" + } + } + ] + } + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/hybridconnectivity.json b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/hybridconnectivity.json new file mode 100644 index 000000000000..090f492c5698 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/Microsoft.HybridConnectivity/preview/2021-10-06-preview/hybridconnectivity.json @@ -0,0 +1,502 @@ +{ + "swagger": "2.0", + "info": { + "title": "Hybrid Connectivity Management API", + "description": "REST API for Hybrid Connectivity", + "version": "2021-10-06-preview" + }, + "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": { + "/providers/Microsoft.HybridConnectivity/operations": { + "get": { + "tags": [ + "Operations" + ], + "description": "Lists the available Hybrid Connectivity REST API operations.", + "operationId": "Operations_List", + "produces": [ + "application/json" + ], + "x-ms-examples": { + "HybridConnectivityOperationsList": { + "$ref": "./examples/OperationsList.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Operation details.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/OperationListResult" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/{resourceUri}/providers/Microsoft.HybridConnectivity/endpoints": { + "get": { + "tags": [ + "Endpoints" + ], + "description": "List of endpoints to the target resource.", + "operationId": "Endpoints_List", + "produces": [ + "application/json" + ], + "x-ms-examples": { + "HybridConnectivityEndpointsGet": { + "$ref": "./examples/EndpointsList.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/ResourceUriParameter" + } + ], + "responses": { + "200": { + "description": "List of endpoints.", + "schema": { + "$ref": "#/definitions/EndpointsList" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/{resourceUri}/providers/Microsoft.HybridConnectivity/endpoints/{endpointName}": { + "get": { + "tags": [ + "Endpoints" + ], + "description": "Gets the endpoint to the resource.", + "operationId": "Endpoints_Get", + "produces": [ + "application/json" + ], + "x-ms-examples": { + "HybridConnectivityEndpointsGetDefault": { + "$ref": "./examples/EndpointsGetDefault.json" + }, + "HybridConnectivityEndpointsGetCustom": { + "$ref": "./examples/EndpointsGetCustom.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/ResourceUriParameter" + }, + { + "$ref": "#/parameters/EndpointNameParameter" + } + ], + "responses": { + "200": { + "description": "Endpoint details", + "schema": { + "$ref": "#/definitions/EndpointResource" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + }, + "deprecated": false + }, + "put": { + "tags": [ + "Endpoints" + ], + "description": "Create or update the endpoint to the target resource.", + "operationId": "Endpoints_CreateOrUpdate", + "produces": [ + "application/json" + ], + "x-ms-examples": { + "HybridConnectivityEndpointsPutDefault": { + "$ref": "./examples/EndpointsPutDefault.json" + }, + "HybridConnectivityEndpointsPutCustom": { + "$ref": "./examples/EndpointsPutCustom.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/ResourceUriParameter" + }, + { + "$ref": "#/parameters/EndpointNameParameter" + }, + { + "name": "EndpointResource", + "description": "Endpoint details", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/EndpointResource" + } + } + ], + "responses": { + "200": { + "description": "Endpoint details.", + "schema": { + "$ref": "#/definitions/EndpointResource" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + } + }, + "patch": { + "tags": [ + "Endpoints" + ], + "description": "Update the endpoint to the target resource.", + "operationId": "Endpoints_Update", + "produces": [ + "application/json" + ], + "x-ms-examples": { + "HybridConnectivityEndpointsPatchDefault": { + "$ref": "./examples/EndpointsPatchDefault.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/ResourceUriParameter" + }, + { + "$ref": "#/parameters/EndpointNameParameter" + }, + { + "name": "EndpointResource", + "description": "Endpoint details", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/EndpointResource" + } + } + ], + "responses": { + "200": { + "description": "Endpoint resource.", + "schema": { + "$ref": "#/definitions/EndpointResource" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + } + }, + "delete": { + "tags": [ + "Endpoints" + ], + "description": "Deletes the endpoint access to the target resource.", + "operationId": "Endpoints_Delete", + "produces": [ + "application/json" + ], + "x-ms-examples": { + "HybridConnectivityEndpointsDeleteDefault": { + "$ref": "./examples/EndpointsDeleteDefault.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/ResourceUriParameter" + }, + { + "$ref": "#/parameters/EndpointNameParameter" + } + ], + "responses": { + "200": { + "description": "The endpoint is deleted successfully." + }, + "204": { + "description": "The endpoint has been deleted already." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + } + } + }, + "/{resourceUri}/providers/Microsoft.HybridConnectivity/endpoints/{endpointName}/listCredentials": { + "post": { + "tags": [ + "Endpoints" + ], + "description": "Gets the endpoint access credentials to the resource.", + "operationId": "Endpoints_ListCredentials", + "produces": [ + "application/json" + ], + "x-ms-examples": { + "HybridConnectivityEndpointsPostListCredentials": { + "$ref": "./examples/EndpointsPostListCredentials.json" + } + }, + "parameters": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/ResourceUriParameter" + }, + { + "$ref": "#/parameters/EndpointNameParameter" + }, + { + "$ref": "#/parameters/AccessTokenExpirationParameter" + } + ], + "responses": { + "200": { + "description": "Endpoint access credentials", + "schema": { + "$ref": "#/definitions/EndpointAccessResource" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" + } + } + }, + "deprecated": false + } + } + }, + "definitions": { + "RelayNamespaceAccessProperties": { + "type": "object", + "description": "Azure relay hybrid connection access properties", + "required": [ + "namespaceName", + "namespaceNameSuffix", + "hybridConnectionName" + ], + "properties": { + "namespaceName": { + "type": "string", + "description": "The namespace name.", + "minLength": 1, + "maxLength": 200 + }, + "namespaceNameSuffix": { + "type": "string", + "description": "The suffix domain name of relay namespace.", + "minLength": 1, + "maxLength": 100 + }, + "hybridConnectionName": { + "type": "string", + "description": "Azure Relay hybrid connection name for the resource." + }, + "accessKey": { + "type": "string", + "description": "Access key for hybrid connection.", + "readOnly": true + }, + "expiresOn": { + "type": "integer", + "format": "int64", + "description": "The expiration of access key in unix time." + } + } + }, + "EndpointAccessResource": { + "description": "The endpoint access for the target resource.", + "type": "object", + "properties": { + "relay": { + "$ref": "#/definitions/RelayNamespaceAccessProperties", + "x-ms-client-flatten": true + } + } + }, + "EndpointProperties": { + "type": "object", + "description": "Endpoint details", + "required": [ + "type" + ], + "properties": { + "type": { + "type": "string", + "description": "The type of endpoint.", + "enum": [ + "default", + "custom" + ], + "x-ms-enum": { + "name": "type", + "modelAsString": true + } + }, + "resourceId": { + "type": "string", + "description": "The resource Id of the connectivity endpoint (optional)." + }, + "provisioningState": { + "type": "string", + "readOnly": true + } + } + }, + "EndpointResource": { + "description": "The endpoint for the target resource.", + "type": "object", + "allOf": [ + { + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ProxyResource" + } + ], + "properties": { + "systemData": { + "description": "System data of endpoint resource", + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/systemData", + "x-ms-client-flatten": true + }, + "properties": { + "description": "The endpoint properties.", + "$ref": "#/definitions/EndpointProperties", + "x-ms-client-flatten": true + } + } + }, + "EndpointsList": { + "description": "The list of endpoints.", + "type": "object", + "properties": { + "nextLink": { + "description": "The link used to get the next page of endpoints list.", + "type": "string" + }, + "value": { + "description": "The list of endpoint.", + "type": "array", + "items": { + "$ref": "#/definitions/EndpointResource" + } + } + } + } + }, + "parameters": { + "ResourceUriParameter": { + "name": "resourceUri", + "in": "path", + "required": true, + "type": "string", + "description": "The fully qualified Azure Resource manager identifier of the resource to be connected.", + "x-ms-skip-url-encoding": true, + "x-ms-parameter-location": "method" + }, + "EndpointNameParameter": { + "name": "endpointName", + "in": "path", + "required": true, + "type": "string", + "description": "The endpoint name.", + "x-ms-skip-url-encoding": true, + "x-ms-parameter-location": "method" + }, + "AccessTokenExpirationParameter": { + "name": "expiresin", + "in": "query", + "required": false, + "type": "integer", + "format": "int64", + "default": 10800, + "minimum": 600, + "maximum": 10800, + "description": "The is how long the endpoint access token is valid (in seconds).", + "x-ms-parameter-location": "method" + } + } +} diff --git a/specification/hybridconnectivity/resource-manager/readme.az.md b/specification/hybridconnectivity/resource-manager/readme.az.md new file mode 100644 index 000000000000..57f5bad54821 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/readme.az.md @@ -0,0 +1,28 @@ +## AZ + +These settings apply only when `--az` is specified on the command line. + +For new Resource Provider. It is highly recommended to onboard Azure CLI extensions. There's no differences in terms of customer usage. + +``` yaml $(az) && $(target-mode) != 'core' +az: + extensions: hybridconnectivity + namespace: azure.mgmt.hybridconnectivity + package-name: azure-mgmt-hybridconnectivity +az-output-folder: $(azure-cli-extension-folder)/src/hybridconnectivity +python-sdk-output-folder: "$(az-output-folder)/azext_hybridconnectivity/vendored_sdks/hybridconnectivity" +# add additional configuration here specific for Azure CLI +# refer to the faq.md for more details +``` + + + +This is for command modules that already in azure cli main repo. +``` yaml $(az) && $(target-mode) == 'core' +az: + extensions: hybridconnectivity + namespace: azure.mgmt.hybridconnectivity + package-name: azure-mgmt-hybridconnectivity +az-output-folder: $(azure-cli-folder)/src/azure-cli/azure/cli/command_modules/hybridconnectivity +python-sdk-output-folder: "$(az-output-folder)/vendored_sdks/hybridconnectivity" +``` \ No newline at end of file diff --git a/specification/hybridconnectivity/resource-manager/readme.cli.md b/specification/hybridconnectivity/resource-manager/readme.cli.md new file mode 100644 index 000000000000..c6cf6ad37ea4 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/readme.cli.md @@ -0,0 +1 @@ +## CLI Common Settings for all the command line tools \ No newline at end of file diff --git a/specification/hybridconnectivity/resource-manager/readme.csharp.md b/specification/hybridconnectivity/resource-manager/readme.csharp.md new file mode 100644 index 000000000000..483da256b6a3 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/readme.csharp.md @@ -0,0 +1,15 @@ +## C# + +These settings apply only when `--csharp` is specified on the command line. +Please also specify `--csharp-sdks-folder=`. + +```yaml $(csharp) +csharp: + azure-arm: true + license-header: MICROSOFT_MIT_NO_VERSION + payload-flattening-threshold: 1 + clear-output-folder: true + client-side-validation: false + namespace: Microsoft.HybridConnectivity + output-folder: $(csharp-sdks-folder)/hybridconnectivity/management/Microsoft.HybridConnectivity/GeneratedProtocol +``` diff --git a/specification/hybridconnectivity/resource-manager/readme.go.md b/specification/hybridconnectivity/resource-manager/readme.go.md new file mode 100644 index 000000000000..17c468591895 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/readme.go.md @@ -0,0 +1,26 @@ +## Go + +These settings apply only when `--go` is specified on the command line. + +```yaml $(go) && !$(track2) +go: + license-header: MICROSOFT_MIT_NO_VERSION + namespace: hybridconnectivity + clear-output-folder: true +``` + +### Go multi-api + +```yaml $(go) && $(multiapi) +batch: + - tag: package-2021-10-06-preview +``` + +### Tag: package-2021-10-06-preview and go + +These settings apply only when `--tag=package-2021-10-06-preview --go` is specified on the command line. +Please also specify `--go-sdk-folder=`. + +```yaml $(tag) == 'package-2021-10-06-preview' && $(go) +output-folder: $(go-sdk-folder)/services/preview/$(namespace)/mgmt/2021-10-06-preview/$(namespace) +``` diff --git a/specification/hybridconnectivity/resource-manager/readme.md b/specification/hybridconnectivity/resource-manager/readme.md new file mode 100644 index 000000000000..e369f406fef0 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/readme.md @@ -0,0 +1,80 @@ +# hybridconnectivity + +> see https://aka.ms/autorest + +This is the AutoRest configuration file for hybridconnectivity. + +## Getting Started + +To build the SDKs for My API, simply install AutoRest via `npm` (`npm install -g autorest`) and then run: + +> `autorest readme.md` + +To see additional help and options, run: + +> `autorest --help` + +For other options on installation see [Installing AutoRest](https://aka.ms/autorest/install) on the AutoRest github page. + +--- + +## Configuration + +### Basic Information + +These are the global settings for the hybridconnectivity. + +```yaml +openapi-type: arm +openapi-subtype: rpaas +tag: package-2021-10-06-preview +``` + +### Tag: package-2021-10-06-preview + +These settings apply only when `--tag=package-2021-10-06-preview` is specified on the command line. + +```yaml $(tag) == 'package-2021-10-06-preview' +input-file: + - Microsoft.HybridConnectivity/preview/2021-10-06-preview/hybridconnectivity.json +``` + +--- + +# Code Generation + +## Swagger to SDK + +This section describes what SDK should be generated by the automatic system. +This is not used by Autorest itself. + +```yaml $(swagger-to-sdk) +swagger-to-sdk: + - repo: azure-sdk-for-net + - repo: azure-sdk-for-python-track2 + - repo: azure-sdk-for-python + - repo: azure-sdk-for-java + - repo: azure-sdk-for-go + - repo: azure-sdk-for-js + - repo: azure-resource-manager-schemas + - repo: azure-cli-extensions +``` +## Az + +See configuration in [readme.az.md](./readme.az.md) + +## Go + +See configuration in [readme.go.md](./readme.go.md) + +## Python + +See configuration in [readme.python.md](./readme.python.md) + +## TypeScript + +See configuration in [readme.typescript.md](./readme.typescript.md) + +## CSharp + +See configuration in [readme.csharp.md](./readme.csharp.md) diff --git a/specification/hybridconnectivity/resource-manager/readme.python.md b/specification/hybridconnectivity/resource-manager/readme.python.md new file mode 100644 index 000000000000..5cf6d5378b3e --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/readme.python.md @@ -0,0 +1,23 @@ +## Python + +These settings apply only when `--python` is specified on the command line. +Please also specify `--python-sdks-folder=`. + +``` yaml $(track2) +azure-arm: true +license-header: MICROSOFT_MIT_NO_VERSION +package-name: azure-mgmt-hybridconnectivity +no-namespace-folders: true +package-version: 1.0.0b1 +clear-output-folder: true +``` + +``` yaml $(python-mode) == 'update' && $(track2) +no-namespace-folders: true +output-folder: $(python-sdks-folder)/hybridconnectivity/azure-mgmt-hybridconnectivity/azure/mgmt/hybridconnectivity +``` + +``` yaml $(python-mode) == 'create' && $(track2) +basic-setup-py: true +output-folder: $(python-sdks-folder)/hybridconnectivity/azure-mgmt-hybridconnectivity +``` diff --git a/specification/hybridconnectivity/resource-manager/readme.typescript.md b/specification/hybridconnectivity/resource-manager/readme.typescript.md new file mode 100644 index 000000000000..e6356be4ea96 --- /dev/null +++ b/specification/hybridconnectivity/resource-manager/readme.typescript.md @@ -0,0 +1,14 @@ +## TypeScript + +These settings apply only when `--typescript` is specified on the command line. +Please also specify `--typescript-sdks-folder=`. + +``` yaml $(typescript) +typescript: + azure-arm: true + package-name: "@azure/arm-hybridconnectivity" + output-folder: "$(typescript-sdks-folder)/sdk/hybridconnectivity/arm-hybridconnectivity" + payload-flattening-threshold: 1 + clear-output-folder: true + generate-metadata: true +```