goddid.money converts a Polymarket trader’s verified trading history into an on chain credit profile and enables borrowing FXRP against their performance. The protocol integrates Flare Data Connector (FDC) for trust minimized Polymarket ingestion, FAssets synthetic XRP for lending liquidity, Pyth Entropy for anti gaming loan variability, and Privy’s embedded wallet with session signer for deterministic enforcement. Users receive a real credit rating based on their Polymarket history and borrow directly into a Privy controlled wallet.
- Uses Flare’s Data Connector to fetch verifiable Web2 data from Polymarket.
- Backend constructs a Web2Json request with a jq post processor.
- Returns ABI encoded payload and Merkle proof verified on chain.
- On chain oracle contracts store validated positions and trades.
- Computes ROI, volatility normalized return, win rate, profit factor, drawdown, HHI concentration, and dead share.
- Produces performance and risk subscores.
- Transforms them via logistic PD model into a 300 to 850 credit score.
- Score determines LTV and borrowing power.
- Each loan quote consumes verifiable randomness.
- Randomness introduces controlled LTV and max borrow variation.
- Prevents deterministic loan farming.
- Removes backend and miner influence from credit pricing.
- Deployed contract address: 0x2e951d54caD20ff3CeA95bFc79CF11FfC62E0134
- Borrowing occurs in FXRP, synthetic XRP minted through Flare’s FAssets system.
- Liquidity comes from an external XRP provider who deposits native XRP, converts it into FXRP, and seeds the lending pool.
- Pool is modular and can later be swapped for LP vaults, AMMs, or external yield strategies.
- Every user receives a Privy embedded wallet and a session signer.
- Session signer handles amortization pulls, collateral checks, liquidation, default writeoffs, and blacklist updates.
- Enables offline enforcement and removes the need for custom escrow logic.
- Saved the project from writing an entire custody and enforcement subsystem in hackathon constraints.
- Real time credit display
- Borrow, withdraw, and wallet connection modules
- Privy provider integrated with session signer initialization
- TSX component architecture
- Flare FDC, Web2Json, Merkle verified ingestion
- FAssets + FXRP synthetic XRP
- Pyth Entropy randomness
- XRPL address binding and flows
- Hardhat (TypeScript)
- Solidity contracts for:
- Credit scoring engine
- Polymarket oracle
- FXRP pool
- FAssets interactions
- TypeScript + ethers v6
- Flare Periphery Contracts
- Polymarket ingestion scripts
- FXRP minting, swapping, redeeming
- Credit engine runners
- Next.js
- React + TSX
- Privy embedded wallet
- Client side lending UI
yarn
# or
npm install --force
# Project Runbook & Architecture Notescp .env.example .env
Add PRIVATE_KEY, XRPL details, Privy keys
yarn dev
open http://localhost:3000
Start using our lending protocol!
npx hardhat compile
npx hardhat run scripts/polymarket/PolymarketUserData.ts --network coston2
npx hardhat run scripts/polymarket/PolymarketPosition.ts --network coston2
npx hardhat run scripts/creditEngine/submitPolymarketData.ts --network coston2
npx hardhat run scripts/creditEngine/runCreditScore.ts --network coston2
Flare provided verifiable Web2 ingestion through FDC and the synthetic XRP system through FAssets and FXRP, letting the protocol operate entirely on chain with real Polymarket data.
Privy replaced an entire escrow and enforcement subsystem by giving us embedded wallets and session signer delegated execution, letting the protocol handle repayments, liquidation, and debt recovery without user approvals.
Team: goddid.money
Zayaan, Pravesh, Konrad, Eric