获取最后一次推送github拉取请求的日期



通过GitHub API,您可以获得PR的提交列表及其提交日期。像这样:https://developer.github.com/v3/pulls/#list-commits-on-a-pull-request

这些日期对我来说似乎是提交日期时间。我想知道是否可以获得推送日期时间。

我想重新创建GitHub PR网页上的评论和提交顺序。

只有两个地方可以获得推送发生时的时间戳:

1) 事件API——https://developer.github.com/v3/activity/events/.请参阅PushEvent:https://developer.github.com/v3/activity/events/types/#pushevent.但API将只返回过去90天中的最后300个事件

2) 网络挂钩--http://developer.github.com/webhooks/.请参阅pull_request事件,该事件在通过推送(synchronize)更新头分支时告诉您。但是您需要拥有存储库的管理员权限才能创建webhook。

最新更新