-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Investigate GitHub's GraphQL API #44
Labels
code/chore
Code maintenance improvements
Comments
Current stateWiP in a local branch - https://github.com/rumyantseva/github-actions/tree/issue-44-trying-graphql (there are some things to try/discuss) |
AlekSi
added
not ready
Issues that are not ready to be worked on; PRs that should skip CI
and removed
not ready
Issues that are not ready to be worked on; PRs that should skip CI
labels
Jun 20, 2022
Main learningsAPI
Objects and ids
How to find PR id or Issue id from CardIt works through {
user(login: "rumyantseva") {
projectNext(number: 1) {
id
title
items(first: 20) {
totalCount
nodes {
id
title
type
content {
... on PullRequest {
id
}
... on Issue {
id
}
}
...
}
}
}
}
} How to find current status, sprint, etcIt is set in field values ( How to find a PNI card by Issue id or PR id?Through {
node(id: "PR_kwDOGTO-Gs45XwlA") {
... on PullRequest {
title
state
id
projectNextItems(first: 20) {
totalCount
nodes {
id
fieldValues(first: 20) {
totalCount
nodes {
value
projectField {
name
settings
}
}
}
}
}
}
}
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For #45, we will need to start interacting with GitHub Projects (beta) via GraphQL API: https://docs.github.com/en/issues/trying-out-the-new-projects-experience/using-the-api-to-manage-projects
First, let's try querying that API manually via
gh
tool.Second, let's investigate what Go modules we should use for that API (probably https://github.com/shurcooL/githubv4?)
Lastly, let's add some code to conform-pr GitHub Action that queries project's iteration for PRs.
The text was updated successfully, but these errors were encountered: