I am experimenting with big query. So far I've been able to get the number of people that have watched a repository. Is it possible to get the user names of the subscribers that have watched a repository?
Thanks
You can use the Events to get the actor login name of a repo. Activity archives for dates starting 1/1/2015 is recorded from the Events API..
SELECT actor.login FROM (
TABLE_DATE_RANGE
( [githubarchive:day.events_]
, TIMESTAMP('2015-01-01')
, TIMESTAMP('2015-03-01') )
)
where type='WatchEvent' and repo.name = 'ptrofimov/beanstalk_console'
For 2014 events
SELECT actor FROM (
TABLE_QUERY([githubarchive:month],
'REGEXP_MATCH(table_id, r"^20140\d")'
))
WHERE type = 'WatchEvent' and repository_name='beanstalk_console' and repository_owner='ptrofimov'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With