54 lines
1001 B
GraphQL
54 lines
1001 B
GraphQL
query canMergeData(
|
|
$owner: String!
|
|
$repo: String!
|
|
$pull: Int!
|
|
$head_sha: String!
|
|
) {
|
|
repository(owner: $owner, name: $repo) {
|
|
branchProtectionRules(first: 100) {
|
|
nodes {
|
|
pattern
|
|
requiredStatusCheckContexts
|
|
requiresApprovingReviews
|
|
requiresCodeOwnerReviews
|
|
matchingRefs(first: 100) {
|
|
nodes {
|
|
name
|
|
}
|
|
}
|
|
}
|
|
}
|
|
pullRequest(number: $pull) {
|
|
isDraft
|
|
reviewDecision
|
|
}
|
|
object(expression: $head_sha) {
|
|
... on Commit {
|
|
checkSuites(first: 100) {
|
|
nodes {
|
|
app {
|
|
name
|
|
slug
|
|
}
|
|
checkRuns(first: 100) {
|
|
nodes {
|
|
name
|
|
conclusion
|
|
}
|
|
}
|
|
}
|
|
}
|
|
status {
|
|
contexts {
|
|
creator {
|
|
login
|
|
}
|
|
state
|
|
context
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|