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

> ## Agent Instructions
> This page is part of the Solana developer documentation at https://solana.com/developers/docs. Append `.md` to any docs URL, or send `Accept: text/markdown`, to get the page as Markdown.
> Index of all pages: https://solana.com/llms.txt. Per-section indexes such as https://solana.com/developers/docs/payments/llms.txt are smaller; prefer them when working on one task.
> Coding agents: install the official Solana skill for current APIs and conventions with `npx skills add https://github.com/solana-foundation/solana-dev-skill` (also served at https://solana.com/SKILL.md).
> Code in the cookbook and task pages comes from tested example files. Prefer it over writing API calls from memory.

# Référence de l'API

> Référence complète de l'API TypeScript pour LiteSVM

Documentation complète de l'API pour utiliser LiteSVM avec `@solana/kit` et son écosystème
de plugins.

## Sections de l'API

<Columns cols={2}>
  <Card title="Gestion des comptes" href="/developers/docs/tools/litesvm/typescript/api-reference/account-management">
    setAccount, getAccount, airdrop, getBalance
  </Card>
  <Card title="Transactions" href="/developers/docs/tools/litesvm/typescript/api-reference/transactions">
    sendTransaction, simulateTransaction, gestion du blockhash
  </Card>
  <Card title="Configuration" href="/developers/docs/tools/litesvm/typescript/api-reference/configuration">
    Méthodes de builder pour configurer LiteSVM
  </Card>
  <Card title="Temps et sysvars" href="/developers/docs/tools/litesvm/typescript/api-reference/time-and-sysvars">
    Manipulation de l'horloge et accès aux sysvars
  </Card>
</Columns>

## Référence rapide

### Configuration du plugin

```typescript
import { createClient, generateKeyPairSigner } from "@solana/kit";
import { litesvm } from "@solana/kit-plugin-litesvm";
import { signer } from "@solana/kit-plugin-signer";

const mySigner = await generateKeyPairSigner();
const client = createClient().use(signer(mySigner)).use(litesvm());
// client.svm: LiteSVM instance
// client.rpc: RPC compatibility layer
```

### Gestion des comptes (client.svm)

| Méthode                                 | Description                   |
| -------------------------------------- | ----------------------------- |
| `setAccount(account)`                  | Définir directement l'état d'un compte    |
| `getAccount(address)`                  | Récupérer les données d'un compte         |
| `getBalance(address)`                  | Obtenir le solde en SOL               |
| `airdrop(address, lamports)`           | Alimenter un compte               |
| `minimumBalanceForRentExemption(size)` | Calculer le minimum requis pour l'exemption de rent |

### Gestion des programmes (client.svm)

| Méthode                                | Description                |
| ------------------------------------- | -------------------------- |
| `addProgram(programId, bytes)`        | Charger un programme à partir d'octets    |
| `addProgramFromFile(programId, path)` | Charger un programme à partir d'un fichier .so |

### Transactions (client.svm)

| Méthode                    | Description                    |
| ------------------------- | ------------------------------ |
| `sendTransaction(tx)`     | Exécuter une transaction          |
| `simulateTransaction(tx)` | Simuler sans modifier l'état |
| `latestBlockhash()`       | Obtenir le blockhash actuel          |
| `expireBlockhash()`       | Passer au blockhash suivant       |

### Configuration (client.svm)

| Méthode                      | Description                           |
| --------------------------- | ------------------------------------- |
| `withSigverify(bool)`       | Activer/désactiver la vérification des signatures |
| `withBlockhashCheck(bool)`  | Activer/désactiver la validation du blockhash   |
| `withSysvars()`             | Réinitialiser les sysvars à leurs valeurs par défaut       |
| `withBuiltins()`            | Activer les programmes intégrés              |
| `withPrecompiles()`         | Activer les programmes précompilés           |
| `withTransactionHistory(n)` | Stocker les n dernières transactions             |
| `withComputeBudget(budget)` | Définir les limites de calcul                    |
| `withLamports(amount)`      | Définir le solde du faucet d'airdrop        |
| `withLogBytesLimit(n)`      | Définir la limite de sortie des journaux                  |

### Temps et sysvars (client.svm)

| Méthode                     | Description           |
| -------------------------- | --------------------- |
| `warpToSlot(slot)`         | Sauter à un slot précis |
| `getClock()`               | Obtenir la sysvar clock      |
| `getRent()`                | Obtenir la sysvar rent       |
| `getEpochSchedule()`       | Obtenir le calendrier des epoch    |
| `getLastRestartSlot()`     | Obtenir le dernier slot de redémarrage |
| `setLastRestartSlot(slot)` | Définir le dernier slot de redémarrage |

### RPC (client.rpc)

| Méthode                           | Description                        |
| -------------------------------- | ---------------------------------- |
| `getAccountInfo(address)`        | Récupérer un seul compte (base64 uniquement) |
| `getMultipleAccounts(addresses)` | Récupérer plusieurs comptes            |
| `getLatestBlockhash()`           | Obtenir le blockhash actuel              |
