---
title: "Delete attributes"
description: "Deletes one or more asset attributes by ID, with an optional force delete for attributes linked to assets."
contentType: "api-reference"
url: "https://developer.mindtickle.com/docs/asset-hub/asset-taxonomy/delete-attributes/"
---

## Prerequisites

1. [Authentication and setup](/docs/getting-started/authentication-and-setup/): A valid access token.
2. [Create attributes](/docs/asset-hub/asset-taxonomy/create-attributes/): The attributes must exist.

## Endpoint

```http
DELETE /api/assethub/v2/attribute_categories/attributes
```

Base URL: the standard REST host for your region. See [Base URLs](/docs/getting-started/authentication-and-setup/#base-urls).

Headers: `Authorization: Bearer ACCESS_TOKEN`, `Content-Type: application/json`.

## Request

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `attribute_ids` | string[] | Required | List of attribute IDs to delete. Maximum 100 attributes per request. Must not contain duplicates. |
| `force_delete` | boolean | Optional | Whether to remove attributes even if they are linked to assets. `true` deletes the attribute and removes it from all linked assets. `false` fails to delete an attribute that is linked to any asset. Default: `false`. |
| `user_id` | string | Required | User ID of the user performing the operation, used as the authorizer. |

### Request example

```json
{
  "attribute_ids": ["123456789012345101", "123456789012345102", "123456789012345103"],
  "force_delete": false,
  "user_id": "123456789abcd104"
}
```

## Response

| Field | Type | Description |
| --- | --- | --- |
| `request_id` | string | Unique ID for the request. |
| `deleted_attribute_ids` | string[] | List of attribute IDs that were successfully deleted. |
| `failed` | array | List of attributes that could not be deleted. Each object contains `attribute_id` and `reason`. |

### Response example

```json
{
  "request_id": "req_101",
  "deleted_attribute_ids": ["123456789012345101", "123456789012345103"],
  "failed": [
    {
      "attribute_id": "123456789012345102",
      "reason": "Attribute is currently linked with assets. Use force_delete=true to delete such attributes."
    }
  ]
}
```

## Notes

- **Limits:** Maximum 100 attributes per request.
- **Partial success:** The response is HTTP 200 even if some attributes fail to delete. Check the `failed` list in the response to identify any issues.
- **Validation:** Duplicate entries in `attribute_ids` are handled by deleting the first occurrence. Subsequent duplicates are reported in the `failed` list.
- **Validation:** If `force_delete` is `false`, attributes linked to assets fail with the reason "Attribute is currently linked with assets."

## Related

- [Create attribute categories](/docs/asset-hub/asset-taxonomy/create-attribute-categories/): Create the categories that hold attributes.
