diff --git a/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/attestation.json b/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/attestation.json index ad290370de96..2798ecbb976e 100644 --- a/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/attestation.json +++ b/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/attestation.json @@ -1,498 +1,499 @@ -{ - "swagger": "2.0", - "info": { - "title": "AttestationManagementClient", - "description": "Various APIs for managing resources in attestation service. This primarily encompasses per-tenant instance management.", - "version": "2018-09-01-preview" - }, - "host": "management.azure.com", - "schemes": [ - "https" - ], - "consumes": [ - "application/json" - ], - "produces": [ - "application/json" - ], - "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.Attestation/operations": { - "get": { - "tags": [ - "Operations" - ], - "operationId": "Operations_List", - "description": "Lists all of the available Azure attestation operations.", - "x-ms-examples": { - "Operations_List": { - "$ref": "./examples/Operations_List.json" - } - }, - "parameters": [ - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "x-ms-pageable": { - "nextLinkName": null - }, - "responses": { - "200": { - "description": "List all the operations.", - "schema": { - "$ref": "#/definitions/OperationList" - } - }, - "default": { - "description": "Attestation service error result", - "schema": { - "$ref": "#/definitions/ErrorResult" + { + "swagger": "2.0", + "info": { + "title": "AttestationManagementClient", + "description": "Various APIs for managing resources in attestation service. This primarily encompasses per-tenant instance management.", + "version": "2018-09-01-preview" + }, + "host": "management.azure.com", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "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" } - } } - } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Attestation/attestationProviders/{providerName}": { - "get": { - "tags": [ - "AttestationProvider" - ], - "operationId": "AttestationProviders_Get", - "description": "Get the status of Attestation Provider.", - "x-ms-examples": { - "AttestationProviders_Get": { - "$ref": "./examples/Get_AttestationProvider.json" - } - }, - "parameters": [ - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ResourceGroupNameParameter" - }, - { - "name": "providerName", - "in": "path", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9-]{3,24}$", - "description": "Name of the attestation service" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Get the status of attestation Provider", - "schema": { - "$ref": "#/definitions/AttestationProvider" - } - }, - "default": { - "description": "Error result from Attestation service", - "schema": { - "$ref": "#/definitions/ErrorResult" + "paths": { + "/providers/Microsoft.Attestation/operations": { + "get": { + "tags": [ + "Operations" + ], + "operationId": "Operations_List", + "description": "Lists all of the available Azure attestation operations.", + "x-ms-examples": { + "Operations_List": { + "$ref": "./examples/Operations_List.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "x-ms-pageable": { + "nextLinkName": null + }, + "responses": { + "200": { + "description": "List all the operations.", + "schema": { + "$ref": "#/definitions/OperationList" + } + }, + "default": { + "description": "Attestation service error result", + "schema": { + "$ref": "#/definitions/ErrorResult" + } + } + } } - } - } - }, - "put": { - "tags": [ - "AttestationProvider" - ], - "operationId": "AttestationProviders_Create", - "description": "Creates or updates the Attestation Provider.", - "x-ms-examples": { - "AttestationProviders_Create": { - "$ref": "./examples/Create_AttestationProvider.json" - } }, - "parameters": [ - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ResourceGroupNameParameter" - }, - { - "name": "providerName", - "in": "path", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9-]{3,24}$", - "description": "Name of the attestation service" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - }, - { - "name": "creationParams", - "in": "body", - "description": "Client supplied parameters.", - "schema": { - "$ref": "#/definitions/AttestationServiceCreationParams" + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Attestation/attestationProviders/{providerName}": { + "get": { + "tags": [ + "AttestationProvider" + ], + "operationId": "AttestationProviders_Get", + "description": "Get the status of Attestation Provider.", + "x-ms-examples": { + "AttestationProviders_Get": { + "$ref": "./examples/Get_AttestationProvider.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ResourceGroupNameParameter" + }, + { + "name": "providerName", + "in": "path", + "required": true, + "type": "string", + "pattern": "^[a-z0-9]{3,24}$", + "description": "Name of the attestation service instance" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "The status of the specified attestation service instance", + "schema": { + "$ref": "#/definitions/AttestationProvider" + } + }, + "default": { + "description": "Error result from Attestation service", + "schema": { + "$ref": "#/definitions/ErrorResult" + } + } + } }, - "x-ms-parameter-location": "method" - } - ], - "responses": { - "200": { - "description": "Created or updated attestation service", - "schema": { - "$ref": "#/definitions/AttestationProvider" + "put": { + "tags": [ + "AttestationProvider" + ], + "operationId": "AttestationProviders_Create", + "description": "Creates or updates the Attestation Provider.", + "x-ms-examples": { + "AttestationProviders_Create": { + "$ref": "./examples/Create_AttestationProvider.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ResourceGroupNameParameter" + }, + { + "name": "providerName", + "in": "path", + "required": true, + "type": "string", + "pattern": "^[a-zA-Z0-9-]{3,24}$", + "description": "Name of the attestation service" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + }, + { + "name": "creationParams", + "in": "body", + "description": "Client supplied parameters.", + "schema": { + "$ref": "#/definitions/AttestationServiceCreationParams" + }, + "x-ms-parameter-location": "method" + } + ], + "responses": { + "200": { + "description": "Created or updated attestation service", + "schema": { + "$ref": "#/definitions/AttestationProvider" + } + }, + "201": { + "description": "Created or updated attestation service", + "schema": { + "$ref": "#/definitions/AttestationProvider" + } + }, + "default": { + "description": "Error result from Attestation service", + "schema": { + "$ref": "#/definitions/ErrorResult" + } + } + } + }, + "delete": { + "tags": [ + "AttestationProvider" + ], + "operationId": "AttestationProviders_Delete", + "description": "Delete Attestation Service.", + "x-ms-examples": { + "AttestationProviders_Delete": { + "$ref": "./examples/Delete_AttestationProvider.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ResourceGroupNameParameter" + }, + { + "name": "providerName", + "in": "path", + "required": true, + "type": "string", + "pattern": "^[a-zA-Z0-9-]{3,24}$", + "description": "Name of the attestation service" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "202": { + "description": "Request accepted for deletion of attestation service" + }, + "200": { + "description": "Resource exists and was deleted successfully" + }, + "204": { + "description": "Resource does not exist" + }, + "default": { + "description": "Error result from Attestation service", + "schema": { + "$ref": "#/definitions/ErrorResult" + } + } + } + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Attestation/attestationProviders": { + "get": { + "tags": [ + "AttestationProviders" + ], + "operationId": "AttestationProviders_List", + "description": "Returns a list of attestation providers in a subscription.", + "x-ms-examples": { + "AttestationProviders_List": { + "$ref": "./examples/Get_AttestationProvidersList.json" } - }, - "201": { - "description": "Created or updated attestation service", - "schema": { - "$ref": "#/definitions/AttestationProvider" + }, + "parameters": [ + { + "$ref": "#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" } - }, - "default": { - "description": "Error result from Attestation service", - "schema": { - "$ref": "#/definitions/ErrorResult" + ], + "x-ms-pageable": { + "nextLinkName": null + }, + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/AttestationProviderListResult" + } + }, + "default": { + "description": "Attestation service error result", + "schema": { + "$ref": "#/definitions/ErrorResult" + } } - } - } - }, - "delete": { - "tags": [ - "AttestationProvider" - ], - "operationId": "AttestationProviders_Delete", - "description": "Delete Attestation Service.", - "x-ms-examples": { - "AttestationProviders_Delete": { - "$ref": "./examples/Delete_AttestationProvider.json" - } - }, - "parameters": [ - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ResourceGroupNameParameter" - }, - { - "name": "providerName", - "in": "path", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9-]{3,24}$", - "description": "Name of the attestation service" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "202": { - "description": "Request accepted for deletion of attestation service" - }, - "200": { - "description": "Resource exists and was deleted successfully" - }, - "204": { - "description": "Resource does not exist" - }, - "default": { - "description": "Error result from Attestation service", - "schema": { - "$ref": "#/definitions/ErrorResult" } - } } - } - }, - "/subscriptions/{subscriptionId}/providers/Microsoft.Attestation/attestationProviders": { - "get": { - "tags": [ - "AttestationProviders" - ], - "operationId": "AttestationProviders_List", - "description": "Returns a list of attestation providers in a subscription.", - "x-ms-examples": { - "AttestationProviders_List": { - "$ref": "./examples/Get_AttestationProvidersList.json" - } - }, - "parameters": [ - { - "$ref": "#/parameters/ApiVersionParameter" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - } - ], - "x-ms-pageable": { - "nextLinkName": null }, - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/AttestationProviderListResult" + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Attestation/attestationProviders": { + "get": { + "tags": [ + "AttestationProviders" + ], + "operationId": "AttestationProviders_ListByResourceGroup", + "description": "Returns attestation providers list in a resource group.", + "x-ms-examples": { + "AttestationProviders_ListByResourceGroup": { + "$ref": "./examples/Get_AttestationProvidersListByResourceGroup.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupNameParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + } + ], + "x-ms-pageable": { + "nextLinkName": null, + "itemName": "keys" + }, + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/AttestationProviderListResult" + } + }, + "default": { + "description": "Attestation service error result", + "schema": { + "$ref": "#/definitions/ErrorResult" + } } - }, - "default": { - "description": "Attestation service error result", - "schema": { - "$ref": "#/definitions/ErrorResult" } - } } - } + } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Attestation/attestationProviders": { - "get": { - "tags": [ - "AttestationProviders" - ], - "operationId": "AttestationProviders_ListByResourceGroup", - "description": "Returns attestation providers list in a resource group.", - "x-ms-examples": { - "AttestationProviders_ListByResourceGroup": { - "$ref": "./examples/Get_AttestationProvidersListByResourceGroup.json" - } + "definitions": { + "OperationList": { + "properties": { + "value": { + "type": "array", + "description": "List of supported operations.", + "items": { + "$ref": "#/definitions/OperationsDefinition" + } + } + }, + "description": "List of supported operations." }, - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupNameParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - } - ], - "x-ms-pageable": { - "nextLinkName": null, - "itemName": "keys" + "OperationsDefinition": { + "type": "object", + "description": "Definition object with the name and properties of an operation.", + "properties": { + "name": { + "type": "string", + "description": "Name of the operation." + }, + "display": { + "$ref": "#/definitions/OperationsDisplayDefinition", + "description": "Display object with properties of the operation." + } + } }, - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/AttestationProviderListResult" + "OperationsDisplayDefinition": { + "type": "object", + "description": "Display object with properties of the operation.", + "properties": { + "provider": { + "type": "string", + "description": "Resource provider of the operation." + }, + "resource": { + "type": "string", + "description": "Resource for the operation." + }, + "operation": { + "type": "string", + "description": "Short description of the operation." + }, + "description": { + "type": "string", + "description": "Description of the operation." + } } - }, - "default": { - "description": "Attestation service error result", - "schema": { - "$ref": "#/definitions/ErrorResult" + }, + "AttestationProvider": { + "description": "Attestation service response message.", + "required": [ + "properties" + ], + "allOf": [ + { + "$ref": "../../../../common-types/resource-management/v1/types.json#/definitions/Resource" + } + ], + "properties": { + "properties": { + "type": "object", + "$ref": "#/definitions/StatusResult", + "description": "Describes Attestation service status.", + "x-ms-client-flatten": true + } } - } - } - } - } - }, - "definitions": { - "OperationList": { - "properties": { - "value": { - "type": "array", - "description": "List of supported operations.", - "items": { - "$ref": "#/definitions/OperationsDefinition" - } - } - }, - "description": "List of supported operations." - }, - "OperationsDefinition": { - "type": "object", - "description": "Definition object with the name and properties of an operation.", - "properties": { - "name": { - "type": "string", - "description": "Name of the operation." }, - "display": { - "$ref": "#/definitions/OperationsDisplayDefinition", - "description": "Display object with properties of the operation." - } - } - }, - "OperationsDisplayDefinition": { - "type": "object", - "description": "Display object with properties of the operation.", - "properties": { - "provider": { - "type": "string", - "description": "Resource provider of the operation." + "StatusResult": { + "type": "object", + "description": "Status of attestation service.", + "required": [ + "status" + ], + "properties": { + "status": { + "type": "string", + "description": "Status of attestation service.", + "enum": [ + "Ready", + "NotReady", + "Error" + ], + "x-ms-enum": { + "name": "AttestationServiceStatus", + "modelAsString": true + } + }, + "attestUri": { + "type": "string", + "description": "Gets the uri of attestation service" + } + } }, - "resource": { - "type": "string", - "description": "Resource for the operation." + "ErrorResult": { + "type": "object", + "title": "Error", + "description": "Error description and code explaining why an operation failed.", + "properties": { + "error": { + "type": "object", + "description": "Error object.", + "$ref": "#/definitions/ErrorResponseBody" + } + } }, - "operation": { - "type": "string", - "description": "Short description of the operation." + "ErrorResponseBody": { + "type": "object", + "title": "Error", + "description": "Error description and code explaining why an operation failed.", + "required": [ + "message", + "code" + ], + "properties": { + "message": { + "type": "string", + "description": "Description of the error." + }, + "code": { + "type": "string", + "description": "Service specific error code" + } + } }, - "description": { - "type": "string", - "description": "Description of the operation." - } - } - }, - "AttestationProvider": { - "description": "Attestation service response message.", - "required": [ - "properties" - ], - "allOf": [ - { - "$ref": "../../../../common-types/resource-management/v1/types.json#/definitions/Resource" - } - ], - "properties": { - "properties": { - "type": "object", - "$ref": "#/definitions/StatusResult", - "description": "Describes Attestation service status.", - "x-ms-client-flatten": true - } - } - }, - "StatusResult": { - "type": "object", - "description": "Status of attestation service.", - "required": [ - "status" - ], - "properties": { - "status": { - "type": "string", - "description": "Status of attestation service.", - "enum": [ - "Ready", - "NotReady", - "Error" - ], - "x-ms-enum": { - "name": "AttestationServiceStatus", - "modelAsString": true - } + "ErrorResponse": { + "type": "object", + "description": "Error response", + "properties": { + "error": { + "type": "object", + "description":"Error response", + "properties": { + "code": { + "type": "string", + "description": "Description of the error." + }, + "message": { + "type": "string", + "description": "Service specific error code." + } + } + } + } }, - "attestUri": { - "type": "string", - "description": "Gets the uri of attestation service" - } - } - }, - "ErrorResult": { - "type": "object", - "title": "Error", - "description": "Error description and code explaining why an operation failed.", - "properties": { - "error": { - "type": "object", - "description": "Error object.", - "$ref": "#/definitions/ErrorResponseBody" - } - } - }, - "ErrorResponseBody": { - "type": "object", - "title": "Error", - "description": "Error description and code explaining why an operation failed.", - "required": [ - "message", - "code" - ], - "properties": { - "message": { - "type": "string", - "description": "Description of the error." + "AttestationProviderListResult": { + "description": "Attestation Providers List.", + "properties": { + "value": { + "type": "array", + "description": "Attestation Provider array.", + "items": { + "$ref": "#/definitions/AttestationProvider" + } + } + } }, - "code": { - "type": "string", - "description": "Service specific error code" - } - } - }, - "ErrorResponse": { - "type": "object", - "description": "Error response", - "properties": { - "error": { - "type": "object", - "description": "Error response", - "properties": { - "code": { - "type": "string", - "description": "Description of the error." - }, - "message": { - "type": "string", - "description": "Service specific error code." + "AttestationServiceCreationParams": { + "description": "Client supplied parameters passed to attestation service.", + "properties": { + "attestationPolicy": { + "type": "string", + "description":"Name of attestation policy." + } } - } - } - } - }, - "AttestationProviderListResult": { - "description": "Attestation Providers List.", - "properties": { - "value": { - "type": "array", - "description": "Attestation Provider array.", - "items": { - "$ref": "#/definitions/AttestationProvider" - } } - } }, - "AttestationServiceCreationParams": { - "description": "Client supplied parameters passed to attestation service.", - "properties": { - "attestationPolicy": { - "type": "string", - "description": "Name of attestation policy." + "parameters": { + "ResourceGroupNameParameter": { + "name": "resourceGroupName", + "in": "path", + "description": "Name of the resource group to which the resource belongs.", + "required": true, + "type": "string", + "maxLength": 90, + "minLength": 1, + "pattern": "^[-\\w\\._\\(\\)]+[^\\.]$", + "x-ms-parameter-location": "method" + }, + "SubscriptionIdParameter": { + "name": "subscriptionId", + "in": "path", + "required": true, + "type": "string", + "description": "Subscription credentials that uniquely identify the Microsoft Azure subscription. The subscription ID forms part of the URI for every service call." + }, + "ApiVersionParameter": { + "name": "api-version", + "in": "query", + "required": true, + "type": "string", + "description": "Client API version.", + "enum": ["2018-09-01-preview"] } - } - } - }, - "parameters": { - "ResourceGroupNameParameter": { - "name": "resourceGroupName", - "in": "path", - "description": "Name of the resource group to which the resource belongs.", - "required": true, - "type": "string", - "maxLength": 90, - "minLength": 1, - "pattern": "^[-\\w\\._\\(\\)]+[^\\.]$", - "x-ms-parameter-location": "method" - }, - "SubscriptionIdParameter": { - "name": "subscriptionId", - "in": "path", - "required": true, - "type": "string", - "description": "Subscription credentials that uniquely identify the Microsoft Azure subscription. The subscription ID forms part of the URI for every service call." - }, - "ApiVersionParameter": { - "name": "api-version", - "in": "query", - "required": true, - "type": "string", - "description": "Client API version." } } -} diff --git a/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/examples/Get_AttestationProvider.json b/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/examples/Get_AttestationProvider.json index 6aae3c0f8e0a..64bb0f15dc35 100644 --- a/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/examples/Get_AttestationProvider.json +++ b/specification/attestation/resource-manager/Microsoft.Attestation/2018-09-01-preview/examples/Get_AttestationProvider.json @@ -1,21 +1,21 @@ { - "parameters": { - "resourceGroupName": "sample-resource-group", - "serviceName": "sampleservicename", - "subscriptionId": "00000000-0000-0000-0000-000000000000", - "api-version": "2018-09-01-preview", - "providerName": "providerName1" - }, - "responses": { - "200": { - "body": { - "id": "subscriptions/subscriptionID/resourceGroups/resourceGroupID/providers/Microsoft.Attestation/attestationProviders/codes1", - "name": "codes1", - "type": "Microsoft.Attestation/attestationProviders", - "properties": { - "status": "Ready" + "parameters": { + "resourceGroupName": "sample-resource-group", + "serviceName": "sampleservicename", + "subscriptionId": "00000000-0000-0000-0000-000000000000", + "api-version": "2018-09-01-preview", + "providerName": "providername1" + }, + "responses": { + "200": { + "body": { + "id": "subscriptions/subscriptionID/resourceGroups/resourceGroupID/providers/Microsoft.Attestation/attestationProviders/codes1", + "name": "codes1", + "type": "Microsoft.Attestation/attestationProviders", + "properties": { + "status": "Ready" + } + } } - } } - } }