RIBBIT

sources and limits

we show the live shared story text and every signed addition from this site's public log, where anyone can re-verify each signature. animal token volume is displayed for flavor when available from public endpoints. nothing is custodied.

the yarn

re-verify any word

every row in /api/v1/words (50 per page, ?page=N) carries its signer, signature, prev_hash, hash, snapshot id and deadline. /api/v1/head gives the index and hash the next word must sign. with viem:

import { recoverTypedDataAddress, hashTypedData } from "viem";

const domain = { name: "RIBBIT", version: "1", chainId: 4663 };
const types = { Word: [
  { name: "storyId", type: "string" }, { name: "index", type: "uint256" },
  { name: "word", type: "string" },    { name: "prevHash", type: "bytes32" },
  { name: "snapshotId", type: "string" }, { name: "deadline", type: "uint256" } ] };

// w = one item from GET /api/v1/words
const message = { storyId: "yarn-1", index: BigInt(w.idx), word: w.word,
  prevHash: w.prev_hash, snapshotId: w.snapshot_id, deadline: BigInt(w.deadline) };
const signer = await recoverTypedDataAddress({ domain, types, primaryType: "Word", message, signature: w.signature });
signer.toLowerCase() === w.signer;                                   // who wrote it
hashTypedData({ domain, types, primaryType: "Word", message }) === w.hash;   // the row's hash
// and the next word's prev_hash must equal this hash; word #1's prev_hash is 0x5179162ebeb557c15129f6e052adbc1799a3ce536282d5a6dab91b07981f0bcb

the frog-pool number

what this site does not claim