primer · onchain

Four onchain primitives, demystified.

Every idea in this repo leans on one of four web3 primitives. Each one runs against the 0G Galileo testnet (a free, real EVM L1 with native storage + AI) so you can ship a verifiable demo with zero hosting cost. Users sign in with Google via Privy, then top up their embedded wallet from the 0G faucet (0.1 OG/day) to pay testnet gas.

The three secrets

Add these in your Lovable project (Settings → Secrets) before pasting any mega-prompt. 0G's public RPC (https://evmrpc-testnet.0g.ai) is hardcoded — no RPC key needed.

  • METAMASK_PRIVATE_KEYExported from MetaMask. Fund on 0G Galileo via the faucet.open ↗
  • PRIVY_APP_IDGoogle sign-in + embedded wallet on 0G Galileo. User signs every tx and pays gas in OG (faucet: 0.1 OG/day).open ↗
  • LOVABLE_API_KEYAuto-provisioned by Lovable for AI calls via Lovable AI Gateway. Nothing to paste. Default model: google/gemini-3-flash-preview.open ↗