1 min read
Add as a preferred source on Google

GitHub Adds Star History API With Fewer Requests and No User Lists

The endpoint returns up to 30 weeks of daily counts grouped by calendar week. GitHub announced it Sept. 4 and explained its design Oct. 14.

A weekly tally notebook rests beside a laptop showing a simple chart / TokenPost.ai
A weekly tally notebook rests beside a laptop showing a simple chart / TokenPost.ai

GitHub announced a repository star history API Sept. 4, giving developers aggregate counts for tracking project interest without retrieving older stargazer lists that exposed user identities.

The GET /repos/{owner}/{repo}/stargazers/history endpoint returns daily counts grouped by calendar week and can provide up to 30 weeks of history in one request. Developers can page backward through a repository’s history. Week and day boundaries are not guaranteed to align with UTC.

Some tools used the older stargazer lists to extract timestamps for trend charts, then discarded the usernames. The history endpoint provides aggregate counts for that purpose.

Reconstructing the full star history of react/react, which had about 251,000 stars, required roughly 2,511 requests with the older approach and about 24 with the new endpoint.

The data represents stars that remain in GitHub’s current records; removed stars are not preserved as historical events. Weeks with unusually high activity can still require costly queries.

GitHub’s technical explanation of the design was published Oct. 14.

Simon Yoon

Reporter

Simon Yoon reports on blockchain technology for TokenPost. Send corrections or tips to info@tokenpost.com.

Loading…