项目贡献者的 github graphql 查询 [英] github graphql query for project contributors
问题描述
我想使用 GitHub Graphql api 查询项目贡献者,谁能给我任何提示如何制作?刚刚尝试了一段时间,我想我错过了一些小元素.
I want to query using GitHub Graphql api for project contributors, can anyone give me any hints how to make it? Just been trying for some time, and I guess that I am missing some small element.
我想要https://api.github.com/repos/facebook/react/contributors?page=15 但仅限于贡献量
I'd like to get sth like https://api.github.com/repos/facebook/react/contributors?page=15 but only for amount of conttributions
您好!
推荐答案
更新时间:2020 年 5 月.
updated: May, 2020.
Github GraphQL API 目前不支持获取存储库的贡献者
.
Github GraphQL API currently don't support getting contributors
of a repo.
你可以得到 collaborators
虽然....
You can get the collaborators
though....
query {
repository(owner: "peek", name: "peek") {
id
name
collaborators(first: 10, affiliation: ALL) {
edges {
permission
node {
id
login
name
}
}
}
}
rateLimit {
cost
}
}
您需要拥有仓库的推送权限才能查看协作者.
You need to have push rights to the repository to view the collaborators.
这篇关于项目贡献者的 github graphql 查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!