primer · onchain

Four onchain primitives, demystified.

Every idea in this repo leans on one of these web3 primitives. Each one runs against Sei Testnet (atlantic-2 — Sei's parallelized EVM testnet with 400ms finality) so you can ship a verifiable demo with zero hosting and zero gas spent by your users.

The four secrets

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

  • METAMASK_PRIVATE_KEYExported from MetaMask. Fund on Sei Testnet via the Sei faucet (captcha → request SEI, 1× per 24h).open ↗
  • SEI_TESTNET_RPC_URLPublic default is https://evm-rpc-testnet.sei-apis.com. For heavy reads, use Ankr or DRPC.open ↗
  • PRIVY_APP_IDGoogle sign-in with a Sei Testnet embedded wallet — user pays their own gas from the Sei faucet.open ↗
  • PINATA_JWTPin to IPFS.open ↗
  • ChainSei Testnet · chainId 1328 (atlantic-2) · explorer https://testnet.seiscan.io

AI calls · Lovable AI Gateway

Any AI step in a mega-prompt runs through the Lovable AI Gateway using LOVABLE_API_KEY — auto-provisioned by Lovable, no signup, no key to paste. This is the primary path for every participant.

AISA_API_KEY is a personal fallback used only by the maintainer when Lovable AI credits run out. Participants can ignore it.

x402 native

Sei + x402 paywall

996 ideas use this
kernel
an x402 pay-per-use paywall on Sei Devnet (arctic-1, chainId 713715) — Privy embedded wallet signs EIP-3009 USDC authorizations, a same-origin proxy relays PAYMENT-SIGNATURE to a facilitator (PayAI) that settles 0.01 USDC and returns a Sei tx hash in PAYMENT-RESPONSE
how it drives the UI
a 4-step flow log (Challenge → Sign → Retry → Settle) that ends with a live Seiscan tx link proving the micropayment cleared