# Remove a Sweep Policy

Stop treating an asset of a chain as an omnibus asset, once no customer holds a claim on it.

## Overview

- **Only with no customer's claim on the asset and no transfer of it on its way** — for `native`, no transfer at all on the chain: `409` `STRUCTURE_LEDGER_NOT_EMPTY` otherwise. To pause sweeps and keep the asset's sub-ledger, set the policy with `enabled` `false` instead ([Set a Sweep Policy](https://docs.aureahub.com/docs/structures-policy-put.md)).
- No policy for that chain and asset on the network: `404` `STRUCTURE_NOT_FOUND` (`No such sweep policy here.`). `asset` is matched in lower case.
- `204`, no body. The asset is no longer swept or reconciled, and no withdrawal is asked for in it; its entries, its transfers and its last reconciliation stay readable, as history.
- For `owner`, `tenantadmin` and `non_signing_admin`, on their own tenant, with an access token. Written to your audit trail [Coming soon, upon request](https://docs.aureahub.com/docs/feature-availability.md), as `structure.sweep_policy_removed`.

## Endpoint

### `DELETE /v1/structures/{network}/sweep-policies/{chainId}/{asset}`

Authentication: bearer token required.

Removes the sweep policy of one asset on one chain of the network.

**Path parameters**

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `network` | string | yes | `mainnet` or `testnet` |
| `chainId` | integer | yes | The policy's chain id |
| `asset` | string | yes | `native`, or the token's contract address |

**Responses**

`204` No Content

`404` Not found

```json
{
  "statusCode": 404,
  "error": "NotFoundError",
  "message": "No such sweep policy here.",
  "details": { "code": "STRUCTURE_NOT_FOUND" }
}
```

`409` Claims held

```json
{
  "statusCode": 409,
  "error": "ConflictError",
  "message": "Customers still hold claims on this asset, or a transfer of it is on its way",
  "details": { "code": "STRUCTURE_LEDGER_NOT_EMPTY" }
}
```

**Example request**

```bash
curl -X DELETE https://api.aureahub.com/v1/structures/mainnet/sweep-policies/8453/native \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
```

---

Web version: https://docs.aureahub.com/#structures-policy-delete
