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

# PDA Helpers

> Seeds used by the core and oracle programs, mirrored in vanna-credit-backend/lib/solana/pdas.ts.

Core program (`VANNA_PROGRAM_ID`):

```ts theme={null}
protocolConfigPda()                   // ["protocol"]
assetConfigPda(mint)                  // ["asset", mint]       (also ["asset", venue] for a venue)
reservePda(mint)                      // ["reserve", mint]
shareMintPda(mint)                    // ["share_mint", mint]
marginPda(authority)                  // ["margin", authority]
debtPositionPda(margin, reserve)      // ["debt", margin, reserve]
integrationPda(programId)             // ["integration", program_id]
```

Oracle program (`ORACLE_PROGRAM_ID`):

```ts theme={null}
priceBookPda()                        // ["price_book"]
marketBookPda(venue)                  // ["market_book", venue]
```

Token accounts:

```ts theme={null}
reserveVault(mint, tokenProgram)          // ATA(mint, reserve PDA)
marginVault(margin, mint, tokenProgram)   // ATA(mint, margin PDA) — its live balance is the collateral
lenderShareAccount(lender, mint)          // ATA(share mint, lender), classic SPL Token
```

External:

```ts theme={null}
// Phoenix trader owned by the margin account (Phoenix program)
["trader", margin, u16 0]
// Pyth push-oracle feed account (push-oracle program)
[u16 shard 0 LE, feed_id_bytes]
```

All are `findProgramAddressSync`. Each mint's token program matters for ATAs: the xStocks are Token-2022, everything else is classic SPL Token.


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