I am using a GITHUB API V3 in one of my project now we are migrating to GraraphQL API V4. I want to list all the branches of the repo and i want to check wether it is protected branch. In GITHUB API V3 it has a branches api that will list all the branches along with it is protected key so it was each to check. Now in GraphQL i can get all the branches list but i can’t check wether the branch is protected or not.
refs(first: 100, refPrefix: "refs/heads/") {
nodes {
name
}
}
Someone could assist on this how to proceed?
If that could not be achieved by the refs
then is there a way to list all the protected branches alone
Regards
Parithiban