> ## Documentation Index
> Fetch the complete documentation index at: https://docs.markz3d.com/llms.txt
> Use this file to discover all available pages before exploring further.

# DeleteSafe

Removes a safe from the world and deletes it from the database, it also works on disabled safes.

<table>
  <thead>
    <tr>
      <th scope="col">
        Argument
      </th>

      <th scope="col">
        Data Type
      </th>

      <th scope="col">
        Needed
      </th>

      <th scope="col">
        Default
      </th>

      <th scope="col">
        Description
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <th>`safe_id`</th>
      <td>string</td>
      <td>✅</td>
      <td>`-`</td>
      <td>The id of the safe to delete</td>
    </tr>
  </tbody>
</table>

> **Returns**
>
> <table>
>   <thead>
>     <tr>
>       <th scope="col">
>         Type
>       </th>
>
>       <th scope="col">
>         Description
>       </th>
>     </tr>
>   </thead>
>
>   <tbody>
>     <tr>
>       <td>boolean</td>
>
>       <td>
>         true if the safe has been deleted, false otherwise
>       </td>
>     </tr>
>
>     <tr>
>       <td>string | nil</td>
>
>       <td>
>         The error message if the safe has not been deleted (`Safe not found`)
>       </td>
>     </tr>
>   </tbody>
> </table>

> **Example**
>
> ```lua theme={null}
> exports["mxc_safe"]:DeleteSafe(safeId)
> ```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.