# VaultDelete

[Source](https://github.com/XRPLF/rippled/blob/release/3.4.x/src/libxrpl/tx/transactors/vault/VaultDelete.cpp)

Permanently deletes an existing `Vault` object from the ledger, removes all associated ledger entries, and frees up the reserve requirement for the Vault Owner.

Only the Vault Owner can initiate this transaction, and the vault must be completely empty before deletion.

_Requires the [SingleAssetVault amendment](/resources/known-amendments#singleassetvault). (Open for Voting: 45.71%)_

_The [LendingProtocolV1_1 amendment](/resources/known-amendments#lendingprotocolv1_1) updates this. (Open for Voting: 0.00%)_

## Example  JSON

```json
{
  "TransactionType": "VaultDelete",
  "Account": "ra5nK24KXen9AHvsdFTKHSANinZseWnPcX",
  "Fee": "12",
  "Flags": 0,
  "LastLedgerSequence": 7108682,
  "Sequence": 8,
  "VaultID": "77D6234D074E505024D39C04C3F262997B773719AB29ACFA83119E4210328776"
}
```

##   Fields

In addition to the [common fields](https://xrpl.org/docs/references/protocol/transactions/common-fields#transaction-common-fields),  transactions use the following fields:

| Field Name | JSON Type | [Internal Type](/docs/references/protocol/binary-format) | Required? | Description |
|  --- | --- | --- | --- | --- |
| `MemoData` | String | Blob | No | A data field to record why the vault was deleted, as hexadecimal. Limited to 256 bytes. _Requires the [LendingProtocolV1_1 amendment](/resources/known-amendments#lendingprotocolv1_1). (Open for Voting: 0.00%)_ |
| `VaultID` | String | Hash256 | Yes | The unique identifier of the vault that needs to be deleted. |


##  Flags

There are no flags defined for  transactions.

## Error Cases

Besides errors that can occur for all transactions, VaultCreate transactions can result in the following [transaction result codes](/docs/references/protocol/transactions/transaction-results):

| Error Code | Description |
|  --- | --- |
| `tecNO_ENTRY` | The `Vault` object with the provided `VaultID` does not exist on the ledger. |
| `tecNO_PERMISSION` | The account submitting the transaction doesn't own the vault. |
| `tecHAS_OBLIGATIONS` | The vault still holds assets or has outstanding shares, so it can't be deleted. |
| `temDISABLED` | The [SingleAssetVault amendment](/resources/known-amendments#singleassetvault) isn't enabled.`MemoData` is present and the [LendingProtocolV1_1 amendment](/resources/known-amendments#lendingprotocolv1_1) isn't enabled. |
| `temMALFORMED` | `VaultID` is zero.`MemoData` is present but empty, or longer than 256 bytes. _The [LendingProtocolV1_1 amendment](/resources/known-amendments#lendingprotocolv1_1) updates this. (Open for Voting: 0.00%)_ |


## See Also

- [Vault entry](/docs/references/protocol/ledger-data/ledger-entry-types/vault)