Docs

MoonX, PayBox, and x402 for people who still have email.

Tip link unlock

someone wants a tip jar that actually unlocks something. not a newsletter. not a dao. a tip.

stack

  • k4d pay product (NEXT_PUBLIC_PAY_URL, local /pay)
  • moonx session for creators; tippers pay USDC from a moonx wallet
  • unlock cookie: k4d_pay_<payLinkId>
  • APIs: POST /api/pay, GET /api/pay/[id], tip via PATCH /api/pay/[id] with { action: "tip", payerWallet, txHash }

this MVP is not paybox and not x402. it is direct USDC + cookie unlock. x402 is a future rail if you want HTTP 402 semantics. see x402-paywalled-api.

steps

1. create a link

signed-in creator posts to /api/pay with tip amount, title, unlock body (and related fields). UI: /pay/new.

2. share

send the public pay link. strangers tip. strangers should not see creator email on public GET responses. that is not "transparency", that is a privacy failure.

3. tip + unlock

tipper signs in (moonx), sends USDC to creatorWallet, then PATCH tip with txHash. server records the tip and sets k4d_pay_<id> cookie so unlock content renders.

pitfalls

  • do not market this as paybox. wrong product.
  • cookie unlock is browser-local trust. it is fine for tips. it is not a fortress.
  • public payloads must strip PII for non-creators.

next