-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Problem
Each widget verification makes 3-4 unauthenticated GitHub API calls:
GET /repos/:owner/:repo/git/matching-refs/auths/— find registry refGET /repos/:owner/:repo/git/commits/:sha— get commit for treeGET /repos/:owner/:repo/git/trees/:sha?recursive=1— walk full treeGET /repos/:owner/:repo/git/blobs/:sha— read state.json (+ more for attestations)
GitHub's unauthenticated rate limit is 60 requests/hour per IP. That means a single user can verify ~15-20 repos per hour before hitting 403 errors.
This already caused a production outage during development — the live demo at auths-dev.github.io/example-verify-badge showed "Error" because rate limits were exhausted.
Options to explore
- Client-side caching — already partially implemented (
cache.ts), but doesn't survive page reloads - Proxy/CDN — serve identity data from a static endpoint that doesn't count against API limits
- GitHub token support — let users optionally provide a PAT (5,000 req/hr), but adds friction
- Collapse API calls — use the Contents API (
/repos/:owner/:repo/contents/) with a single call if possible - Service worker cache — persist verified results in browser storage
Impact
Any page embedding multiple <auths-verify> widgets (e.g., a team page) will exhaust rate limits quickly. This needs a solution before launch.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels