问题
I am looking into creating a service that tweets whenever a user stars a Github repository. The Github Webhooks API would be ideal, but it only supports webhooks for orgs and repos, not users.
https://api.github.com/users/metaraine/watched provides exactly the information needed, but it is static.
I want to get newly starred repos without having to poll the /watched endpoint. Any suggestions?
回答1:
I want to get newly starred repos without having to poll the /watched endpoint. Any suggestions?
Yeah, that's not possible currently. An alternative would be to poll the Events endpoint for the user and look for events which indicate that the user starred a repository. But that's still polling.
来源:https://stackoverflow.com/questions/27300356/how-can-i-subscribe-to-a-github-users-new-stars