Delete Index (Azure Search Service REST API)

The Delete Index operation removes an index and associated documents from your Azure Search service. You can get the index name from the service dashboard in the Azure Preview portal, or from the API. See List Indexes (Azure Search Service REST API) for details.

DELETE https://[service name].search.windows.net/indexes/[index name]?api-version=[api-version]  
api-key: [admin key]  

Request

HTTPS is required for service requests. The Delete Index request can be constructed using the DELETE method.

The [index name] in the request URI specifies which index to delete from the indexes collection.

The api-version parameter is required. The current version is api-version=2016-09-01. See API versions in Azure Search for a list of available versions.

Request Headers

The following table describes the required and optional request headers.

Request Header Description
api-key: Required. The api-key is used to authenticate the request to your Search service. It is a string value, unique to your service URL. The Delete Index request must include an api-key header set to your admin key (as opposed to a query key).

You will also need the service name to construct the request URL. You can get the service name and api-key from your service dashboard in the Azure Preview Portal. See Create an Azure Search service in the portal for page navigation help.

Request Body

None.

Response

Status Code: 204 No Content is returned for a successful response.

See also

Azure Search Service REST
HTTP status codes (Azure Search)
Create Index (Azure Search Service REST API)
API versions in Azure Search