{ "swagger": "2.0", "info": { "version": "2024-11-01", "title": "SiteCertificates API Client" }, "host": "management.azure.com", "schemes": [ "https" ], "consumes": [ "application/json" ], "produces": [ "application/json" ], "paths": { "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/certificates": { "get": { "tags": [ "SiteCertificates" ], "summary": "Get all certificates in a resource group under a site.", "operationId": "SiteCertificates_List", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string", "pattern": "^[A-z][A-z0-9]*$" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/CertificateCollection" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "List Certificates by resource group": { "$ref": "./examples/ListSiteCertificatesByResourceGroup.json" } }, "x-ms-pageable": { "nextLinkName": "nextLink" } } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/certificates/{certificateName}": { "get": { "tags": [ "SiteCertificates" ], "summary": "Get a certificate belonging to a given site.", "operationId": "SiteCertificates_Get", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string", "pattern": "^[A-z][A-z0-9]*$" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string", "pattern": "^[A-z][A-z0-9]*$" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Get Certificate": { "$ref": "./examples/GetSiteCertificate.json" } } }, "put": { "tags": [ "SiteCertificates" ], "summary": "Create or update a certificate under a given site.", "operationId": "SiteCertificates_CreateOrUpdate", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string", "pattern": "^[A-z][A-z0-9]*$" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string" }, { "name": "certificateEnvelope", "in": "body", "description": "Details of certificate, if it exists already.", "required": true, "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "201": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Create Or Update Certificate": { "$ref": "./examples/CreateOrUpdateSiteCertificate.json" } } }, "delete": { "tags": [ "SiteCertificates" ], "summary": "Delete a certificate from the site.", "operationId": "SiteCertificates_Delete", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "Successfully deleted certificate." }, "204": { "description": "Certificate does not exist." }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Delete Certificate": { "$ref": "./examples/DeleteSiteCertificate.json" } } }, "patch": { "tags": [ "SiteCertificates" ], "summary": "Create or update a certificate under a given site.", "operationId": "SiteCertificates_Update", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string" }, { "name": "certificateEnvelope", "in": "body", "description": "Details of certificate, if it exists already.", "required": true, "schema": { "$ref": "./CommonDefinitions.json#/definitions/CertificatePatchResource" } }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Patch Certificate": { "$ref": "./examples/PatchSiteCertificate.json" } } } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/certificates": { "get": { "tags": [ "SiteCertificates" ], "summary": "Get all certificates in a resource group for a given site and a deployment slot.", "operationId": "SiteCertificates_ListSlot", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string", "pattern": "^[A-z][A-z0-9]*$" }, { "name": "slot", "in": "path", "description": "Name of the deployment slot. If a slot is not specified, the API will create a binding for the production slot.", "required": true, "type": "string" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/CertificateCollection" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "List Certificates by resource group for a slot": { "$ref": "./examples/ListSiteCertificatesByResourceGroupSlot.json" } }, "x-ms-pageable": { "nextLinkName": "nextLink" } } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/certificates/{certificateName}": { "get": { "tags": [ "SiteCertificates" ], "summary": "Get a certificate for a given site and deployment slot.", "operationId": "SiteCertificates_GetSlot", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string", "pattern": "^[A-z][A-z0-9]*$" }, { "name": "slot", "in": "path", "description": "Name of the deployment slot. If a slot is not specified, the API will create a binding for the production slot.", "required": true, "type": "string" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string", "pattern": "^[A-z][A-z0-9]*$" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Get Site Certificate for a slot": { "$ref": "./examples/GetSiteCertificateSlot.json" } } }, "put": { "tags": [ "SiteCertificates" ], "summary": "Create or update a certificate in a given site and deployment slot.", "operationId": "SiteCertificates_CreateOrUpdateSlot", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string" }, { "name": "slot", "in": "path", "description": "Name of the deployment slot. If a slot is not specified, the API will create a binding for the production slot.", "required": true, "type": "string" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string" }, { "name": "certificateEnvelope", "in": "body", "description": "Details of certificate, if it exists already.", "required": true, "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "201": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Create Or Update Certificate for slot": { "$ref": "./examples/CreateOrUpdateSiteCertificateSlot.json" } } }, "delete": { "tags": [ "SiteCertificates" ], "summary": "Delete a certificate for a given site and deployment slot.", "operationId": "SiteCertificates_DeleteSlot", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string" }, { "name": "slot", "in": "path", "description": "Name of the deployment slot. If a slot is not specified, the API will create a binding for the production slot.", "required": true, "type": "string" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "Successfully deleted certificate." }, "204": { "description": "Certificate does not exist." }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Delete Certificate for slot": { "$ref": "./examples/DeleteSiteCertificateSlot.json" } } }, "patch": { "tags": [ "SiteCertificates" ], "summary": "Create or update a certificate for a site and deployment slot.", "operationId": "SiteCertificates_UpdateSlot", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "name", "in": "path", "description": "Name of the site.", "required": true, "type": "string" }, { "name": "slot", "in": "path", "description": "Name of the deployment slot. If a slot is not specified, the API will create a binding for the production slot.", "required": true, "type": "string" }, { "name": "certificateName", "in": "path", "description": "Name of the certificate.", "required": true, "type": "string" }, { "name": "certificateEnvelope", "in": "body", "description": "Details of certificate, if it exists already.", "required": true, "schema": { "$ref": "./CommonDefinitions.json#/definitions/CertificatePatchResource" } }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/Certificate" } }, "default": { "description": "App Service error response.", "schema": { "$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse" } } }, "x-ms-examples": { "Patch Certificate for slot": { "$ref": "./examples/PatchSiteCertificateSlot.json" } } } } }, "definitions": {}, "parameters": {}, "securityDefinitions": { "azure_auth": { "type": "oauth2", "description": "Azure Active Directory OAuth2 Flow", "flow": "implicit", "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", "scopes": { "user_impersonation": "impersonate your user account" } } }, "security": [ { "azure_auth": [ "user_impersonation" ] } ] }