| 1 | /** |
| 2 | * The part of GitHub's GraphQL schema (https://docs.github.com/graphql) that Diffinery answers at |
| 3 | * /api/graphql. Names, types and enum values are GitHub's, so the GitHub CLI and tools built on it |
| 4 | * (Claude Code's pull request badge, `gh pr view`, `gh pr checks`, `gh pr list`, `gh pr status`, |
| 5 | * `gh pr create`, `gh pr merge`, `gh pr ready`, `gh pr comment`) read and change Diffinery as a |
| 6 | * GitHub Enterprise Server host. The mutations are the pull request ones gh uses; everything else |
| 7 | * changes through the REST API. |
| 8 | */ |
| 9 | export const SCHEMA_SDL = /* GraphQL */ ` |
| 10 | """Ids from the REST API, which can be wider than GraphQL's 32-bit Int (GitHub types these as Int).""" |
| 11 | scalar BigInt |
| 12 | scalar DateTime |
| 13 | scalar URI |
| 14 | scalar GitObjectID |
| 15 | scalar HTML |
| 16 | scalar GitTimestamp |
| 17 | |
| 18 | schema { query: Query, mutation: Mutation } |
| 19 | |
| 20 | type Mutation { |
| 21 | addAssigneesToAssignable(input: AddAssigneesToAssignableInput!): AddAssigneesToAssignablePayload |
| 22 | addComment(input: AddCommentInput!): AddCommentPayload |
| 23 | addLabelsToLabelable(input: AddLabelsToLabelableInput!): AddLabelsToLabelablePayload |
| 24 | closePullRequest(input: ClosePullRequestInput!): ClosePullRequestPayload |
| 25 | convertPullRequestToDraft(input: ConvertPullRequestToDraftInput!): ConvertPullRequestToDraftPayload |
| 26 | createPullRequest(input: CreatePullRequestInput!): CreatePullRequestPayload |
| 27 | disablePullRequestAutoMerge(input: DisablePullRequestAutoMergeInput!): DisablePullRequestAutoMergePayload |
| 28 | enablePullRequestAutoMerge(input: EnablePullRequestAutoMergeInput!): EnablePullRequestAutoMergePayload |
| 29 | markPullRequestReadyForReview(input: MarkPullRequestReadyForReviewInput!): MarkPullRequestReadyForReviewPayload |
| 30 | mergePullRequest(input: MergePullRequestInput!): MergePullRequestPayload |
| 31 | removeAssigneesFromAssignable(input: RemoveAssigneesFromAssignableInput!): RemoveAssigneesFromAssignablePayload |
| 32 | removeLabelsFromLabelable(input: RemoveLabelsFromLabelableInput!): RemoveLabelsFromLabelablePayload |
| 33 | reopenPullRequest(input: ReopenPullRequestInput!): ReopenPullRequestPayload |
| 34 | requestReviews(input: RequestReviewsInput!): RequestReviewsPayload |
| 35 | updatePullRequest(input: UpdatePullRequestInput!): UpdatePullRequestPayload |
| 36 | } |
| 37 | |
| 38 | input CreatePullRequestInput { |
| 39 | baseRefName: String! |
| 40 | body: String |
| 41 | clientMutationId: String |
| 42 | draft: Boolean = false |
| 43 | headRefName: String! |
| 44 | headRepositoryId: ID |
| 45 | maintainerCanModify: Boolean = true |
| 46 | repositoryId: ID! |
| 47 | title: String! |
| 48 | } |
| 49 | type CreatePullRequestPayload { clientMutationId: String, pullRequest: PullRequest } |
| 50 | |
| 51 | input UpdatePullRequestInput { |
| 52 | assigneeIds: [ID!] |
| 53 | baseRefName: String |
| 54 | body: String |
| 55 | clientMutationId: String |
| 56 | labelIds: [ID!] |
| 57 | maintainerCanModify: Boolean |
| 58 | milestoneId: ID |
| 59 | projectIds: [ID!] |
| 60 | pullRequestId: ID! |
| 61 | state: PullRequestUpdateState |
| 62 | title: String |
| 63 | } |
| 64 | enum PullRequestUpdateState { OPEN CLOSED } |
| 65 | type UpdatePullRequestPayload { actor: Actor, clientMutationId: String, pullRequest: PullRequest } |
| 66 | |
| 67 | input ClosePullRequestInput { clientMutationId: String, pullRequestId: ID! } |
| 68 | type ClosePullRequestPayload { clientMutationId: String, pullRequest: PullRequest } |
| 69 | input ReopenPullRequestInput { clientMutationId: String, pullRequestId: ID! } |
| 70 | type ReopenPullRequestPayload { clientMutationId: String, pullRequest: PullRequest } |
| 71 | input MarkPullRequestReadyForReviewInput { clientMutationId: String, pullRequestId: ID! } |
| 72 | type MarkPullRequestReadyForReviewPayload { clientMutationId: String, pullRequest: PullRequest } |
| 73 | input ConvertPullRequestToDraftInput { clientMutationId: String, pullRequestId: ID! } |
| 74 | type ConvertPullRequestToDraftPayload { clientMutationId: String, pullRequest: PullRequest } |
| 75 | |
| 76 | input EnablePullRequestAutoMergeInput { |
| 77 | authorEmail: String |
| 78 | clientMutationId: String |
| 79 | commitBody: String |
| 80 | commitHeadline: String |
| 81 | expectedHeadOid: GitObjectID |
| 82 | mergeMethod: PullRequestMergeMethod = MERGE |
| 83 | pullRequestId: ID! |
| 84 | } |
| 85 | type EnablePullRequestAutoMergePayload { actor: Actor, clientMutationId: String, pullRequest: PullRequest } |
| 86 | input DisablePullRequestAutoMergeInput { clientMutationId: String, pullRequestId: ID! } |
| 87 | type DisablePullRequestAutoMergePayload { actor: Actor, clientMutationId: String, pullRequest: PullRequest } |
| 88 | |
| 89 | input MergePullRequestInput { |
| 90 | authorEmail: String |
| 91 | clientMutationId: String |
| 92 | commitBody: String |
| 93 | commitHeadline: String |
| 94 | expectedHeadOid: GitObjectID |
| 95 | mergeMethod: PullRequestMergeMethod = MERGE |
| 96 | pullRequestId: ID! |
| 97 | } |
| 98 | type MergePullRequestPayload { actor: Actor, clientMutationId: String, pullRequest: PullRequest } |
| 99 | |
| 100 | input AddCommentInput { body: String!, clientMutationId: String, subjectId: ID! } |
| 101 | type IssueCommentEdge { cursor: String!, node: IssueComment } |
| 102 | type AddCommentPayload { clientMutationId: String, commentEdge: IssueCommentEdge, subject: Node } |
| 103 | |
| 104 | input AddLabelsToLabelableInput { clientMutationId: String, labelableId: ID!, labelIds: [ID!]! } |
| 105 | type AddLabelsToLabelablePayload { clientMutationId: String, labelable: PullRequest } |
| 106 | input RemoveLabelsFromLabelableInput { clientMutationId: String, labelableId: ID!, labelIds: [ID!]! } |
| 107 | type RemoveLabelsFromLabelablePayload { clientMutationId: String, labelable: PullRequest } |
| 108 | input AddAssigneesToAssignableInput { clientMutationId: String, assignableId: ID!, assigneeIds: [ID!]! } |
| 109 | type AddAssigneesToAssignablePayload { clientMutationId: String, assignable: PullRequest } |
| 110 | input RemoveAssigneesFromAssignableInput { clientMutationId: String, assignableId: ID!, assigneeIds: [ID!]! } |
| 111 | type RemoveAssigneesFromAssignablePayload { clientMutationId: String, assignable: PullRequest } |
| 112 | |
| 113 | input RequestReviewsInput { |
| 114 | clientMutationId: String |
| 115 | pullRequestId: ID! |
| 116 | teamIds: [ID!] |
| 117 | union: Boolean = false |
| 118 | userIds: [ID!] |
| 119 | } |
| 120 | type RequestReviewsPayload { actor: Actor, clientMutationId: String, pullRequest: PullRequest } |
| 121 | |
| 122 | type Query { |
| 123 | "The signed-in account." |
| 124 | viewer: User! |
| 125 | "A repository by owner and name." |
| 126 | repository(owner: String!, name: String!, followRenames: Boolean = true): Repository |
| 127 | "An account by login." |
| 128 | user(login: String!): User |
| 129 | "Request budget, reported as GitHub does. Diffinery limits requests per account rather than by query cost." |
| 130 | rateLimit(dryRun: Boolean = false): RateLimit |
| 131 | "A repository or pull request by its global id." |
| 132 | node(id: ID!): Node |
| 133 | nodes(ids: [ID!]!): [Node]! |
| 134 | "Pull requests in one repository (the query needs a repo: qualifier), as \`gh pr status\` asks for them." |
| 135 | search(query: String!, type: SearchType!, first: Int, last: Int, after: String, before: String): SearchResultItemConnection! |
| 136 | } |
| 137 | |
| 138 | enum SearchType { ISSUE ISSUE_ADVANCED REPOSITORY USER DISCUSSION } |
| 139 | union SearchResultItem = PullRequest |
| 140 | type SearchResultItemEdge { cursor: String!, node: SearchResultItem } |
| 141 | type SearchResultItemConnection { |
| 142 | edges: [SearchResultItemEdge] |
| 143 | issueCount: Int! |
| 144 | nodes: [SearchResultItem] |
| 145 | pageInfo: PageInfo! |
| 146 | repositoryCount: Int! |
| 147 | userCount: Int! |
| 148 | } |
| 149 | |
| 150 | enum ReactionContent { THUMBS_UP THUMBS_DOWN LAUGH HOORAY CONFUSED HEART ROCKET EYES } |
| 151 | type ReactingUserConnection { totalCount: Int! } |
| 152 | type ReactionGroup { |
| 153 | content: ReactionContent! |
| 154 | users(first: Int, last: Int, after: String, before: String): ReactingUserConnection! |
| 155 | viewerHasReacted: Boolean! |
| 156 | } |
| 157 | |
| 158 | type RateLimit { |
| 159 | cost: Int! |
| 160 | limit: Int! |
| 161 | nodeCount: Int! |
| 162 | remaining: Int! |
| 163 | resetAt: DateTime! |
| 164 | used: Int! |
| 165 | } |
| 166 | |
| 167 | type PageInfo { |
| 168 | endCursor: String |
| 169 | hasNextPage: Boolean! |
| 170 | hasPreviousPage: Boolean! |
| 171 | startCursor: String |
| 172 | } |
| 173 | |
| 174 | interface Node { id: ID! } |
| 175 | |
| 176 | interface Actor { |
| 177 | avatarUrl(size: Int): URI! |
| 178 | login: String! |
| 179 | resourcePath: URI! |
| 180 | url: URI! |
| 181 | } |
| 182 | |
| 183 | interface RepositoryOwner { |
| 184 | avatarUrl(size: Int): URI! |
| 185 | id: ID! |
| 186 | login: String! |
| 187 | resourcePath: URI! |
| 188 | url: URI! |
| 189 | } |
| 190 | |
| 191 | type User implements Node & Actor & RepositoryOwner { |
| 192 | avatarUrl(size: Int): URI! |
| 193 | databaseId: BigInt |
| 194 | email: String! |
| 195 | id: ID! |
| 196 | isBot: Boolean! |
| 197 | login: String! |
| 198 | name: String |
| 199 | resourcePath: URI! |
| 200 | url: URI! |
| 201 | } |
| 202 | |
| 203 | type Organization implements Node & Actor & RepositoryOwner { |
| 204 | avatarUrl(size: Int): URI! |
| 205 | databaseId: BigInt |
| 206 | id: ID! |
| 207 | login: String! |
| 208 | name: String |
| 209 | resourcePath: URI! |
| 210 | url: URI! |
| 211 | } |
| 212 | |
| 213 | type Bot implements Node & Actor { |
| 214 | avatarUrl(size: Int): URI! |
| 215 | databaseId: BigInt |
| 216 | id: ID! |
| 217 | login: String! |
| 218 | resourcePath: URI! |
| 219 | url: URI! |
| 220 | } |
| 221 | |
| 222 | "Someone brought over by a GitHub import who has no Diffinery account." |
| 223 | type Mannequin implements Node & Actor { |
| 224 | avatarUrl(size: Int): URI! |
| 225 | id: ID! |
| 226 | login: String! |
| 227 | resourcePath: URI! |
| 228 | url: URI! |
| 229 | } |
| 230 | |
| 231 | enum RepositoryPermission { ADMIN MAINTAIN WRITE TRIAGE READ } |
| 232 | enum RepositoryVisibility { PRIVATE PUBLIC INTERNAL } |
| 233 | enum PullRequestState { OPEN CLOSED MERGED } |
| 234 | enum IssueState { OPEN CLOSED } |
| 235 | enum OrderDirection { ASC DESC } |
| 236 | enum IssueOrderField { CREATED_AT UPDATED_AT COMMENTS } |
| 237 | input IssueOrder { field: IssueOrderField!, direction: OrderDirection! } |
| 238 | enum LabelOrderField { NAME CREATED_AT } |
| 239 | input LabelOrder { field: LabelOrderField!, direction: OrderDirection! } |
| 240 | enum MilestoneState { OPEN CLOSED } |
| 241 | enum MilestoneOrderField { DUE_DATE CREATED_AT UPDATED_AT NUMBER } |
| 242 | input MilestoneOrder { field: MilestoneOrderField!, direction: OrderDirection! } |
| 243 | enum PullRequestReviewDecision { CHANGES_REQUESTED APPROVED REVIEW_REQUIRED } |
| 244 | enum PullRequestReviewState { PENDING COMMENTED APPROVED CHANGES_REQUESTED DISMISSED } |
| 245 | enum MergeableState { MERGEABLE CONFLICTING UNKNOWN } |
| 246 | enum MergeStateStatus { DIRTY UNKNOWN BLOCKED BEHIND DRAFT UNSTABLE HAS_HOOKS CLEAN } |
| 247 | enum PullRequestMergeMethod { MERGE SQUASH REBASE } |
| 248 | enum StatusState { EXPECTED ERROR FAILURE PENDING SUCCESS } |
| 249 | enum CheckStatusState { REQUESTED QUEUED IN_PROGRESS COMPLETED WAITING PENDING } |
| 250 | enum CheckConclusionState { ACTION_REQUIRED TIMED_OUT CANCELLED FAILURE SUCCESS NEUTRAL SKIPPED STARTUP_FAILURE STALE } |
| 251 | enum CheckRunState { REQUESTED QUEUED IN_PROGRESS COMPLETED WAITING PENDING ACTION_REQUIRED TIMED_OUT CANCELLED FAILURE SUCCESS NEUTRAL SKIPPED STARTUP_FAILURE STALE } |
| 252 | enum PatchStatus { ADDED DELETED RENAMED COPIED MODIFIED CHANGED } |
| 253 | |
| 254 | type Repository implements Node { |
| 255 | assignableUsers(first: Int, last: Int, after: String, before: String, query: String): UserConnection! |
| 256 | createdAt: DateTime! |
| 257 | databaseId: BigInt |
| 258 | defaultBranchRef: Ref |
| 259 | deleteBranchOnMerge: Boolean! |
| 260 | description: String |
| 261 | hasDiscussionsEnabled: Boolean! |
| 262 | hasIssuesEnabled: Boolean! |
| 263 | hasProjectsEnabled: Boolean! |
| 264 | hasWikiEnabled: Boolean! |
| 265 | homepageUrl: URI |
| 266 | id: ID! |
| 267 | isArchived: Boolean! |
| 268 | isEmpty: Boolean! |
| 269 | isFork: Boolean! |
| 270 | isInOrganization: Boolean! |
| 271 | isLocked: Boolean! |
| 272 | isMirror: Boolean! |
| 273 | isPrivate: Boolean! |
| 274 | isTemplate: Boolean! |
| 275 | label(name: String!): Label |
| 276 | labels(first: Int, last: Int, after: String, before: String, query: String, orderBy: LabelOrder): LabelConnection |
| 277 | mentionableUsers(first: Int, last: Int, after: String, before: String, query: String): UserConnection! |
| 278 | mergeCommitAllowed: Boolean! |
| 279 | milestones(first: Int, last: Int, after: String, before: String, states: [MilestoneState!], orderBy: MilestoneOrder, query: String): MilestoneConnection |
| 280 | name: String! |
| 281 | nameWithOwner: String! |
| 282 | owner: RepositoryOwner! |
| 283 | parent: Repository |
| 284 | pullRequest(number: Int!): PullRequest |
| 285 | pullRequests(first: Int, last: Int, after: String, before: String, states: [PullRequestState!], headRefName: String, baseRefName: String, labels: [String!], orderBy: IssueOrder): PullRequestConnection! |
| 286 | pushedAt: DateTime |
| 287 | rebaseMergeAllowed: Boolean! |
| 288 | resourcePath: URI! |
| 289 | squashMergeAllowed: Boolean! |
| 290 | sshUrl: String! |
| 291 | updatedAt: DateTime! |
| 292 | url: URI! |
| 293 | viewerCanAdminister: Boolean! |
| 294 | viewerPermission: RepositoryPermission |
| 295 | visibility: RepositoryVisibility! |
| 296 | } |
| 297 | |
| 298 | type Ref implements Node { |
| 299 | branchProtectionRule: BranchProtectionRule |
| 300 | id: ID! |
| 301 | name: String! |
| 302 | prefix: String! |
| 303 | target: Commit |
| 304 | } |
| 305 | |
| 306 | type BranchProtectionRule implements Node { |
| 307 | id: ID! |
| 308 | pattern: String! |
| 309 | requiredApprovingReviewCount: Int |
| 310 | requiredStatusCheckContexts: [String] |
| 311 | requiresApprovingReviews: Boolean! |
| 312 | requiresLinearHistory: Boolean! |
| 313 | requiresStatusChecks: Boolean! |
| 314 | requiresStrictStatusChecks: Boolean! |
| 315 | } |
| 316 | |
| 317 | type PullRequestConnection { |
| 318 | edges: [PullRequestEdge] |
| 319 | nodes: [PullRequest] |
| 320 | pageInfo: PageInfo! |
| 321 | totalCount: Int! |
| 322 | } |
| 323 | type PullRequestEdge { cursor: String!, node: PullRequest } |
| 324 | |
| 325 | type PullRequest implements Node { |
| 326 | additions: Int! |
| 327 | assignees(first: Int, last: Int, after: String, before: String): UserConnection! |
| 328 | author: Actor |
| 329 | authorAssociation: String! |
| 330 | autoMergeRequest: AutoMergeRequest |
| 331 | baseRef: Ref |
| 332 | baseRefName: String! |
| 333 | baseRefOid: GitObjectID! |
| 334 | baseRepository: Repository |
| 335 | body: String! |
| 336 | changedFiles: Int! |
| 337 | closed: Boolean! |
| 338 | closedAt: DateTime |
| 339 | comments(first: Int, last: Int, after: String, before: String): IssueCommentConnection! |
| 340 | commits(first: Int, last: Int, after: String, before: String): PullRequestCommitConnection! |
| 341 | createdAt: DateTime! |
| 342 | databaseId: BigInt |
| 343 | deletions: Int! |
| 344 | files(first: Int, last: Int, after: String, before: String): PullRequestChangedFileConnection |
| 345 | headRef: Ref |
| 346 | headRefName: String! |
| 347 | headRefOid: GitObjectID! |
| 348 | headRepository: Repository |
| 349 | headRepositoryOwner: RepositoryOwner |
| 350 | id: ID! |
| 351 | isCrossRepository: Boolean! |
| 352 | isDraft: Boolean! |
| 353 | labels(first: Int, last: Int, after: String, before: String): LabelConnection |
| 354 | latestReviews(first: Int, last: Int, after: String, before: String): PullRequestReviewConnection |
| 355 | locked: Boolean! |
| 356 | maintainerCanModify: Boolean! |
| 357 | mergeCommit: Commit |
| 358 | mergeStateStatus: MergeStateStatus! |
| 359 | mergeable: MergeableState! |
| 360 | merged: Boolean! |
| 361 | mergedAt: DateTime |
| 362 | mergedBy: Actor |
| 363 | milestone: Milestone |
| 364 | number: Int! |
| 365 | permalink: URI! |
| 366 | projectItems(first: Int, last: Int, after: String, before: String): ProjectV2ItemConnection! |
| 367 | reactionGroups: [ReactionGroup!] |
| 368 | repository: Repository! |
| 369 | resourcePath: URI! |
| 370 | reviewDecision: PullRequestReviewDecision |
| 371 | reviewRequests(first: Int, last: Int, after: String, before: String): ReviewRequestConnection |
| 372 | reviews(first: Int, last: Int, after: String, before: String, states: [PullRequestReviewState!]): PullRequestReviewConnection |
| 373 | state: PullRequestState! |
| 374 | statusCheckRollup: StatusCheckRollup |
| 375 | title: String! |
| 376 | updatedAt: DateTime! |
| 377 | url: URI! |
| 378 | } |
| 379 | |
| 380 | type AutoMergeRequest { |
| 381 | authorEmail: String |
| 382 | commitBody: String |
| 383 | commitHeadline: String |
| 384 | enabledAt: DateTime |
| 385 | enabledBy: Actor |
| 386 | mergeMethod: PullRequestMergeMethod! |
| 387 | } |
| 388 | |
| 389 | type Milestone implements Node { |
| 390 | description: String |
| 391 | dueOn: DateTime |
| 392 | id: ID! |
| 393 | number: Int! |
| 394 | state: String! |
| 395 | title: String! |
| 396 | } |
| 397 | |
| 398 | type MilestoneConnection { nodes: [Milestone], totalCount: Int!, pageInfo: PageInfo! } |
| 399 | |
| 400 | type UserConnection { nodes: [User], totalCount: Int!, pageInfo: PageInfo! } |
| 401 | |
| 402 | type Label implements Node { |
| 403 | color: String! |
| 404 | description: String |
| 405 | id: ID! |
| 406 | name: String! |
| 407 | } |
| 408 | type LabelConnection { nodes: [Label], totalCount: Int!, pageInfo: PageInfo! } |
| 409 | |
| 410 | type Team implements Node { |
| 411 | id: ID! |
| 412 | name: String! |
| 413 | organization: Organization! |
| 414 | slug: String! |
| 415 | } |
| 416 | union RequestedReviewer = User | Team | Bot | Mannequin |
| 417 | type ReviewRequest { requestedReviewer: RequestedReviewer } |
| 418 | type ReviewRequestConnection { nodes: [ReviewRequest], totalCount: Int!, pageInfo: PageInfo! } |
| 419 | |
| 420 | type PullRequestReview implements Node { |
| 421 | author: Actor |
| 422 | authorAssociation: String! |
| 423 | body: String! |
| 424 | commit: Commit |
| 425 | id: ID! |
| 426 | includesCreatedEdit: Boolean! |
| 427 | reactionGroups: [ReactionGroup!] |
| 428 | state: PullRequestReviewState! |
| 429 | submittedAt: DateTime |
| 430 | } |
| 431 | type PullRequestReviewConnection { nodes: [PullRequestReview], totalCount: Int!, pageInfo: PageInfo! } |
| 432 | |
| 433 | type IssueComment implements Node { |
| 434 | author: Actor |
| 435 | authorAssociation: String! |
| 436 | body: String! |
| 437 | createdAt: DateTime! |
| 438 | id: ID! |
| 439 | includesCreatedEdit: Boolean! |
| 440 | isMinimized: Boolean! |
| 441 | minimizedReason: String |
| 442 | reactionGroups: [ReactionGroup!] |
| 443 | url: URI! |
| 444 | viewerDidAuthor: Boolean! |
| 445 | } |
| 446 | type IssueCommentConnection { nodes: [IssueComment], totalCount: Int!, pageInfo: PageInfo! } |
| 447 | |
| 448 | type PullRequestChangedFile { |
| 449 | additions: Int! |
| 450 | changeType: PatchStatus! |
| 451 | deletions: Int! |
| 452 | path: String! |
| 453 | } |
| 454 | type PullRequestChangedFileConnection { nodes: [PullRequestChangedFile], totalCount: Int!, pageInfo: PageInfo! } |
| 455 | |
| 456 | type PullRequestCommit implements Node { |
| 457 | commit: Commit! |
| 458 | id: ID! |
| 459 | url: URI! |
| 460 | } |
| 461 | type PullRequestCommitEdge { cursor: String!, node: PullRequestCommit } |
| 462 | type PullRequestCommitConnection { |
| 463 | edges: [PullRequestCommitEdge] |
| 464 | nodes: [PullRequestCommit] |
| 465 | pageInfo: PageInfo! |
| 466 | totalCount: Int! |
| 467 | } |
| 468 | |
| 469 | type GitActor { |
| 470 | date: GitTimestamp |
| 471 | email: String |
| 472 | name: String |
| 473 | user: User |
| 474 | } |
| 475 | |
| 476 | type GitActorConnection { nodes: [GitActor], totalCount: Int!, pageInfo: PageInfo! } |
| 477 | |
| 478 | "Projects aren't part of Diffinery: always empty." |
| 479 | type ProjectV2Item implements Node { id: ID! } |
| 480 | type ProjectV2ItemConnection { nodes: [ProjectV2Item], totalCount: Int!, pageInfo: PageInfo! } |
| 481 | |
| 482 | type Commit implements Node { |
| 483 | abbreviatedOid: String! |
| 484 | author: GitActor |
| 485 | authoredDate: DateTime! |
| 486 | authors(first: Int, last: Int, after: String, before: String): GitActorConnection! |
| 487 | commitUrl: URI! |
| 488 | committedDate: DateTime! |
| 489 | committer: GitActor |
| 490 | id: ID! |
| 491 | message: String! |
| 492 | messageBody: String! |
| 493 | messageHeadline: String! |
| 494 | oid: GitObjectID! |
| 495 | status: Status |
| 496 | statusCheckRollup: StatusCheckRollup |
| 497 | url: URI! |
| 498 | } |
| 499 | |
| 500 | "The legacy combined commit status (commit statuses only, no check runs)." |
| 501 | type Status implements Node { |
| 502 | contexts: [StatusContext!]! |
| 503 | id: ID! |
| 504 | state: StatusState! |
| 505 | } |
| 506 | |
| 507 | type StatusCheckRollup implements Node { |
| 508 | commit: Commit |
| 509 | contexts(first: Int, last: Int, after: String, before: String): StatusCheckRollupContextConnection! |
| 510 | id: ID! |
| 511 | state: StatusState! |
| 512 | } |
| 513 | |
| 514 | union StatusCheckRollupContext = CheckRun | StatusContext |
| 515 | |
| 516 | type CheckRunStateCount { count: Int!, state: CheckRunState! } |
| 517 | type StatusContextStateCount { count: Int!, state: StatusState! } |
| 518 | type StatusCheckRollupContextEdge { cursor: String!, node: StatusCheckRollupContext } |
| 519 | |
| 520 | type StatusCheckRollupContextConnection { |
| 521 | checkRunCount: Int! |
| 522 | checkRunCountsByState: [CheckRunStateCount!] |
| 523 | edges: [StatusCheckRollupContextEdge] |
| 524 | nodes: [StatusCheckRollupContext] |
| 525 | pageInfo: PageInfo! |
| 526 | statusContextCount: Int! |
| 527 | statusContextCountsByState: [StatusContextStateCount!] |
| 528 | totalCount: Int! |
| 529 | } |
| 530 | |
| 531 | type App implements Node { |
| 532 | id: ID! |
| 533 | logoUrl(size: Int): URI! |
| 534 | name: String! |
| 535 | slug: String! |
| 536 | } |
| 537 | |
| 538 | type Workflow implements Node { |
| 539 | id: ID! |
| 540 | name: String! |
| 541 | } |
| 542 | |
| 543 | type WorkflowRun implements Node { |
| 544 | databaseId: BigInt |
| 545 | event: String! |
| 546 | id: ID! |
| 547 | runNumber: Int! |
| 548 | url: URI! |
| 549 | workflow: Workflow! |
| 550 | } |
| 551 | |
| 552 | type CheckSuite implements Node { |
| 553 | app: App |
| 554 | conclusion: CheckConclusionState |
| 555 | id: ID! |
| 556 | status: CheckStatusState! |
| 557 | workflowRun: WorkflowRun |
| 558 | } |
| 559 | |
| 560 | type CheckRun implements Node { |
| 561 | checkSuite: CheckSuite! |
| 562 | completedAt: DateTime |
| 563 | conclusion: CheckConclusionState |
| 564 | databaseId: BigInt |
| 565 | detailsUrl: URI |
| 566 | id: ID! |
| 567 | isRequired(pullRequestId: ID, pullRequestNumber: Int): Boolean! |
| 568 | name: String! |
| 569 | permalink: URI! |
| 570 | startedAt: DateTime |
| 571 | status: CheckStatusState! |
| 572 | summary: String |
| 573 | text: String |
| 574 | title: String |
| 575 | url: URI! |
| 576 | } |
| 577 | |
| 578 | type StatusContext implements Node { |
| 579 | avatarUrl(size: Int): URI |
| 580 | context: String! |
| 581 | createdAt: DateTime! |
| 582 | creator: Actor |
| 583 | description: String |
| 584 | id: ID! |
| 585 | isRequired(pullRequestId: ID, pullRequestNumber: Int): Boolean! |
| 586 | state: StatusState! |
| 587 | targetUrl: URI |
| 588 | } |
| 589 | `; |