primer · onchain

Four onchain primitives, demystified.

Every idea in this repo leans on one of four web3 primitives. Each one runs against Rootstock testnet (a free, real testnet) so you can ship a verifiable demo with zero hosting and zero gas spent by your users.

The five secrets

Add these in your Lovable project (Settings → Secrets) before pasting any mega-prompt:

  • METAMASK_PRIVATE_KEYExported from MetaMask. Fund on Rootstock testnet via the Google Cloud faucet.open ↗
  • ROOTSTOCK_EXPLORER_API_KEYFor npx hardhat verify after deploy.open ↗
  • PRIVY_APP_IDGoogle sign-in + faucet-funded transactions.open ↗
  • PINATA_JWTPin to IPFS.open ↗
  • ROOTSTOCK_TESTNET_RPC_URLOptional. A public RPC is used if omitted.
x402 native

Rootstock testnet + x402 paywall

996 ideas use this
kernel
an x402 v2 paywall that meters access with 0.01 USDC per call via EIP-3009 authorization, signed by an external MetaMask EOA (connected through Privy) and settled by a self-hosted facilitator on Rootstock testnet
how it drives the UI
a 'pay 0.01 USDC to unlock' button that returns the Rootstock testnet tx hash and links straight to Rootstock Explorer