{"id":25633773,"url":"https://github.com/jongan69/potion-leaderboard","last_synced_at":"2026-06-11T20:31:55.400Z","repository":{"id":277269354,"uuid":"931888378","full_name":"jongan69/potion-leaderboard","owner":"jongan69","description":"Start of Entry for potion leaderboard contest","archived":false,"fork":false,"pushed_at":"2025-02-16T16:59:26.000Z","size":1569,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-22T22:29:40.378Z","etag":null,"topics":["data-analysis","leaderboard","potion","trading"],"latest_commit_sha":null,"homepage":"https://potionleaderboard.xyz","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jongan69.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-02-13T02:41:34.000Z","updated_at":"2025-02-21T13:21:34.000Z","dependencies_parsed_at":"2025-02-13T03:37:55.205Z","dependency_job_id":null,"html_url":"https://github.com/jongan69/potion-leaderboard","commit_stats":null,"previous_names":["jongan69/potion-leaderboard"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jongan69/potion-leaderboard","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jongan69%2Fpotion-leaderboard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jongan69%2Fpotion-leaderboard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jongan69%2Fpotion-leaderboard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jongan69%2Fpotion-leaderboard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jongan69","download_url":"https://codeload.github.com/jongan69/potion-leaderboard/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jongan69%2Fpotion-leaderboard/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34217312,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-11T02:00:06.485Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-analysis","leaderboard","potion","trading"],"created_at":"2025-02-22T22:29:41.330Z","updated_at":"2026-06-11T20:31:55.362Z","avatar_url":"https://github.com/jongan69.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Potion Trader Leaderboard\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://potionleaderboard.xyz/\"\u003e\n    \u003cimg src=\"./public/logo.webp\" /\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n[Live Demo](https://potionleaderboard.xyz/)\n\nA Next.js application that displays the leaderboard for Potion Traders on Solana, built for the Potion Competition.\n\n## Tech Stack\n- Frontend: Next.js, TailwindCSS, Tanstack Table, Radix UI, Shadcn UI\n- Backend: MongoDB, Upstash, Pusher\n- Integrations: Helius, Twitter API\n- Wallet: Custom-styled Solana Wallet Adapter\n\n## Features\n\n### Leaderboard (`/`)\n- Displays trader rankings with filterable columns\n- Live trading feed powered by Helius webhooks and Pusher\n- Twitter follower count integration\n- Simplified PnL calculations\n- Actions per trader:\n  - Copy wallet address\n  - View profile\n\n### Trader Profiles (`/users/[walletAddress]`)\n- Displays trader statistics and trade history\n- PnL visualization with sharing capabilities\n- Twitter account linking\n- Wallet connection support\n\n### Additional Pages\n- `/learn` - Educational resources\n- `/prizes` - Competition rewards information\n\n## API Routes\n\n### `/api/traders/getLeaderboard`\n- Returns trader data with enhanced information:\n  - Live Twitter follower counts (via Raspberry Pi hosted service)\n  - Simplified PnL calculations\n\n### `/api/traders/getProfile`\n- Fetches single trader data using wallet address\n- Handles two scenarios:\n  1. Existing trader: Displays stats and trade history\n  2. New user: Guides through wallet and Twitter connection\n\n### `/api/twitterAuth/*`\nTwitter authentication flow:\n1. User initiates auth via connect button\n2. Redirects to Twitter for approval\n3. Callback saves user profile and wallet address to MongoDB\n4. Completes authentication flow\n\n### `/api/webhook`\nHandles live trading feed data:\n- Receives Helius webhook data\n- Forwards to Pusher\n- Updates frontend via LiveTrader component\n\n## Setup Instructions\n\n1. Clone the repository\n2. Set up environment variables:\n   ```bash\n   cp .env.example .env\n   # Fill in required variables\n   ```\n3. Install dependencies:\n   ```bash\n   npm install\n   ```\n4. Start development server:\n   ```bash\n   npm run dev\n   ```\n\n## Environment Variables\nRequired variables (add to `.env`):\n\n### Public Environment Variables (Frontend)\n- `NEXT_PUBLIC_API_URL`: http://localhost:3000\n- `NEXT_PUBLIC_SOLANA_RPC_URL`: \n- `NEXT_PUBLIC_PUSHER_KEY`: \n- `NEXT_PUBLIC_PUSHER_CLUSTER`: \n- `NEXT_PUBLIC_WALLET_CONNECT_PROJECT_ID`: \n\n### Helius Dashboard\n- `HELIUS_KEY`: \n\n### Twitter Dashboard\n- `TWITTER_API_KEY`: \n- `TWITTER_API_SECRET`: \n- `TWITTER_CLIENT_ID`: \n- `TWITTER_CLIENT_SECRET`: \n\n### MongoDB Dashboard\n- `MONGODB_URI`: \n\n### Upstash Dashboard\n- `UPSTASH_REDIS_REST_URL`: \n- `UPSTASH_REDIS_REST_TOKEN`: \n\n### Pusher Dashboard\n- `PUSHER_APP_ID`: \n- `PUSHER_KEY`: \n- `PUSHER_SECRET`: \n- `PUSHER_CLUSTER`: \n\n## Deployment\nThe demo is deployed on Vercel and can be accessed at https://potionleaderboard.xyz/\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjongan69%2Fpotion-leaderboard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjongan69%2Fpotion-leaderboard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjongan69%2Fpotion-leaderboard/lists"}