Mutations
createCommitOnBranch
Appends a commit to the given branch as the authenticated user.
This mutation creates a commit whose parent is the HEAD of the provided
branch and also updates that branch to point to the new commit.
It can be thought of as similar to git commit.
Locating a Branch
Commits are appended to a branch of type Ref.
This must refer to a git branch (i.e. the fully qualified path must
begin with refs/heads/, although including this prefix is optional.
Callers may specify the branch to commit to either by its global node
ID or by passing both of repositoryNameWithOwner and refName. For
more details see the documentation for CommittableBranch.
Describing Changes
fileChanges are specified as a FilesChanges object describing
FileAdditions and FileDeletions.
Please see the documentation for FileChanges for more information on
how to use this argument to describe any set of file changes.
Authorship
Similar to the web commit interface, this mutation does not support specifying the author or committer of the commit and will not add support for this in the future.
A commit created by a successful execution of this mutation will be authored by the owner of the credential which authenticates the API request. The committer will be identical to that of commits authored using the web interface.
If you need full control over author and committer information, please use the Git Database REST API instead.
Commit Signing
Commits made using this mutation are automatically signed by GitHub if supported and will be marked as verified in the user interface.
createCommitOnBranch の入力フィールド
input(CreateCommitOnBranchInput!)
createCommitOnBranch の戻り値フィールド
| 名前 | 説明 |
|---|---|
| A unique identifier for the client performing the mutation. |
| The new commit. |
| The ref which has been updated to point to the new commit. |
Objects
Commit
Represents a Git commit.
Commit 実装
Commit のフィールド
| 名前 | 説明 |
|---|---|
| An abbreviated version of the Git object ID. |
| The number of additions in this commit. |
| The merged Pull Request that introduced the commit to the repository. If the commit is not present in the default branch, additionally returns open Pull Requests associated with the commit.
|
| Authorship details of the commit. |
| Check if the committer and the author match. |
| The datetime when this commit was authored. |
| The list of authors for this commit based on the git author and the Co-authored-by message trailer. The git author will always be first. |
| Fetches
|
| We recommend using the 警告
|
| The number of changed files in this commit. If GitHub is unable to calculate
the number of changed files (for example due to a timeout), this will return
|
| The check suites associated with a commit.
|
| Comments made on the commit. |
| The HTTP path for this Git object. |
| The HTTP URL for this Git object. |
| The datetime when this commit was committed. |
| Check if committed via GitHub web UI. |
| Committer details of the commit. |
| The number of deletions in this commit. |
| The deployments associated with a commit.
|
| The tree entry representing the file located at the given path.
|
| The linear commit history starting from (and including) this commit, in the same order as
|
| The Node ID of the Commit object. |
| The Git commit message. |
| The Git commit message body. |
| The commit message body rendered to HTML. |
| The Git commit message headline. |
| The commit message headline rendered to HTML. |
| The Git object ID. |
| The organization this commit was made on behalf of. |
| The parents of a commit. |
| The datetime when this commit was pushed. 警告
|
| The Repository this commit belongs to. |
| The HTTP path for this commit. |
| Commit signing information, if present. |
| Status information for this commit. |
| Check and Status rollup information for this commit. |
| Returns a list of all submodules in this repository as of this Commit parsed from the .gitmodules file. |
| Returns a URL to download a tarball archive for a repository. Note: For private repositories, these links are temporary and expire after five minutes. |
| Commit's root Tree. |
| The HTTP path for the tree of this commit. |
| The HTTP URL for the tree of this commit. |
| The HTTP URL for this commit. |
| Check if the viewer is able to change their subscription status for the repository. |
| Identifies if the viewer is watching, not watching, or ignoring the subscribable entity. |
| Returns a URL to download a zipball archive for a repository. Note: For private repositories, these links are temporary and expire after five minutes. |
CommitAuthorEmailPatternParameters
Parameters to be used for the commit_author_email_pattern rule.
CommitAuthorEmailPatternParameters のフィールド
| 名前 | 説明 |
|---|---|
| How this rule will appear to users. |
| If true, the rule will fail if the pattern matches. |
| The operator to use for matching. |
| The pattern to match with. |
CommitComment
Represents a comment on a given Commit.
CommitComment 実装
CommitComment のフィールド
| 名前 | 説明 |
|---|---|
| The actor who authored the comment. |
| Author's association with the subject of the comment. |
| Identifies the comment body. |
| The body rendered to HTML. |
| The body rendered to text. |
| Identifies the commit associated with the comment, if the commit exists. |
| Identifies the date and time when the object was created. |
| Check if this comment was created via an email reply. |
| Identifies the primary key from the database. |
| The actor who edited the comment. |
| The Node ID of the CommitComment object. |
| Check if this comment was edited and includes an edit with the creation data. |
| Returns whether or not a comment has been minimized. |
| The moment the editor made the last edit. |
| Returns why the comment was minimized. One of |
| Identifies the file path associated with the comment. |
| Identifies the line position associated with the comment. |
| Identifies when the comment was published at. |
| A list of reactions grouped by content left on the subject. |
| A list of Reactions left on the Issue.
|
| The repository associated with this node. |
| The HTTP path permalink for this commit comment. |
| Identifies the date and time when the object was last updated. |
| The HTTP URL permalink for this commit comment. |
| A list of edits to this content. |
| Check if the current viewer can delete this object. |
| Check if the current viewer can minimize this object. |
| Can user react to this subject. |
| Check if the current viewer can unminimize this object. |
| Check if the current viewer can update this object. |
| Reasons why the current viewer can not update this comment. |
| Did the viewer author this comment. |
CommitCommentConnection
The connection type for CommitComment.
CommitCommentConnection のフィールド
| 名前 | 説明 |
|---|---|
| A list of edges. |
| A list of nodes. |
| Information to aid in pagination. |
| Identifies the total count of items in the connection. |
CommitCommentEdge
An edge in a connection.
CommitCommentEdge のフィールド
| 名前 | 説明 |
|---|---|
| A cursor for use in pagination. |
| The item at the end of the edge. |
CommitCommentThread
A thread of comments on a commit.
CommitCommentThread 実装
CommitCommentThread のフィールド
| 名前 | 説明 |
|---|---|
| The comments that exist in this thread. |
| The commit the comments were made on. |
| The Node ID of the CommitCommentThread object. |
| The file the comments were made on. |
| The position in the diff for the commit that the comment was made on. |
| The repository associated with this node. |
CommitConnection
The connection type for Commit.
CommitConnection のフィールド
| 名前 | 説明 |
|---|---|
| A list of edges. |
| A list of nodes. |
| Information to aid in pagination. |
| Identifies the total count of items in the connection. |
CommitContributionsByRepository
This aggregates commits made by a user within one repository.
CommitContributionsByRepository のフィールド
| 名前 | 説明 |
|---|---|
| The commit contributions, each representing a day.
|
| The repository in which the commits were made. |
| The HTTP path for the user's commits to the repository in this time range. |
| The HTTP URL for the user's commits to the repository in this time range. |
CommitEdge
An edge in a connection.
CommitEdge のフィールド
| 名前 | 説明 |
|---|---|
| A cursor for use in pagination. |
| The item at the end of the edge. |
CommitHistoryConnection
The connection type for Commit.
CommitHistoryConnection のフィールド
| 名前 | 説明 |
|---|---|
| A list of edges. |
| A list of nodes. |
| Information to aid in pagination. |
| Identifies the total count of items in the connection. |
CommitMessagePatternParameters
Parameters to be used for the commit_message_pattern rule.
CommitMessagePatternParameters のフィールド
| 名前 | 説明 |
|---|---|
| How this rule will appear to users. |
| If true, the rule will fail if the pattern matches. |
| The operator to use for matching. |
| The pattern to match with. |
CommitterEmailPatternParameters
Parameters to be used for the committer_email_pattern rule.
CommitterEmailPatternParameters のフィールド
| 名前 | 説明 |
|---|---|
| How this rule will appear to users. |
| If true, the rule will fail if the pattern matches. |
| The operator to use for matching. |
| The pattern to match with. |
Comparison
Represents a comparison between two commit revisions.
Comparison 実装
Comparison のフィールド
| 名前 | 説明 |
|---|---|
| The number of commits ahead of the base branch. |
| The base revision of this comparison. |
| The number of commits behind the base branch. |
| The commits which compose this comparison. |
| The head revision of this comparison. |
| The Node ID of the Comparison object. |
| The status of this comparison. |
ComparisonCommitConnection
The connection type for Commit.
ComparisonCommitConnection のフィールド
| 名前 | 説明 |
|---|---|
| The total count of authors and co-authors across all commits. |
| A list of edges. |
| A list of nodes. |
| Information to aid in pagination. |
| Identifies the total count of items in the connection. |
Status
Represents a commit status.
Status 実装
Status のフィールド
| 名前 | 説明 |
|---|---|
| A list of status contexts and check runs for this commit. |
| The commit this status is attached to. |
| Looks up an individual status context by context name.
|
| The individual status contexts for this commit. |
| The Node ID of the Status object. |
| The combined commit status. |
StatusCheckConfiguration
Required status check.
StatusCheckConfiguration のフィールド
| 名前 | 説明 |
|---|---|
| The status check context name that must be present on the commit. |
| The optional integration ID that this status check must originate from. |
StatusCheckRollup
Represents the rollup for both the check runs and status for a commit.
StatusCheckRollup 実装
StatusCheckRollup のフィールド
| 名前 | 説明 |
|---|---|
| The commit the status and check runs are attached to. |
| A list of status contexts and check runs for this commit. |
| The Node ID of the StatusCheckRollup object. |
| The combined status for the commit. |
StatusCheckRollupContextConnection
The connection type for StatusCheckRollupContext.
StatusCheckRollupContextConnection のフィールド
| 名前 | 説明 |
|---|---|
| The number of check runs in this rollup. |
| Counts of check runs by state. |
| A list of edges. |
| A list of nodes. |
| Information to aid in pagination. |
| The number of status contexts in this rollup. |
| Counts of status contexts by state. |
| Identifies the total count of items in the connection. |
StatusCheckRollupContextEdge
An edge in a connection.
StatusCheckRollupContextEdge のフィールド
| 名前 | 説明 |
|---|---|
| A cursor for use in pagination. |
| The item at the end of the edge. |
StatusContext
Represents an individual commit status context.
StatusContext 実装
StatusContext のフィールド
| 名前 | 説明 |
|---|---|
| The avatar of the OAuth application or the user that created the status.
|
| This commit this status context is attached to. |
| The name of this status context. |
| Identifies the date and time when the object was created. |
| The actor who created this status context. |
| The description for this status context. |
| The Node ID of the StatusContext object. |
| Whether this is required to pass before merging for a specific pull request. |
| The state of this status context. |
| The URL for this status context. |
StatusContextStateCount
Represents a count of the state of a status context.
StatusContextStateCount のフィールド
| 名前 | 説明 |
|---|---|
| The number of statuses with this state. |
| The state of a status context. |
Enums
CommitContributionOrderField
Properties by which commit contribution connections can be ordered.
CommitContributionOrderField の値です。
| 名前 | 説明 |
|---|---|
COMMIT_COUNT | Order commit contributions by how many commits they represent. |
OCCURRED_AT | Order commit contributions by when they were made. |
ComparisonStatus
The status of a git comparison between two refs.
ComparisonStatus の値です。
| 名前 | 説明 |
|---|---|
AHEAD | The head ref is ahead of the base ref. |
BEHIND | The head ref is behind the base ref. |
DIVERGED | The head ref is both ahead and behind of the base ref, indicating git history has diverged. |
IDENTICAL | The head ref and base ref are identical. |
StatusState
The possible commit status states.
StatusState の値です。
| 名前 | 説明 |
|---|---|
ERROR | Status is errored. |
EXPECTED | Status is expected. |
FAILURE | Status is failing. |
PENDING | Status is pending. |
SUCCESS | Status is successful. |
Unions
StatusCheckRollupContext
Types that can be inside a StatusCheckRollup context.
StatusCheckRollupContext の可能な型
Input objects
CommitAuthor
Specifies an author for filtering Git commits.
CommitAuthor の入力フィールド
| 名前 | 説明 |
|---|---|
| Email addresses to filter by. Commits authored by any of the specified email addresses will be returned. |
| ID of a User to filter by. If non-null, only commits authored by this user will be returned. This field takes precedence over emails. |
CommitAuthorEmailPatternParametersInput
Parameters to be used for the commit_author_email_pattern rule.
CommitAuthorEmailPatternParametersInput の入力フィールド
| 名前 | 説明 |
|---|---|
| How this rule will appear to users. |
| If true, the rule will fail if the pattern matches. |
| The operator to use for matching. |
| The pattern to match with. |
CommitContributionOrder
Ordering options for commit contribution connections.
CommitContributionOrder の入力フィールド
| 名前 | 説明 |
|---|---|
| The ordering direction. |
| The field by which to order commit contributions. |
CommitMessage
A message to include with a new commit.
CommitMessage の入力フィールド
| 名前 | 説明 |
|---|---|
| The body of the message. |
| The headline of the message. |
CommitMessagePatternParametersInput
Parameters to be used for the commit_message_pattern rule.
CommitMessagePatternParametersInput の入力フィールド
| 名前 | 説明 |
|---|---|
| How this rule will appear to users. |
| If true, the rule will fail if the pattern matches. |
| The operator to use for matching. |
| The pattern to match with. |
CommitterEmailPatternParametersInput
Parameters to be used for the committer_email_pattern rule.
CommitterEmailPatternParametersInput の入力フィールド
| 名前 | 説明 |
|---|---|
| How this rule will appear to users. |
| If true, the rule will fail if the pattern matches. |
| The operator to use for matching. |
| The pattern to match with. |
CreateCommitOnBranchInput
Autogenerated input type of CreateCommitOnBranch.
CreateCommitOnBranchInput の入力フィールド
| 名前 | 説明 |
|---|---|
| The Ref to be updated. Must be a branch. |
| A unique identifier for the client performing the mutation. |
| The git commit oid expected at the head of the branch prior to the commit. |
| A description of changes to files in this commit. |
| The commit message the be included with the commit. |
StatusCheckConfigurationInput
Required status check.
StatusCheckConfigurationInput の入力フィールド
| 名前 | 説明 |
|---|---|
| The status check context name that must be present on the commit. |
| The optional integration ID that this status check must originate from. |