# Solana Vaults

Upshift Solana Vaults bring the same institutional-grade vault infrastructure to the Solana ecosystem. Built as a native Anchor program, Solana vaults offer fast, non-custodial yield generation transparently on-chain, with actively managed strategies.

|                   |                                                 |
| ----------------- | ----------------------------------------------- |
| **Program**       | `up12bytoZBmwofqsySf2uqKQ7zpfeKiAWwfvqzJjtRt`   |
| **Framework**     | Anchor (v0.1.0)                                 |
| **Deposit Asset** | Any SPL Token                                   |
| **Share Token**   | PDA-minted receipt token with on-chain metadata |
| **Redemptions**   | Instant, no lock-ups                            |

### Vault Architecture

Each Upshift Solana vault is deployed as an instance of the `august_vault` program. A vault is initialized with three roles  (**admin**, **operator**, and **fee recipient),** and is bound to a single SPL deposit token (e.g. USDC). On initialization, the program creates:

* A **VaultState** PDA that stores all vault configuration and accounting
* A **share mint** PDA used to mint receipt tokens to depositors
* A **vault token ATA** PDA that holds the vault's deposit token balance

### Deposit Flow

1. User calls `deposit(amount)` with their SPL tokens
2. The vault transfers tokens from the user's account to the vault token ATA
3. Share tokens are minted to the user proportional to the current NAV:

```
   shares_minted = deposit_amount * total_share_supply / total_AUM
```

4. `local_aum` increases by the deposit amount
5. A `DepositEvt` is emitted with `caller`, `receiver`, `amount`, and `shares`

### Redemption Flow

1. User calls `redeem(shares)` with the number of share tokens to burn
2. The vault calculates the underlying token amount based on current NAV:

```
   tokens_returned = shares * total_AUM / total_share_supply
```

3. If a withdrawal fee is configured, the fee portion (in bps) is routed to the `fee_recipient`
4. Share tokens are burned and underlying tokens are transferred to the user
5. `local_aum` decreases by the redeemed amount
6. A `WithdrawEvt` is emitted with `caller`, `receiver`, `owner`, `assets`, and `shares`

### Share Price Derivation

The share token price is fully derivable on-chain:

```
share_price = (local_aum + deployed_aum) / total_share_supply
```

* **`local_aum`** - tokens held directly in the vault's token ATA. Fully verifiable on-chain.
* **`deployed_aum`** - value of tokens deployed in external strategies, reported by the operator via `operator_update_aum`.
* **`total_share_supply`** - readable from the share mint account.

Any Solana program can compute the share price by reading the VaultState account and the share mint. No external oracle is required.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.upshift.finance/vault-architecture/solana-vaults.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
