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

# SingleDepositorVault

> Single-depositor vault with direct deposit, withdraw, and execute capabilities

## Overview

`SingleDepositorVault` extends [BaseVault](/contract-reference/base-vault) with direct deposit and withdraw functions for a single vault owner. It is designed for dedicated treasury management where one entity (the vault owner) deposits assets and a guardian executes strategy operations on their behalf.

Unlike the multi-depositor model, `SingleDepositorVault` does not use tokenized vault units or a Provisioner. The vault owner interacts directly with the vault contract to deposit and withdraw assets. The guardian model, Merkle verification, hooks, and pause functionality are all inherited from `BaseVault`.

Fee calculation for single-depositor vaults uses the `DelayedFeeCalculator`, which applies time-delayed fee accrual based on accountant-reported vault values. See [FeeVault](/contract-reference/fee-vault) for fee distribution details.

## Functions

### deposit

Deposits assets into the vault. Only callable by the vault owner. Assets are held by the vault and managed by the guardian via submitted operations.

**Signature:**

```solidity theme={null}
function deposit(address token, uint256 amount) external
```

| Parameter | Type      | Description                            |
| --------- | --------- | -------------------------------------- |
| `token`   | `address` | Address of the ERC-20 token to deposit |
| `amount`  | `uint256` | Amount of tokens to deposit            |

### withdraw

Withdraws assets from the vault. Only callable by the vault owner.

**Signature:**

```solidity theme={null}
function withdraw(address token, uint256 amount, address recipient) external
```

| Parameter   | Type      | Description                             |
| ----------- | --------- | --------------------------------------- |
| `token`     | `address` | Address of the ERC-20 token to withdraw |
| `amount`    | `uint256` | Amount of tokens to withdraw            |
| `recipient` | `address` | Address to receive the withdrawn tokens |

### execute

Executes an arbitrary call from the vault. Only callable by the vault owner. This provides a direct execution path outside the guardian model for owner-level administrative actions.

**Signature:**

```solidity theme={null}
function execute(address target, bytes calldata data) external returns (bytes memory)
```

| Parameter | Type      | Description           |
| --------- | --------- | --------------------- |
| `target`  | `address` | Contract to call      |
| `data`    | `bytes`   | Calldata for the call |

### setFeeCalculator

Sets the fee calculator contract for this vault. Only callable by the vault owner.

**Signature:**

```solidity theme={null}
function setFeeCalculator(address calculator) external
```

| Parameter    | Type      | Description                                    |
| ------------ | --------- | ---------------------------------------------- |
| `calculator` | `address` | Address of the `DelayedFeeCalculator` contract |

## Events

### Deposited

Emitted when the vault owner deposits assets.

```solidity theme={null}
event Deposited(address indexed token, uint256 amount)
```

### Withdrawn

Emitted when the vault owner withdraws assets.

```solidity theme={null}
event Withdrawn(address indexed token, uint256 amount, address indexed recipient)
```

### Executed

Emitted when the vault owner executes a direct call.

```solidity theme={null}
event Executed(address indexed target, bytes data, bytes result)
```

## Errors

### SingleDepositorVault\_\_NotOwner

Thrown when a non-owner address attempts a deposit, withdraw, or execute action.

```solidity theme={null}
error SingleDepositorVault__NotOwner()
```

## Inheritance

* [BaseVault](/contract-reference/base-vault) -- Core guardian operations, Merkle verification, hooks, pause
  * **SingleDepositorVault** -- Adds single-depositor deposit/withdraw/execute

<Info>
  This page was manually created as a baseline. Run the [contract reference generation pipeline](/contract-reference/overview#generation-pipeline) to update with complete NatSpec documentation from the Solidity source.
</Info>
