Testnet · LitVM · Dokumentasi Resmi Testnet · LitVM · Official Docs

Dokumentasi Freesia DEXFreesia DEX Documentation

Panduan ringkas tentang apa itu Freesia, cara kerjanya, kontrak yang dipakai, dan pendekatan keamanannya. Semua terbuka untuk diverifikasi. A concise guide to what Freesia is, how it works, the contracts it uses, and its security approach. All open for verification.

1. PengenalanIntroduction

Freesia DEX adalah automated market maker (AMM) yang berjalan di LitVM Testnet — jaringan EVM pertama Litecoin. Freesia menyediakan siklus DeFi lengkap dalam satu aplikasi: tukar token (swap), sediakan likuiditas, stake LP token, dan dapatkan reward. Freesia DEX is an automated market maker (AMM) running on LitVM Testnet — Litecoin's first EVM network. Freesia offers a complete DeFi cycle in one app: swap tokens, provide liquidity, stake LP tokens, and earn rewards.

Yang membedakan Freesia bukan jumlah fitur, tapi fokus pada transparansi dan perlindungan pengguna. Kami mempublikasikan temuan audit sendiri, menampilkan risiko harga secara jujur, dan mengintegrasikan oracle resmi ekosistem. What sets Freesia apart isn't feature count, but a focus on transparency and user protection. We publish our own audit findings, show price risk honestly, and integrate the ecosystem's official oracle.

2. FiturFeatures

  • Swap — tukar token dengan AMM constant-product, fee 0.3%, proteksi slippage.Swap — trade tokens via constant-product AMM, 0.3% fee, slippage protection.
  • Likuiditas — tambah/tarik likuiditas ke pool USDC/DAI, LP token bisa ditransfer.Liquidity — add/remove liquidity to the USDC/DAI pool, transferable LP tokens.
  • Staking (Earn) — stake LP untuk mendapatkan reward token FREE dengan periode terbatas waktu.Staking (Earn) — stake LP to earn FREE reward tokens over a time-bounded period.
  • Harga referensi DIA — harga pasar independen di samping harga pool.DIA reference pricing — independent market price shown next to pool price.
  • UX risiko jujur — dampak harga ditampilkan dalam nominal uang nyata, bukan cuma persen.Honest risk UX — price impact shown in real money, not just a percentage.
  • Faucet testnet, riwayat transaksi, kuotasi on-chain, dan koneksi wallet native.Testnet faucet, transaction history, on-chain quotes, and native wallet connection.

3. ArsitekturArchitecture

Freesia memakai model constant-product (x·y=k), sama seperti Uniswap V2. Harga ditentukan oleh rasio cadangan (reserve) dua token di pool. Setiap swap membayar fee 0.3% yang tertinggal di pool sebagai imbalan bagi penyedia likuiditas. Freesia uses a constant-product model (x·y=k), like Uniswap V2. Price is set by the ratio of the two token reserves in the pool. Each swap pays a 0.3% fee that stays in the pool as a reward for liquidity providers.

Stack
Solidity 0.8.x · LitVM LiteForge (chainId 4441) · Frontend HTML/JS + ethers.js · Oracle DIA (Chainlink-compatible) Solidity 0.8.x · LitVM LiteForge (chainId 4441) · HTML/JS frontend + ethers.js · DIA oracle (Chainlink-compatible)

4. Kontrak (dapat diverifikasi)Contracts (verifiable)

Semua alamat terbuka. Jangan percaya, verifikasi sendiri di explorer. All addresses are open. Don't trust, verify on the explorer yourself.

Jaringan: LitVM Testnet · Chain ID 4441 · Explorer: liteforge.explorer.caldera.xyz Network: LitVM Testnet · Chain ID 4441 · Explorer: liteforge.explorer.caldera.xyz

5. KeamananSecurity

Saat migrasi dari V2 ke V3, enam kelas kerentanan diidentifikasi dan ditutup secara terbuka (ditandai FIX #1–#6 di kode): During the V2→V3 migration, six vulnerability classes were identified and closed openly (marked FIX #1–#6 in code):

  • FIX #1setoran kecil tidak lagi lenyap (require lpTokens > 0).small deposits no longer vanish (require lpTokens > 0).
  • FIX #2cegah serangan first-depositor (MINIMUM_LIQUIDITY).first-depositor attack prevented (MINIMUM_LIQUIDITY).
  • FIX #3token sisa dikembalikan pada rasio tak seimbang.excess tokens returned on unbalanced ratio.
  • FIX #4proteksi slippage saat menarik likuiditas.slippage protection on liquidity removal.
  • FIX #5reentrancy guard di semua fungsi utama.reentrancy guard on all core functions.
  • FIX #6transfer gagal = revert, tidak diam-diam.failed transfers revert, never silent.
Kami memilih menampilkan kelemahan yang kami temukan, bukan menyembunyikannya. Ini fondasi kepercayaan. We choose to show the weaknesses we found, not hide them. That's the foundation of trust.

6. Oracle DIADIA Oracle

Freesia mengintegrasikan DIA, oracle resmi LitVM, untuk menampilkan harga pasar independen di samping harga pool. Feed yang tersedia: LTC, USDC, USDT, ETH, BTC (18 desimal, antarmuka Chainlink-compatible). Untuk token tanpa feed (mis. DAI, MBG), kami jujur menandai bahwa referensi belum tersedia. Freesia integrates DIA, LitVM's official oracle, to show independent market prices next to pool prices. Available feeds: LTC, USDC, USDT, ETH, BTC (18 decimals, Chainlink-compatible interface). For tokens without a feed (e.g. DAI, MBG), we honestly mark that a reference isn't available.

Harga oracle dicek kesegarannya (staleness): data lebih dari 2 jam ditandai sebagai perkiraan. Oracle hanya untuk referensi — tidak memengaruhi logika swap. Oracle prices are checked for staleness: data older than 2 hours is flagged as an estimate. The oracle is reference-only — it does not affect swap logic.

7. Model KeberlanjutanSustainability Model

  • Fee 0.3% saat ini 100% ke penyedia likuiditas — bukan ke protokol. Prioritas menarik likuiditas dulu.The 0.3% fee currently goes 100% to liquidity providers — not the protocol. Attracting liquidity comes first.
  • Fee-switch protokol dirancang (maks 1/6 fee, meniru Uniswap) tapi dimatikan default; hanya diaktifkan governance saat likuiditas cukup dalam.Protocol fee-switch is designed (max 1/6 of fees, mirroring Uniswap) but off by default; only enabled via governance once liquidity is deep enough.
  • Treasury awal dari dukungan ekosistem (grant, kredit audit), bukan dari fee pengguna.Early treasury from ecosystem support (grants, audit credits), not user fees.
  • Belum ada token. Token hanya masuk akal saat ada volume nyata yang membenarkannya.No token yet. A token only makes sense when real volume justifies it.

8. Cara Pakai (3 Langkah)How to Use (3 Steps)

  1. 1. Sambungkan walletConnect walletbuka app, tap Connect Wallet, otomatis diarahkan ke LitVM Testnet. Klaim token testnet lewat Faucet.open the app, tap Connect Wallet, auto-switch to LitVM Testnet. Claim testnet tokens via the Faucet.
  2. 2. Tambah likuiditasAdd liquiditydi tab Pool, isi USDC & DAI seimbang, Approve dua token, konfirmasi.in the Pool tab, enter balanced USDC & DAI, approve both tokens, confirm.
  3. 3. Stake & klaimStake & claimdi tab Earn, stake LP, reward FREE mulai terkumpul dan bisa diklaim kapan saja.in the Earn tab, stake LP; FREE rewards accrue and can be claimed anytime.

9. Status & DisclaimerStatus & Disclaimer

Fase testnet. Freesia berjalan di LitVM Testnet, bukan mainnet.Testnet phase. Freesia runs on LitVM Testnet, not mainnet.

Belum diaudit pihak ketiga. Sudah ada audit mandiri (FIX #1–#6); audit profesional direncanakan sebelum mainnet.Not third-party audited. A self-audit is done (FIX #1–#6); a professional audit is planned before mainnet.

Solo developer. Dibangun dari nol, open source, transparan.Solo developer. Built from scratch, open source, transparent.

⚠️ Gunakan hanya dana testnet. Jangan gunakan dana sungguhan.⚠️ Use testnet funds only. Do not use real funds.

10. KontakContact