TR: Arkadaşlarla restoran hesabı veya grup masraflarını kolayca böl, payını Stellar testnet üzerinden anında gönder.
SplitPay is a responsive web dApp for the Stellar White Belt challenge. Enter a total, choose how many people are sharing, pick how many shares you pay for, and send your calculated XLM portion on Stellar testnet via Freighter.
https://splitpay-stellar.vercel.app
TR: Kullanıcının uygulamayı açmaktan başarılı ödemeye kadar geçtiği tam akış. Tüm validasyon ve hata yolları dahildir.
flowchart TD
A([🚀 Open SplitPay]) --> B{Freighter\nInstalled?}
B -- No --> C[Install Freighter\nfreighter.app]
C --> B
B -- Yes --> D[Connect Wallet\nrequestAccess API]
D --> E{Access\nGranted?}
E -- Denied --> F([❌ Show Error])
E -- Granted --> G[Fetch XLM Balance\nvia Horizon API]
G --> H[Display Balance\n+ Live USD Equivalent]
H --> I[Enter Bill Details\nTotal · People · Shares]
I --> J[Instant Share Calculation\nYour share = Total ÷ People × Shares]
J --> K[Enter Recipient Address]
K --> L{Address\nFormat Valid?}
L -- Invalid --> M([🔴 Invalid Badge\nSend Disabled])
L -- Valid --> N{Account Exists\non Testnet?\nHorizon Lookup}
N -- Not Found --> O([🟡 Warning Badge\nSend Disabled])
N -- ✅ Found --> P{Balance ≥\nYour Share?}
P -- Insufficient --> Q([🟠 Balance Warning\nSend Disabled])
P -- ✅ Sufficient --> R[Click Pay My Share 🚀]
R --> S[Build Transaction\nStellar SDK\nMemo + Payment Op]
S --> T[Sign via Freighter\nFreighter API]
T --> U{User\nApproves?}
U -- Rejected --> V([❌ Show Rejection])
U -- ✅ Approved --> W[Submit to\nHorizon Testnet]
W --> X{Transaction\nResult?}
X -- Failed --> Y([❌ Show Error\n+ Reason])
X -- ✅ Success --> Z[🎊 Confetti Burst!]
Z --> AA[Show TX Hash\n+ Stellar Expert Link]
AA --> BB[Refresh Balance]
BB --> I
style A fill:#6366f1,color:#fff,stroke:none
style Z fill:#10b981,color:#fff,stroke:none
style AA fill:#10b981,color:#fff,stroke:none
style F fill:#ef4444,color:#fff,stroke:none
style M fill:#ef4444,color:#fff,stroke:none
style O fill:#f59e0b,color:#fff,stroke:none
style Q fill:#f97316,color:#fff,stroke:none
style V fill:#ef4444,color:#fff,stroke:none
style Y fill:#ef4444,color:#fff,stroke:none
TR: Jüri için tüm akış ekran görüntüleri aşağıdadır.
TR: Cüzdan bağlantısı, bakiye görüntüleme, hesap bölme, XLM gönderimi, işlem geri bildirimi, çoklu ödeme, QR kod, USD karşılığı ve daha fazlası.
- Freighter wallet integration — connect / disconnect with
@stellar/freighter-api - Live XLM balance — fetched from Horizon with live XLM → USD conversion (CoinGecko)
- Copy address — one-click clipboard copy of your own Stellar address
- Split-first UX — total bill, group size, and "you pay for N people" with instant share calculation
- Balance guard — send button disabled automatically when balance is insufficient
- Recipient validation — debounced testnet account existence check before sending
- QR code — shows recipient address as scannable QR when address is verified
- Copy split summary — one-click clipboard message with per-person share + app link
- Multi-Pay — bundle payments to multiple recipients into a single Stellar transaction (multi-op)
- On-chain memo (Text) — embedded via
Memo.text()inTransactionBuilder, visible on Stellar Expert - EN / TR UI toggle — English default for global jury; Turkish for local demos
- Testnet payments —
TransactionBuilder+ Freighter signing + Horizon submission - Transaction feedback — loading state, success/error, transaction hash, Stellar Expert link
- Confetti animation — celebratory particle burst on successful payment
- Friendbot shortcut — one-click testnet funding when balance is empty
TR: İşlemlere
Memo.text()ile zincir üstü not eklenir (maks. 28 karakter). Stellar Expert'te herkese açık olarak görünür, harici veritabanı gerekmez.
Payments attach an optional Memo (Text) field (max 28 characters) using the Stellar SDK. This follows Stellar's on-ledger metadata pattern — no off-chain database required for payment context. Reviewers can verify memos on Stellar Expert (testnet).
TR: Next.js 14, TypeScript, Tailwind CSS, Stellar SDK, Freighter API.
- Next.js 14 (App Router)
- TypeScript
- Tailwind CSS
@stellar/stellar-sdk@stellar/freighter-api
TR: Kurulum için Freighter eklentisini yükle, ağı Testnet'e al, aşağıdaki komutları çalıştır.
- Freighter browser extension
- Freighter set to Testnet (Settings → Network → Testnet)
- Node.js 18+
git clone https://github.com/deniznizam/splitpay-stellar.git
cd splitpay-stellar
npm install
npm run devOpen http://localhost:3000.
cp .env.example .env.local
# Set NEXT_PUBLIC_APP_URL=https://your-splitpay.vercel.appTR:
NEXT_PUBLIC_APP_URL— "Özeti Kopyala" butonunun oluşturduğu mesajın sonundaki link. Vercel'e deploy sonrası gerçek URL'inizi yazın. Yazılmazsa tarayıcının adresi kullanılır.
TR: Bakiyeniz 0 ise uygulamadaki "Bedava Test Parası Al" butonuna basın.
- Connect your wallet in the app
- Click Get test XLM, or use Stellar Laboratory Friendbot
TR: Demo senaryodan birini seç → kendi adresini alıcı olarak gir → "Payımı Gönder" → Freighter'da onayla.
- Select a demo scenario (Pizza Night, Dinner at Luna, Coffee Break)
- Enter a valid testnet recipient address (or your own address to test)
- Add an on-chain memo (e.g.
Pizza split) - Click Pay My Share Now and approve in Freighter
- Watch the confetti 🎊 and verify on Stellar Expert
TR:
src/components/altında UI bileşenleri,src/lib/altında Stellar/i18n/split mantığı bulunur.
src/
├── app/
├── components/
│ ├── SplitPayApp.tsx
│ ├── SplitCalculator.tsx # Split UI + QR + account validation
│ ├── MultiPay.tsx # Multi-recipient single-tx payments
│ ├── Confetti.tsx # Canvas confetti animation
│ ├── LanguageToggle.tsx # EN / TR
│ ├── WalletButton.tsx
│ ├── BalanceCard.tsx # Balance + USD price + copy address
│ └── TransactionFeedback.tsx
└── lib/
├── stellar.ts # Freighter + Horizon + Memo.text + multi-op
├── split.ts
└── i18n.ts
public/
├── images/
└── screenshots/
TR: Vercel'de GitHub reposunu seç, Next.js otomatik algılanır, deploy et.
- Push to a public GitHub repository
- Import repo at vercel.com/new — Next.js auto-detected
- No env vars required (Horizon testnet URL is hardcoded)
- Optional: add
NEXT_PUBLIC_APP_URLin Vercel → Settings → Environment Variables - Paste live URL into README
- Freighter + Stellar Testnet
- Wallet connect / disconnect
- XLM balance from Horizon
- Send XLM on testnet
- Success / failure feedback with transaction hash
- On-chain memo support
- EN / TR UI
- Public GitHub repository → https://github.com/deniznizam/splitpay-stellar
- Deploy to Vercel → https://splitpay-stellar.vercel.app
- README live URL + screenshots attached
MIT








