# ImportLocationsController_DeleteLocation

Deletes a location.

`DELETE /api/v1/ImportLocations/DeleteLocation`

**API:** Excise Platform API
**Tag:** ImportLocationsController
**API Version:** v1
**Base URL:** https://excise.avalara.com
**Accepts:** `text/plain`
**Authentication:** Basic (username + license key)

Source: https://developer.avalara.com/products/excise/api/methods/ImportLocationsController/ImportLocationsController_DeleteLocation/

## Description

Permanently deletes a location by its unique identifier. The location must belong to the current
master company and must not be locked or in use by profiles, scenarios, cross-references, or company accounts.
Associated location alternates and special jurisdictions are also deleted.

## Parameters

| Name | Type | In | Required | Description |
|---|---|---|---|---|
| `x-company-id` | integer | header | Yes | Company ID that owns the data. |
| `X-Avalara-Client` | string | header | No | Identifies the software you are using to call this API. For more information on the client header, see Client Headers. |
| `locationId` | integer | query | Yes | The unique identifier of the location to delete. |

## Responses

| Status | Description | Schema |
|---|---|---|
| 200 | Returns a message indicating the result of the delete operation. |  |
| 400 | The location was not found, does not belong to the current company, or is locked. |  |

## Example Request

```bash
curl -X DELETE "https://excise.avalara.com/api/v1/ImportLocations/DeleteLocation" \
  -H "Authorization: Basic <credentials>" \
  -H "Accept: application/json"
```