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

# Aave

Offer yield on [Aave](https://aave.com/) through Privy [earn](/wallets/actions/earn/overview). Your app deposits, withdraws, and reads positions through the standard earn API, and Privy handles the Aave-specific contract interactions for you.

<Info>
  Aave vaults are an **Enterprise plan** feature that Privy sets up for your app. Contact
  [sales@privy.io](mailto:sales@privy.io) to get started — you choose the chain, the token to
  supply, and the performance fee, and Privy deploys the vault. Once deployed, the vault appears
  under **Wallet infrastructure > Earn** in the [Privy Dashboard](https://dashboard.privy.io), where
  you can view its vault ID, address, admin wallet, and live APY and TVL at any time.
</Info>

## Resources

<CardGroup cols={2}>
  <Card title="Aave Earn vaults" icon="arrow-up-right-from-square" href="https://aave.com/docs/vaults/simple-earn/overview" arrow>
    How Aave's Earn vaults work on Aave v3 markets.
  </Card>

  <Card title="Earn" icon="vault" href="/wallets/actions/earn/overview" arrow>
    Deposit, withdraw, and track positions across yield vaults with a single API.
  </Card>
</CardGroup>

***

## How Aave works with Privy

Aave is served through Privy's native earn API. Once an Aave vault is enabled for your app, you interact with it through the standard earn endpoints — pass a `vault_id` to the deposit, withdraw, position, and vault-details endpoints.

A few things are specific to Aave:

* **Supplies to an Aave v3 market.** An Aave vault supplies a single token to an [Aave v3](https://aave.com/docs/aave-v3/overview) lending market on a given chain. You choose the chain and the token to supply when the vault is set up.
* **Performance fee and revenue sharing.** You set a performance fee between 0% and 100% of the yield the vault earns. The performance fee is shared 50/50 with Aave Labs. For example, with a 20% performance fee, users keep 80% of the vault's yield, your admin wallet receives 10%, and Aave Labs receives 10%.
* **Fee collection.** Performance fees accumulate in the vault rather than accruing to the vault's admin wallet automatically. Read the amount available to your app with `available_fees` from [get vault details](/wallets/actions/earn/get-vault-details), and collect it with the [collect performance fees](#collect-performance-fees) endpoint.

<Tip>
  Because Aave goes through the standard earn API, the [earn product
  docs](/wallets/actions/earn/overview) — [deposit](/wallets/actions/earn/deposit),
  [withdraw](/wallets/actions/earn/withdraw), [get vault
  details](/wallets/actions/earn/get-vault-details), [get vault
  position](/wallets/actions/earn/get-vault-position), and
  [webhooks](/wallets/actions/earn/webhooks) — all apply to Aave vaults. This guide highlights
  what's specific to Aave.
</Tip>

### Supported chains

Privy deploys Aave vaults on Ethereum, Base, Optimism, Polygon, and Arbitrum. Each vault supplies its token to an [Aave market](https://app.aave.com/markets) on one of these chains.

***

## Collect performance fees

Check how much is collectable with the [get vault details](/wallets/actions/earn/get-vault-details) endpoint. For Aave vaults, the response includes `available_fees` — the performance fees your app can currently collect, in the smallest unit of the underlying asset. This reflects your app's share after the split with Aave Labs.

```bash theme={"system"}
curl https://api.privy.io/api/v1/earn/ethereum/vaults/{vault_id} \
  -H "privy-app-id: <your-app-id>" \
  -H "Authorization: Basic <credentials>"
```

Performance fees accumulate in the vault contract. To collect them, submit a fee collection action with the vault's **admin wallet** — this moves the available fees from the vault to the admin wallet. Call the collect fees endpoint with the admin wallet's ID and the `vault_id`.

```bash theme={"system"}
curl -X POST https://api.privy.io/api/v1/wallets/{admin_wallet_id}/earn/ethereum/fees/collect \
  -H "privy-app-id: <your-app-id>" \
  -H "Authorization: Basic <credentials>" \
  -H "Content-Type: application/json" \
  -d '{
    "vault_id": "<your-aave-vault-id>"
  }'
```

* **Use the admin wallet.** The `wallet_id` in the path must be the vault's admin wallet. Find it in the Privy Dashboard or as `admin_wallet_id` in the [get vault details](/wallets/actions/earn/get-vault-details) response.
* **Authentication.** If the admin wallet was created automatically when the vault was deployed and has not been modified, you can authenticate this request with just your app secret.
* **Collects everything.** A single call collects all available fees for the vault; partial collection is not supported.

The call creates a `pending` wallet action that moves to `succeeded` once confirmed onchain. Track it by polling [get wallet action](/api-reference/wallets/actions/get) or by subscribing to the `wallet_action.earn_fee_collect` [webhooks](/wallets/actions/earn/webhooks). See the [collect fees](/wallets/actions/earn/collect-fees) endpoint for the full request and response.

<Info>
  The collected amount is your app's share of the performance fee, after the 50/50 split with Aave
  Labs. It is returned in the underlying asset and sent to the admin wallet.
</Info>

***

## Key integration tips

1. **Set the performance fee thoughtfully.** It can range from 0% to 100% of yield and is split 50/50 with Aave Labs, so a 20% fee leaves users with 80% of the vault's yield.
2. **Collect accrued fees.** Monitor `available_fees` from get vault details, then collect them by calling the collect fees endpoint with the admin wallet. Until collected, fees remain in the vault rather than your app's wallet.

<Warning title="Disclaimer">
  Privy does not control DeFi vaults or underlying protocols. Vault information is provided for
  reference only and may change or be inaccurate. Earnings are generated from third-party vaults and
  are not guaranteed. Using vaults involves risk, including loss of funds. These materials are for
  general information purposes only and are not investment advice or a recommendation or
  solicitation to engage in any specific transaction. You are responsible for evaluating vaults at
  your own discretion. Privy does not provide investment, financial, legal, or tax advice.
</Warning>
