# Proofnetwork Sample Click Counter

> Use this when scaffolding a first ProofNetwork app: a signed click counter contract plus a proofwallet leaderboard/pie UI.

- Skill: `shixuuu/proofnetwork-sample-click-counter` (Agent Skill)
- Install (CLI): `npx get-skill add shixuuu/proofnetwork-sample-click-counter`
- Raw SKILL.md: https://api.skillmd.com/api/skills/shixuuu/proofnetwork-sample-click-counter/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: Shixuuu (https://skillmd.com/u/shixuuu)
- Updated: 2026-11-24
- Page: https://skillmd.com/skills/shixuuu/proofnetwork-sample-click-counter

---


Use this when someone wants a first working ProofNetwork app: a signed global click counter, a leaderboard, pie-chart data, and a browser UI. Replace 0xYourContract with the address returned by deploy.

Ship order: lint, simulate click without a signature (requiresSignature), simulate views, deploy, then set CONTRACT in the frontend.

Contract: const state with metadata, totalClicks, players. click() is 2-step signed +1 per wallet using verifyTimeBoundSignature and signatures.markUsed. getLeaderboard, getPieChart, getStats are @view. getPieChart returns slices with percent and an Others bucket.

Frontend: static index.html + app.js. apiUrl must be https://proofnetwork.lol/api. Load proofwallet from jsdelivr. Click signs with signatureBase58. Burner path for testing. If JSON.parse fails on <!DOCTYPE, apiUrl is missing /api.

