> ## 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.

# مرجع API

> مرجع كامل لواجهة TypeScript API الخاصة بـ LiteSVM

توثيق API كامل لاستخدام LiteSVM مع `@solana/kit` ومنظومة الإضافات
الخاصة به.

## أقسام API

<Columns cols={2}>
  <Card title="إدارة الحسابات" href="/developers/docs/tools/litesvm/typescript/api-reference/account-management">
    setAccount, getAccount, airdrop, getBalance
  </Card>
  <Card title="المعاملات" href="/developers/docs/tools/litesvm/typescript/api-reference/transactions">
    sendTransaction, simulateTransaction، وإدارة blockhash
  </Card>
  <Card title="التهيئة" href="/developers/docs/tools/litesvm/typescript/api-reference/configuration">
    دوال Builder لتهيئة LiteSVM
  </Card>
  <Card title="الوقت وSysvars" href="/developers/docs/tools/litesvm/typescript/api-reference/time-and-sysvars">
    التحكم في الساعة (Clock) والوصول إلى sysvar
  </Card>
</Columns>

## مرجع سريع

### إعداد الإضافة

```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
```

### إدارة الحسابات (client.svm)

| الدالة                                 | الوصف                   |
| -------------------------------------- | ----------------------------- |
| `setAccount(account)`                  | تعيين حالة الحساب مباشرةً    |
| `getAccount(address)`                  | جلب بيانات الحساب         |
| `getBalance(address)`                  | الحصول على رصيد SOL               |
| `airdrop(address, lamports)`           | تمويل حساب               |
| `minimumBalanceForRentExemption(size)` | حساب الحد الأدنى للإعفاء من rent |

### إدارة البرامج (client.svm)

| الدالة                                | الوصف                |
| ------------------------------------- | -------------------------- |
| `addProgram(programId, bytes)`        | تحميل برنامج من البايتات    |
| `addProgramFromFile(programId, path)` | تحميل برنامج من ملف .so |

### المعاملات (client.svm)

| الدالة                    | الوصف                    |
| ------------------------- | ------------------------------ |
| `sendTransaction(tx)`     | تنفيذ معاملة          |
| `simulateTransaction(tx)` | المحاكاة دون تغيير الحالة |
| `latestBlockhash()`       | الحصول على blockhash الحالي          |
| `expireBlockhash()`       | الانتقال إلى blockhash جديد       |

### التهيئة (client.svm)

| الدالة                      | الوصف                           |
| --------------------------- | ------------------------------------- |
| `withSigverify(bool)`       | تفعيل/تعطيل التحقق من التوقيعات |
| `withBlockhashCheck(bool)`  | تفعيل/تعطيل التحقق من blockhash   |
| `withSysvars()`             | إعادة تعيين sysvars إلى قيمها الافتراضية       |
| `withBuiltins()`            | تفعيل البرامج المدمجة              |
| `withPrecompiles()`         | تفعيل البرامج المُجمَّعة مسبقًا           |
| `withTransactionHistory(n)` | تخزين آخر n معاملة             |
| `withComputeBudget(budget)` | تعيين حدود الحوسبة                    |
| `withLamports(amount)`      | تعيين رصيد صنبور airdrop        |
| `withLogBytesLimit(n)`      | تعيين حد مخرجات السجل                  |

### الوقت وSysvars (client.svm)

| الدالة                     | الوصف           |
| -------------------------- | --------------------- |
| `warpToSlot(slot)`         | الانتقال إلى slot محدد |
| `getClock()`               | الحصول على sysvar الخاص بالساعة      |
| `getRent()`                | الحصول على sysvar الخاص بـ rent       |
| `getEpochSchedule()`       | الحصول على جدول epoch    |
| `getLastRestartSlot()`     | الحصول على آخر slot لإعادة التشغيل |
| `setLastRestartSlot(slot)` | تعيين آخر slot لإعادة التشغيل |

### RPC (client.rpc)

| الدالة                           | الوصف                        |
| -------------------------------- | ---------------------------------- |
| `getAccountInfo(address)`        | جلب حساب واحد (base64 فقط) |
| `getMultipleAccounts(addresses)` | جلب عدة حسابات            |
| `getLatestBlockhash()`           | الحصول على blockhash الحالي              |
