Commit

class github.Commit.Commit

This class represents Commits. The reference can be found here https://docs.github.com/en/rest/reference/git#commits

author
Type:github.NamedUser.NamedUser
comments_url
Type:string
commit
Type:github.GitCommit.GitCommit
committer
Type:github.NamedUser.NamedUser
files
Type:list of github.File.File
html_url
Type:string
parents
Type:list of github.Commit.Commit
sha
Type:string
stats
Type:github.CommitStats.CommitStats
url
Type:string
create_comment(body, line=NotSet, path=NotSet, position=NotSet)
Calls:

POST /repos/{owner}/{repo}/commits/{sha}/comments

Parameters:
  • body – string
  • line – integer
  • path – string
  • position – integer
Return type:

github.CommitComment.CommitComment

create_status(state, target_url=NotSet, description=NotSet, context=NotSet)
Calls:

POST /repos/{owner}/{repo}/statuses/{sha}

Parameters:
  • state – string
  • target_url – string
  • description – string
  • context – string
Return type:

github.CommitStatus.CommitStatus

get_comments()
Calls:GET /repos/{owner}/{repo}/commits/{sha}/comments
Return type:github.PaginatedList.PaginatedList of github.CommitComment.CommitComment
get_statuses()
Calls:GET /repos/{owner}/{repo}/statuses/{ref}
Return type:github.PaginatedList.PaginatedList of github.CommitStatus.CommitStatus
get_combined_status()
Calls:GET /repos/{owner}/{repo}/commits/{ref}/status/
Return type:github.CommitCombinedStatus.CommitCombinedStatus
get_pulls()
Calls:GET /repos/{owner}/{repo}/commits/{sha}/pulls
Return type:github.PaginatedList.PaginatedList of github.PullRequest.PullRequest
get_check_runs(check_name=NotSet, status=NotSet, filter=NotSet)
Calls:

GET /repos/{owner}/{repo}/commits/{sha}/check-runs

Parameters:
  • check_name – string
  • status – string
  • filter – string
Return type:

github.PaginatedList.PaginatedList of github.CheckRun.CheckRun

get_check_suites(app_id=NotSet, check_name=NotSet)
Class:

GET /repos/{owner}/{repo}/commits/{ref}/check-suites

Parameters:
  • app_id – int
  • check_name – string
Return type:

github.PaginatedList.PaginatedList of github.CheckSuite.CheckSuite