GitHub Trending Repositories API
github.com/trending — repos ranked by starsGained (daily|weekly|monthly), not all-time stars (2 credits).
Scrapes the public github.com/trending page (source: "github.com/trending") — repositories ranked by stars gained in a window, not REST /search/repositories sorted by all-time stars. Pass since=daily|weekly|monthly (default daily) and optional language slug (e.g. python → /trending/python). Each row: rank, fullName, url, description, language (programming language), stars, forks, starsGained, since. Flat 2 credits. The HTML page usually lists ~25 repos; there is no cursor (unlike Search API's 1000-result cap). This is not a substitute for github/repository detail fields (license, watchers/subscribers, parent, …).
Request
- Base URL: https://api.captapi.com
- URL: https://api.captapi.com/v1/github/trending-repositories
- Auth: one of:
- HTTP bearer
- API key in header X-API-Key
Query parameters
Trending window: daily (default), weekly, or monthly — matches github.com/trending?since=.
Optional programming-language slug (e.g. python, typescript) → /trending/{language}.
Max items to return (default 25, max 100). Flat 2 credits per call.
Set true to serve from the 24h response cache (0 credits on hit). Default false — always fetch fresh.
Response
Success. The data object for this endpoint.
Changes
No recorded changes to this operation across all 3 revisions of this API.