Add GitHub Stars lead tracking to web admin#3692
Merged
ComputelessComputer merged 4 commits intomainfrom Feb 6, 2026
Merged
Conversation
- Add /admin/stars/ dashboard page for tracking GitHub stargazers - Add API routes for fetching stars, researching leads via OpenRouter AI - Add Supabase migration for github_star_leads table - Add Stars nav link to admin header Co-Authored-By: john@hyprnote.com <john@hyprnote.com>
✅ Deploy Preview for hyprnote ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for hyprnote-storybook canceled.
|
Contributor
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
…act import, add auto-generated routeTree Co-Authored-By: john@hyprnote.com <john@hyprnote.com>
Co-Authored-By: john@hyprnote.com <john@hyprnote.com>
…eads Co-Authored-By: john@hyprnote.com <john@hyprnote.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add GitHub Stars lead tracking to web admin
Summary
Implements a "Catching Stars" feature inspired by Val Town's blog post — an admin dashboard to track GitHub stargazers/activity on
fastrepl/hyprnoteand qualify them as potential leads/hires using LLM research via OpenRouter.New files:
supabase/migrations/20250206000000_create_github_star_leads.sql— Postgres table for storing stargazer data and AI research resultssupabase/migrations/20250206000001_github_star_leads_rls.sql— RLS policy (service_role only)apps/web/src/functions/github-stars.ts— Server functions for GitHub API polling, DB operations, and OpenRouter-based lead researchapps/web/src/routes/admin/stars/index.tsx— Dashboard UI with table view, search, filters, and per-lead research triggerapps/web/src/routes/api/admin/stars/{leads,fetch,research}.ts— API endpoints (admin-protected)Modified files:
apps/web/src/routes/admin/route.tsx— Renamed "Content Admin" → "Char Admin", added "Stars" nav link with vertical separator after "Media"Updates since last revision
divseparator between "Media" and "Stars" nav links in the admin header.20250206000001) enables Row Level Security ongithub_star_leadsand grants full access toservice_role.Review & Testing Checklist for Human
getSql()creates a newpostgres()connection on every function call without pooling or closing. Under load (e.g. researching many leads), this could leak connections. Consider a singleton or connection pool.fetchGitHubActivity()also makes a per-user API call for bio data, which compounds quickly. Consider adding a GitHub token.OPENROUTER_API_KEYhandling: Not registered inapps/web/src/env.tsvalidation schema — read directly fromprocess.env. The research endpoint also accepts API keys in the request body; verify this is acceptable from a security perspective.as unknown as StarLead[]casts bypass type checking on query results. If the DB schema drifts from theStarLeadinterface, these will silently produce incorrect types at runtime.20250206000000_create_github_star_leads.sql(table) and20250206000001_github_star_leads_rls.sql(RLS) against your database.Recommended test plan:
/admin/stars/— verify header says "Char Admin" with separator before "Stars"Notes