GithubClient
Attributes
TRIGGER_OPERATIONS
module-attribute
TRIGGER_OPERATIONS: Dict[str, Dict[str, Any]] = {'WebhookPullRequestTrigger': {'operation_id': 'WebhookPullRequestTrigger', 'path': '/{connectionId}/repos/{repositoryOwner}/{repositoryName}/hooks', 'method': 'post', 'required_parameters': ['repositoryOwner', 'repositoryName'], 'callback_payload_type': 'WebhookCreationResponse'}, 'IssueOpened': {'operation_id': 'IssueOpened', 'path': '/{connectionId}/trigger/issueOpened', 'method': 'get', 'required_parameters': [], 'callback_payload_type': 'IssueDetailsModel'}, 'IssueClosed': {'operation_id': 'IssueClosed', 'path': '/{connectionId}/trigger/issueClosed', 'method': 'get', 'required_parameters': [], 'callback_payload_type': 'IssueDetailsModel'}, 'IssueAssigned': {'operation_id': 'IssueAssigned', 'path': '/{connectionId}/trigger/issueAssigned', 'method': 'get', 'required_parameters': [], 'callback_payload_type': 'IssueDetailsModel'}}
Classes
IssueDetailsModel
dataclass
IssueDetailsModel(title: Optional[str] = None, body: Optional[str] = None, assignee: Optional[UserDetailsModel] = None, number: Optional[int] = None, state: Optional[str] = None, created_at: Optional[str] = None, repository_url: Optional[str] = None)
Response for Create an issue
Attributes
created_at
class-attribute
instance-attribute
yyyy-MM-ddTHH:mm:ss.fffZ (UTC format).
ActionsPublicKey
dataclass
ActionsPublicKey(key_id: Optional[str] = None, key: Optional[str] = None, id: Optional[int] = None, url: Optional[str] = None, title: Optional[str] = None, created_at: Optional[str] = None)
Response for Get a repository public key
Attributes
RepositoryDetails
dataclass
RepositoryDetails(id: Optional[int] = None, node_id: Optional[str] = None, name: Optional[str] = None, full_name: Optional[str] = None, license: Optional[LicenseDetails] = None, forks: Optional[int] = None, permissions: Optional[Dict[str, Any]] = None, owner: Optional[UserDetailsModel] = None, private: Optional[bool] = None, html_url: Optional[str] = None, description: Optional[str] = None, fork: Optional[bool] = None, url: Optional[str] = None, archive_url: Optional[str] = None, assignees_url: Optional[str] = None, blobs_url: Optional[str] = None, branches_url: Optional[str] = None, collaborators_url: Optional[str] = None, comments_url: Optional[str] = None, commits_url: Optional[str] = None, compare_url: Optional[str] = None, contents_url: Optional[str] = None, contributors_url: Optional[str] = None, deployments_url: Optional[str] = None, downloads_url: Optional[str] = None, events_url: Optional[str] = None, forks_url: Optional[str] = None, git_commits_url: Optional[str] = None, git_refs_url: Optional[str] = None, git_tags_url: Optional[str] = None, git_url: Optional[str] = None, issue_comment_url: Optional[str] = None, issue_events_url: Optional[str] = None, issues_url: Optional[str] = None, keys_url: Optional[str] = None, labels_url: Optional[str] = None, languages_url: Optional[str] = None, merges_url: Optional[str] = None, milestones_url: Optional[str] = None, notifications_url: Optional[str] = None, pulls_url: Optional[str] = None, releases_url: Optional[str] = None, ssh_url: Optional[str] = None, stargazers_url: Optional[str] = None, statuses_url: Optional[str] = None, subscribers_url: Optional[str] = None, subscription_url: Optional[str] = None, tags_url: Optional[str] = None, teams_url: Optional[str] = None, trees_url: Optional[str] = None, clone_url: Optional[str] = None, mirror_url: Optional[str] = None, hooks_url: Optional[str] = None, svn_url: Optional[str] = None, homepage: Optional[str] = None, language: Optional[str] = None, forks_count: Optional[int] = None, stargazers_count: Optional[int] = None, watchers_count: Optional[int] = None, size: Optional[int] = None, default_branch: Optional[str] = None, open_issues_count: Optional[int] = None, is_template: Optional[bool] = None, topics: Optional[List[str]] = None, has_issues: Optional[bool] = None, has_projects: Optional[bool] = None, has_wiki: Optional[bool] = None, has_pages: Optional[bool] = None, has_downloads: Optional[bool] = None, archived: Optional[bool] = None, disabled: Optional[bool] = None, visibility: Optional[str] = None, pushed_at: Optional[str] = None, created_at: Optional[str] = None, updated_at: Optional[str] = None, allow_rebase_merge: Optional[bool] = None, template_repository: Optional[Dict[str, Any]] = None, temp_clone_token: Optional[str] = None, allow_squash_merge: Optional[bool] = None, delete_branch_on_merge: Optional[bool] = None, allow_merge_commit: Optional[bool] = None, subscribers_count: Optional[int] = None, network_count: Optional[int] = None, open_issues: Optional[int] = None, watchers: Optional[int] = None, master_branch: Optional[str] = None, starred_at: Optional[str] = None)
Response for Create a repository using a template
Attributes
node_id
class-attribute
instance-attribute
The Node Id of the repository.
full_name
class-attribute
instance-attribute
The full name of the repository.
forks
class-attribute
instance-attribute
The number of forks of the repository.
permissions
class-attribute
instance-attribute
Permissions on the repository.
private
class-attribute
instance-attribute
Whether the repository is private or public.
html_url
class-attribute
instance-attribute
The Html Url of the repository
description
class-attribute
instance-attribute
The description of the repository
archive_url
class-attribute
instance-attribute
The Archive URL for this repository
assignees_url
class-attribute
instance-attribute
The Assignees URL for this repository
blobs_url
class-attribute
instance-attribute
The Blobs URL for this repository
branches_url
class-attribute
instance-attribute
The Branches URL for this repository
collaborators_url
class-attribute
instance-attribute
The Collaborators URL for this repository
comments_url
class-attribute
instance-attribute
The Comments URL for this repository
commits_url
class-attribute
instance-attribute
The Commits URL for this repository
compare_url
class-attribute
instance-attribute
The Compare URL for this repository
contents_url
class-attribute
instance-attribute
The Contents URL for this repository
contributors_url
class-attribute
instance-attribute
The Contributors URL for this repository
deployments_url
class-attribute
instance-attribute
The Deployments URL for this repository
downloads_url
class-attribute
instance-attribute
The Downloads URL for this repository
events_url
class-attribute
instance-attribute
The Events URL for this repository
forks_url
class-attribute
instance-attribute
The Forks URL for this repository
git_commits_url
class-attribute
instance-attribute
The Git Commits URL for this repository
git_refs_url
class-attribute
instance-attribute
The Git References URL for this repository
git_tags_url
class-attribute
instance-attribute
The Git Tags URL for this repository
git_url
class-attribute
instance-attribute
The Git URL for this repository
issue_comment_url
class-attribute
instance-attribute
The issue comment URL for this repository
issue_events_url
class-attribute
instance-attribute
The issue events URL for this repository
issues_url
class-attribute
instance-attribute
The issues URL for this repository
keys_url
class-attribute
instance-attribute
The keys URL for this repository
labels_url
class-attribute
instance-attribute
The labels URL for this repository
languages_url
class-attribute
instance-attribute
The languages URL for this repository
merges_url
class-attribute
instance-attribute
The merges URL for this repository
milestones_url
class-attribute
instance-attribute
The milestones URL for this repository
notifications_url
class-attribute
instance-attribute
The notifications URL for this repository
pulls_url
class-attribute
instance-attribute
The pulls URL for this repository
releases_url
class-attribute
instance-attribute
The releases URL for this repository
ssh_url
class-attribute
instance-attribute
The SSH URL to clone this repository
stargazers_url
class-attribute
instance-attribute
The stargazers (Stargazers are the people that have bookmarked the GitHub repository) URL for this repository
statuses_url
class-attribute
instance-attribute
The statuses URL for this repository
subscribers_url
class-attribute
instance-attribute
The subscribers URL for this repository
subscription_url
class-attribute
instance-attribute
The subscription URL for this repository
tags_url
class-attribute
instance-attribute
The tags URL for this repository
teams_url
class-attribute
instance-attribute
The teams URL for this repository
trees_url
class-attribute
instance-attribute
The trees URL for this repository
clone_url
class-attribute
instance-attribute
The clone URL for this repository
mirror_url
class-attribute
instance-attribute
The original mirror URL for this repository
hooks_url
class-attribute
instance-attribute
The hooks URL for this repository
svn_url
class-attribute
instance-attribute
The SVN URL for this repository
homepage
class-attribute
instance-attribute
The homepage for this repository
language
class-attribute
instance-attribute
The language for this repository
forks_count
class-attribute
instance-attribute
Number of forks there are of this repository in the whole network.
stargazers_count
class-attribute
instance-attribute
Number of users who have starred the repository.
watchers_count
class-attribute
instance-attribute
Number of users watching the repository.
default_branch
class-attribute
instance-attribute
The default branch of the repository.
open_issues_count
class-attribute
instance-attribute
Number of open issues in the repository.
is_template
class-attribute
instance-attribute
Whether this repository acts as a template that can be used to generate new repositories.
topics
class-attribute
instance-attribute
List of topics in the repository
has_issues
class-attribute
instance-attribute
Whether issues are enabled.
has_projects
class-attribute
instance-attribute
Whether projects are enabled.
has_wiki
class-attribute
instance-attribute
Whether the wiki is enabled.
has_pages
class-attribute
instance-attribute
Whether pages are enabled.
has_downloads
class-attribute
instance-attribute
Whether downloads are enabled.
archived
class-attribute
instance-attribute
Whether the repository is archived.
disabled
class-attribute
instance-attribute
Returns whether or not this repository disabled.
visibility
class-attribute
instance-attribute
The repository visibility: public, private, or internal.
pushed_at
class-attribute
instance-attribute
When the repository was last pushed to.
created_at
class-attribute
instance-attribute
the date and time when the repository was created.
updated_at
class-attribute
instance-attribute
the date and time when the repository was last updated.
allow_rebase_merge
class-attribute
instance-attribute
Whether to allow rebase merges for pull requests.
temp_clone_token
class-attribute
instance-attribute
Temporary authentication token for cloning this repository.
allow_squash_merge
class-attribute
instance-attribute
Whether to allow squash merges for pull requests.
delete_branch_on_merge
class-attribute
instance-attribute
Whether to delete head branches when pull requests are merged
allow_merge_commit
class-attribute
instance-attribute
Whether to allow merge commits for pull requests.
subscribers_count
class-attribute
instance-attribute
Number of subscribers for the repository.
network_count
class-attribute
instance-attribute
Repository Network Count
open_issues
class-attribute
instance-attribute
Repository open issues.
master_branch
class-attribute
instance-attribute
Repository master branch.
GitReference
dataclass
GitReference(ref: Optional[str] = None, node_id: Optional[str] = None, url: Optional[str] = None, object: Optional[Dict[str, Any]] = None)
Response for Create a reference
Attributes
ref
class-attribute
instance-attribute
The name of the fully qualified reference.
node_id
class-attribute
instance-attribute
The Node Id of the reference.
PullRequestMergeResult
dataclass
PullRequestMergeResult(sha: Optional[str] = None, merged: Optional[bool] = None, message: Optional[str] = None)
Response for Merge a pull request
Attributes
merged
class-attribute
instance-attribute
Whether or not the pull request was merged.
PullRequest
dataclass
PullRequest(url: Optional[str] = None, id: Optional[int] = None, node_id: Optional[str] = None, html_url: Optional[str] = None, diff_url: Optional[str] = None, patch_url: Optional[str] = None, issue_url: Optional[str] = None, commits_url: Optional[str] = None, review_comments_url: Optional[str] = None, review_comment_url: Optional[str] = None, comments_url: Optional[str] = None, statuses_url: Optional[str] = None, number: Optional[int] = None, state: Optional[str] = None, locked: Optional[bool] = None, title: Optional[str] = None, user: Optional[UserDetailsModel] = None, body: Optional[str] = None, labels: Optional[List[Label]] = None, milestone: Optional[Milestone] = None, active_lock_reason: Optional[str] = None, created_at: Optional[str] = None, updated_at: Optional[str] = None, closed_at: Optional[str] = None, merged_at: Optional[str] = None, merge_commit_sha: Optional[str] = None, assignee: Optional[UserDetailsModel] = None, assignees: Optional[List[UserDetailsModel]] = None, requested_reviewers: Optional[List[UserDetailsModel]] = None, requested_teams: Optional[List[TeamDetails]] = None, head: Optional[Dict[str, Any]] = None, base: Optional[Dict[str, Any]] = None, author_association: Optional[str] = None, draft: Optional[bool] = None, merged: Optional[bool] = None, mergeable: Optional[bool] = None, rebaseable: Optional[bool] = None, mergeable_state: Optional[str] = None, merged_by: Optional[UserDetailsModel] = None, comments: Optional[int] = None, review_comments: Optional[int] = None, maintainer_can_modify: Optional[bool] = None, commits: Optional[int] = None, additions: Optional[int] = None, deletions: Optional[int] = None, changed_files: Optional[int] = None)
Response for Get a pull request
Attributes
url
class-attribute
instance-attribute
The HTTP URL for this pull request.
id
class-attribute
instance-attribute
The Unique Identifier for the pull request.
node_id
class-attribute
instance-attribute
The Node ID for the pull request.
html_url
class-attribute
instance-attribute
The HTML URL for the pull request.
diff_url
class-attribute
instance-attribute
The Diff URL for the pull request.
patch_url
class-attribute
instance-attribute
The patch URL for the pull request.
issue_url
class-attribute
instance-attribute
The issue URL for the pull request.
commits_url
class-attribute
instance-attribute
The commit URL for the pull request.
review_comments_url
class-attribute
instance-attribute
The review comments URL for the pull request.
review_comment_url
class-attribute
instance-attribute
The review comment URL for the pull request.
comments_url
class-attribute
instance-attribute
The Diff URL for the pull request.
statuses_url
class-attribute
instance-attribute
The statuses URL for the pull request.
number
class-attribute
instance-attribute
Number uniquely identifying the pull request within its repository.
state
class-attribute
instance-attribute
State of this Pull Request. Either open or closed.
locked
class-attribute
instance-attribute
Whether the pull request is locked or not.
labels
class-attribute
instance-attribute
The list of labels associated with the pull request.
active_lock_reason
class-attribute
instance-attribute
Reason that the conversation was locked.
created_at
class-attribute
instance-attribute
The date and time when the pull request was created.
updated_at
class-attribute
instance-attribute
The date and time when the pull request was last updated.
closed_at
class-attribute
instance-attribute
The date and time when the pull request was closed.
merged_at
class-attribute
instance-attribute
The date and time that the pull request was merged.
merge_commit_sha
class-attribute
instance-attribute
The merge commit Sha of the pull request.
assignees
class-attribute
instance-attribute
The list of assignees for the pull request.
requested_reviewers
class-attribute
instance-attribute
The list of Users assigned to this pull request.
requested_teams
class-attribute
instance-attribute
The list of requested teams to this pull request.
author_association
class-attribute
instance-attribute
Author's association with the subject of the comment.
draft
class-attribute
instance-attribute
Indicates whether or not the pull request is a draft.
merged
class-attribute
instance-attribute
Whether or not the pull request was merged.
mergeable
class-attribute
instance-attribute
Whether or not the pull request can be merged based on the existence of merge conflicts.
rebaseable
class-attribute
instance-attribute
Whether or not the pull request is rebaseable.
mergeable_state
class-attribute
instance-attribute
The mergeable state of the pull request.
comments
class-attribute
instance-attribute
The number of comments in this pull request.
review_comments
class-attribute
instance-attribute
The number of review comments in this pull request.
maintainer_can_modify
class-attribute
instance-attribute
Indicates whether maintainers can modify the pull request.
commits
class-attribute
instance-attribute
The number of commits in this pull request.
additions
class-attribute
instance-attribute
The number of additions in this pull request.
deletions
class-attribute
instance-attribute
The number of deletions in this pull request.
PullRequestFile
dataclass
PullRequestFile(sha: Optional[str] = None, filename: Optional[str] = None, status: Optional[str] = None, additions: Optional[int] = None, deletions: Optional[int] = None, changes: Optional[int] = None, blob_url: Optional[str] = None, raw_url: Optional[str] = None, contents_url: Optional[str] = None, patch: Optional[str] = None)
Response for Get the list of files from a pull request
Attributes
status
class-attribute
instance-attribute
The modification status for the file.
additions
class-attribute
instance-attribute
The number of additions made to the file.
deletions
class-attribute
instance-attribute
The number of deletions made to the file.
changes
class-attribute
instance-attribute
The number of changes made to the file.
blob_url
class-attribute
instance-attribute
The blob Url for the file.
contents_url
class-attribute
instance-attribute
The contents Url for the file.
CommitComparison
dataclass
CommitComparison(url: Optional[str] = None, html_url: Optional[str] = None, permalink_url: Optional[str] = None, diff_url: Optional[str] = None, patch_url: Optional[str] = None, base_commit: Optional[Commit] = None, merge_base_commit: Optional[Commit] = None, status: Optional[str] = None, ahead_by: Optional[int] = None, behind_by: Optional[int] = None, total_commits: Optional[int] = None, commits: Optional[List[Commit]] = None, files: Optional[List[DiffEntry]] = None)
Response for Compare two commits
Attributes
html_url
class-attribute
instance-attribute
Html Url for the comparison
permalink_url
class-attribute
instance-attribute
Permanent Url for the comparison
status
class-attribute
instance-attribute
Status of the comparision eg. diverged etc.,
WebhookCreationResponse
dataclass
WebhookCreationResponse(type_: Optional[str] = None, id: Optional[int] = None, name: Optional[str] = None, active: Optional[bool] = None, events: Optional[List[str]] = None, config: Optional[Dict[str, Any]] = None, updated_at: Optional[str] = None, created_at: Optional[str] = None, url: Optional[str] = None, test_url: Optional[str] = None, ping_url: Optional[str] = None, last_response: Optional[Dict[str, Any]] = None)
Response for When a pull request is created or modified
Milestone
dataclass
Milestone(url: Optional[str] = None, html_url: Optional[str] = None, labels_url: Optional[str] = None, id: Optional[int] = None, node_id: Optional[str] = None, number: Optional[int] = None, state: Optional[str] = None, title: Optional[str] = None, description: Optional[str] = None, creator: Optional[UserDetailsModel] = None, open_issues: Optional[int] = None, closed_issues: Optional[int] = None, created_at: Optional[str] = None, updated_at: Optional[str] = None, closed_at: Optional[str] = None, due_on: Optional[str] = None)
Response for Update a milestone
Attributes
html_url
class-attribute
instance-attribute
The HTML URL for the milestone.
labels_url
class-attribute
instance-attribute
The labels URL for the milestone.
id
class-attribute
instance-attribute
The Unique Identifier for the milestone.
node_id
class-attribute
instance-attribute
The Node ID for the milestone.
description
class-attribute
instance-attribute
The description of the milestone.
open_issues
class-attribute
instance-attribute
Number of open issues for the repository.
closed_issues
class-attribute
instance-attribute
Number of closed issues for the repository.
created_at
class-attribute
instance-attribute
The date and time when the milestone was created.
updated_at
class-attribute
instance-attribute
The date and time when the milestone was last updated.
closed_at
class-attribute
instance-attribute
The date and time when the milestone was closed.
UserDetailsModel
dataclass
UserDetailsModel(login: Optional[str] = None, id: Optional[int] = None, node_id: Optional[str] = None, avatar_url: Optional[str] = None, gravatar_id: Optional[str] = None, url: Optional[str] = None, html_url: Optional[str] = None, followers_url: Optional[str] = None, following_url: Optional[str] = None, gists_url: Optional[str] = None, starred_url: Optional[str] = None, subscriptions_url: Optional[str] = None, organizations_url: Optional[str] = None, repos_url: Optional[str] = None, events_url: Optional[str] = None, received_events_url: Optional[str] = None, type_: Optional[str] = None, site_admin: Optional[bool] = None, name: Optional[str] = None, company: Optional[str] = None, blog: Optional[str] = None, location: Optional[str] = None, email: Optional[str] = None, hireable: Optional[bool] = None, bio: Optional[str] = None, public_repos: Optional[int] = None, public_gists: Optional[int] = None, followers: Optional[int] = None, following: Optional[int] = None, created_at: Optional[str] = None, updated_at: Optional[str] = None)
Response for Get the authenticated user
Attributes
followers_url
class-attribute
instance-attribute
User FollowersUrl
following_url
class-attribute
instance-attribute
User Following Url.
subscriptions_url
class-attribute
instance-attribute
User Subscriptions Url.
organizations_url
class-attribute
instance-attribute
User Organizations Url.
received_events_url
class-attribute
instance-attribute
User Received Events Url.
type_
class-attribute
instance-attribute
User Type.
public_repos
class-attribute
instance-attribute
User Public Repos.
public_gists
class-attribute
instance-attribute
User Public Gists.
GeneralAPIModel
dataclass
MultipleSearchFetchModel
dataclass
IssueBasicDetailsModel
dataclass
SingleSearchFetchModel
dataclass
IssueUpdateModel
dataclass
IssueUpdateModel(title: Optional[str] = None, body: Optional[str] = None, assignee: Optional[str] = None, state: Optional[str] = None, state_reason: Optional[str] = None, milestone: Optional[str] = None, labels: Optional[List[str]] = None, assignees: Optional[List[str]] = None)
Definition: IssueUpdateModel
Attributes
state
class-attribute
instance-attribute
The open or close state of an issue. Can be one of open or closed.
state_reason
class-attribute
instance-attribute
The reason for change of state.
milestone
class-attribute
instance-attribute
Number of milestones to associate with issue.
labels
class-attribute
instance-attribute
labels associated with the issue.
MilestoneUpdateModel
dataclass
MilestoneUpdateModel(title: Optional[str] = None, state: Optional[str] = None, description: Optional[str] = None, due_on: Optional[str] = None)
Definition: MilestoneUpdateModel
Attributes
state
class-attribute
instance-attribute
The open or close state of the milestone.
description
class-attribute
instance-attribute
A description of the milestone.
Verification
dataclass
Verification(verified: Optional[bool] = None, reason: Optional[str] = None, payload: Optional[str] = None, signature: Optional[str] = None)
Definition: Verification
Attributes
verified
class-attribute
instance-attribute
Indicates whether GitHub considers the signature in this commit to be verified.
reason
class-attribute
instance-attribute
The reason for verified value.
GitUser
dataclass
GraphQlQuery
dataclass
DiffEntry
dataclass
DiffEntry(filename: Optional[str] = None, additions: Optional[int] = None, deletions: Optional[int] = None, changes: Optional[int] = None, status: Optional[str] = None, raw_url: Optional[str] = None, blob_url: Optional[str] = None, patch: Optional[str] = None, sha: Optional[str] = None, contents_url: Optional[str] = None, previous_filename: Optional[str] = None)
Definition: DiffEntry
Attributes
additions
class-attribute
instance-attribute
Number of additions in the file
deletions
class-attribute
instance-attribute
Number of Deletions in the file
changes
class-attribute
instance-attribute
Number of Changes in the file
status
class-attribute
instance-attribute
Status of the change modified, renamed etc.,
blob_url
class-attribute
instance-attribute
Blob Url link to the file
patch
class-attribute
instance-attribute
Actual changes made to the file.
contents_url
class-attribute
instance-attribute
File Contents Url.
Commit
dataclass
Commit(url: Optional[str] = None, sha: Optional[str] = None, node_id: Optional[str] = None, html_url: Optional[str] = None, comments_url: Optional[str] = None, commit: Optional[Dict[str, Any]] = None, author: Optional[UserDetailsModel] = None, committer: Optional[UserDetailsModel] = None, parents: Optional[List[Dict[str, Any]]] = None, stats: Optional[Dict[str, Any]] = None, files: Optional[List[DiffEntry]] = None)
Definition: Commit
Attributes
RepositoryDispatchEvent
dataclass
RepositoryDispatchEvent(event_type: Optional[str] = None, client_payload: Optional[Dict[str, Any]] = None)
Definition: RepositoryDispatchEvent
Attributes
event_type
class-attribute
instance-attribute
A custom webhook event name.
CreateRepositorySecretRequest
dataclass
Definition: CreateRepositorySecretRequest
Attributes
encrypted_value
class-attribute
instance-attribute
Value for your secret, encrypted with LibSodium using the public key retrieved from the Get an Repository public key action.
CreateRepositoryUsingTemplateRequest
dataclass
CreateRepositoryUsingTemplateRequest(owner: Optional[str] = None, name: Optional[str] = None, description: Optional[str] = None, private: Optional[bool] = None)
Definition: CreateRepositoryUsingTemplateRequest
Attributes
owner
class-attribute
instance-attribute
The organization or person who will own the new repository. If left blank, the authenticated user will be the owner.
description
class-attribute
instance-attribute
A short description of the new repository.
LicenseDetails
dataclass
LicenseDetails(key: Optional[str] = None, name: Optional[str] = None, url: Optional[str] = None, spdx_id: Optional[str] = None, node_id: Optional[str] = None, html_url: Optional[str] = None)
Definition: LicenseDetails
Attributes
key
class-attribute
instance-attribute
The lowercased SPDX Id of the license.
name
class-attribute
instance-attribute
The license full name specified by https://spdx.org/licenses.
url
class-attribute
instance-attribute
URL to the license on https://choosealicense.com.
spdx_id
class-attribute
instance-attribute
Short identifier specified by https://spdx.org/licenses.
RepositoryMiniDetails
dataclass
RepositoryMiniDetails(id: Optional[int] = None, node_id: Optional[str] = None, name: Optional[str] = None, full_name: Optional[str] = None, permissions: Optional[Dict[str, Any]] = None, owner: Optional[UserDetailsModel] = None, private: Optional[bool] = None, description: Optional[str] = None, homepage: Optional[str] = None, language: Optional[str] = None, archived: Optional[bool] = None, disabled: Optional[bool] = None, visibility: Optional[str] = None, created_at: Optional[str] = None, updated_at: Optional[str] = None, allow_rebase_merge: Optional[bool] = None, allow_squash_merge: Optional[bool] = None, delete_branch_on_merge: Optional[bool] = None, allow_merge_commit: Optional[bool] = None, master_branch: Optional[str] = None)
Definition: RepositoryMiniDetails
Attributes
node_id
class-attribute
instance-attribute
The Node Id of the repository.
full_name
class-attribute
instance-attribute
The full name of the repository.
permissions
class-attribute
instance-attribute
Permissions on the repository.
private
class-attribute
instance-attribute
Whether the repository is private or public.
description
class-attribute
instance-attribute
The description of the repository
homepage
class-attribute
instance-attribute
The homepage for this repository
language
class-attribute
instance-attribute
The language for this repository
archived
class-attribute
instance-attribute
Whether the repository is archived.
disabled
class-attribute
instance-attribute
Returns whether or not this repository disabled.
visibility
class-attribute
instance-attribute
The repository visibility: public, private, or internal.
created_at
class-attribute
instance-attribute
the date and time when the repository was created.
updated_at
class-attribute
instance-attribute
the date and time when the repository was last updated.
allow_rebase_merge
class-attribute
instance-attribute
Whether to allow rebase merges for pull requests.
allow_squash_merge
class-attribute
instance-attribute
Whether to allow squash merges for pull requests.
delete_branch_on_merge
class-attribute
instance-attribute
Whether to delete head branches when pull requests are merged
allow_merge_commit
class-attribute
instance-attribute
Whether to allow merge commits for pull requests.
CreateReferenceRequest
dataclass
Definition: CreateReferenceRequest
Attributes
ref
class-attribute
instance-attribute
The name of the fully qualified reference (ie: refs/heads/master). If it
doesn't start with 'refs' and have at least two slashes, it will be
rejected.
PullRequestCreateRequest
dataclass
PullRequestCreateRequest(title: Optional[str] = None, head: Optional[str] = None, base: Optional[str] = None, body: Optional[str] = None, maintainer_can_modify: Optional[bool] = None, draft: Optional[bool] = None)
Definition: PullRequestCreateRequest
Attributes
title
class-attribute
instance-attribute
The title of the new pull request.
head
class-attribute
instance-attribute
The name of the branch where your changes are implemented. For
cross-repository pull requests in the same network, namespace head with a
user like this: username:branch.
base
class-attribute
instance-attribute
The name of the branch you want the changes pulled into. This should be an existing branch on the current repository. You cannot submit a pull request to one repository that requests a merge to a base of another repository.
body
class-attribute
instance-attribute
The contents of the pull request.
maintainer_can_modify
class-attribute
instance-attribute
Indicates whether maintainers can modify the pull request.
PullRequestMergeRequest
dataclass
PullRequestMergeRequest(commit_title: Optional[str] = None, commit_message: Optional[str] = None, sha: Optional[str] = None, merge_method: Optional[str] = None)
Definition: PullRequestMergeRequest
Attributes
commit_title
class-attribute
instance-attribute
Title for the automatic commit message.
commit_message
class-attribute
instance-attribute
Extra detail to append to automatic commit message.
sha
class-attribute
instance-attribute
SHA that pull request head must match to allow merge.
PullRequestUpdateRequest
dataclass
PullRequestUpdateRequest(title: Optional[str] = None, body: Optional[str] = None, state: Optional[str] = None, base: Optional[str] = None, maintainer_can_modify: Optional[bool] = None)
Definition: PullRequestUpdateRequest
Attributes
body
class-attribute
instance-attribute
The contents of the pull request.
state
class-attribute
instance-attribute
State of this Pull Request. Either open or closed.
base
class-attribute
instance-attribute
The name of the branch you want your changes pulled into. This should be an existing branch on the current repository. You cannot update the base branch on a pull request to point to another repository.
Label
dataclass
Label(id: Optional[int] = None, node_id: Optional[str] = None, url: Optional[str] = None, name: Optional[str] = None, description: Optional[str] = None, color: Optional[str] = None, default: Optional[bool] = None)
Definition: Label
Attributes
description
class-attribute
instance-attribute
A brief description of this label.
color
class-attribute
instance-attribute
6-character hex code, without the leading #, identifying the color
TeamDetails
dataclass
TeamDetails(id: Optional[int] = None, node_id: Optional[str] = None, url: Optional[str] = None, members_url: Optional[str] = None, name: Optional[str] = None, description: Optional[str] = None, permission: Optional[str] = None, privacy: Optional[str] = None, html_url: Optional[str] = None, repositories_url: Optional[str] = None, slug: Optional[str] = None, ldap_dn: Optional[str] = None)
Definition: TeamDetails
Attributes
members_url
class-attribute
instance-attribute
The HTTP URL for the team members.
description
class-attribute
instance-attribute
Description of the team
permission
class-attribute
instance-attribute
Permission that the team will have for its repositories
privacy
class-attribute
instance-attribute
The level of privacy this team should have
repositories_url
class-attribute
instance-attribute
The HTTP URL for this team's repositories.
slug
class-attribute
instance-attribute
The slug corresponding to the team.
WebhookPullRequestResponse
dataclass
WebhookRequestBody
dataclass
WebhookRequestBody(active: Optional[bool] = None, name: Optional[str] = None, config: Optional[Dict[str, Any]] = None, events: Optional[List[str]] = None)
Definition: WebhookRequestBody
Attributes
active
class-attribute
instance-attribute
State of the Trigger, always set to true
config
class-attribute
instance-attribute
Configuration of the Trigger
RequestReviewersBody
dataclass
RequestReviewersBody(reviewers: Optional[List[str]] = None, team_reviewers: Optional[List[str]] = None)
Definition: RequestReviewersBody
QueryRequest
dataclass
QueryRequest(jsonrpc: Optional[str] = None, id: Optional[str] = None, method: Optional[str] = None, params: Optional[Dict[str, Any]] = None, result: Optional[Dict[str, Any]] = None, error: Optional[Dict[str, Any]] = None)
Definition: QueryRequest
GithubClient
GithubClient(connection_runtime_url: str, token_provider: Optional[TokenProvider] = None, options: Optional[ConnectorClientOptions] = None)
Bases: ConnectorClientBase
Typed client for github connector.
Initialize a GithubClient.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
connection_runtime_url
|
str
|
The connection runtime URL from Azure Portal. |
required |
token_provider
|
Optional[TokenProvider]
|
Optional token provider. Defaults to ManagedIdentityTokenProvider. |
None
|
options
|
Optional[ConnectorClientOptions]
|
Optional connector client options. |
None
|
Methods:
create_issue_async
async
create_issue_async(input: IssueBasicDetailsModel, repository_owner: str, repository_name: str) -> dict[str, Any] | None
Create an issue
This operation is used to create a new issue for a specific repository.
get_issues_async
async
get_issues_async(repository_owner: str, repository_name: str, milestone: Optional[str] = None, state: Optional[str] = None, assignee: Optional[str] = None, creator: Optional[str] = None, mentioned: Optional[str] = None, labels: Optional[str] = None, sort: Optional[str] = None, direction: Optional[str] = None, since: Optional[str] = None, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Get all issues of a repository
Get all issues of a repository.
get_repository_public_key_async
async
get_repository_public_key_async(repository_owner: str, repository_name: str) -> dict[str, Any] | None
Get a repository public key
Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets.
create_update_repository_secret_async
async
create_update_repository_secret_async(input: CreateRepositorySecretRequest, repository_owner: str, repository_name: str, secret_name: str) -> None
Create or update a repository secret
Creates or updates a repository secret with an encrypted value. Encrypt your secret using LibSodium.
create_repository_using_template_async
async
create_repository_using_template_async(input: CreateRepositoryUsingTemplateRequest, template_owner: str, template_repository: str) -> dict[str, Any] | None
Create a repository using a template
Creates a new repository using a repository template. The authenticated user must own or be a member of an organization that owns the repository.
get_repository_by_id_async
async
Get a repository by Id
Gets a repository by Id.
create_reference_async
async
create_reference_async(input: CreateReferenceRequest, repository_owner: str, repository_name: str) -> dict[str, Any] | None
Create a reference
Creates a reference for your repository. You are unable to create new references for empty repositories, even if the commit SHA-1 hash used exists. Empty repositories are repositories without branches.
get_reference_async
async
get_reference_async(repository_owner: str, repository_name: str, reference: str) -> dict[str, Any] | None
Get a reference
Returns a single reference from your Git database. The reference
parameter must be formatted as heads/<branch name> for branches and
tags/<tag name> for tags. If the reference doesn't match an
existing ref, a 404 is returned.
merge_pull_request_async
async
merge_pull_request_async(input: PullRequestMergeRequest, repository_owner: str, repository_name: str, pull_number: int) -> dict[str, Any] | None
Merge a pull request
This operation is used to merge a pull request for the repository.
get_pull_request_async
async
get_pull_request_async(repository_owner: str, repository_name: str, pull_number: int) -> dict[str, Any] | None
Get a pull request
This operation is used to get a pull request for the repository.
update_pull_request_async
async
update_pull_request_async(input: PullRequestUpdateRequest, repository_owner: str, repository_name: str, pull_number: int) -> dict[str, Any] | None
Update a pull request
This operation is used to update a pull request for the repository. To update a pull request in a public repository, you must have write access to the head or the source branch. For organization-owned repositories, you must be a member of the organization that owns the repository to open or update a pull request.
get_pull_request_files_async
async
get_pull_request_files_async(repository_owner: str, repository_name: str, pull_number: int) -> dict[str, Any] | None
Get the list of files from a pull request
This operation is used to get the list of files from a pull request for the repository.
request_reviewers_pull_request_async
async
request_reviewers_pull_request_async(input: RequestReviewersBody, repository_owner: str, repository_name: str, pull_number: int) -> None
Request reviewers for a pull request
Requests reviews for a pull request from a given set of users and/or teams.
remove_reviewers_pull_request_async
async
remove_reviewers_pull_request_async(input: RequestReviewersBody, repository_owner: str, repository_name: str, pull_number: int) -> None
Remove requested reviewers from a pull request
Remove requested reviewers from a pull request from a given set of users and/or teams.
create_pull_request_async
async
create_pull_request_async(input: PullRequestCreateRequest, repository_owner: str, repository_name: str) -> dict[str, Any] | None
Create a pull request
This operation is to create a pull request in a repository. To open or update a pull request in a public repository, you must have write access to the head or the source branch. For organization-owned repositories, you must be a member of the organization that owns the repository to create a pull request.
get_pull_requests_async
async
get_pull_requests_async(repository_owner: str, repository_name: str, state: Optional[str] = None, head: Optional[str] = None, base: Optional[str] = None, sort: Optional[str] = None, direction: Optional[str] = None, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Get all Pull Requests of A Repository
Get all Pull Requests of A Repository.
create_repository_dispatch_event_async
async
create_repository_dispatch_event_async(input: RepositoryDispatchEvent, repository_owner: str, repository_name: str) -> None
Create a repository dispatch event
This operation is to trigger a webhook event called
repository_dispatch when you want activity that happens outside of
GitHub to trigger a GitHub Actions workflow or GitHub App webhook. You
must configure your GitHub Actions workflow or GitHub App to run when
the repository_dispatch event occurs.
compare_repository_commits_async
async
compare_repository_commits_async(repository_owner: str, repository_name: str, base: str, head: str) -> dict[str, Any] | None
Compare two commits
Both base and head must be branch names in repositoryName. To
compare branches across other repositories in the same network as
repositoryName, use the format <USERNAME>:branch. The response is
equivalent to running the git log base..head command; however,
commits are returned in chronological order.
add_selected_repo_to_org_secret_async
async
add_selected_repo_to_org_secret_async(repository_owner: str, repository_id: int, secret_name: str) -> None
Add selected repository to an organization secret
Adds a repository to an organization secret when the visibility for
repository access is set to selected. The visibility is set when you
Create or update an organization
secret.
You must authenticate using an access token with the admin:org scope
to use this endpoint. GitHub Apps must have the secrets organization
permission to use this endpoint.
remove_selected_repo_from_org_secret_async
async
remove_selected_repo_from_org_secret_async(repository_owner: str, repository_id: int, secret_name: str) -> None
Remove selected repository from an organization secret
Removes a repository from an organization secret when the visibility
for repository access is set to selected. The visibility is set when
you Create or update an organization
secret.
You must authenticate using an access token with the admin:org scope
to use this endpoint. GitHub Apps must have the secrets organization
permission to use this endpoint.
delete_webhook_trigger_async
async
Deletes a GitHub Webhook
Deletes a GitHub Webhook
get_issue_num_async
async
get_issue_num_async(repository_owner: str, repository_name: str, issue_number: int) -> dict[str, Any] | None
Get a particular issue of a repository
Get a particular issue of a repository.
update_issue_num_async
async
update_issue_num_async(input: IssueUpdateModel, repository_owner: str, repository_name: str, issue_number: int) -> dict[str, Any] | None
Update an Issue
Update an existing issue given the issue number.
update_milestone_async
async
update_milestone_async(input: MilestoneUpdateModel, repository_owner: str, repository_name: str, milestone_number: int) -> dict[str, Any] | None
Update a milestone
Update an existing milestone.
get_user_async
async
Get the authenticated user
Get the authenticated user.
search_github_with_query_async
async
Search Github using Query
Search Github using Query
get_assignees_async
async
get_assignees_async(repository_owner: str, repository_name: str, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Lists the available assignees for issues in a repository
Lists the available assignees for issues in a repository.
list_collaborators_async
async
list_collaborators_async(repository_owner: str, repository_name: str, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
List repository collaborators
List repository collaborators.
check_collaborator_async
async
check_collaborator_async(repository_owner: str, repository_name: str, user_name: str) -> dict[str, Any] | None
Check if a user is a repository collaborator
Check if a user is a repository collaborator.
get_milestones_async
async
get_milestones_async(repository_owner: str, repository_name: str, state: Optional[str] = None, sort: Optional[str] = None, direction: Optional[str] = None, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Lists all milestones of a repository
Lists all milestones of a repository.
get_labels_async
async
get_labels_async(repository_owner: str, repository_name: str, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Lists all labels for a repository
Lists all labels for a repository.
get_issue_labels_async
async
get_issue_labels_async(repository_owner: str, repository_name: str, issue_number: int, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Lists all labels for an issue
Lists all labels for an issue.
get_repos_async
async
get_repos_async(repository_owner: str, type_: Optional[str] = None, sort: Optional[str] = None, direction: Optional[str] = None, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Lists all public repositories for a user
Lists all public repositories for a user.
get_org_repos_async
async
get_org_repos_async(repository_owner: str, type_: Optional[str] = None, sort: Optional[str] = None, direction: Optional[str] = None, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Lists all public repositories for an organization
Lists all public repositories for an organization.
get_user_repos_async
async
get_user_repos_async(visibility: Optional[str] = None, affiliation: Optional[str] = None, since: Optional[str] = None, before: Optional[str] = None, type_: Optional[str] = None, sort: Optional[str] = None, direction: Optional[str] = None, per_page: Optional[int] = None, page: Optional[int] = None) -> dict[str, Any] | None
Lists all repositories for the authenticated user
Lists all repositories (both public and private) for the authenticated user.