Documentation
¶
Index ¶
- Constants
- type ActionArtifact
- type ActionJob
- type ActionRun
- type ActionRunner
- type ActionStep
- type ActionWorkflow
- type AddCollaboratorOptions
- type AddToKanbanBoardOptions
- type AnnotatedTag
- type ArchiveStatus
- type AuthStyle
- type Branch
- type BranchCommitDetail
- type BranchProtection
- type BranchProtectionRule
- type Client
- func (c *Client) AcceptRepoInvitation(ctx context.Context, invitationID int64) error
- func (c *Client) AddCollaborator(ctx context.Context, owner, repo, username string, ...) error
- func (c *Client) AddIssueAssignees(ctx context.Context, owner, repo string, number int, assignees []string) (*Issue, error)
- func (c *Client) AddIssueLabels(ctx context.Context, owner, repo string, number int, labels []string) error
- func (c *Client) AddPullRequestLabels(ctx context.Context, owner, repo string, number int, labels []string) error
- func (c *Client) AddRepositoryTopic(ctx context.Context, owner, repo, topic string) error
- func (c *Client) AddTeamMember(ctx context.Context, teamID int64, username string) error
- func (c *Client) AddTeamRepository(ctx context.Context, teamID int64, org, repo string) error
- func (c *Client) AddToKanbanBoard(ctx context.Context, org string, boardID int64, opts AddToKanbanBoardOptions) (*KanbanBoardItem, error)
- func (c *Client) ArchiveRepository(ctx context.Context, owner, repo string) error
- func (c *Client) AssignPullRequestApprovalReviewers(ctx context.Context, owner, repo string, number int, reviewers string) error
- func (c *Client) AssignPullRequestReviewers(ctx context.Context, owner, repo string, number int, assignees string) error
- func (c *Client) AssignPullRequestTesters(ctx context.Context, owner, repo string, number int, testers string) error
- func (c *Client) BlockOrgUser(ctx context.Context, org, username string) error
- func (c *Client) CloseIssue(ctx context.Context, owner, repo string, number int) (*Issue, error)
- func (c *Client) ClosePullRequest(ctx context.Context, owner, repo string, number int) (*PullRequest, error)
- func (c *Client) CompareCommits(ctx context.Context, owner, repo, base, head string) (*CommitComparison, error)
- func (c *Client) ConcealOrgMembership(ctx context.Context, org, username string) error
- func (c *Client) ConfigureRepoCLA(ctx context.Context, owner, repo string, opts *RepoCLA) (*RepoCLA, error)
- func (c *Client) CreateAnnotatedTag(ctx context.Context, owner, repo string, opts CreateAnnotatedTagOptions) (*AnnotatedTag, error)
- func (c *Client) CreateBranch(ctx context.Context, owner, repo string, opts CreateBranchOptions) (*Branch, error)
- func (c *Client) CreateBranchProtection(ctx context.Context, owner, repo string, opts CreateBranchProtectionOptions) (*BranchProtectionRule, error)
- func (c *Client) CreateCommitComment(ctx context.Context, owner, repo, sha string, opts CreateCommitCommentOptions) (*CommitComment, error)
- func (c *Client) CreateCommitStatus(ctx context.Context, owner, repo, sha string, opts CreateCommitStatusOptions) (*CommitStatus, error)
- func (c *Client) CreateDeployKey(ctx context.Context, owner, repo string, opts CreateDeployKeyOptions) (*DeployKey, error)
- func (c *Client) CreateEnterpriseLabel(ctx context.Context, enterprise string, opts CreateEnterpriseLabelOptions) (*EnterpriseLabel, error)
- func (c *Client) CreateEnterpriseMilestone(ctx context.Context, enterprise string, opts CreateEnterpriseMilestoneOptions) (*EnterpriseMilestone, error)
- func (c *Client) CreateFile(ctx context.Context, owner, repo, path string, opts CreateFileOptions) (*FileResult, error)
- func (c *Client) CreateGitReference(ctx context.Context, owner, repo string, opts CreateReferenceOptions) (*GitReference, error)
- func (c *Client) CreateIssue(ctx context.Context, owner, repo string, opts CreateIssueOptions) (*Issue, error)
- func (c *Client) CreateIssueComment(ctx context.Context, owner, repo string, number int, body string) (*IssueComment, error)
- func (c *Client) CreateIssueCommentReaction(ctx context.Context, owner, repo string, commentID int64, content string) (*Reaction, error)
- func (c *Client) CreateIssueDependency(ctx context.Context, owner, repo string, number int, dependsOnNumber int) (*IssueDependency, error)
- func (c *Client) CreateIssueLabel(ctx context.Context, owner, repo string, name, color string) (*Label, error)
- func (c *Client) CreateIssueReaction(ctx context.Context, owner, repo string, number int, content string) (*Reaction, error)
- func (c *Client) CreateMilestone(ctx context.Context, owner, repo string, title, description string) (*Milestone, error)
- func (c *Client) CreateMilestoneWithOptions(ctx context.Context, owner, repo string, opts CreateMilestoneOptions) (*Milestone, error)
- func (c *Client) CreateOrgLabel(ctx context.Context, org string, opts CreateOrgLabelOptions) (*OrgLabel, error)
- func (c *Client) CreateOrgRepository(ctx context.Context, org string, opts CreateOrgRepoOptions) (*Repository, error)
- func (c *Client) CreateOrgWebhook(ctx context.Context, org string, opts CreateOrgWebhookOptions) (*OrgWebhook, error)
- func (c *Client) CreateOrganization(ctx context.Context, opts CreateOrgOptions) (*Organization, error)
- func (c *Client) CreateProtectedTag(ctx context.Context, owner, repo string, opts CreateProtectedTagOptions) (*ProtectedTag, error)
- func (c *Client) CreatePullRequest(ctx context.Context, owner, repo string, opts CreatePullRequestOptions) (*PullRequest, error)
- func (c *Client) CreatePullRequestComment(ctx context.Context, owner, repo string, number int, body, path string, ...) (*PullRequestComment, error)
- func (c *Client) CreatePullRequestCommentReaction(ctx context.Context, owner, repo string, commentID int64, content string) (*Reaction, error)
- func (c *Client) CreatePullRequestInlineComment(ctx context.Context, owner, repo string, number int, ...) (*PullRequestComment, error)
- func (c *Client) CreatePullRequestReview(ctx context.Context, owner, repo string, number int, body, event string) (*PullRequestReview, error)
- func (c *Client) CreateRelease(ctx context.Context, owner, repo string, opts CreateReleaseOptions) (*Release, error)
- func (c *Client) CreateRepository(ctx context.Context, opts CreateRepositoryOptions) (*Repository, error)
- func (c *Client) CreateSSHKey(ctx context.Context, opts CreateSSHKeyOptions) (*SSHKey, error)
- func (c *Client) CreateTag(ctx context.Context, owner, repo string, opts CreateTagOptions) (*Tag, error)
- func (c *Client) CreateTeam(ctx context.Context, org string, opts CreateTeamOptions) (*Team, error)
- func (c *Client) CreateWebhook(ctx context.Context, owner, repo string, opts CreateWebhookOptions) (*Webhook, error)
- func (c *Client) CreateWikiPage(ctx context.Context, owner, repo string, opts CreateWikiPageOptions) (*WikiPage, error)
- func (c *Client) DeclineRepoInvitation(ctx context.Context, invitationID int64) error
- func (c *Client) DeleteActionArtifact(ctx context.Context, owner, repo string, artifactID int64) error
- func (c *Client) DeleteBranch(ctx context.Context, owner, repo, branch string) error
- func (c *Client) DeleteBranchProtection(ctx context.Context, owner, repo, name string) error
- func (c *Client) DeleteCommitComment(ctx context.Context, owner, repo string, commentID int64) error
- func (c *Client) DeleteDeployKey(ctx context.Context, owner, repo string, keyID int64) error
- func (c *Client) DeleteEnterpriseLabel(ctx context.Context, enterprise string, labelID int64) error
- func (c *Client) DeleteEnterpriseMember(ctx context.Context, enterprise, username string) error
- func (c *Client) DeleteEnterpriseMilestone(ctx context.Context, enterprise string, milestoneID int64) error
- func (c *Client) DeleteFile(ctx context.Context, owner, repo, path string, opts DeleteFileOptions) (*FileResult, error)
- func (c *Client) DeleteGitReference(ctx context.Context, owner, repo, ref string) error
- func (c *Client) DeleteIssueComment(ctx context.Context, owner, repo string, commentID int64) error
- func (c *Client) DeleteIssueCommentReaction(ctx context.Context, owner, repo string, commentID, reactionID int64) error
- func (c *Client) DeleteIssueDependency(ctx context.Context, owner, repo string, number int, dependencyNumber int) error
- func (c *Client) DeleteIssueLabel(ctx context.Context, owner, repo string, name string) error
- func (c *Client) DeleteIssueReaction(ctx context.Context, owner, repo string, number int, reactionID int64) error
- func (c *Client) DeleteMilestone(ctx context.Context, owner, repo string, number int) error
- func (c *Client) DeleteOrgLabel(ctx context.Context, org string, labelID int64) error
- func (c *Client) DeleteOrgWebhook(ctx context.Context, org string, hookID int64) error
- func (c *Client) DeleteOrganization(ctx context.Context, org string) error
- func (c *Client) DeleteProtectedTag(ctx context.Context, owner, repo, tag string) error
- func (c *Client) DeletePullRequestComment(ctx context.Context, owner, repo string, commentID string) error
- func (c *Client) DeletePullRequestCommentReaction(ctx context.Context, owner, repo string, commentID, reactionID int64) error
- func (c *Client) DeleteRelease(ctx context.Context, owner, repo string, tagName string) error
- func (c *Client) DeleteReleaseAsset(ctx context.Context, owner, repo string, assetID int64) error
- func (c *Client) DeleteReleaseByID(ctx context.Context, owner, repo string, releaseID int64) error
- func (c *Client) DeleteRepository(ctx context.Context, owner, repo string) error
- func (c *Client) DeleteRepositoryTopic(ctx context.Context, owner, repo, topic string) error
- func (c *Client) DeleteSSHKey(ctx context.Context, id int64) error
- func (c *Client) DeleteTag(ctx context.Context, owner, repo, tagName string) error
- func (c *Client) DeleteTeam(ctx context.Context, teamID int64) error
- func (c *Client) DeleteWebhook(ctx context.Context, owner, repo string, hookID int64) error
- func (c *Client) DeleteWikiPage(ctx context.Context, owner, repo, pageName string) error
- func (c *Client) DismissPullRequestReview(ctx context.Context, owner, repo string, number int, reviewID int64, ...) error
- func (c *Client) DownloadActionArtifact(ctx context.Context, owner, repo string, artifactID int64) ([]byte, error)
- func (c *Client) DownloadReleaseAsset(ctx context.Context, owner, repo string, assetID int64) ([]byte, error)
- func (c *Client) DownloadRepository(ctx context.Context, owner, repo, format string) ([]byte, error)
- func (c *Client) ExitOrganization(ctx context.Context, org string) error
- func (c *Client) FollowUser(ctx context.Context, username string) error
- func (c *Client) ForkRepository(ctx context.Context, owner, repo string, opts *CreateRepositoryOptions) (*Repository, error)
- func (c *Client) GenerateRepositoryArchive(ctx context.Context, owner, repo, ref, format string) ([]byte, error)
- func (c *Client) GetActionArtifact(ctx context.Context, owner, repo string, artifactID int64) (*ActionArtifact, error)
- func (c *Client) GetActionJob(ctx context.Context, owner, repo string, jobID int64) (*ActionJob, error)
- func (c *Client) GetActionJobLogs(ctx context.Context, owner, repo string, jobID int64) ([]byte, error)
- func (c *Client) GetActionJobStepLogs(ctx context.Context, owner, repo string, jobID int64) ([]byte, error)
- func (c *Client) GetActionRun(ctx context.Context, owner, repo string, runID int64) (*ActionRun, error)
- func (c *Client) GetAnnotatedTag(ctx context.Context, owner, repo, sha string) (*AnnotatedTag, error)
- func (c *Client) GetArchiveStatus(ctx context.Context, owner, repo string) (*ArchiveStatus, error)
- func (c *Client) GetBlob(ctx context.Context, owner, repo, sha string) (*GitBlob, error)
- func (c *Client) GetBranch(ctx context.Context, owner, repo, branch string) (*Branch, error)
- func (c *Client) GetCollaboratorPermission(ctx context.Context, owner, repo, username string) (*CollaboratorPermission, error)
- func (c *Client) GetCombinedStatus(ctx context.Context, owner, repo, sha string) (*CombinedStatus, error)
- func (c *Client) GetCommit(ctx context.Context, owner, repo, sha string) (*Commit, error)
- func (c *Client) GetCommitComment(ctx context.Context, owner, repo string, commentID int64) (*CommitComment, error)
- func (c *Client) GetCommitDiff(ctx context.Context, owner, repo, sha string) ([]byte, error)
- func (c *Client) GetCommitPatch(ctx context.Context, owner, repo, sha string) ([]byte, error)
- func (c *Client) GetContributorStatistics(ctx context.Context, owner, repo string) ([]*ContributorStatistic, error)
- func (c *Client) GetCurrentUser(ctx context.Context) (*User, error)
- func (c *Client) GetCustomizedRoles(ctx context.Context, owner, repo string) ([]*CustomizedRole, error)
- func (c *Client) GetDeployKey(ctx context.Context, owner, repo string, keyID int64) (*DeployKey, error)
- func (c *Client) GetDiscussion(ctx context.Context, owner, repo string, number int) (*Discussion, error)
- func (c *Client) GetDownloadStatistics(ctx context.Context, owner, repo string) ([]*DownloadStatistic, error)
- func (c *Client) GetEnterpriseIssue(ctx context.Context, enterprise string, number int) (*Issue, error)
- func (c *Client) GetEnterpriseIssueLinkedPRs(ctx context.Context, enterprise string, number int) ([]*PullRequest, error)
- func (c *Client) GetEnterpriseMember(ctx context.Context, enterprise, username string) (*EnterpriseMember, error)
- func (c *Client) GetEnterpriseMilestone(ctx context.Context, enterprise string, milestoneID int64) (*EnterpriseMilestone, error)
- func (c *Client) GetExtendedUser(ctx context.Context, username string) (*ExtendedUser, error)
- func (c *Client) GetForkSyncStatus(ctx context.Context, owner, repo string) (*ForkSyncStatus, error)
- func (c *Client) GetGitReference(ctx context.Context, owner, repo, ref string) (*GitReference, error)
- func (c *Client) GetGitignoreTemplate(ctx context.Context, name string) (*GitignoreTemplate, error)
- func (c *Client) GetIssue(ctx context.Context, owner, repo string, number int) (*Issue, error)
- func (c *Client) GetIssueComment(ctx context.Context, owner, repo string, commentID int64) (*IssueComment, error)
- func (c *Client) GetIssueLinkedPRs(ctx context.Context, owner, repo string, number int) ([]*PullRequest, error)
- func (c *Client) GetIssueOperateLogs(ctx context.Context, owner, repo string, number int) ([]*IssueOperateLog, error)
- func (c *Client) GetIssueTemplate(ctx context.Context, owner, repo, name string) (*IssueTemplate, error)
- func (c *Client) GetKanbanBoard(ctx context.Context, org string, boardID int64) (*KanbanBoard, error)
- func (c *Client) GetLabelTemplate(ctx context.Context, name string) ([]*Label, error)
- func (c *Client) GetLanguages(ctx context.Context, owner, repo string) (Language, error)
- func (c *Client) GetLatestRelease(ctx context.Context, owner, repo string) (*Release, error)
- func (c *Client) GetLicenseTemplate(ctx context.Context, name string) (*LicenseTemplate, error)
- func (c *Client) GetMilestone(ctx context.Context, owner, repo string, number int) (*Milestone, error)
- func (c *Client) GetNamespace(ctx context.Context, path string) (*Namespace, error)
- func (c *Client) GetNotificationThread(ctx context.Context, threadID int64) (*NotificationThread, error)
- func (c *Client) GetOrgDiscussion(ctx context.Context, org string, number int) (*OrgDiscussion, error)
- func (c *Client) GetOrgEnterprise(ctx context.Context, org string) (*OrgEnterprise, error)
- func (c *Client) GetOrgInfo(ctx context.Context, org string) (*Organization, error)
- func (c *Client) GetOrgIssueExtendSettings(ctx context.Context, org string) ([]*IssueExtendSetting, error)
- func (c *Client) GetOrgLabel(ctx context.Context, org string, labelID int64) (*OrgLabel, error)
- func (c *Client) GetOrgMemberDetail(ctx context.Context, org, username string) (*OrgMemberDetail, error)
- func (c *Client) GetOrgWebhook(ctx context.Context, org string, hookID int64) (*OrgWebhook, error)
- func (c *Client) GetOrganization(ctx context.Context, org string) (*Organization, error)
- func (c *Client) GetPRSettings(ctx context.Context, owner, repo string) (*PRSettings, error)
- func (c *Client) GetProtectedTag(ctx context.Context, owner, repo, tag string) (*ProtectedTag, error)
- func (c *Client) GetPullRequest(ctx context.Context, owner, repo string, number int) (*PullRequest, error)
- func (c *Client) GetPullRequestComment(ctx context.Context, owner, repo string, commentID int64) (*PullRequestComment, error)
- func (c *Client) GetPullRequestDiff(ctx context.Context, owner, repo string, number int) ([]byte, error)
- func (c *Client) GetPullRequestLinkedIssues(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*Issue, error)
- func (c *Client) GetPullRequestOperateLogs(ctx context.Context, owner, repo string, number int) ([]*PROperateLog, error)
- func (c *Client) GetPullRequestPatch(ctx context.Context, owner, repo string, number int) ([]byte, error)
- func (c *Client) GetPullRequestReview(ctx context.Context, owner, repo string, number int, reviewID int64) (*PullRequestReview, error)
- func (c *Client) GetPushConfig(ctx context.Context, owner, repo string) (*PushConfig, error)
- func (c *Client) GetRateLimit(ctx context.Context) (*RateLimit, error)
- func (c *Client) GetRawFile(ctx context.Context, owner, repo, path, ref string) ([]byte, error)
- func (c *Client) GetRelease(ctx context.Context, owner, repo string, releaseID int64) (*Release, error)
- func (c *Client) GetReleaseAsset(ctx context.Context, owner, repo string, assetID int64) (*ReleaseAsset, error)
- func (c *Client) GetReleaseByTag(ctx context.Context, owner, repo, tag string) (*Release, error)
- func (c *Client) GetReleaseUploadURL(ctx context.Context, owner, repo string, releaseID int64, name, label string) (*ReleaseUploadURL, error)
- func (c *Client) GetRepoBranchDetail(ctx context.Context, owner, repo, branch string) (*RepoBranchInfo, error)
- func (c *Client) GetRepoCodeFrequency(ctx context.Context, owner, repo string) ([]CodeFrequencyEntry, error)
- func (c *Client) GetRepoCommitActivity(ctx context.Context, owner, repo string) ([]*CommitActivity, error)
- func (c *Client) GetRepoLicense(ctx context.Context, owner, repo string) (*RepoLicense, error)
- func (c *Client) GetRepoParticipation(ctx context.Context, owner, repo string) (*ParticipationStats, error)
- func (c *Client) GetRepoPunchCard(ctx context.Context, owner, repo string) ([]PunchCardEntry, error)
- func (c *Client) GetRepoRemoteMirror(ctx context.Context, owner, repo string) (*RemoteMirror, error)
- func (c *Client) GetRepoSettings(ctx context.Context, owner, repo string) (*RepoSettings, error)
- func (c *Client) GetRepoVisibility(ctx context.Context, owner, repo string) (bool, error)
- func (c *Client) GetRepository(ctx context.Context, owner, repo string) (*Repository, error)
- func (c *Client) GetRepositoryArchive(ctx context.Context, owner, repo, archive string) ([]byte, error)
- func (c *Client) GetRepositoryContent(ctx context.Context, owner, repo, path, ref string) (*RepositoryContent, error)
- func (c *Client) GetRunnerGroup(ctx context.Context, org string, groupID int64) (*RunnerGroup, error)
- func (c *Client) GetSSHKey(ctx context.Context, id int64) (*SSHKey, error)
- func (c *Client) GetTag(ctx context.Context, owner, repo, tagName string) (*Tag, error)
- func (c *Client) GetTeam(ctx context.Context, teamID int64) (*Team, error)
- func (c *Client) GetTeamMember(ctx context.Context, teamID int64, username string) (*User, error)
- func (c *Client) GetTree(ctx context.Context, owner, repo, sha string, recursive bool) (*GitTree, error)
- func (c *Client) GetUser(ctx context.Context, username string) (*User, error)
- func (c *Client) GetUserEvents(ctx context.Context, username, year, next string) (*UserEventsResponse, error)
- func (c *Client) GetUserMembership(ctx context.Context, org string) (*UserMembership, error)
- func (c *Client) GetWebhook(ctx context.Context, owner, repo string, hookID int64) (*Webhook, error)
- func (c *Client) GetWikiPage(ctx context.Context, owner, repo, pageName string) (*WikiPage, error)
- func (c *Client) HandlePullRequestReview(ctx context.Context, owner, repo string, number int, force bool) error
- func (c *Client) HandlePullRequestTest(ctx context.Context, owner, repo string, number int, force bool) error
- func (c *Client) InviteEnterpriseMember(ctx context.Context, enterprise string, username string, ...) error
- func (c *Client) InviteOrgMember(ctx context.Context, org, username string, opts InviteMemberOptions) (*User, error)
- func (c *Client) IsCollaborator(ctx context.Context, owner, repo, username string) (bool, error)
- func (c *Client) IsFollowing(ctx context.Context, username string) (bool, error)
- func (c *Client) IsOrgBlockedUser(ctx context.Context, org, username string) (bool, error)
- func (c *Client) IsOrgPublicMember(ctx context.Context, org, username string) (bool, error)
- func (c *Client) IsPullRequestMerged(ctx context.Context, owner, repo string, number int) (bool, error)
- func (c *Client) IsRepoAssignee(ctx context.Context, owner, repo, username string) (bool, error)
- func (c *Client) IsRepositoryStarred(ctx context.Context, owner, repo string) (bool, error)
- func (c *Client) LinkPullRequestIssue(ctx context.Context, owner, repo string, number int, issueNumber int) error
- func (c *Client) ListActionArtifacts(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionArtifact, error)
- func (c *Client) ListActionJobs(ctx context.Context, owner, repo string, runID int64, opts ListOptions) ([]*ActionJob, error)
- func (c *Client) ListActionRunArtifacts(ctx context.Context, owner, repo string, runID int64, opts ListOptions) ([]*ActionArtifact, error)
- func (c *Client) ListActionRuns(ctx context.Context, owner, repo string, opts ListActionRunsOptions) ([]*ActionRun, error)
- func (c *Client) ListActionWorkflows(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionWorkflow, error)
- func (c *Client) ListBranchProtections(ctx context.Context, owner, repo string) ([]*BranchProtectionRule, error)
- func (c *Client) ListBranches(ctx context.Context, owner, repo string) ([]*Branch, error)
- func (c *Client) ListCollaborators(ctx context.Context, owner, repo string, opts ListOptions) ([]*Collaborator, error)
- func (c *Client) ListCommitComments(ctx context.Context, owner, repo, sha string, opts ListOptions) ([]*CommitComment, error)
- func (c *Client) ListCommitStatuses(ctx context.Context, owner, repo, sha string, opts ListOptions) ([]*CommitStatus, error)
- func (c *Client) ListCommits(ctx context.Context, owner, repo string, opts ListCommitsOptions) ([]*Commit, error)
- func (c *Client) ListContributors(ctx context.Context, owner, repo string) ([]*Contributor, error)
- func (c *Client) ListCurrentUserFollowers(ctx context.Context, opts ListOptions) ([]*User, error)
- func (c *Client) ListCurrentUserFollowing(ctx context.Context, opts ListOptions) ([]*User, error)
- func (c *Client) ListCurrentUserRepositories(ctx context.Context, opts ListRepositoriesOptions) ([]*Repository, error)
- func (c *Client) ListCurrentUserWatchedRepositories(ctx context.Context, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListDeployKeys(ctx context.Context, owner, repo string, opts ListOptions) ([]*DeployKey, error)
- func (c *Client) ListDiscussionCommentReplies(ctx context.Context, owner, repo string, number int, commentID int64, ...) ([]*DiscussionCommentReply, error)
- func (c *Client) ListDiscussionComments(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*DiscussionComment, error)
- func (c *Client) ListDiscussions(ctx context.Context, owner, repo string, opts ListOptions) ([]*Discussion, error)
- func (c *Client) ListEmails(ctx context.Context) ([]*Email, error)
- func (c *Client) ListEnterpriseCustomizedRoles(ctx context.Context, enterprise string) ([]*EnterpriseCustomizedRole, error)
- func (c *Client) ListEnterpriseIssueComments(ctx context.Context, enterprise string, number int, opts ListOptions) ([]*IssueComment, error)
- func (c *Client) ListEnterpriseIssueCustomFields(ctx context.Context, enterprise string) ([]*IssueCustomField, error)
- func (c *Client) ListEnterpriseIssueLabels(ctx context.Context, enterprise string, issueID int64) ([]*Label, error)
- func (c *Client) ListEnterpriseIssueStatuses(ctx context.Context, enterprise string) ([]*EnterpriseIssueStatus, error)
- func (c *Client) ListEnterpriseIssues(ctx context.Context, enterprise string, opts ListUserIssuesOptions) ([]*Issue, error)
- func (c *Client) ListEnterpriseLabels(ctx context.Context, enterprise string) ([]*EnterpriseLabel, error)
- func (c *Client) ListEnterpriseMembers(ctx context.Context, enterprise, role string, opts ListOptions) ([]*EnterpriseMember, error)
- func (c *Client) ListEnterpriseMilestoneRepos(ctx context.Context, enterprise string, milestoneID int64, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListEnterpriseMilestones(ctx context.Context, enterprise string, opts ListMilestonesOptions) ([]*EnterpriseMilestone, error)
- func (c *Client) ListEnterprisePullRequests(ctx context.Context, enterprise string, opts ListEnterprisePRsOptions) ([]*PullRequest, error)
- func (c *Client) ListFiles(ctx context.Context, owner, repo string) ([]*FileListEntry, error)
- func (c *Client) ListForks(ctx context.Context, owner, repo string, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListGitRefSubPaths(ctx context.Context, owner, repo, refPrefix string) ([]*GitReference, error)
- func (c *Client) ListGitReferences(ctx context.Context, owner, repo string, opts ListOptions) ([]*GitReference, error)
- func (c *Client) ListGitignoreTemplates(ctx context.Context) ([]string, error)
- func (c *Client) ListIssueBlockingIssues(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*Issue, error)
- func (c *Client) ListIssueCommentModifyHistory(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*ModifyHistoryEntry, error)
- func (c *Client) ListIssueCommentReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*Reaction, error)
- func (c *Client) ListIssueCommentUserReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*IssueUserReaction, error)
- func (c *Client) ListIssueComments(ctx context.Context, owner, repo string, number int) ([]*IssueComment, error)
- func (c *Client) ListIssueDependencies(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueDependency, error)
- func (c *Client) ListIssueLabels(ctx context.Context, owner, repo string) ([]*Label, error)
- func (c *Client) ListIssueModifyHistory(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*ModifyHistoryEntry, error)
- func (c *Client) ListIssueReactions(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*Reaction, error)
- func (c *Client) ListIssueRelatedBranches(ctx context.Context, owner, repo string, number int) ([]*IssueRelatedBranch, error)
- func (c *Client) ListIssueSubscribers(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueSubscriber, error)
- func (c *Client) ListIssueTemplates(ctx context.Context, owner, repo string) ([]*IssueTemplate, error)
- func (c *Client) ListIssueTimelineEvents(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueTimelineEvent, error)
- func (c *Client) ListIssueUserReactions(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueUserReaction, error)
- func (c *Client) ListIssues(ctx context.Context, owner, repo string, opts ListIssuesOptions) ([]*Issue, error)
- func (c *Client) ListKanbanBoardItems(ctx context.Context, org string, boardID int64, opts ListOptions) ([]*KanbanBoardItem, error)
- func (c *Client) ListKanbanBoards(ctx context.Context, org string, opts ListOptions) ([]*KanbanBoard, error)
- func (c *Client) ListLabelTemplates(ctx context.Context) ([]string, error)
- func (c *Client) ListLicenseTemplates(ctx context.Context) ([]*LicenseTemplate, error)
- func (c *Client) ListMilestones(ctx context.Context, owner, repo string) ([]*Milestone, error)
- func (c *Client) ListMilestonesWithOptions(ctx context.Context, owner, repo string, opts ListMilestonesOptions) ([]*Milestone, error)
- func (c *Client) ListNotifications(ctx context.Context) ([]*Notification, error)
- func (c *Client) ListNotificationsWithOptions(ctx context.Context, opts ListNotificationsOptions) ([]*NotificationThread, error)
- func (c *Client) ListOrgBlockedUsers(ctx context.Context, org string, opts ListOptions) ([]*User, error)
- func (c *Client) ListOrgCustomizedRoles(ctx context.Context, org string) ([]*OrgCustomizedRole, error)
- func (c *Client) ListOrgDiscussionCommentReplies(ctx context.Context, org string, number int, commentID int64, opts ListOptions) ([]*OrgDiscussionCommentReply, error)
- func (c *Client) ListOrgDiscussionComments(ctx context.Context, org string, number int, opts ListOptions) ([]*OrgDiscussionComment, error)
- func (c *Client) ListOrgDiscussions(ctx context.Context, org string, opts ListOptions) ([]*OrgDiscussion, error)
- func (c *Client) ListOrgFollowers(ctx context.Context, org string, opts ListOptions) ([]*OrgFollowers, error)
- func (c *Client) ListOrgIssues(ctx context.Context, org string, opts ListUserIssuesOptions) ([]*Issue, error)
- func (c *Client) ListOrgLabels(ctx context.Context, org string, opts ListOptions) ([]*OrgLabel, error)
- func (c *Client) ListOrgMembers(ctx context.Context, org, role string, opts ListOptions) ([]*OrgMember, error)
- func (c *Client) ListOrgPublicMembers(ctx context.Context, org string, opts ListOptions) ([]*User, error)
- func (c *Client) ListOrgPullRequests(ctx context.Context, org string, opts ListEnterprisePRsOptions) ([]*PullRequest, error)
- func (c *Client) ListOrgRepositories(ctx context.Context, org, repoType string, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListOrgRunnerGroups(ctx context.Context, org string, opts ListOptions) ([]*RunnerGroup, error)
- func (c *Client) ListOrgTeams(ctx context.Context, org string, opts ListOptions) ([]*Team, error)
- func (c *Client) ListOrgWebhooks(ctx context.Context, org string, opts ListOptions) ([]*OrgWebhook, error)
- func (c *Client) ListOrganizationMembers(ctx context.Context, org string) ([]*Member, error)
- func (c *Client) ListOrganizations(ctx context.Context) ([]*Organization, error)
- func (c *Client) ListOrganizationsWithOptions(ctx context.Context, admin bool, opts ListOptions) ([]*Organization, error)
- func (c *Client) ListPendingRepoInvitations(ctx context.Context, opts ListOptions) ([]*RepoInvitation, error)
- func (c *Client) ListProtectedTags(ctx context.Context, owner, repo string, opts ListOptions) ([]*ProtectedTag, error)
- func (c *Client) ListPullRequestAvailableReviewers(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*User, error)
- func (c *Client) ListPullRequestAvailableTesters(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*User, error)
- func (c *Client) ListPullRequestCommentModifyHistory(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*ModifyHistoryEntry, error)
- func (c *Client) ListPullRequestCommentReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*Reaction, error)
- func (c *Client) ListPullRequestCommentUserReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*IssueUserReaction, error)
- func (c *Client) ListPullRequestComments(ctx context.Context, owner, repo string, number int) ([]*PullRequestComment, error)
- func (c *Client) ListPullRequestCommits(ctx context.Context, owner, repo string, number int) ([]*Commit, error)
- func (c *Client) ListPullRequestFiles(ctx context.Context, owner, repo string, number int) ([]*PullRequestFile, error)
- func (c *Client) ListPullRequestFilesJSON(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*PullRequestFileChange, error)
- func (c *Client) ListPullRequestLabels(ctx context.Context, owner, repo string, number int) ([]*Label, error)
- func (c *Client) ListPullRequestMergeTemplates(ctx context.Context, owner, repo string) ([]*PRMergeTemplate, error)
- func (c *Client) ListPullRequestModifyHistory(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*ModifyHistoryEntry, error)
- func (c *Client) ListPullRequestReviewers(ctx context.Context, owner, repo string, number int) ([]*Reviewer, error)
- func (c *Client) ListPullRequestReviews(ctx context.Context, owner, repo string, number int) ([]*PullRequestReview, error)
- func (c *Client) ListPullRequestUserReactions(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueUserReaction, error)
- func (c *Client) ListPullRequests(ctx context.Context, owner, repo string, opts ListPullRequestsOptions) ([]*PullRequest, error)
- func (c *Client) ListPushRemoteMirrors(ctx context.Context, owner, repo string, opts ListOptions) ([]*RemoteMirror, error)
- func (c *Client) ListReleaseAssets(ctx context.Context, owner, repo string, releaseID int64, opts ListOptions) ([]*ReleaseAsset, error)
- func (c *Client) ListReleases(ctx context.Context, owner, repo string) ([]*Release, error)
- func (c *Client) ListRepoAllIssueComments(ctx context.Context, owner, repo string, opts ListOptions) ([]*IssueComment, error)
- func (c *Client) ListRepoAssignees(ctx context.Context, owner, repo string, opts ListOptions) ([]*User, error)
- func (c *Client) ListRepoBranchesPaginated(ctx context.Context, owner, repo string, opts ListOptions) ([]*RepoBranchInfo, error)
- func (c *Client) ListRepoCLAs(ctx context.Context, owner, repo string) ([]*RepoCLA, error)
- func (c *Client) ListRepoCommitComments(ctx context.Context, owner, repo string, opts ListOptions) ([]*CommitComment, error)
- func (c *Client) ListRepoEvents(ctx context.Context, owner, repo string, opts ListOptions) ([]*RepoEvent, error)
- func (c *Client) ListRepoHostRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
- func (c *Client) ListRepoK8SRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
- func (c *Client) ListRepoNotifications(ctx context.Context, owner, repo string, opts ListNotificationsOptions) ([]*NotificationThread, error)
- func (c *Client) ListRepoReviewers(ctx context.Context, owner, repo string, opts ListOptions) ([]*Reviewer, error)
- func (c *Client) ListRepoSharedHostRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
- func (c *Client) ListRepoSharedK8SRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
- func (c *Client) ListRepositories(ctx context.Context, opts ListRepositoriesOptions) ([]*Repository, error)
- func (c *Client) ListRepositoryContents(ctx context.Context, owner, repo, path, ref string) ([]*RepositoryContent, error)
- func (c *Client) ListRepositoryTopics(ctx context.Context, owner, repo string) ([]string, error)
- func (c *Client) ListRunnerGroupHostRunners(ctx context.Context, org string, groupID int64, opts ListOptions) ([]*ActionRunner, error)
- func (c *Client) ListRunnerGroupK8SRunners(ctx context.Context, org string, groupID int64, opts ListOptions) ([]*ActionRunner, error)
- func (c *Client) ListRunnerGroupRepos(ctx context.Context, org string, groupID int64, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListSSHKeys(ctx context.Context, opts ListOptions) ([]*SSHKey, error)
- func (c *Client) ListStargazers(ctx context.Context, owner, repo string, opts ListOptions) ([]*User, error)
- func (c *Client) ListStarredRepositories(ctx context.Context, opts ListStarredReposOptions) ([]*Repository, error)
- func (c *Client) ListTags(ctx context.Context, owner, repo string) ([]*Tag, error)
- func (c *Client) ListTagsWithOptions(ctx context.Context, owner, repo string, opts ListOptions) ([]*Tag, error)
- func (c *Client) ListTeamMembers(ctx context.Context, teamID int64, opts ListOptions) ([]*TeamMember, error)
- func (c *Client) ListTeamRepositories(ctx context.Context, teamID int64, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListUserFollowers(ctx context.Context, username string, opts ListOptions) ([]*User, error)
- func (c *Client) ListUserFollowing(ctx context.Context, username string, opts ListOptions) ([]*User, error)
- func (c *Client) ListUserIssues(ctx context.Context, opts ListUserIssuesOptions) ([]*Issue, error)
- func (c *Client) ListUserOrganizations(ctx context.Context, username string, opts ListOptions) ([]*Organization, error)
- func (c *Client) ListUserPullRequests(ctx context.Context, opts ListPullRequestsOptions) ([]*PullRequest, error)
- func (c *Client) ListUserRepositories(ctx context.Context, username string, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListUserWatchedRepositories(ctx context.Context, username string, opts ListOptions) ([]*Repository, error)
- func (c *Client) ListWatchers(ctx context.Context, owner, repo string, opts ListOptions) ([]*User, error)
- func (c *Client) ListWebhooks(ctx context.Context, owner, repo string) ([]*Webhook, error)
- func (c *Client) ListWikiPages(ctx context.Context, owner, repo string, opts ListOptions) ([]*WikiPage, error)
- func (c *Client) MarkNotificationThreadAsRead(ctx context.Context, threadID int64) error
- func (c *Client) MarkNotificationsAsRead(ctx context.Context, opts MarkNotificationsOptions) error
- func (c *Client) MarkRepoNotificationsAsRead(ctx context.Context, owner, repo string, opts MarkNotificationsOptions) error
- func (c *Client) MergePullRequest(ctx context.Context, owner, repo string, number int, ...) error
- func (c *Client) ParseIssueEvent(payload []byte) (*IssueWebhookEvent, error)
- func (c *Client) ParseNoteEvent(payload []byte) (*NoteWebhookEvent, error)
- func (c *Client) ParsePullRequestEvent(payload []byte) (*PullRequestWebhookEvent, error)
- func (c *Client) ParsePushEvent(payload []byte) (*PushEvent, error)
- func (c *Client) ParseTagPushEvent(payload []byte) (*TagPushEvent, error)
- func (c *Client) PublicizeOrgMembership(ctx context.Context, org, username string) error
- func (c *Client) RefreshPullRequestCommentPosition(ctx context.Context, owner, repo string, number int) error
- func (c *Client) RemoveAllIssueLabels(ctx context.Context, owner, repo string, number int) error
- func (c *Client) RemoveCollaborator(ctx context.Context, owner, repo, username string) error
- func (c *Client) RemoveFromKanbanBoard(ctx context.Context, org string, boardID, itemID int64) error
- func (c *Client) RemoveIssueAssignees(ctx context.Context, owner, repo string, number int, assignees []string) (*Issue, error)
- func (c *Client) RemoveIssueLabel(ctx context.Context, owner, repo string, number int, name string) error
- func (c *Client) RemoveOrgMember(ctx context.Context, org, username string) error
- func (c *Client) RemovePullRequestLabel(ctx context.Context, owner, repo string, number int, name string) error
- func (c *Client) RemovePullRequestReviewer(ctx context.Context, owner, repo string, number int, ...) error
- func (c *Client) RemoveTeamMember(ctx context.Context, teamID int64, username string) error
- func (c *Client) RemoveTeamRepository(ctx context.Context, teamID int64, org, repo string) error
- func (c *Client) RenderMarkdown(ctx context.Context, text, mode, context string) (string, error)
- func (c *Client) RenderMarkdownRaw(ctx context.Context, markdown string) (string, error)
- func (c *Client) ReopenIssue(ctx context.Context, owner, repo string, number int) (*Issue, error)
- func (c *Client) ReopenPullRequest(ctx context.Context, owner, repo string, number int) (*PullRequest, error)
- func (c *Client) ReplaceIssueLabels(ctx context.Context, owner, repo string, number int, labels []string) error
- func (c *Client) ReplacePullRequestLabels(ctx context.Context, owner, repo string, number int, labels []string) error
- func (c *Client) ReplyPullRequestComment(ctx context.Context, owner, repo string, number int, discussionID string, ...) (*PRDiscussionComment, error)
- func (c *Client) RequestPullRequestReviewers(ctx context.Context, owner, repo string, number int, ...) error
- func (c *Client) ResetPullRequestReviewStatus(ctx context.Context, owner, repo string, number int, resetAll bool) error
- func (c *Client) ResetPullRequestTestStatus(ctx context.Context, owner, repo string, number int, resetAll bool) error
- func (c *Client) ResolvePullRequestDiscussion(ctx context.Context, owner, repo string, number int, discussionID string, ...) error
- func (c *Client) RunActionWorkflow(ctx context.Context, owner, repo string, opts RunActionWorkflowOptions) error
- func (c *Client) SearchIssues(ctx context.Context, opts SearchIssuesOptions) ([]*SearchIssueResult, error)
- func (c *Client) SearchRepositories(ctx context.Context, opts SearchRepositoriesOptions) ([]*SearchRepositoryResult, error)
- func (c *Client) SearchUsers(ctx context.Context, opts SearchUsersOptions) ([]*SearchUserResult, error)
- func (c *Client) SetAuthStyle(style AuthStyle)
- func (c *Client) SetHTTPClient(client *http.Client)
- func (c *Client) SetIssueRelatedBranches(ctx context.Context, owner, repo string, number int, branches []string) error
- func (c *Client) SetModuleSetting(ctx context.Context, owner, repo string, setting ModuleSetting) error
- func (c *Client) SetRepoVisibility(ctx context.Context, owner, repo string, private bool) (*Repository, error)
- func (c *Client) StarRepository(ctx context.Context, owner, repo string) error
- func (c *Client) SubmitPullRequestReview(ctx context.Context, owner, repo string, number int, reviewID int64, ...) (*PullRequestReview, error)
- func (c *Client) SubscribeToIssue(ctx context.Context, owner, repo string, number int, username string) error
- func (c *Client) SyncForkRepository(ctx context.Context, owner, repo string) error
- func (c *Client) TestWebhook(ctx context.Context, owner, repo string, hookID int64) error
- func (c *Client) TransferRepository(ctx context.Context, owner, repo string, opts TransferRepoOptions) error
- func (c *Client) TransferToOrg(ctx context.Context, org, repo, newOwner string) error
- func (c *Client) UnassignPullRequestApprovalReviewers(ctx context.Context, owner, repo string, number int, reviewers string) error
- func (c *Client) UnassignPullRequestReviewers(ctx context.Context, owner, repo string, number int, assignees string) error
- func (c *Client) UnassignPullRequestTesters(ctx context.Context, owner, repo string, number int, testers string) error
- func (c *Client) UnblockOrgUser(ctx context.Context, org, username string) error
- func (c *Client) UnfollowUser(ctx context.Context, username string) error
- func (c *Client) UnlinkPullRequestIssue(ctx context.Context, owner, repo string, number int, issueNumber int) error
- func (c *Client) UnstarRepository(ctx context.Context, owner, repo string) error
- func (c *Client) UnsubscribeFromIssue(ctx context.Context, owner, repo string, number int, username string) error
- func (c *Client) UpdateBranchProtection(ctx context.Context, owner, repo, wildcard string, ...) error
- func (c *Client) UpdateCommitComment(ctx context.Context, owner, repo string, commentID int64, ...) (*CommitComment, error)
- func (c *Client) UpdateCurrentUser(ctx context.Context, opts UpdateCurrentUserOptions) (*User, error)
- func (c *Client) UpdateEnterpriseLabel(ctx context.Context, enterprise string, labelID int64, ...) (*EnterpriseLabel, error)
- func (c *Client) UpdateEnterpriseMember(ctx context.Context, enterprise, username string, ...) (*EnterpriseMember, error)
- func (c *Client) UpdateEnterpriseMilestone(ctx context.Context, enterprise string, milestoneID int64, ...) (*EnterpriseMilestone, error)
- func (c *Client) UpdateFile(ctx context.Context, owner, repo, path string, opts UpdateFileOptions) (*FileResult, error)
- func (c *Client) UpdateGitReference(ctx context.Context, owner, repo, ref string, opts UpdateReferenceOptions) (*GitReference, error)
- func (c *Client) UpdateIssue(ctx context.Context, owner, repo string, number int, opts UpdateIssueOptions) (*Issue, error)
- func (c *Client) UpdateIssueComment(ctx context.Context, owner, repo string, commentID int64, body string) (*IssueComment, error)
- func (c *Client) UpdateIssueKanbanValues(ctx context.Context, owner, repo string, number int, values []KanbanValue) error
- func (c *Client) UpdateIssueLabel(ctx context.Context, owner, repo, originalName string, opts UpdateLabelOptions) (*Label, error)
- func (c *Client) UpdateKanbanBoardItem(ctx context.Context, org string, boardID, itemID int64, ...) (*KanbanBoardItem, error)
- func (c *Client) UpdateKanbanBoardStatus(ctx context.Context, org string, boardID int64, ...) error
- func (c *Client) UpdateMilestone(ctx context.Context, owner, repo string, number int, ...) (*Milestone, error)
- func (c *Client) UpdateOrgLabel(ctx context.Context, org string, labelID int64, opts UpdateOrgLabelOptions) (*OrgLabel, error)
- func (c *Client) UpdateOrgRepoStatus(ctx context.Context, org, repo, status string) error
- func (c *Client) UpdateOrgWebhook(ctx context.Context, org string, hookID int64, opts UpdateOrgWebhookOptions) (*OrgWebhook, error)
- func (c *Client) UpdateOrganization(ctx context.Context, org string, opts UpdateOrgOptions) (*Organization, error)
- func (c *Client) UpdatePRSettings(ctx context.Context, owner, repo string, settings *PRSettings) error
- func (c *Client) UpdateProtectedTag(ctx context.Context, owner, repo, tag string, opts UpdateProtectedTagOptions) (*ProtectedTag, error)
- func (c *Client) UpdatePullRequest(ctx context.Context, owner, repo string, number int, ...) (*PullRequest, error)
- func (c *Client) UpdatePullRequestComment(ctx context.Context, owner, repo string, commentID string, body string) (*PullRequestComment, error)
- func (c *Client) UpdatePushConfig(ctx context.Context, owner, repo string, config *PushConfig) error
- func (c *Client) UpdateRelease(ctx context.Context, owner, repo string, releaseID int64, ...) (*Release, error)
- func (c *Client) UpdateRepoMember(ctx context.Context, owner, repo, username string, opts UpdateMemberOptions) error
- func (c *Client) UpdateRepoSettings(ctx context.Context, owner, repo string, opts *RepoSettings) (*RepoSettings, error)
- func (c *Client) UpdateRepository(ctx context.Context, owner, repo string, opts UpdateRepositoryOptions) (*Repository, error)
- func (c *Client) UpdateRepositoryTopics(ctx context.Context, owner, repo string, topics []string) ([]string, error)
- func (c *Client) UpdateReviewerConfig(ctx context.Context, owner, repo string, config ReviewerConfig) error
- func (c *Client) UpdateTeam(ctx context.Context, teamID int64, opts UpdateTeamOptions) (*Team, error)
- func (c *Client) UpdateWebhook(ctx context.Context, owner, repo string, hookID int64, ...) (*Webhook, error)
- func (c *Client) UpdateWikiPage(ctx context.Context, owner, repo, pageName string, opts UpdateWikiPageOptions) (*WikiPage, error)
- func (c *Client) UploadFile(ctx context.Context, owner, repo string, filePath string) (*FileUploadResult, error)
- func (c *Client) UploadImage(ctx context.Context, owner, repo string, filePath string) (*FileUploadResult, error)
- func (c *Client) ValidateWorkflowYAML(ctx context.Context, owner, repo string, yamlContent string) error
- type CodeFrequencyEntry
- type Collaborator
- type CollaboratorPermission
- type CombinedStatus
- type Commit
- type CommitActivity
- type CommitAuthor
- type CommitComment
- type CommitComparison
- type CommitStatus
- type Contributor
- type ContributorStatistic
- type CreateAnnotatedTagOptions
- type CreateBranchOptions
- type CreateBranchProtectionOptions
- type CreateCommitCommentOptions
- type CreateCommitStatusOptions
- type CreateDeployKeyOptions
- type CreateEnterpriseLabelOptions
- type CreateEnterpriseMilestoneOptions
- type CreateFileOptions
- type CreateIssueOptions
- type CreateMilestoneOptions
- type CreateOrgLabelOptions
- type CreateOrgOptions
- type CreateOrgRepoOptions
- type CreateOrgWebhookOptions
- type CreateProtectedTagOptions
- type CreatePullRequestInlineCommentOptions
- type CreatePullRequestOptions
- type CreateReactionOptions
- type CreateReferenceOptions
- type CreateReleaseOptions
- type CreateRepositoryOptions
- type CreateSSHKeyOptions
- type CreateTagOptions
- type CreateTeamOptions
- type CreateWebhookOptions
- type CreateWikiPageOptions
- type CustomizedRole
- type DeleteFileOptions
- type DeployKey
- type Discussion
- type DiscussionComment
- type DiscussionCommentReply
- type DownloadStatistic
- type Email
- type EnterpriseCustomizedRole
- type EnterpriseIssueStatus
- type EnterpriseLabel
- type EnterpriseMember
- type EnterpriseMilestone
- type Error
- type ExtendedUser
- type FileListEntry
- type FileResult
- type FileUploadResult
- type FlexInt
- type FlexString
- type ForkSyncStatus
- type GitBlob
- type GitObject
- type GitReference
- type GitTree
- type GitTreeEntry
- type GitignoreTemplate
- type InviteMemberOptions
- type Issue
- type IssueAssigneeResult
- type IssueComment
- type IssueCustomField
- type IssueDependency
- type IssueExtendSetting
- type IssueOperateLog
- type IssueRelatedBranch
- type IssueState
- type IssueSubscriber
- type IssueTemplate
- type IssueTimelineEvent
- type IssueUserReaction
- type IssueWebhookEvent
- type KanbanBoard
- type KanbanBoardItem
- type KanbanBoardStatus
- type KanbanValue
- type Label
- type Language
- type LicenseTemplate
- type ListActionRunsOptions
- type ListBranchProtectionOptions
- type ListCommitsOptions
- type ListEnterprisePRsOptions
- type ListIssuesOptions
- type ListMilestonesOptions
- type ListNotificationsOptions
- type ListOptions
- type ListPullRequestsOptions
- type ListRepositoriesOptions
- type ListStarredReposOptions
- type ListUserIssuesOptions
- type MarkNotificationsOptions
- type Member
- type MergePullRequestOptions
- type Milestone
- type ModifyHistoryEntry
- type ModuleSetting
- type Namespace
- type NoteWebhookEvent
- type Notification
- type NotificationSubject
- type NotificationThread
- type NullableTime
- type OAuthClient
- func (o *OAuthClient) AuthorizeURL(scope, state string) string
- func (o *OAuthClient) ExchangeToken(ctx context.Context, code string) (*OAuthToken, error)
- func (o *OAuthClient) RefreshToken(ctx context.Context, refreshToken string) (*OAuthToken, error)
- func (o *OAuthClient) SetBaseURL(baseURL string)
- type OAuthToken
- type OrgCustomizedRole
- type OrgDiscussion
- type OrgDiscussionComment
- type OrgDiscussionCommentReply
- type OrgEnterprise
- type OrgFollowers
- type OrgLabel
- type OrgMember
- type OrgMemberDetail
- type OrgWebhook
- type Organization
- type PRDiscussionComment
- type PRMergeTemplate
- type PROperateLog
- type PRSettings
- type ParticipationStats
- type ProtectedTag
- type PullRequest
- type PullRequestBranch
- type PullRequestComment
- type PullRequestDiff
- type PullRequestFile
- type PullRequestFileChange
- type PullRequestReview
- type PullRequestReviewRequest
- type PullRequestState
- type PullRequestWebhookEvent
- type PunchCardEntry
- type PushConfig
- type PushEvent
- type RateLimit
- type Reaction
- type Release
- type ReleaseAsset
- type ReleaseUploadURL
- type RemoteMirror
- type RepoBranchInfo
- type RepoCLA
- type RepoEvent
- type RepoInvitation
- type RepoLicense
- type RepoSettings
- type RepoStats
- type Repository
- type RepositoryContent
- type RepositoryTopics
- type Reviewer
- type ReviewerConfig
- type RunActionWorkflowOptions
- type RunnerGroup
- type SSHKey
- type SearchIssueResult
- type SearchIssuesOptions
- type SearchOptions
- type SearchRepositoriesOptions
- type SearchRepositoryResult
- type SearchResult
- type SearchUserResult
- type SearchUsersOptions
- type Star
- type Tag
- type TagPushEvent
- type TagWithRelease
- type Team
- type TeamMember
- type Timestamp
- type TransferRepoOptions
- type UpdateBranchProtectionOptions
- type UpdateCommitCommentOptions
- type UpdateCurrentUserOptions
- type UpdateEnterpriseLabelOptions
- type UpdateEnterpriseMemberOptions
- type UpdateEnterpriseMilestoneOptions
- type UpdateFileOptions
- type UpdateIssueOptions
- type UpdateKanbanBoardItemOptions
- type UpdateKanbanBoardStatusOptions
- type UpdateLabelOptions
- type UpdateMemberOptions
- type UpdateMilestoneOptions
- type UpdateOrgLabelOptions
- type UpdateOrgOptions
- type UpdateOrgWebhookOptions
- type UpdateProtectedTagOptions
- type UpdatePullRequestOptions
- type UpdateReferenceOptions
- type UpdateReleaseOptions
- type UpdateRepositoryOptions
- type UpdateTeamOptions
- type UpdateWebhookOptions
- type UpdateWikiPageOptions
- type User
- type UserEvent
- type UserEventsResponse
- type UserMembership
- type Webhook
- type WebhookConfig
- type WebhookEvent
- type WikiPage
Constants ¶
const ( ReactionPlusOne = "+1" ReactionMinusOne = "-1" ReactionLaugh = "laugh" ReactionConfused = "confused" ReactionHeart = "heart" ReactionHooray = "hooray" ReactionRocket = "rocket" ReactionEyes = "eyes" )
ReactionContent constants for reaction types.
const (
DefaultBaseURL = "https://api.gitcode.com/api/v5"
)
const (
DefaultOAuthBaseURL = "https://gitcode.com"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActionArtifact ¶ added in v0.5.0
type ActionArtifact struct {
ID int64 `json:"id"`
Name string `json:"name"`
Size int64 `json:"size"`
ArchiveURL string `json:"archive_download_url,omitempty"`
Expired bool `json:"expired"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
RunID int64 `json:"run_id,omitempty"`
}
ActionArtifact represents a workflow artifact.
type ActionJob ¶ added in v0.5.0
type ActionJob struct {
ID int64 `json:"id"`
RunID int64 `json:"run_id"`
Name string `json:"name"`
Status string `json:"status"`
Conclusion string `json:"conclusion,omitempty"`
StartedAt time.Time `json:"started_at"`
CompletedAt *time.Time `json:"completed_at,omitempty"`
RunnerID int64 `json:"runner_id,omitempty"`
RunnerName string `json:"runner_name,omitempty"`
Steps []*ActionStep `json:"steps,omitempty"`
}
ActionJob represents a workflow job.
type ActionRun ¶ added in v0.5.0
type ActionRun struct {
ID int64 `json:"id"`
Name string `json:"name"`
WorkflowID int64 `json:"workflow_id"`
Status string `json:"status"`
Conclusion string `json:"conclusion,omitempty"`
Branch string `json:"head_branch"`
SHA string `json:"head_sha"`
Event string `json:"event"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
RunStartedAt time.Time `json:"run_started_at,omitempty"`
HTMLURL string `json:"html_url,omitempty"`
}
ActionRun represents a workflow run.
type ActionRunner ¶ added in v0.5.0
type ActionRunner struct {
ID int64 `json:"id"`
Name string `json:"name"`
Status string `json:"status"`
OS string `json:"os,omitempty"`
Arch string `json:"arch,omitempty"`
Labels []string `json:"labels,omitempty"`
RunnerType string `json:"runner_type,omitempty"`
}
ActionRunner represents a CI/CD runner.
type ActionStep ¶ added in v0.5.0
type ActionStep struct {
Name string `json:"name"`
Status string `json:"status"`
Conclusion string `json:"conclusion,omitempty"`
Number int `json:"number"`
StartedAt time.Time `json:"started_at,omitempty"`
CompletedAt *time.Time `json:"completed_at,omitempty"`
}
ActionStep represents a step in a workflow job.
type ActionWorkflow ¶ added in v0.5.0
type ActionWorkflow struct {
ID int64 `json:"id"`
Name string `json:"name"`
Path string `json:"path"`
State string `json:"state"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
ActionWorkflow represents a CI/CD workflow.
type AddCollaboratorOptions ¶ added in v0.4.0
type AddCollaboratorOptions struct {
Permission string `json:"permission,omitempty"` // pull, push, admin
}
AddCollaboratorOptions specifies options for adding a collaborator.
type AddToKanbanBoardOptions ¶ added in v0.5.0
type AddToKanbanBoardOptions struct {
IssueNumber int `json:"issue_number,omitempty"`
PRNumber int `json:"pr_number,omitempty"`
Status string `json:"status,omitempty"`
}
AddToKanbanBoardOptions specifies options for adding an item to a kanban board.
type AnnotatedTag ¶ added in v0.4.0
type AnnotatedTag struct {
SHA string `json:"sha"`
URL string `json:"url"`
Tag string `json:"tag"`
Message string `json:"message"`
Object *GitObject `json:"object"`
Tagger *CommitAuthor `json:"tagger"`
}
AnnotatedTag represents an annotated git tag.
type ArchiveStatus ¶
type ArchiveStatus struct {
Archived bool `json:"archived"`
}
type Branch ¶
type Branch struct {
Name string `json:"name"`
Commit *BranchCommitDetail `json:"commit"`
DefaultBranch bool `json:"default_branch,omitempty"`
Protected bool `json:"protected"`
}
type BranchCommitDetail ¶
type BranchCommitDetail struct {
SHA string `json:"sha"`
URL string `json:"url"`
Commit *struct {
Author *CommitAuthor `json:"author"`
Committer *CommitAuthor `json:"committer"`
Message string `json:"message"`
} `json:"commit"`
}
type BranchProtection ¶
type BranchProtectionRule ¶
type BranchProtectionRule struct {
ID int64 `json:"id"`
RepositoryID int64 `json:"repository_id"`
Name string `json:"name"`
RequiredStatusChecks bool `json:"required_status_checks"`
RequiredApprovingReviews int `json:"required_approving_reviews"`
AllowForcePushes bool `json:"allow_force_pushes"`
AllowDeletions bool `json:"allow_deletions"`
}
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewClientFromOAuthToken ¶
func NewClientFromOAuthToken(token *OAuthToken) *Client
func NewClientWithBaseURL ¶
func (*Client) AcceptRepoInvitation ¶ added in v0.4.0
AcceptRepoInvitation accepts a repository invitation.
PATCH /user/repository_invitations/{id}
func (*Client) AddCollaborator ¶ added in v0.4.0
func (c *Client) AddCollaborator(ctx context.Context, owner, repo, username string, opts *AddCollaboratorOptions) error
AddCollaborator adds a collaborator to a repository.
PUT /repos/{owner}/{repo}/collaborators/{username}
func (*Client) AddIssueAssignees ¶ added in v0.4.0
func (c *Client) AddIssueAssignees(ctx context.Context, owner, repo string, number int, assignees []string) (*Issue, error)
AddIssueAssignees adds assignees to an issue.
POST /repos/{owner}/{repo}/issues/{index}/assignees
func (*Client) AddIssueLabels ¶
func (*Client) AddPullRequestLabels ¶
func (*Client) AddRepositoryTopic ¶ added in v0.4.0
AddRepositoryTopic adds a single topic to a repository.
PUT /repos/{owner}/{repo}/topics/{topic}
func (*Client) AddTeamMember ¶ added in v0.4.0
AddTeamMember adds a member to a team.
PUT /teams/{team_id}/members/{username}
func (*Client) AddTeamRepository ¶ added in v0.4.0
AddTeamRepository adds a repository to a team.
PUT /teams/{team_id}/repos/{org}/{repo}
func (*Client) AddToKanbanBoard ¶ added in v0.5.0
func (c *Client) AddToKanbanBoard(ctx context.Context, org string, boardID int64, opts AddToKanbanBoardOptions) (*KanbanBoardItem, error)
AddToKanbanBoard adds an issue or pull request to a kanban board.
POST /orgs/{org}/kanban/boards/{id}/items
func (*Client) ArchiveRepository ¶
func (*Client) AssignPullRequestApprovalReviewers ¶ added in v0.4.0
func (c *Client) AssignPullRequestApprovalReviewers(ctx context.Context, owner, repo string, number int, reviewers string) error
AssignPullRequestApprovalReviewers assigns users as approval reviewers for a pull request.
POST /repos/{owner}/{repo}/pulls/{number}/approval-reviewers
func (*Client) AssignPullRequestReviewers ¶
func (*Client) AssignPullRequestTesters ¶
func (*Client) BlockOrgUser ¶ added in v0.4.0
BlockOrgUser blocks a user from an organization.
PUT /orgs/{org}/blocks/{username}
func (*Client) CloseIssue ¶
func (*Client) ClosePullRequest ¶
func (*Client) CompareCommits ¶
func (*Client) ConcealOrgMembership ¶ added in v0.4.0
ConcealOrgMembership makes the authenticated user's membership private.
DELETE /orgs/{org}/public_members/{username}
func (*Client) ConfigureRepoCLA ¶ added in v0.4.0
func (c *Client) ConfigureRepoCLA(ctx context.Context, owner, repo string, opts *RepoCLA) (*RepoCLA, error)
ConfigureRepoCLA configures the CLA for a repository.
PUT /repos/{owner}/{repo}/clas
func (*Client) CreateAnnotatedTag ¶ added in v0.4.0
func (c *Client) CreateAnnotatedTag(ctx context.Context, owner, repo string, opts CreateAnnotatedTagOptions) (*AnnotatedTag, error)
CreateAnnotatedTag creates a new annotated tag.
POST /repos/{owner}/{repo}/git/tags
func (*Client) CreateBranch ¶
func (*Client) CreateBranchProtection ¶
func (c *Client) CreateBranchProtection(ctx context.Context, owner, repo string, opts CreateBranchProtectionOptions) (*BranchProtectionRule, error)
func (*Client) CreateCommitComment ¶ added in v0.4.0
func (c *Client) CreateCommitComment(ctx context.Context, owner, repo, sha string, opts CreateCommitCommentOptions) (*CommitComment, error)
CreateCommitComment creates a new commit comment.
POST /repos/{owner}/{repo}/commits/{sha}/comments
func (*Client) CreateCommitStatus ¶ added in v0.4.0
func (c *Client) CreateCommitStatus(ctx context.Context, owner, repo, sha string, opts CreateCommitStatusOptions) (*CommitStatus, error)
CreateCommitStatus creates a commit status.
POST /repos/{owner}/{repo}/statuses/{sha}
func (*Client) CreateDeployKey ¶ added in v0.4.0
func (c *Client) CreateDeployKey(ctx context.Context, owner, repo string, opts CreateDeployKeyOptions) (*DeployKey, error)
CreateDeployKey creates a new deploy key for a repository.
POST /repos/{owner}/{repo}/keys
func (*Client) CreateEnterpriseLabel ¶ added in v0.5.0
func (c *Client) CreateEnterpriseLabel(ctx context.Context, enterprise string, opts CreateEnterpriseLabelOptions) (*EnterpriseLabel, error)
CreateEnterpriseLabel creates a new enterprise label.
POST /enterprises/{enterprise}/labels
func (*Client) CreateEnterpriseMilestone ¶ added in v0.5.0
func (c *Client) CreateEnterpriseMilestone(ctx context.Context, enterprise string, opts CreateEnterpriseMilestoneOptions) (*EnterpriseMilestone, error)
CreateEnterpriseMilestone creates a new enterprise milestone.
POST /enterprises/{enterprise}/milestones
func (*Client) CreateFile ¶
func (c *Client) CreateFile(ctx context.Context, owner, repo, path string, opts CreateFileOptions) (*FileResult, error)
func (*Client) CreateGitReference ¶ added in v0.4.0
func (c *Client) CreateGitReference(ctx context.Context, owner, repo string, opts CreateReferenceOptions) (*GitReference, error)
CreateGitReference creates a new reference.
POST /repos/{owner}/{repo}/git/refs
func (*Client) CreateIssue ¶
func (*Client) CreateIssueComment ¶
func (*Client) CreateIssueCommentReaction ¶ added in v0.4.0
func (c *Client) CreateIssueCommentReaction(ctx context.Context, owner, repo string, commentID int64, content string) (*Reaction, error)
CreateIssueCommentReaction adds a reaction to an issue comment.
POST /repos/{owner}/{repo}/issues/comments/{id}/reactions
func (*Client) CreateIssueDependency ¶ added in v0.4.0
func (c *Client) CreateIssueDependency(ctx context.Context, owner, repo string, number int, dependsOnNumber int) (*IssueDependency, error)
CreateIssueDependency creates a dependency between two issues.
POST /repos/{owner}/{repo}/issues/{index}/dependencies
func (*Client) CreateIssueLabel ¶
func (*Client) CreateIssueReaction ¶ added in v0.4.0
func (c *Client) CreateIssueReaction(ctx context.Context, owner, repo string, number int, content string) (*Reaction, error)
CreateIssueReaction adds a reaction to an issue.
POST /repos/{owner}/{repo}/issues/{index}/reactions
func (*Client) CreateMilestone ¶
func (*Client) CreateMilestoneWithOptions ¶
func (*Client) CreateOrgLabel ¶ added in v0.4.0
func (c *Client) CreateOrgLabel(ctx context.Context, org string, opts CreateOrgLabelOptions) (*OrgLabel, error)
CreateOrgLabel creates a new organization label.
POST /orgs/{org}/labels
func (*Client) CreateOrgRepository ¶
func (c *Client) CreateOrgRepository(ctx context.Context, org string, opts CreateOrgRepoOptions) (*Repository, error)
func (*Client) CreateOrgWebhook ¶ added in v0.4.0
func (c *Client) CreateOrgWebhook(ctx context.Context, org string, opts CreateOrgWebhookOptions) (*OrgWebhook, error)
CreateOrgWebhook creates a new organization webhook.
POST /orgs/{org}/hooks
func (*Client) CreateOrganization ¶ added in v0.4.0
func (c *Client) CreateOrganization(ctx context.Context, opts CreateOrgOptions) (*Organization, error)
CreateOrganization creates a new organization.
POST /orgs
func (*Client) CreateProtectedTag ¶ added in v0.5.0
func (c *Client) CreateProtectedTag(ctx context.Context, owner, repo string, opts CreateProtectedTagOptions) (*ProtectedTag, error)
CreateProtectedTag creates a new protected tag rule.
POST /repos/{owner}/{repo}/protected-tags
func (*Client) CreatePullRequest ¶
func (c *Client) CreatePullRequest(ctx context.Context, owner, repo string, opts CreatePullRequestOptions) (*PullRequest, error)
func (*Client) CreatePullRequestComment ¶
func (*Client) CreatePullRequestCommentReaction ¶ added in v0.4.0
func (c *Client) CreatePullRequestCommentReaction(ctx context.Context, owner, repo string, commentID int64, content string) (*Reaction, error)
CreatePullRequestCommentReaction adds a reaction to a pull request comment.
POST /repos/{owner}/{repo}/pulls/comments/{id}/reactions
func (*Client) CreatePullRequestInlineComment ¶
func (c *Client) CreatePullRequestInlineComment(ctx context.Context, owner, repo string, number int, opts CreatePullRequestInlineCommentOptions) (*PullRequestComment, error)
func (*Client) CreatePullRequestReview ¶
func (*Client) CreateRelease ¶
func (*Client) CreateRepository ¶
func (c *Client) CreateRepository(ctx context.Context, opts CreateRepositoryOptions) (*Repository, error)
func (*Client) CreateSSHKey ¶
func (*Client) CreateTag ¶ added in v0.4.0
func (c *Client) CreateTag(ctx context.Context, owner, repo string, opts CreateTagOptions) (*Tag, error)
CreateTag creates a new lightweight tag.
POST /repos/{owner}/{repo}/tags
func (*Client) CreateTeam ¶ added in v0.4.0
CreateTeam creates a new team in an organization.
POST /orgs/{org}/teams
func (*Client) CreateWebhook ¶
func (*Client) CreateWikiPage ¶ added in v0.4.0
func (c *Client) CreateWikiPage(ctx context.Context, owner, repo string, opts CreateWikiPageOptions) (*WikiPage, error)
CreateWikiPage creates a new wiki page.
POST /repos/{owner}/{repo}/wiki/new
func (*Client) DeclineRepoInvitation ¶ added in v0.4.0
DeclineRepoInvitation declines a repository invitation.
DELETE /user/repository_invitations/{id}
func (*Client) DeleteActionArtifact ¶ added in v0.5.0
func (c *Client) DeleteActionArtifact(ctx context.Context, owner, repo string, artifactID int64) error
DeleteActionArtifact deletes an artifact.
DELETE /repos/{owner}/{repo}/actions/artifacts/{id}
func (*Client) DeleteBranch ¶
func (*Client) DeleteBranchProtection ¶
func (*Client) DeleteCommitComment ¶ added in v0.4.0
func (c *Client) DeleteCommitComment(ctx context.Context, owner, repo string, commentID int64) error
DeleteCommitComment deletes a commit comment.
DELETE /repos/{owner}/{repo}/comments/{id}
func (*Client) DeleteDeployKey ¶ added in v0.4.0
DeleteDeployKey deletes a deploy key.
DELETE /repos/{owner}/{repo}/keys/{id}
func (*Client) DeleteEnterpriseLabel ¶ added in v0.5.0
DeleteEnterpriseLabel deletes an enterprise label.
DELETE /enterprises/{enterprise}/labels/{id}
func (*Client) DeleteEnterpriseMember ¶ added in v0.5.0
DeleteEnterpriseMember removes a member from an enterprise.
DELETE /enterprises/{enterprise}/members/{username}
func (*Client) DeleteEnterpriseMilestone ¶ added in v0.5.0
func (c *Client) DeleteEnterpriseMilestone(ctx context.Context, enterprise string, milestoneID int64) error
DeleteEnterpriseMilestone deletes an enterprise milestone.
DELETE /enterprises/{enterprise}/milestones/{id}
func (*Client) DeleteFile ¶
func (c *Client) DeleteFile(ctx context.Context, owner, repo, path string, opts DeleteFileOptions) (*FileResult, error)
func (*Client) DeleteGitReference ¶ added in v0.4.0
DeleteGitReference deletes a reference.
DELETE /repos/{owner}/{repo}/git/refs/{ref}
func (*Client) DeleteIssueComment ¶
func (*Client) DeleteIssueCommentReaction ¶ added in v0.4.0
func (c *Client) DeleteIssueCommentReaction(ctx context.Context, owner, repo string, commentID, reactionID int64) error
DeleteIssueCommentReaction removes a reaction from an issue comment.
DELETE /repos/{owner}/{repo}/issues/comments/{id}/reactions/{id}
func (*Client) DeleteIssueDependency ¶ added in v0.4.0
func (c *Client) DeleteIssueDependency(ctx context.Context, owner, repo string, number int, dependencyNumber int) error
DeleteIssueDependency removes a dependency between two issues.
DELETE /repos/{owner}/{repo}/issues/{index}/dependencies/{dependency}
func (*Client) DeleteIssueLabel ¶
func (*Client) DeleteIssueReaction ¶ added in v0.4.0
func (c *Client) DeleteIssueReaction(ctx context.Context, owner, repo string, number int, reactionID int64) error
DeleteIssueReaction removes a reaction from an issue.
DELETE /repos/{owner}/{repo}/issues/{index}/reactions/{id}
func (*Client) DeleteMilestone ¶
func (*Client) DeleteOrgLabel ¶ added in v0.4.0
DeleteOrgLabel deletes an organization label.
DELETE /orgs/{org}/labels/{id}
func (*Client) DeleteOrgWebhook ¶ added in v0.4.0
DeleteOrgWebhook deletes an organization webhook.
DELETE /orgs/{org}/hooks/{id}
func (*Client) DeleteOrganization ¶ added in v0.4.0
DeleteOrganization deletes an organization.
DELETE /orgs/{org}
func (*Client) DeleteProtectedTag ¶ added in v0.5.0
DeleteProtectedTag deletes a protected tag rule.
DELETE /repos/{owner}/{repo}/protected-tags/{tag}
func (*Client) DeletePullRequestComment ¶
func (*Client) DeletePullRequestCommentReaction ¶ added in v0.4.0
func (c *Client) DeletePullRequestCommentReaction(ctx context.Context, owner, repo string, commentID, reactionID int64) error
DeletePullRequestCommentReaction removes a reaction from a pull request comment.
DELETE /repos/{owner}/{repo}/pulls/comments/{id}/reactions/{id}
func (*Client) DeleteRelease ¶
func (*Client) DeleteReleaseAsset ¶ added in v0.4.0
DeleteReleaseAsset deletes a release asset.
DELETE /repos/{owner}/{repo}/releases/assets/{id}
func (*Client) DeleteReleaseByID ¶ added in v0.4.0
DeleteReleaseByID deletes a release by ID.
DELETE /repos/{owner}/{repo}/releases/{id}
func (*Client) DeleteRepository ¶
func (*Client) DeleteRepositoryTopic ¶ added in v0.4.0
DeleteRepositoryTopic removes a single topic from a repository.
DELETE /repos/{owner}/{repo}/topics/{topic}
func (*Client) DeleteWebhook ¶
func (*Client) DeleteWikiPage ¶ added in v0.4.0
DeleteWikiPage deletes a wiki page.
DELETE /repos/{owner}/{repo}/wiki/page/{pageName}
func (*Client) DismissPullRequestReview ¶ added in v0.4.0
func (c *Client) DismissPullRequestReview(ctx context.Context, owner, repo string, number int, reviewID int64, message string) error
DismissPullRequestReview dismisses a pull request review.
PUT /repos/{owner}/{repo}/pulls/{index}/reviews/{id}/dismissals
func (*Client) DownloadActionArtifact ¶ added in v0.5.0
func (c *Client) DownloadActionArtifact(ctx context.Context, owner, repo string, artifactID int64) ([]byte, error)
DownloadActionArtifact downloads an artifact.
GET /repos/{owner}/{repo}/actions/artifacts/{id}/download
func (*Client) DownloadReleaseAsset ¶ added in v0.5.0
func (c *Client) DownloadReleaseAsset(ctx context.Context, owner, repo string, assetID int64) ([]byte, error)
DownloadReleaseAsset downloads a release asset by ID.
GET /repos/{owner}/{repo}/releases/assets/{id}
func (*Client) DownloadRepository ¶ added in v0.4.0
func (c *Client) DownloadRepository(ctx context.Context, owner, repo, format string) ([]byte, error)
DownloadRepository downloads a repository as a zip or tarball.
GET /repos/{owner}/{repo}/{format}
func (*Client) ExitOrganization ¶
func (*Client) FollowUser ¶ added in v0.4.0
FollowUser follows a user.
PUT /user/following/{username}
func (*Client) ForkRepository ¶
func (c *Client) ForkRepository(ctx context.Context, owner, repo string, opts *CreateRepositoryOptions) (*Repository, error)
func (*Client) GenerateRepositoryArchive ¶ added in v0.4.0
func (c *Client) GenerateRepositoryArchive(ctx context.Context, owner, repo, ref, format string) ([]byte, error)
GenerateRepositoryArchive generates a repository archive.
GET /repos/{owner}/{repo}/archive
func (*Client) GetActionArtifact ¶ added in v0.5.0
func (c *Client) GetActionArtifact(ctx context.Context, owner, repo string, artifactID int64) (*ActionArtifact, error)
GetActionArtifact gets a single artifact.
GET /repos/{owner}/{repo}/actions/artifacts/{id}
func (*Client) GetActionJob ¶ added in v0.5.0
func (c *Client) GetActionJob(ctx context.Context, owner, repo string, jobID int64) (*ActionJob, error)
GetActionJob gets a single workflow job.
GET /repos/{owner}/{repo}/actions/jobs/{id}
func (*Client) GetActionJobLogs ¶ added in v0.5.0
func (c *Client) GetActionJobLogs(ctx context.Context, owner, repo string, jobID int64) ([]byte, error)
GetActionJobLogs gets the logs for a workflow job.
GET /repos/{owner}/{repo}/actions/jobs/{id}/logs
func (*Client) GetActionJobStepLogs ¶ added in v0.5.0
func (c *Client) GetActionJobStepLogs(ctx context.Context, owner, repo string, jobID int64) ([]byte, error)
GetActionJobStepLogs gets the step-level logs for a workflow job.
GET /repos/{owner}/{repo}/actions/jobs/{id}/logs/step
func (*Client) GetActionRun ¶ added in v0.5.0
func (c *Client) GetActionRun(ctx context.Context, owner, repo string, runID int64) (*ActionRun, error)
GetActionRun gets a single workflow run.
GET /repos/{owner}/{repo}/actions/runs/{id}
func (*Client) GetAnnotatedTag ¶ added in v0.4.0
func (c *Client) GetAnnotatedTag(ctx context.Context, owner, repo, sha string) (*AnnotatedTag, error)
GetAnnotatedTag gets an annotated tag by SHA.
GET /repos/{owner}/{repo}/git/tags/{sha}
func (*Client) GetArchiveStatus ¶
func (*Client) GetCollaboratorPermission ¶ added in v0.4.0
func (c *Client) GetCollaboratorPermission(ctx context.Context, owner, repo, username string) (*CollaboratorPermission, error)
GetCollaboratorPermission gets the permission of a collaborator for a repository.
GET /repos/{owner}/{repo}/collaborators/{username}/permission
func (*Client) GetCombinedStatus ¶ added in v0.4.0
func (c *Client) GetCombinedStatus(ctx context.Context, owner, repo, sha string) (*CombinedStatus, error)
GetCombinedStatus gets the combined status for a commit.
GET /repos/{owner}/{repo/commits/{sha}/status
func (*Client) GetCommitComment ¶ added in v0.4.0
func (c *Client) GetCommitComment(ctx context.Context, owner, repo string, commentID int64) (*CommitComment, error)
GetCommitComment gets a single commit comment.
GET /repos/{owner}/{repo}/comments/{id}
func (*Client) GetCommitDiff ¶ added in v0.5.0
GetCommitDiff returns the diff of a commit.
GET /repos/{owner}/{repo}/commits/{sha}.diff
func (*Client) GetCommitPatch ¶ added in v0.5.0
GetCommitPatch returns the patch of a commit.
GET /repos/{owner}/{repo}/commits/{sha}.patch
func (*Client) GetContributorStatistics ¶
func (*Client) GetCustomizedRoles ¶
func (*Client) GetDeployKey ¶ added in v0.4.0
func (c *Client) GetDeployKey(ctx context.Context, owner, repo string, keyID int64) (*DeployKey, error)
GetDeployKey gets a single deploy key.
GET /repos/{owner}/{repo}/keys/{id}
func (*Client) GetDiscussion ¶ added in v0.4.0
func (c *Client) GetDiscussion(ctx context.Context, owner, repo string, number int) (*Discussion, error)
GetDiscussion gets a single discussion by number.
GET /repos/{owner}/{repo}/discuss/{number}
func (*Client) GetDownloadStatistics ¶
func (*Client) GetEnterpriseIssue ¶
func (*Client) GetEnterpriseIssueLinkedPRs ¶
func (*Client) GetEnterpriseMember ¶
func (*Client) GetEnterpriseMilestone ¶ added in v0.5.0
func (c *Client) GetEnterpriseMilestone(ctx context.Context, enterprise string, milestoneID int64) (*EnterpriseMilestone, error)
GetEnterpriseMilestone gets a single enterprise milestone.
GET /enterprises/{enterprise}/milestones/{id}
func (*Client) GetExtendedUser ¶ added in v0.4.0
GetExtendedUser gets extended information about a user.
GET /users/{username}
func (*Client) GetForkSyncStatus ¶ added in v0.4.0
func (c *Client) GetForkSyncStatus(ctx context.Context, owner, repo string) (*ForkSyncStatus, error)
GetForkSyncStatus checks the sync status of a forked repository.
GET /repos/{owner}/{repo}/sync-repo
func (*Client) GetGitReference ¶ added in v0.4.0
func (c *Client) GetGitReference(ctx context.Context, owner, repo, ref string) (*GitReference, error)
GetGitReference gets a single reference.
GET /repos/{owner}/{repo}/git/refs/{ref}
func (*Client) GetGitignoreTemplate ¶ added in v0.4.0
GetGitignoreTemplate gets a gitignore template by name.
GET /gitignore/templates/{name}
func (*Client) GetIssueComment ¶
func (*Client) GetIssueLinkedPRs ¶
func (*Client) GetIssueOperateLogs ¶
func (*Client) GetIssueTemplate ¶ added in v0.4.0
func (c *Client) GetIssueTemplate(ctx context.Context, owner, repo, name string) (*IssueTemplate, error)
GetIssueTemplate gets a single issue template by name.
GET /repos/{owner}/{repo}/issue_templates/{name}
func (*Client) GetKanbanBoard ¶ added in v0.5.0
func (c *Client) GetKanbanBoard(ctx context.Context, org string, boardID int64) (*KanbanBoard, error)
GetKanbanBoard gets a single kanban board.
GET /orgs/{org}/kanban/boards/{id}
func (*Client) GetLabelTemplate ¶ added in v0.4.0
GetLabelTemplate gets a label template by name.
GET /label/templates/{name}
func (*Client) GetLanguages ¶
func (*Client) GetLatestRelease ¶ added in v0.5.0
GetLatestRelease gets the latest release for a repository.
GET /repos/{owner}/{repo}/releases/latest
func (*Client) GetLicenseTemplate ¶ added in v0.4.0
GetLicenseTemplate gets a license template by key.
GET /licenses/{name}
func (*Client) GetMilestone ¶
func (*Client) GetNamespace ¶
func (*Client) GetNotificationThread ¶ added in v0.4.0
func (c *Client) GetNotificationThread(ctx context.Context, threadID int64) (*NotificationThread, error)
GetNotificationThread gets a single notification thread.
GET /notifications/threads/{id}
func (*Client) GetOrgDiscussion ¶ added in v0.4.0
func (c *Client) GetOrgDiscussion(ctx context.Context, org string, number int) (*OrgDiscussion, error)
GetOrgDiscussion gets a single organization discussion by number.
GET /orgs/{org}/discuss/{number}
func (*Client) GetOrgEnterprise ¶ added in v0.5.0
GetOrgEnterprise gets the enterprise associated with an organization.
GET /orgs/{org}/enterprise
func (*Client) GetOrgInfo ¶
func (*Client) GetOrgIssueExtendSettings ¶
func (*Client) GetOrgLabel ¶ added in v0.4.0
GetOrgLabel gets a single organization label.
GET /orgs/{org}/labels/{id}
func (*Client) GetOrgMemberDetail ¶
func (*Client) GetOrgWebhook ¶ added in v0.4.0
GetOrgWebhook gets a single organization webhook.
GET /orgs/{org}/hooks/{id}
func (*Client) GetOrganization ¶
func (*Client) GetPRSettings ¶
func (*Client) GetProtectedTag ¶ added in v0.5.0
func (c *Client) GetProtectedTag(ctx context.Context, owner, repo, tag string) (*ProtectedTag, error)
GetProtectedTag gets a single protected tag rule.
GET /repos/{owner}/{repo}/protected-tags/{tag}
func (*Client) GetPullRequest ¶
func (*Client) GetPullRequestComment ¶
func (*Client) GetPullRequestDiff ¶ added in v0.4.0
func (c *Client) GetPullRequestDiff(ctx context.Context, owner, repo string, number int) ([]byte, error)
GetPullRequestDiff returns the diff of a pull request.
GET /repos/{owner}/{repo}/pulls/{index}.diff
func (*Client) GetPullRequestLinkedIssues ¶
func (*Client) GetPullRequestOperateLogs ¶
func (*Client) GetPullRequestPatch ¶ added in v0.4.0
func (c *Client) GetPullRequestPatch(ctx context.Context, owner, repo string, number int) ([]byte, error)
GetPullRequestPatch returns the patch of a pull request.
GET /repos/{owner}/{repo}/pulls/{index}.patch
func (*Client) GetPullRequestReview ¶ added in v0.4.0
func (c *Client) GetPullRequestReview(ctx context.Context, owner, repo string, number int, reviewID int64) (*PullRequestReview, error)
GetPullRequestReview gets a single pull request review.
GET /repos/{owner}/{repo}/pulls/{index}/reviews/{id}
func (*Client) GetPushConfig ¶
func (*Client) GetRateLimit ¶
func (*Client) GetRawFile ¶
func (*Client) GetRelease ¶ added in v0.4.0
func (c *Client) GetRelease(ctx context.Context, owner, repo string, releaseID int64) (*Release, error)
GetRelease gets a single release by ID.
GET /repos/{owner}/{repo}/releases/{id}
func (*Client) GetReleaseAsset ¶ added in v0.4.0
func (c *Client) GetReleaseAsset(ctx context.Context, owner, repo string, assetID int64) (*ReleaseAsset, error)
GetReleaseAsset gets a single release asset.
GET /repos/{owner}/{repo}/releases/assets/{id}
func (*Client) GetReleaseByTag ¶ added in v0.4.0
GetReleaseByTag gets a release by its tag name.
GET /repos/{owner}/{repo}/releases/tags/{tag}
func (*Client) GetReleaseUploadURL ¶ added in v0.5.0
func (c *Client) GetReleaseUploadURL(ctx context.Context, owner, repo string, releaseID int64, name, label string) (*ReleaseUploadURL, error)
GetReleaseUploadURL gets the upload URL for a release asset.
POST /repos/{owner}/{repo}/releases/{id}/assets/upload_url
func (*Client) GetRepoBranchDetail ¶ added in v0.4.0
func (c *Client) GetRepoBranchDetail(ctx context.Context, owner, repo, branch string) (*RepoBranchInfo, error)
GetRepoBranch gets a single branch with full details.
GET /repos/{owner}/{repo}/branches/{branch}
func (*Client) GetRepoCodeFrequency ¶ added in v0.4.0
func (c *Client) GetRepoCodeFrequency(ctx context.Context, owner, repo string) ([]CodeFrequencyEntry, error)
GetRepoCodeFrequency returns a weekly aggregate of the number of additions and deletions.
GET /repos/{owner}/{repo}/stats/code_frequency
func (*Client) GetRepoCommitActivity ¶ added in v0.4.0
func (c *Client) GetRepoCommitActivity(ctx context.Context, owner, repo string) ([]*CommitActivity, error)
GetRepoCommitActivity returns a weekly aggregate of the number of commits.
GET /repos/{owner}/{repo}/stats/commit_activity
func (*Client) GetRepoLicense ¶ added in v0.4.0
GetRepoLicense gets the license of a repository.
GET /repos/{owner}/{repo}/license
func (*Client) GetRepoParticipation ¶ added in v0.4.0
func (c *Client) GetRepoParticipation(ctx context.Context, owner, repo string) (*ParticipationStats, error)
GetRepoParticipation returns the total commit counts for the owner and all contributors.
GET /repos/{owner}/{repo}/stats/participation
func (*Client) GetRepoPunchCard ¶ added in v0.4.0
func (c *Client) GetRepoPunchCard(ctx context.Context, owner, repo string) ([]PunchCardEntry, error)
GetRepoPunchCard returns the number of commits per hour in each day.
GET /repos/{owner}/{repo}/stats/punch_card
func (*Client) GetRepoRemoteMirror ¶ added in v0.4.0
func (c *Client) GetRepoRemoteMirror(ctx context.Context, owner, repo string) (*RemoteMirror, error)
GetRepoRemoteMirror gets the remote mirror configuration of a repository.
GET /repos/{owner}/{repo}/repo-remote-mirror
func (*Client) GetRepoSettings ¶
func (*Client) GetRepoVisibility ¶ added in v0.4.0
GetRepoVisibility returns whether a repository is public or private.
GET /repos/{owner}/{repo}
func (*Client) GetRepository ¶
func (*Client) GetRepositoryArchive ¶ added in v0.4.0
func (c *Client) GetRepositoryArchive(ctx context.Context, owner, repo, archive string) ([]byte, error)
GetRepositoryArchive downloads a repository archive (tar.gz, zip, etc.).
GET /repos/{owner}/{repo}/archive/{archive}
func (*Client) GetRepositoryContent ¶
func (*Client) GetRunnerGroup ¶ added in v0.5.0
func (c *Client) GetRunnerGroup(ctx context.Context, org string, groupID int64) (*RunnerGroup, error)
GetRunnerGroup gets a single runner group.
GET /orgs/{org}/actions/runner-groups/{id}
func (*Client) GetTag ¶ added in v0.4.0
GetTag gets a single tag by name.
GET /repos/{owner}/{repo}/tags/{tag}
func (*Client) GetTeamMember ¶ added in v0.4.0
GetTeamMember gets a team member.
GET /teams/{team_id}/members/{username}
func (*Client) GetUserEvents ¶
func (*Client) GetUserMembership ¶
func (*Client) GetWebhook ¶
func (*Client) GetWikiPage ¶ added in v0.4.0
GetWikiPage gets a single wiki page by title.
GET /repos/{owner}/{repo}/wiki/page/{pageName}
func (*Client) HandlePullRequestReview ¶
func (*Client) HandlePullRequestTest ¶
func (*Client) InviteEnterpriseMember ¶ added in v0.5.0
func (c *Client) InviteEnterpriseMember(ctx context.Context, enterprise string, username string, opts InviteMemberOptions) error
InviteEnterpriseMember invites a user to an enterprise.
POST /enterprises/{enterprise}/members
func (*Client) InviteOrgMember ¶
func (*Client) IsCollaborator ¶ added in v0.4.0
IsCollaborator checks if a user is a collaborator of a repository.
GET /repos/{owner}/{repo}/collaborators/{username}
func (*Client) IsFollowing ¶ added in v0.4.0
IsFollowing checks if the authenticated user is following a user.
GET /user/following/{username}
func (*Client) IsOrgBlockedUser ¶ added in v0.4.0
IsOrgBlockedUser checks if a user is blocked by an organization.
GET /orgs/{org}/blocks/{username}
func (*Client) IsOrgPublicMember ¶ added in v0.4.0
IsOrgPublicMember checks if a user is a public member of an organization.
GET /orgs/{org}/public_members/{username}
func (*Client) IsPullRequestMerged ¶
func (*Client) IsRepoAssignee ¶ added in v0.4.0
IsRepoAssignee checks if a user is an assignee for issues in a repository.
GET /repos/{owner}/{repo}/assignees/{username}
func (*Client) IsRepositoryStarred ¶
func (*Client) LinkPullRequestIssue ¶ added in v0.4.0
func (c *Client) LinkPullRequestIssue(ctx context.Context, owner, repo string, number int, issueNumber int) error
LinkPullRequestIssue links an issue to a pull request.
POST /repos/{owner}/{repo}/pulls/{number}/linked-issues
func (*Client) ListActionArtifacts ¶ added in v0.5.0
func (c *Client) ListActionArtifacts(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionArtifact, error)
ListActionArtifacts lists all artifacts for a repository.
GET /repos/{owner}/{repo}/actions/artifacts
func (*Client) ListActionJobs ¶ added in v0.5.0
func (c *Client) ListActionJobs(ctx context.Context, owner, repo string, runID int64, opts ListOptions) ([]*ActionJob, error)
ListActionJobs lists all jobs for a workflow run.
GET /repos/{owner}/{repo}/actions/runs/{id}/jobs
func (*Client) ListActionRunArtifacts ¶ added in v0.5.0
func (c *Client) ListActionRunArtifacts(ctx context.Context, owner, repo string, runID int64, opts ListOptions) ([]*ActionArtifact, error)
ListActionRunArtifacts lists all artifacts for a specific workflow run.
GET /repos/{owner}/{repo}/actions/runs/{id}/artifacts
func (*Client) ListActionRuns ¶ added in v0.5.0
func (c *Client) ListActionRuns(ctx context.Context, owner, repo string, opts ListActionRunsOptions) ([]*ActionRun, error)
ListActionRuns lists all workflow runs for a repository.
GET /repos/{owner}/{repo}/actions/runs
func (*Client) ListActionWorkflows ¶ added in v0.5.0
func (c *Client) ListActionWorkflows(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionWorkflow, error)
ListActionWorkflows lists all workflows for a repository.
GET /repos/{owner}/{repo}/actions/workflows
func (*Client) ListBranchProtections ¶
func (*Client) ListBranches ¶
func (*Client) ListCollaborators ¶ added in v0.4.0
func (c *Client) ListCollaborators(ctx context.Context, owner, repo string, opts ListOptions) ([]*Collaborator, error)
ListCollaborators lists all collaborators of a repository.
GET /repos/{owner}/{repo}/collaborators
func (*Client) ListCommitComments ¶ added in v0.4.0
func (c *Client) ListCommitComments(ctx context.Context, owner, repo, sha string, opts ListOptions) ([]*CommitComment, error)
ListCommitComments lists all comments for a commit.
GET /repos/{owner}/{repo}/commits/{sha}/comments
func (*Client) ListCommitStatuses ¶ added in v0.4.0
func (c *Client) ListCommitStatuses(ctx context.Context, owner, repo, sha string, opts ListOptions) ([]*CommitStatus, error)
ListCommitStatuses lists all statuses for a commit.
GET /repos/{owner}/{repo}/statuses/{sha}
func (*Client) ListCommits ¶
func (*Client) ListContributors ¶
func (*Client) ListCurrentUserFollowers ¶ added in v0.4.0
ListCurrentUserFollowers lists the followers of the authenticated user.
GET /user/followers
func (*Client) ListCurrentUserFollowing ¶ added in v0.4.0
ListCurrentUserFollowing lists the users that the authenticated user is following.
GET /user/following
func (*Client) ListCurrentUserRepositories ¶ added in v0.4.0
func (c *Client) ListCurrentUserRepositories(ctx context.Context, opts ListRepositoriesOptions) ([]*Repository, error)
ListCurrentUserRepositories lists the authenticated user's repositories.
GET /user/repos
func (*Client) ListCurrentUserWatchedRepositories ¶ added in v0.4.0
func (c *Client) ListCurrentUserWatchedRepositories(ctx context.Context, opts ListOptions) ([]*Repository, error)
ListCurrentUserWatchedRepositories lists repositories watched by the authenticated user.
GET /user/subscriptions
func (*Client) ListDeployKeys ¶ added in v0.4.0
func (c *Client) ListDeployKeys(ctx context.Context, owner, repo string, opts ListOptions) ([]*DeployKey, error)
ListDeployKeys lists all deploy keys of a repository.
GET /repos/{owner}/{repo}/keys
func (*Client) ListDiscussionCommentReplies ¶ added in v0.4.0
func (c *Client) ListDiscussionCommentReplies(ctx context.Context, owner, repo string, number int, commentID int64, opts ListOptions) ([]*DiscussionCommentReply, error)
ListDiscussionCommentReplies lists all replies for a discussion comment.
GET /repos/{owner}/{repo}/discuss/{number}/comment/{comment_id}/reply
func (*Client) ListDiscussionComments ¶ added in v0.4.0
func (c *Client) ListDiscussionComments(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*DiscussionComment, error)
ListDiscussionComments lists all comments for a discussion.
GET /repos/{owner}/{repo}/discuss/{number}/comment
func (*Client) ListDiscussions ¶ added in v0.4.0
func (c *Client) ListDiscussions(ctx context.Context, owner, repo string, opts ListOptions) ([]*Discussion, error)
ListDiscussions lists all discussions for a repository.
GET /repos/{owner}/{repo}/discuss
func (*Client) ListEnterpriseCustomizedRoles ¶ added in v0.5.0
func (c *Client) ListEnterpriseCustomizedRoles(ctx context.Context, enterprise string) ([]*EnterpriseCustomizedRole, error)
ListEnterpriseCustomizedRoles lists all customized roles for an enterprise.
GET /enterprises/{enterprise}/customized-roles
func (*Client) ListEnterpriseIssueComments ¶
func (c *Client) ListEnterpriseIssueComments(ctx context.Context, enterprise string, number int, opts ListOptions) ([]*IssueComment, error)
func (*Client) ListEnterpriseIssueCustomFields ¶ added in v0.5.0
func (c *Client) ListEnterpriseIssueCustomFields(ctx context.Context, enterprise string) ([]*IssueCustomField, error)
ListEnterpriseIssueCustomFields lists all custom fields for enterprise issues.
GET /enterprises/{enterprise}/issue-custom-fields
func (*Client) ListEnterpriseIssueLabels ¶
func (*Client) ListEnterpriseIssueStatuses ¶ added in v0.4.0
func (c *Client) ListEnterpriseIssueStatuses(ctx context.Context, enterprise string) ([]*EnterpriseIssueStatus, error)
ListEnterpriseIssueStatuses lists all enterprise issue statuses.
GET /enterprises/{enterprise}/issue-statuses
func (*Client) ListEnterpriseIssues ¶
func (*Client) ListEnterpriseLabels ¶
func (*Client) ListEnterpriseMembers ¶
func (c *Client) ListEnterpriseMembers(ctx context.Context, enterprise, role string, opts ListOptions) ([]*EnterpriseMember, error)
func (*Client) ListEnterpriseMilestoneRepos ¶ added in v0.5.0
func (c *Client) ListEnterpriseMilestoneRepos(ctx context.Context, enterprise string, milestoneID int64, opts ListOptions) ([]*Repository, error)
ListEnterpriseMilestoneRepos lists repositories that can be associated with an enterprise milestone.
GET /enterprises/{enterprise}/milestones/{id}/repos
func (*Client) ListEnterpriseMilestones ¶ added in v0.5.0
func (c *Client) ListEnterpriseMilestones(ctx context.Context, enterprise string, opts ListMilestonesOptions) ([]*EnterpriseMilestone, error)
ListEnterpriseMilestones lists all milestones for an enterprise.
GET /enterprises/{enterprise}/milestones
func (*Client) ListEnterprisePullRequests ¶
func (c *Client) ListEnterprisePullRequests(ctx context.Context, enterprise string, opts ListEnterprisePRsOptions) ([]*PullRequest, error)
func (*Client) ListForks ¶
func (c *Client) ListForks(ctx context.Context, owner, repo string, opts ListOptions) ([]*Repository, error)
func (*Client) ListGitRefSubPaths ¶ added in v0.4.0
func (c *Client) ListGitRefSubPaths(ctx context.Context, owner, repo, refPrefix string) ([]*GitReference, error)
ListGitRefSubPaths lists references filtered by prefix (e.g. "heads/", "tags/").
GET /repos/{owner}/{repo}/git/refs/{refPrefix}
func (*Client) ListGitReferences ¶ added in v0.4.0
func (c *Client) ListGitReferences(ctx context.Context, owner, repo string, opts ListOptions) ([]*GitReference, error)
ListGitReferences lists all references of a repository.
GET /repos/{owner}/{repo}/git/refs
func (*Client) ListGitignoreTemplates ¶ added in v0.4.0
ListGitignoreTemplates lists all available gitignore templates.
GET /gitignore/templates
func (*Client) ListIssueBlockingIssues ¶ added in v0.4.0
func (c *Client) ListIssueBlockingIssues(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*Issue, error)
ListIssueBlockingIssues lists all issues that this issue blocks.
GET /repos/{owner}/{repo}/issues/{index}/blocks
func (*Client) ListIssueCommentModifyHistory ¶ added in v0.4.0
func (c *Client) ListIssueCommentModifyHistory(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*ModifyHistoryEntry, error)
ListIssueCommentModifyHistory lists the modification history of an issue comment.
GET /repos/{owner}/{repo}/issues/comment/{comment_id}/modify-history
func (*Client) ListIssueCommentReactions ¶ added in v0.4.0
func (c *Client) ListIssueCommentReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*Reaction, error)
ListIssueCommentReactions lists all reactions for an issue comment.
GET /repos/{owner}/{repo}/issues/comments/{id}/reactions
func (*Client) ListIssueCommentUserReactions ¶ added in v0.4.0
func (c *Client) ListIssueCommentUserReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*IssueUserReaction, error)
ListIssueCommentUserReactions lists user reactions for an issue comment.
GET /repos/{owner}/{repo}/issues/comment/{comment_id}/user-reactions
func (*Client) ListIssueComments ¶
func (*Client) ListIssueDependencies ¶ added in v0.4.0
func (c *Client) ListIssueDependencies(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueDependency, error)
ListIssueDependencies lists all dependencies of an issue.
GET /repos/{owner}/{repo}/issues/{index}/dependencies
func (*Client) ListIssueLabels ¶
func (*Client) ListIssueModifyHistory ¶ added in v0.4.0
func (c *Client) ListIssueModifyHistory(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*ModifyHistoryEntry, error)
ListIssueModifyHistory lists the modification history of an issue.
GET /repos/{owner}/{repo}/issues/{number}/modify-history
func (*Client) ListIssueReactions ¶ added in v0.4.0
func (c *Client) ListIssueReactions(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*Reaction, error)
ListIssueReactions lists all reactions for an issue.
GET /repos/{owner}/{repo}/issues/{index}/reactions
func (*Client) ListIssueRelatedBranches ¶ added in v0.4.0
func (c *Client) ListIssueRelatedBranches(ctx context.Context, owner, repo string, number int) ([]*IssueRelatedBranch, error)
ListIssueRelatedBranches lists all branches related to an issue.
GET /repos/{owner}/{repo}/issues/{number}/related-branches
func (*Client) ListIssueSubscribers ¶ added in v0.4.0
func (c *Client) ListIssueSubscribers(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueSubscriber, error)
ListIssueSubscribers lists all subscribers of an issue.
GET /repos/{owner}/{repo}/issues/{index}/subscribers
func (*Client) ListIssueTemplates ¶ added in v0.4.0
func (c *Client) ListIssueTemplates(ctx context.Context, owner, repo string) ([]*IssueTemplate, error)
ListIssueTemplates lists all issue templates of a repository.
GET /repos/{owner}/{repo}/issue_templates
func (*Client) ListIssueTimelineEvents ¶ added in v0.4.0
func (c *Client) ListIssueTimelineEvents(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueTimelineEvent, error)
ListIssueTimelineEvents lists all timeline events for an issue.
GET /repos/{owner}/{repo}/issues/{index}/timeline
func (*Client) ListIssueUserReactions ¶ added in v0.4.0
func (c *Client) ListIssueUserReactions(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueUserReaction, error)
ListIssueUserReactions lists user reactions for an issue.
GET /repos/{owner}/{repo}/issues/{number}/user-reactions
func (*Client) ListIssues ¶
func (*Client) ListKanbanBoardItems ¶ added in v0.5.0
func (c *Client) ListKanbanBoardItems(ctx context.Context, org string, boardID int64, opts ListOptions) ([]*KanbanBoardItem, error)
ListKanbanBoardItems lists all items on a kanban board.
GET /orgs/{org}/kanban/boards/{id}/items
func (*Client) ListKanbanBoards ¶ added in v0.5.0
func (c *Client) ListKanbanBoards(ctx context.Context, org string, opts ListOptions) ([]*KanbanBoard, error)
ListKanbanBoards lists all kanban boards for an organization.
GET /orgs/{org}/kanban/boards
func (*Client) ListLabelTemplates ¶ added in v0.4.0
ListLabelTemplates lists all available label templates.
GET /label/templates
func (*Client) ListLicenseTemplates ¶ added in v0.4.0
func (c *Client) ListLicenseTemplates(ctx context.Context) ([]*LicenseTemplate, error)
ListLicenseTemplates lists all available license templates.
GET /licenses
func (*Client) ListMilestones ¶
func (*Client) ListMilestonesWithOptions ¶
func (*Client) ListNotifications ¶
func (c *Client) ListNotifications(ctx context.Context) ([]*Notification, error)
func (*Client) ListNotificationsWithOptions ¶ added in v0.4.0
func (c *Client) ListNotificationsWithOptions(ctx context.Context, opts ListNotificationsOptions) ([]*NotificationThread, error)
ListNotificationsWithOptions lists the current user's notifications with options.
GET /notifications
func (*Client) ListOrgBlockedUsers ¶ added in v0.4.0
func (c *Client) ListOrgBlockedUsers(ctx context.Context, org string, opts ListOptions) ([]*User, error)
ListOrgBlockedUsers lists all blocked users of an organization.
GET /orgs/{org}/blocks
func (*Client) ListOrgCustomizedRoles ¶ added in v0.4.0
func (c *Client) ListOrgCustomizedRoles(ctx context.Context, org string) ([]*OrgCustomizedRole, error)
ListOrgCustomizedRoles lists all customized roles for an organization.
GET /org/{org}/customized-roles
func (*Client) ListOrgDiscussionCommentReplies ¶ added in v0.4.0
func (c *Client) ListOrgDiscussionCommentReplies(ctx context.Context, org string, number int, commentID int64, opts ListOptions) ([]*OrgDiscussionCommentReply, error)
ListOrgDiscussionCommentReplies lists all replies for an organization discussion comment.
GET /orgs/{org}/discuss/{number}/comment/{comment_id}/reply
func (*Client) ListOrgDiscussionComments ¶ added in v0.4.0
func (c *Client) ListOrgDiscussionComments(ctx context.Context, org string, number int, opts ListOptions) ([]*OrgDiscussionComment, error)
ListOrgDiscussionComments lists all comments for an organization discussion.
GET /orgs/{org}/discuss/{number}/comment
func (*Client) ListOrgDiscussions ¶ added in v0.4.0
func (c *Client) ListOrgDiscussions(ctx context.Context, org string, opts ListOptions) ([]*OrgDiscussion, error)
ListOrgDiscussions lists all discussions for an organization.
GET /orgs/{org}/discuss
func (*Client) ListOrgFollowers ¶
func (c *Client) ListOrgFollowers(ctx context.Context, org string, opts ListOptions) ([]*OrgFollowers, error)
func (*Client) ListOrgIssues ¶
func (*Client) ListOrgLabels ¶ added in v0.4.0
func (c *Client) ListOrgLabels(ctx context.Context, org string, opts ListOptions) ([]*OrgLabel, error)
ListOrgLabels lists all labels of an organization.
GET /orgs/{org}/labels
func (*Client) ListOrgMembers ¶
func (*Client) ListOrgPublicMembers ¶ added in v0.4.0
func (c *Client) ListOrgPublicMembers(ctx context.Context, org string, opts ListOptions) ([]*User, error)
ListOrgPublicMembers lists all public members of an organization.
GET /orgs/{org}/public_members
func (*Client) ListOrgPullRequests ¶
func (c *Client) ListOrgPullRequests(ctx context.Context, org string, opts ListEnterprisePRsOptions) ([]*PullRequest, error)
func (*Client) ListOrgRepositories ¶
func (c *Client) ListOrgRepositories(ctx context.Context, org, repoType string, opts ListOptions) ([]*Repository, error)
func (*Client) ListOrgRunnerGroups ¶ added in v0.5.0
func (c *Client) ListOrgRunnerGroups(ctx context.Context, org string, opts ListOptions) ([]*RunnerGroup, error)
ListOrgRunnerGroups lists all runner groups for an organization.
GET /orgs/{org}/actions/runner-groups
func (*Client) ListOrgTeams ¶ added in v0.4.0
ListOrgTeams lists all teams in an organization.
GET /orgs/{org}/teams
func (*Client) ListOrgWebhooks ¶ added in v0.4.0
func (c *Client) ListOrgWebhooks(ctx context.Context, org string, opts ListOptions) ([]*OrgWebhook, error)
ListOrgWebhooks lists all webhooks of an organization.
GET /orgs/{org}/hooks
func (*Client) ListOrganizationMembers ¶
func (*Client) ListOrganizations ¶
func (c *Client) ListOrganizations(ctx context.Context) ([]*Organization, error)
func (*Client) ListOrganizationsWithOptions ¶
func (c *Client) ListOrganizationsWithOptions(ctx context.Context, admin bool, opts ListOptions) ([]*Organization, error)
func (*Client) ListPendingRepoInvitations ¶ added in v0.4.0
func (c *Client) ListPendingRepoInvitations(ctx context.Context, opts ListOptions) ([]*RepoInvitation, error)
ListPendingRepoInvitations lists pending repository invitations for the authenticated user.
GET /user/repository_invitations
func (*Client) ListProtectedTags ¶ added in v0.5.0
func (c *Client) ListProtectedTags(ctx context.Context, owner, repo string, opts ListOptions) ([]*ProtectedTag, error)
ListProtectedTags lists all protected tag rules for a repository.
GET /repos/{owner}/{repo}/protected-tags
func (*Client) ListPullRequestAvailableReviewers ¶ added in v0.4.0
func (c *Client) ListPullRequestAvailableReviewers(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*User, error)
ListPullRequestAvailableReviewers lists users available as approval reviewers for a pull request.
GET /repos/{owner}/{repo}/pulls/{number}/option-approval-reviewers
func (*Client) ListPullRequestAvailableTesters ¶ added in v0.4.0
func (c *Client) ListPullRequestAvailableTesters(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*User, error)
ListPullRequestAvailableTesters lists users available as testers for a pull request.
GET /repos/{owner}/{repo}/pulls/{number}/option-approval-testers
func (*Client) ListPullRequestCommentModifyHistory ¶ added in v0.4.0
func (c *Client) ListPullRequestCommentModifyHistory(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*ModifyHistoryEntry, error)
ListPullRequestCommentModifyHistory lists the modification history of a PR comment.
GET /repos/{owner}/{repo}/pulls/comment/{comment_id}/modify-history
func (*Client) ListPullRequestCommentReactions ¶ added in v0.4.0
func (c *Client) ListPullRequestCommentReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*Reaction, error)
ListPullRequestCommentReactions lists all reactions for a pull request comment.
GET /repos/{owner}/{repo}/pulls/comments/{id}/reactions
func (*Client) ListPullRequestCommentUserReactions ¶ added in v0.4.0
func (c *Client) ListPullRequestCommentUserReactions(ctx context.Context, owner, repo string, commentID int64, opts ListOptions) ([]*IssueUserReaction, error)
ListPullRequestCommentUserReactions lists user reactions for a PR comment.
GET /repos/{owner}/{repo}/pulls/comment/{comment_id}/user-reactions
func (*Client) ListPullRequestComments ¶
func (*Client) ListPullRequestCommits ¶
func (*Client) ListPullRequestFiles ¶
func (*Client) ListPullRequestFilesJSON ¶ added in v0.4.0
func (c *Client) ListPullRequestFilesJSON(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*PullRequestFileChange, error)
ListPullRequestFilesJSON lists files changed in a pull request in JSON format.
GET /repos/{owner}/{repo}/pulls/{number}/files.json
func (*Client) ListPullRequestLabels ¶
func (*Client) ListPullRequestMergeTemplates ¶ added in v0.4.0
func (c *Client) ListPullRequestMergeTemplates(ctx context.Context, owner, repo string) ([]*PRMergeTemplate, error)
ListPullRequestMergeTemplates lists all pull request merge templates of a repository.
GET /repos/{owner}/{repo}/merge_templates
func (*Client) ListPullRequestModifyHistory ¶ added in v0.4.0
func (c *Client) ListPullRequestModifyHistory(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*ModifyHistoryEntry, error)
ListPullRequestModifyHistory lists the modification history of a pull request.
GET /repos/{owner}/{repo}/pulls/{number}/modify-history
func (*Client) ListPullRequestReviewers ¶ added in v0.4.0
func (c *Client) ListPullRequestReviewers(ctx context.Context, owner, repo string, number int) ([]*Reviewer, error)
ListPullRequestReviewers lists all reviewers requested for a pull request.
GET /repos/{owner}/{repo}/pulls/{index}/requested_reviewers
func (*Client) ListPullRequestReviews ¶
func (*Client) ListPullRequestUserReactions ¶ added in v0.4.0
func (c *Client) ListPullRequestUserReactions(ctx context.Context, owner, repo string, number int, opts ListOptions) ([]*IssueUserReaction, error)
ListPullRequestUserReactions lists user reactions for a pull request.
GET /repos/{owner}/{repo}/pulls/{number}/user-reactions
func (*Client) ListPullRequests ¶
func (c *Client) ListPullRequests(ctx context.Context, owner, repo string, opts ListPullRequestsOptions) ([]*PullRequest, error)
func (*Client) ListPushRemoteMirrors ¶ added in v0.4.0
func (c *Client) ListPushRemoteMirrors(ctx context.Context, owner, repo string, opts ListOptions) ([]*RemoteMirror, error)
ListPushRemoteMirrors lists all push remote mirrors of a repository.
GET /repos/{owner}/{repo}/push-remote-mirrors
func (*Client) ListReleaseAssets ¶ added in v0.4.0
func (c *Client) ListReleaseAssets(ctx context.Context, owner, repo string, releaseID int64, opts ListOptions) ([]*ReleaseAsset, error)
ListReleaseAssets lists all assets for a release.
GET /repos/{owner}/{repo}/releases/{id}/assets
func (*Client) ListReleases ¶
func (*Client) ListRepoAllIssueComments ¶
func (c *Client) ListRepoAllIssueComments(ctx context.Context, owner, repo string, opts ListOptions) ([]*IssueComment, error)
func (*Client) ListRepoAssignees ¶ added in v0.4.0
func (c *Client) ListRepoAssignees(ctx context.Context, owner, repo string, opts ListOptions) ([]*User, error)
ListRepoAssignees lists all available assignees for issues in a repository.
GET /repos/{owner}/{repo}/assignees
func (*Client) ListRepoBranchesPaginated ¶ added in v0.4.0
func (c *Client) ListRepoBranchesPaginated(ctx context.Context, owner, repo string, opts ListOptions) ([]*RepoBranchInfo, error)
ListRepoBranches lists all branches of a repository with pagination.
GET /repos/{owner}/{repo}/branches
func (*Client) ListRepoCLAs ¶ added in v0.4.0
ListRepoCLAs lists all CLAs for a repository.
GET /repos/{owner}/{repo}/clas
func (*Client) ListRepoCommitComments ¶ added in v0.4.0
func (c *Client) ListRepoCommitComments(ctx context.Context, owner, repo string, opts ListOptions) ([]*CommitComment, error)
ListRepoCommitComments lists all commit comments for a repository.
GET /repos/{owner}/{repo}/comments
func (*Client) ListRepoEvents ¶
func (*Client) ListRepoHostRunners ¶ added in v0.5.0
func (c *Client) ListRepoHostRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
ListRepoHostRunners lists all host runners for a repository.
GET /repos/{owner}/{repo}/actions/runners/host
func (*Client) ListRepoK8SRunners ¶ added in v0.5.0
func (c *Client) ListRepoK8SRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
ListRepoK8SRunners lists all K8S runners for a repository.
GET /repos/{owner}/{repo}/actions/runners/k8s
func (*Client) ListRepoNotifications ¶ added in v0.4.0
func (c *Client) ListRepoNotifications(ctx context.Context, owner, repo string, opts ListNotificationsOptions) ([]*NotificationThread, error)
ListRepoNotifications lists notifications for a repository.
GET /repos/{owner}/{repo}/notifications
func (*Client) ListRepoReviewers ¶ added in v0.4.0
func (c *Client) ListRepoReviewers(ctx context.Context, owner, repo string, opts ListOptions) ([]*Reviewer, error)
ListRepoReviewers lists all available reviewers for a repository.
GET /repos/{owner}/{repo}/reviewers
func (*Client) ListRepoSharedHostRunners ¶ added in v0.5.0
func (c *Client) ListRepoSharedHostRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
ListRepoSharedHostRunners lists all shared host runners for a repository.
GET /repos/{owner}/{repo}/actions/runners/shared-host
func (*Client) ListRepoSharedK8SRunners ¶ added in v0.5.0
func (c *Client) ListRepoSharedK8SRunners(ctx context.Context, owner, repo string, opts ListOptions) ([]*ActionRunner, error)
ListRepoSharedK8SRunners lists all shared K8S runners for a repository.
GET /repos/{owner}/{repo}/actions/runners/shared-k8s
func (*Client) ListRepositories ¶
func (c *Client) ListRepositories(ctx context.Context, opts ListRepositoriesOptions) ([]*Repository, error)
func (*Client) ListRepositoryContents ¶
func (*Client) ListRepositoryTopics ¶ added in v0.4.0
ListRepositoryTopics lists all topics of a repository.
GET /repos/{owner}/{repo}/topics
func (*Client) ListRunnerGroupHostRunners ¶ added in v0.5.0
func (c *Client) ListRunnerGroupHostRunners(ctx context.Context, org string, groupID int64, opts ListOptions) ([]*ActionRunner, error)
ListRunnerGroupHostRunners lists all host runners in a runner group.
GET /orgs/{org}/actions/runner-groups/{id}/host-runners
func (*Client) ListRunnerGroupK8SRunners ¶ added in v0.5.0
func (c *Client) ListRunnerGroupK8SRunners(ctx context.Context, org string, groupID int64, opts ListOptions) ([]*ActionRunner, error)
ListRunnerGroupK8SRunners lists all K8S runners in a runner group.
GET /orgs/{org}/actions/runner-groups/{id}/k8s-runners
func (*Client) ListRunnerGroupRepos ¶ added in v0.5.0
func (c *Client) ListRunnerGroupRepos(ctx context.Context, org string, groupID int64, opts ListOptions) ([]*Repository, error)
ListRunnerGroupRepos lists all repositories that have access to a runner group.
GET /orgs/{org}/actions/runner-groups/{id}/repos
func (*Client) ListSSHKeys ¶
func (*Client) ListStargazers ¶
func (*Client) ListStarredRepositories ¶
func (c *Client) ListStarredRepositories(ctx context.Context, opts ListStarredReposOptions) ([]*Repository, error)
func (*Client) ListTagsWithOptions ¶ added in v0.4.0
func (c *Client) ListTagsWithOptions(ctx context.Context, owner, repo string, opts ListOptions) ([]*Tag, error)
ListTagsWithOptions lists all tags with pagination options.
GET /repos/{owner}/{repo}/tags
func (*Client) ListTeamMembers ¶ added in v0.4.0
func (c *Client) ListTeamMembers(ctx context.Context, teamID int64, opts ListOptions) ([]*TeamMember, error)
ListTeamMembers lists all members of a team.
GET /teams/{team_id}/members
func (*Client) ListTeamRepositories ¶ added in v0.4.0
func (c *Client) ListTeamRepositories(ctx context.Context, teamID int64, opts ListOptions) ([]*Repository, error)
ListTeamRepositories lists all repositories of a team.
GET /teams/{team_id}/repos
func (*Client) ListUserFollowers ¶ added in v0.4.0
func (c *Client) ListUserFollowers(ctx context.Context, username string, opts ListOptions) ([]*User, error)
ListUserFollowers lists the followers of a user.
GET /users/{username}/followers
func (*Client) ListUserFollowing ¶ added in v0.4.0
func (c *Client) ListUserFollowing(ctx context.Context, username string, opts ListOptions) ([]*User, error)
ListUserFollowing lists the users that a user is following.
GET /users/{username}/following
func (*Client) ListUserIssues ¶
func (*Client) ListUserOrganizations ¶
func (c *Client) ListUserOrganizations(ctx context.Context, username string, opts ListOptions) ([]*Organization, error)
func (*Client) ListUserPullRequests ¶ added in v0.4.0
func (c *Client) ListUserPullRequests(ctx context.Context, opts ListPullRequestsOptions) ([]*PullRequest, error)
ListUserPullRequests lists pull requests for the authenticated user.
GET /users/merge-requests
func (*Client) ListUserRepositories ¶ added in v0.4.0
func (c *Client) ListUserRepositories(ctx context.Context, username string, opts ListOptions) ([]*Repository, error)
ListUserRepositories lists a user's public repositories.
GET /users/{username}/repos
func (*Client) ListUserWatchedRepositories ¶ added in v0.4.0
func (c *Client) ListUserWatchedRepositories(ctx context.Context, username string, opts ListOptions) ([]*Repository, error)
ListUserWatchedRepositories lists repositories watched by a user.
GET /users/{username}/subscriptions
func (*Client) ListWatchers ¶
func (*Client) ListWebhooks ¶
func (*Client) ListWikiPages ¶ added in v0.4.0
func (c *Client) ListWikiPages(ctx context.Context, owner, repo string, opts ListOptions) ([]*WikiPage, error)
ListWikiPages lists all wiki pages of a repository.
GET /repos/{owner}/{repo}/wiki/pages
func (*Client) MarkNotificationThreadAsRead ¶ added in v0.4.0
MarkNotificationThreadAsRead marks a single notification thread as read.
PATCH /notifications/threads/{id}
func (*Client) MarkNotificationsAsRead ¶ added in v0.4.0
func (c *Client) MarkNotificationsAsRead(ctx context.Context, opts MarkNotificationsOptions) error
MarkNotificationsAsRead marks all notifications as read.
PUT /notifications
func (*Client) MarkRepoNotificationsAsRead ¶ added in v0.4.0
func (c *Client) MarkRepoNotificationsAsRead(ctx context.Context, owner, repo string, opts MarkNotificationsOptions) error
MarkRepoNotificationsAsRead marks all notifications for a repository as read.
PUT /repos/{owner}/{repo}/notifications
func (*Client) MergePullRequest ¶
func (*Client) ParseIssueEvent ¶
func (c *Client) ParseIssueEvent(payload []byte) (*IssueWebhookEvent, error)
func (*Client) ParseNoteEvent ¶
func (c *Client) ParseNoteEvent(payload []byte) (*NoteWebhookEvent, error)
func (*Client) ParsePullRequestEvent ¶
func (c *Client) ParsePullRequestEvent(payload []byte) (*PullRequestWebhookEvent, error)
func (*Client) ParseTagPushEvent ¶
func (c *Client) ParseTagPushEvent(payload []byte) (*TagPushEvent, error)
func (*Client) PublicizeOrgMembership ¶ added in v0.4.0
PublicizeOrgMembership makes the authenticated user's membership public.
PUT /orgs/{org}/public_members/{username}
func (*Client) RefreshPullRequestCommentPosition ¶ added in v0.4.0
func (c *Client) RefreshPullRequestCommentPosition(ctx context.Context, owner, repo string, number int) error
RefreshPullRequestCommentPosition refreshes the position/expired status of PR comments.
POST /repos/{owner}/{repo}/pulls/{number}/refresh-position
func (*Client) RemoveAllIssueLabels ¶
func (*Client) RemoveCollaborator ¶ added in v0.4.0
RemoveCollaborator removes a collaborator from a repository.
DELETE /repos/{owner}/{repo}/collaborators/{username}
func (*Client) RemoveFromKanbanBoard ¶ added in v0.5.0
func (c *Client) RemoveFromKanbanBoard(ctx context.Context, org string, boardID, itemID int64) error
RemoveFromKanbanBoard removes an item from a kanban board.
DELETE /orgs/{org}/kanban/boards/{id}/items/{item_id}
func (*Client) RemoveIssueAssignees ¶ added in v0.4.0
func (c *Client) RemoveIssueAssignees(ctx context.Context, owner, repo string, number int, assignees []string) (*Issue, error)
RemoveIssueAssignees removes assignees from an issue.
DELETE /repos/{owner}/{repo}/issues/{index}/assignees
func (*Client) RemoveIssueLabel ¶
func (*Client) RemoveOrgMember ¶
func (*Client) RemovePullRequestLabel ¶
func (*Client) RemovePullRequestReviewer ¶ added in v0.4.0
func (c *Client) RemovePullRequestReviewer(ctx context.Context, owner, repo string, number int, opts PullRequestReviewRequest) error
RemovePullRequestReviewer removes a requested reviewer from a pull request.
DELETE /repos/{owner}/{repo}/pulls/{index}/requested_reviewers
func (*Client) RemoveTeamMember ¶ added in v0.4.0
RemoveTeamMember removes a member from a team.
DELETE /teams/{team_id}/members/{username}
func (*Client) RemoveTeamRepository ¶ added in v0.4.0
RemoveTeamRepository removes a repository from a team.
DELETE /teams/{team_id}/repos/{org}/{repo}
func (*Client) RenderMarkdown ¶ added in v0.4.0
RenderMarkdown renders a markdown document as HTML.
POST /markdown
func (*Client) RenderMarkdownRaw ¶ added in v0.4.0
RenderMarkdownRaw renders raw markdown as HTML.
POST /markdown/raw
func (*Client) ReopenIssue ¶
func (*Client) ReopenPullRequest ¶
func (*Client) ReplaceIssueLabels ¶
func (*Client) ReplacePullRequestLabels ¶
func (*Client) ReplyPullRequestComment ¶ added in v0.4.0
func (c *Client) ReplyPullRequestComment(ctx context.Context, owner, repo string, number int, discussionID string, body string) (*PRDiscussionComment, error)
ReplyPullRequestComment replies to a pull request review comment.
POST /repos/{owner}/{repo}/pulls/{number}/discussions/{discussions_id}/comments
func (*Client) RequestPullRequestReviewers ¶ added in v0.4.0
func (c *Client) RequestPullRequestReviewers(ctx context.Context, owner, repo string, number int, opts PullRequestReviewRequest) error
RequestPullRequestReviewers requests reviewers for a pull request.
POST /repos/{owner}/{repo}/pulls/{index}/requested_reviewers
func (*Client) ResetPullRequestReviewStatus ¶
func (*Client) ResetPullRequestTestStatus ¶
func (*Client) ResolvePullRequestDiscussion ¶ added in v0.4.0
func (c *Client) ResolvePullRequestDiscussion(ctx context.Context, owner, repo string, number int, discussionID string, resolved bool) error
ResolvePullRequestDiscussion resolves or unresolves a review discussion.
PUT /repos/{owner}/{repo}/pulls/{number}/comments/discussions/{id}
func (*Client) RunActionWorkflow ¶ added in v0.5.0
func (c *Client) RunActionWorkflow(ctx context.Context, owner, repo string, opts RunActionWorkflowOptions) error
RunActionWorkflow manually triggers a workflow run.
POST /repos/{owner}/{repo}/actions/run
func (*Client) SearchIssues ¶
func (c *Client) SearchIssues(ctx context.Context, opts SearchIssuesOptions) ([]*SearchIssueResult, error)
func (*Client) SearchRepositories ¶
func (c *Client) SearchRepositories(ctx context.Context, opts SearchRepositoriesOptions) ([]*SearchRepositoryResult, error)
func (*Client) SearchUsers ¶
func (c *Client) SearchUsers(ctx context.Context, opts SearchUsersOptions) ([]*SearchUserResult, error)
func (*Client) SetAuthStyle ¶
func (*Client) SetHTTPClient ¶
func (*Client) SetIssueRelatedBranches ¶ added in v0.4.0
func (c *Client) SetIssueRelatedBranches(ctx context.Context, owner, repo string, number int, branches []string) error
SetIssueRelatedBranches sets the branches related to an issue.
PUT /repos/{owner}/{repo}/issues/{number}/related-branches
func (*Client) SetModuleSetting ¶
func (*Client) SetRepoVisibility ¶ added in v0.4.0
func (c *Client) SetRepoVisibility(ctx context.Context, owner, repo string, private bool) (*Repository, error)
SetRepoVisibility sets a repository's visibility (public/private).
PATCH /repos/{owner}/{repo}
func (*Client) StarRepository ¶
func (*Client) SubmitPullRequestReview ¶ added in v0.4.0
func (c *Client) SubmitPullRequestReview(ctx context.Context, owner, repo string, number int, reviewID int64, body, event string) (*PullRequestReview, error)
SubmitPullRequestReview submits a pull request review.
POST /repos/{owner}/{repo}/pulls/{index}/reviews/{id}
func (*Client) SubscribeToIssue ¶ added in v0.4.0
func (c *Client) SubscribeToIssue(ctx context.Context, owner, repo string, number int, username string) error
SubscribeToIssue subscribes the authenticated user to an issue.
PUT /repos/{owner}/{repo}/issues/{index}/subscribers/{username}
func (*Client) SyncForkRepository ¶ added in v0.4.0
SyncForkRepository syncs a forked repository with its upstream.
PUT /repos/{owner}/{repo}/sync-repo
func (*Client) TestWebhook ¶
func (*Client) TransferRepository ¶
func (*Client) TransferToOrg ¶
func (*Client) UnassignPullRequestApprovalReviewers ¶ added in v0.4.0
func (c *Client) UnassignPullRequestApprovalReviewers(ctx context.Context, owner, repo string, number int, reviewers string) error
UnassignPullRequestApprovalReviewers removes approval reviewers from a pull request.
DELETE /repos/{owner}/{repo}/pulls/{number}/approval-reviewers
func (*Client) UnassignPullRequestReviewers ¶
func (*Client) UnassignPullRequestTesters ¶ added in v0.4.0
func (c *Client) UnassignPullRequestTesters(ctx context.Context, owner, repo string, number int, testers string) error
UnassignPullRequestTesters removes testers from a pull request.
DELETE /repos/{owner}/{repo}/pulls/{number}/testers
func (*Client) UnblockOrgUser ¶ added in v0.4.0
UnblockOrgUser unblocks a user from an organization.
DELETE /orgs/{org}/blocks/{username}
func (*Client) UnfollowUser ¶ added in v0.4.0
UnfollowUser unfollows a user.
DELETE /user/following/{username}
func (*Client) UnlinkPullRequestIssue ¶ added in v0.4.0
func (c *Client) UnlinkPullRequestIssue(ctx context.Context, owner, repo string, number int, issueNumber int) error
UnlinkPullRequestIssue removes an issue link from a pull request.
DELETE /repos/{owner}/{repo}/pulls/{number}/issues
func (*Client) UnstarRepository ¶
func (*Client) UnsubscribeFromIssue ¶ added in v0.4.0
func (c *Client) UnsubscribeFromIssue(ctx context.Context, owner, repo string, number int, username string) error
UnsubscribeFromIssue unsubscribes the authenticated user from an issue.
DELETE /repos/{owner}/{repo}/issues/{index}/subscribers/{username}
func (*Client) UpdateBranchProtection ¶
func (*Client) UpdateCommitComment ¶ added in v0.4.0
func (c *Client) UpdateCommitComment(ctx context.Context, owner, repo string, commentID int64, opts UpdateCommitCommentOptions) (*CommitComment, error)
UpdateCommitComment updates a commit comment.
PATCH /repos/{owner}/{repo}/comments/{id}
func (*Client) UpdateCurrentUser ¶ added in v0.4.0
func (c *Client) UpdateCurrentUser(ctx context.Context, opts UpdateCurrentUserOptions) (*User, error)
UpdateCurrentUser updates the authenticated user's profile.
PATCH /user
func (*Client) UpdateEnterpriseLabel ¶ added in v0.5.0
func (c *Client) UpdateEnterpriseLabel(ctx context.Context, enterprise string, labelID int64, opts UpdateEnterpriseLabelOptions) (*EnterpriseLabel, error)
UpdateEnterpriseLabel updates an enterprise label.
PATCH /enterprises/{enterprise}/labels/{id}
func (*Client) UpdateEnterpriseMember ¶
func (c *Client) UpdateEnterpriseMember(ctx context.Context, enterprise, username string, opts UpdateEnterpriseMemberOptions) (*EnterpriseMember, error)
func (*Client) UpdateEnterpriseMilestone ¶ added in v0.5.0
func (c *Client) UpdateEnterpriseMilestone(ctx context.Context, enterprise string, milestoneID int64, opts UpdateEnterpriseMilestoneOptions) (*EnterpriseMilestone, error)
UpdateEnterpriseMilestone updates an enterprise milestone.
PATCH /enterprises/{enterprise}/milestones/{id}
func (*Client) UpdateFile ¶
func (c *Client) UpdateFile(ctx context.Context, owner, repo, path string, opts UpdateFileOptions) (*FileResult, error)
func (*Client) UpdateGitReference ¶ added in v0.4.0
func (c *Client) UpdateGitReference(ctx context.Context, owner, repo, ref string, opts UpdateReferenceOptions) (*GitReference, error)
UpdateGitReference updates a reference.
PATCH /repos/{owner}/{repo}/git/refs/{ref}
func (*Client) UpdateIssue ¶
func (*Client) UpdateIssueComment ¶
func (*Client) UpdateIssueKanbanValues ¶ added in v0.4.0
func (c *Client) UpdateIssueKanbanValues(ctx context.Context, owner, repo string, number int, values []KanbanValue) error
UpdateIssueKanbanValues updates the kanban field values of an issue.
PUT /repos/{owner}/{repo}/issues/{number}/kanban-values
func (*Client) UpdateIssueLabel ¶
func (*Client) UpdateKanbanBoardItem ¶ added in v0.5.0
func (c *Client) UpdateKanbanBoardItem(ctx context.Context, org string, boardID, itemID int64, opts UpdateKanbanBoardItemOptions) (*KanbanBoardItem, error)
UpdateKanbanBoardItem updates an item on a kanban board.
PUT /orgs/{org}/kanban/boards/{id}/items/{item_id}
func (*Client) UpdateKanbanBoardStatus ¶ added in v0.5.0
func (c *Client) UpdateKanbanBoardStatus(ctx context.Context, org string, boardID int64, opts UpdateKanbanBoardStatusOptions) error
UpdateKanbanBoardStatus updates the statuses of a kanban board.
PUT /orgs/{org}/kanban/boards/{id}/status
func (*Client) UpdateMilestone ¶
func (*Client) UpdateOrgLabel ¶ added in v0.4.0
func (c *Client) UpdateOrgLabel(ctx context.Context, org string, labelID int64, opts UpdateOrgLabelOptions) (*OrgLabel, error)
UpdateOrgLabel updates an organization label.
PATCH /orgs/{org}/labels/{id}
func (*Client) UpdateOrgRepoStatus ¶
func (*Client) UpdateOrgWebhook ¶ added in v0.4.0
func (c *Client) UpdateOrgWebhook(ctx context.Context, org string, hookID int64, opts UpdateOrgWebhookOptions) (*OrgWebhook, error)
UpdateOrgWebhook updates an organization webhook.
PATCH /orgs/{org}/hooks/{id}
func (*Client) UpdateOrganization ¶
func (c *Client) UpdateOrganization(ctx context.Context, org string, opts UpdateOrgOptions) (*Organization, error)
func (*Client) UpdatePRSettings ¶
func (*Client) UpdateProtectedTag ¶ added in v0.5.0
func (c *Client) UpdateProtectedTag(ctx context.Context, owner, repo, tag string, opts UpdateProtectedTagOptions) (*ProtectedTag, error)
UpdateProtectedTag updates a protected tag rule.
PUT /repos/{owner}/{repo}/protected-tags/{tag}
func (*Client) UpdatePullRequest ¶
func (c *Client) UpdatePullRequest(ctx context.Context, owner, repo string, number int, opts UpdatePullRequestOptions) (*PullRequest, error)
func (*Client) UpdatePullRequestComment ¶
func (*Client) UpdatePushConfig ¶
func (*Client) UpdateRelease ¶ added in v0.4.0
func (c *Client) UpdateRelease(ctx context.Context, owner, repo string, releaseID int64, opts UpdateReleaseOptions) (*Release, error)
UpdateRelease updates a release.
PATCH /repos/{owner}/{repo}/releases/{id}
func (*Client) UpdateRepoMember ¶
func (*Client) UpdateRepoSettings ¶
func (c *Client) UpdateRepoSettings(ctx context.Context, owner, repo string, opts *RepoSettings) (*RepoSettings, error)
func (*Client) UpdateRepository ¶
func (c *Client) UpdateRepository(ctx context.Context, owner, repo string, opts UpdateRepositoryOptions) (*Repository, error)
func (*Client) UpdateRepositoryTopics ¶ added in v0.4.0
func (c *Client) UpdateRepositoryTopics(ctx context.Context, owner, repo string, topics []string) ([]string, error)
UpdateRepositoryTopics replaces all topics of a repository.
PUT /repos/{owner}/{repo}/topics
func (*Client) UpdateReviewerConfig ¶
func (*Client) UpdateTeam ¶ added in v0.4.0
func (c *Client) UpdateTeam(ctx context.Context, teamID int64, opts UpdateTeamOptions) (*Team, error)
UpdateTeam updates a team.
PATCH /teams/{team_id}
func (*Client) UpdateWebhook ¶
func (*Client) UpdateWikiPage ¶ added in v0.4.0
func (c *Client) UpdateWikiPage(ctx context.Context, owner, repo, pageName string, opts UpdateWikiPageOptions) (*WikiPage, error)
UpdateWikiPage updates an existing wiki page.
PATCH /repos/{owner}/{repo}/wiki/page/{pageName}
func (*Client) UploadFile ¶
func (*Client) UploadImage ¶
type CodeFrequencyEntry ¶ added in v0.4.0
type CodeFrequencyEntry []int
CodeFrequencyEntry represents a [additions, deletions, timestamp] tuple.
type Collaborator ¶ added in v0.4.0
type Collaborator struct {
ID int64 `json:"id"`
Login string `json:"login"`
Name string `json:"name"`
AvatarURL string `json:"avatar_url"`
HTMLURL string `json:"html_url"`
Permission string `json:"permission,omitempty"`
}
Collaborator represents a repository collaborator.
type CollaboratorPermission ¶ added in v0.4.0
type CollaboratorPermission struct {
Permission string `json:"permission"`
RoleName string `json:"role_name"`
}
CollaboratorPermission represents a collaborator's permission level.
type CombinedStatus ¶ added in v0.4.0
type CombinedStatus struct {
SHA string `json:"sha"`
TotalCount int `json:"total_count"`
Statuses []*CommitStatus `json:"statuses"`
Repository *Repository `json:"repository"`
CommitURL string `json:"commit_url"`
URL string `json:"url"`
}
CombinedStatus represents the combined status for a commit.
type CommitActivity ¶ added in v0.4.0
type CommitActivity struct {
Days []int `json:"days"` // Sun-Sat
Total int `json:"total"`
Week int64 `json:"week"` // Unix timestamp
}
CommitActivity represents weekly commit activity.
type CommitAuthor ¶
type CommitComment ¶ added in v0.4.0
type CommitComment struct {
ID int64 `json:"id"`
Body string `json:"body"`
Path string `json:"path,omitempty"`
Position int `json:"position,omitempty"`
Line int `json:"line,omitempty"`
CommitID string `json:"commit_id"`
User *User `json:"user"`
Author *User `json:"author"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
HTMLURL string `json:"html_url,omitempty"`
}
CommitComment represents a comment on a commit.
type CommitComparison ¶
type CommitComparison struct {
TotalCommits int `json:"total_commits"`
AheadBy int `json:"ahead_by"`
BehindBy int `json:"behind_by"`
Commits []*Commit `json:"commits"`
Files []*PullRequestFile `json:"files"`
}
type CommitStatus ¶ added in v0.4.0
type CommitStatus struct {
ID int64 `json:"id"`
SHA string `json:"sha"`
State string `json:"state"` // pending, success, error, failure
TargetURL string `json:"target_url"`
Description string `json:"description"`
Context string `json:"context"`
Creator *User `json:"creator"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
CommitStatus represents a commit status.
type Contributor ¶
type ContributorStatistic ¶
type CreateAnnotatedTagOptions ¶ added in v0.4.0
type CreateAnnotatedTagOptions struct {
Tag string `json:"tag"`
Message string `json:"message"`
Object string `json:"object"` // SHA of the object to tag
Type string `json:"type"` // commit, tree, blob
Tagger *struct {
Name string `json:"name"`
Email string `json:"email"`
Date string `json:"date"`
} `json:"tagger,omitempty"`
}
CreateAnnotatedTagOptions specifies options for creating an annotated tag.
type CreateBranchOptions ¶
type CreateCommitCommentOptions ¶ added in v0.4.0
type CreateCommitCommentOptions struct {
Body string `json:"body"`
Path string `json:"path,omitempty"`
Position int `json:"position,omitempty"`
Line int `json:"line,omitempty"`
}
CreateCommitCommentOptions specifies options for creating a commit comment.
type CreateCommitStatusOptions ¶ added in v0.4.0
type CreateCommitStatusOptions struct {
State string `json:"state"` // pending, success, error, failure
TargetURL string `json:"target_url,omitempty"`
Description string `json:"description,omitempty"`
Context string `json:"context,omitempty"`
}
CreateCommitStatusOptions specifies options for creating a commit status.
type CreateDeployKeyOptions ¶ added in v0.4.0
type CreateDeployKeyOptions struct {
Title string `json:"title"`
Key string `json:"key"`
ReadOnly *bool `json:"read_only,omitempty"`
}
CreateDeployKeyOptions specifies options for creating a deploy key.
type CreateEnterpriseLabelOptions ¶ added in v0.5.0
CreateEnterpriseLabelOptions specifies options for creating an enterprise label.
type CreateEnterpriseMilestoneOptions ¶ added in v0.5.0
type CreateEnterpriseMilestoneOptions struct {
Title string `json:"title"`
Description string `json:"description,omitempty"`
DueOn string `json:"due_on,omitempty"`
}
CreateEnterpriseMilestoneOptions specifies options for creating an enterprise milestone.
type CreateFileOptions ¶
type CreateIssueOptions ¶
type CreateIssueOptions struct {
Title string `json:"title"`
Body string `json:"body,omitempty"`
Assignee string `json:"assignee,omitempty"`
Assignees []string `json:"assignees,omitempty"`
Milestone int64 `json:"milestone,omitempty"`
Labels []string `json:"labels,omitempty"`
}
func (CreateIssueOptions) MarshalJSON ¶
func (o CreateIssueOptions) MarshalJSON() ([]byte, error)
type CreateMilestoneOptions ¶
type CreateOrgLabelOptions ¶ added in v0.4.0
type CreateOrgLabelOptions struct {
Name string `json:"name"`
Color string `json:"color"`
Exclusive *bool `json:"exclusive,omitempty"`
Template *bool `json:"template,omitempty"`
}
CreateOrgLabelOptions specifies options for creating an organization label.
type CreateOrgOptions ¶ added in v0.4.0
type CreateOrgOptions struct {
Username string `json:"username"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
Email string `json:"email,omitempty"`
Location string `json:"location,omitempty"`
Website string `json:"website,omitempty"`
Visibility string `json:"visibility,omitempty"` // public, limited, private
}
CreateOrgOptions specifies options for creating an organization.
type CreateOrgRepoOptions ¶
type CreateOrgRepoOptions struct {
Name string `json:"name"`
Description string `json:"description,omitempty"`
Homepage string `json:"homepage,omitempty"`
HasIssues *bool `json:"has_issues,omitempty"`
HasWiki *bool `json:"has_wiki,omitempty"`
CanComment *bool `json:"can_comment,omitempty"`
Public *int `json:"public,omitempty"`
Private *bool `json:"private,omitempty"`
AutoInit *bool `json:"auto_init,omitempty"`
GitignoreTemplate string `json:"gitignore_template,omitempty"`
LicenseTemplate string `json:"license_template,omitempty"`
Path string `json:"path,omitempty"`
DefaultBranch string `json:"default_branch,omitempty"`
}
type CreateOrgWebhookOptions ¶ added in v0.4.0
type CreateOrgWebhookOptions struct {
URL string `json:"url"`
Secret string `json:"secret,omitempty"`
Events []string `json:"events,omitempty"`
Active *bool `json:"active,omitempty"`
Config *WebhookConfig `json:"config,omitempty"`
}
CreateOrgWebhookOptions specifies options for creating an organization webhook.
type CreateProtectedTagOptions ¶ added in v0.5.0
type CreateProtectedTagOptions struct {
NamePattern string `json:"name_pattern"`
Owners []string `json:"owners,omitempty"`
}
CreateProtectedTagOptions specifies options for creating a protected tag.
type CreateReactionOptions ¶ added in v0.4.0
type CreateReactionOptions struct {
Content string `json:"content"`
}
CreateReactionOptions specifies options for creating a reaction.
type CreateReferenceOptions ¶ added in v0.4.0
type CreateReferenceOptions struct {
Ref string `json:"ref"` // e.g. "refs/heads/feature" or "refs/tags/v1.0"
SHA string `json:"sha"` // The SHA of the object to point to
}
CreateReferenceOptions specifies options for creating a reference.
type CreateReleaseOptions ¶
type CreateRepositoryOptions ¶
type CreateSSHKeyOptions ¶
type CreateTagOptions ¶ added in v0.4.0
type CreateTagOptions struct {
TagName string `json:"tag_name"`
Target string `json:"target"` // SHA
Message string `json:"message,omitempty"`
}
CreateTagOptions specifies options for creating a lightweight tag.
type CreateTeamOptions ¶ added in v0.4.0
type CreateTeamOptions struct {
Name string `json:"name"`
Description string `json:"description,omitempty"`
Permission string `json:"permission,omitempty"` // none, read, write, admin
Privacy string `json:"privacy,omitempty"` // closed, secret
CanCreateOrgRepo *bool `json:"can_create_org_repo,omitempty"`
ParentTeamID int64 `json:"parent_team_id,omitempty"`
}
CreateTeamOptions specifies options for creating a team.
type CreateWebhookOptions ¶
type CreateWikiPageOptions ¶ added in v0.4.0
type CreateWikiPageOptions struct {
Title string `json:"title"`
ContentBase64 string `json:"content_base64,omitempty"` // base64 encoded content
Message string `json:"message,omitempty"`
}
CreateWikiPageOptions specifies options for creating a wiki page.
type CustomizedRole ¶
type DeleteFileOptions ¶
type DeployKey ¶ added in v0.4.0
type DeployKey struct {
ID int64 `json:"id"`
Key string `json:"key"`
Title string `json:"title"`
CreatedAt time.Time `json:"created_at"`
ReadOnly bool `json:"read_only"`
URL string `json:"url,omitempty"`
}
DeployKey represents a repository deploy key.
type Discussion ¶ added in v0.4.0
type Discussion struct {
ID int64 `json:"id"`
Number int `json:"number"`
Title string `json:"title"`
Body string `json:"body"`
State string `json:"state"`
User *User `json:"user"`
Author *User `json:"author"`
Labels []*Label `json:"labels"`
HTMLURL string `json:"html_url,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
Discussion represents a repository discussion.
type DiscussionComment ¶ added in v0.4.0
type DiscussionComment struct {
ID int64 `json:"id"`
Body string `json:"body"`
User *User `json:"user"`
Author *User `json:"author"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
DiscussionComment represents a comment on a discussion.
type DiscussionCommentReply ¶ added in v0.4.0
type DiscussionCommentReply struct {
ID int64 `json:"id"`
Body string `json:"body"`
User *User `json:"user"`
Author *User `json:"author"`
ReplyToID int64 `json:"reply_to_id,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
DiscussionCommentReply represents a reply to a discussion comment.
type DownloadStatistic ¶
type EnterpriseCustomizedRole ¶ added in v0.5.0
type EnterpriseCustomizedRole struct {
ID int64 `json:"id"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
Permission string `json:"permission,omitempty"`
}
EnterpriseCustomizedRole represents a customized role in an enterprise.
type EnterpriseIssueStatus ¶ added in v0.4.0
type EnterpriseIssueStatus struct {
ID int64 `json:"id"`
Name string `json:"name"`
Color string `json:"color,omitempty"`
Sort int `json:"sort,omitempty"`
IsDefault bool `json:"is_default,omitempty"`
}
EnterpriseIssueStatus represents an enterprise-level issue status.
type EnterpriseLabel ¶
type EnterpriseMember ¶
type EnterpriseMilestone ¶ added in v0.5.0
type EnterpriseMilestone struct {
ID int64 `json:"id"`
Title string `json:"title"`
Description string `json:"description,omitempty"`
State string `json:"state"`
DueDate *time.Time `json:"due_date,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
EnterpriseMilestone represents an enterprise milestone.
type Error ¶
type ExtendedUser ¶ added in v0.4.0
type ExtendedUser struct {
ID int64 `json:"id"`
Login string `json:"login"`
Name string `json:"name"`
Email string `json:"email"`
AvatarURL string `json:"avatar_url"`
HTMLURL string `json:"html_url"`
Type string `json:"type"`
Bio string `json:"bio,omitempty"`
Location string `json:"location,omitempty"`
Website string `json:"website,omitempty"`
FullName string `json:"full_name,omitempty"`
FollowersCount int `json:"followers_count,omitempty"`
FollowingCount int `json:"following_count,omitempty"`
StarredReposCount int `json:"starred_repos_count,omitempty"`
Username string `json:"username,omitempty"`
}
ExtendedUser represents extended user information.
type FileListEntry ¶
type FileResult ¶
type FileResult struct {
Content *RepositoryContent `json:"content"`
Commit *Commit `json:"commit"`
}
type FileUploadResult ¶
type FileUploadResult struct {
FilePath string `json:"file_path"`
}
type FlexString ¶
type FlexString string
func (*FlexString) UnmarshalJSON ¶
func (fs *FlexString) UnmarshalJSON(data []byte) error
type ForkSyncStatus ¶ added in v0.4.0
type ForkSyncStatus struct {
Synced bool `json:"synced"`
BehindBy int `json:"behind_by"`
AheadBy int `json:"ahead_by"`
MergeBase string `json:"merge_base,omitempty"`
}
ForkSyncStatus represents the sync status of a forked repository.
type GitReference ¶ added in v0.4.0
type GitReference struct {
Ref string `json:"ref"`
URL string `json:"url"`
Object *GitObject `json:"object"`
}
GitReference represents a git reference.
type GitTree ¶
type GitTree struct {
SHA string `json:"sha"`
URL string `json:"url"`
Truncated bool `json:"truncated"`
Tree []*GitTreeEntry `json:"tree"`
}
type GitTreeEntry ¶
type GitignoreTemplate ¶ added in v0.4.0
GitignoreTemplate represents a gitignore template.
type InviteMemberOptions ¶
type Issue ¶
type Issue struct {
ID int64 `json:"id"`
Number FlexInt `json:"number"`
Title string `json:"title"`
Body string `json:"body"`
State IssueState `json:"state"`
User *User `json:"user"`
Author *User `json:"author"`
Assignees []*User `json:"assignees"`
Labels []*Label `json:"labels"`
Milestone *Milestone `json:"milestone"`
HTMLURL string `json:"html_url"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
ClosedAt *time.Time `json:"closed_at"`
}
type IssueAssigneeResult ¶ added in v0.4.0
type IssueAssigneeResult struct {
Assignees []*User `json:"assignees"`
}
IssueAssignee represents an issue assignee operation result.
type IssueComment ¶
type IssueCustomField ¶ added in v0.5.0
type IssueCustomField struct {
ID int64 `json:"id"`
Name string `json:"name"`
Type string `json:"type"`
Required bool `json:"required"`
Options []struct {
ID int64 `json:"id"`
Name string `json:"name"`
} `json:"options,omitempty"`
}
IssueCustomField represents a custom field for enterprise issues.
type IssueDependency ¶ added in v0.4.0
IssueDependency represents a dependency between issues.
type IssueExtendSetting ¶
type IssueExtendSetting struct {
TypeName string `json:"type_name"`
TypeID int `json:"type_id"`
TypeDesc string `json:"type_desc"`
Status []*struct {
StatusName string `json:"status_name"`
StatusID int `json:"status_id"`
StatusDesc string `json:"status_desc"`
GitcodeIssueStatus int `json:"gitcode_issue_status"`
} `json:"status"`
}
type IssueOperateLog ¶
type IssueRelatedBranch ¶ added in v0.4.0
type IssueRelatedBranch struct {
BranchName string `json:"branch_name"`
RepoName string `json:"repo_name,omitempty"`
}
IssueRelatedBranch represents a branch related to an issue.
type IssueState ¶
type IssueState string
const ( IssueStateOpen IssueState = "open" IssueStateClosed IssueState = "closed" )
type IssueSubscriber ¶ added in v0.4.0
type IssueSubscriber struct {
ID int64 `json:"id"`
Login string `json:"login"`
Name string `json:"name"`
AvatarURL string `json:"avatar_url"`
}
IssueSubscriber represents a user subscribed to an issue.
type IssueTemplate ¶ added in v0.4.0
type IssueTemplate struct {
Name string `json:"name"`
FileName string `json:"file_name,omitempty"`
Title string `json:"title"`
Body string `json:"body"`
Labels []string `json:"labels,omitempty"`
Assignees []string `json:"assignees,omitempty"`
Description string `json:"description,omitempty"`
}
IssueTemplate represents a repository issue template.
type IssueTimelineEvent ¶ added in v0.4.0
type IssueTimelineEvent struct {
ID int64 `json:"id"`
Action string `json:"action"`
Body string `json:"body,omitempty"`
User *User `json:"user"`
Author *User `json:"author"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
CommitID string `json:"commit_id,omitempty"`
EventType string `json:"event,omitempty"`
Label *Label `json:"label,omitempty"`
Milestone *Milestone `json:"milestone,omitempty"`
Rename *struct {
From string `json:"from"`
To string `json:"to"`
} `json:"rename,omitempty"`
}
IssueTimelineEvent represents an event in an issue's timeline.
type IssueUserReaction ¶ added in v0.4.0
type IssueUserReaction struct {
ID int64 `json:"id"`
Content string `json:"content"`
User *User `json:"user"`
CreatedAt time.Time `json:"created_at"`
}
IssueUserReaction represents a user's reaction to an issue.
type IssueWebhookEvent ¶
type IssueWebhookEvent struct {
Action string `json:"action"`
Issue *Issue `json:"issue"`
Repository *Repository `json:"repository"`
Sender *User `json:"sender"`
}
type KanbanBoard ¶ added in v0.5.0
type KanbanBoard struct {
ID int64 `json:"id"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
KanbanBoard represents a kanban board.
type KanbanBoardItem ¶ added in v0.5.0
type KanbanBoardItem struct {
ID int64 `json:"id"`
BoardID int64 `json:"board_id"`
IssueNumber int `json:"issue_number,omitempty"`
PRNumber int `json:"pr_number,omitempty"`
Status string `json:"status"`
Sort int `json:"sort,omitempty"`
}
KanbanBoardItem represents an item on a kanban board.
type KanbanBoardStatus ¶ added in v0.5.0
type KanbanBoardStatus struct {
ID int64 `json:"id"`
Name string `json:"name"`
Color string `json:"color,omitempty"`
Sort int `json:"sort,omitempty"`
IsDefault bool `json:"is_default,omitempty"`
}
KanbanBoardStatus represents a kanban board status.
type KanbanValue ¶ added in v0.4.0
type KanbanValue struct {
FieldID int64 `json:"field_id"`
FieldName string `json:"field_name"`
ValueID int64 `json:"value_id"`
ValueName string `json:"value_name"`
}
KanbanValue represents a kanban field value for an issue.
type LicenseTemplate ¶ added in v0.4.0
type LicenseTemplate struct {
Key string `json:"key"`
Name string `json:"name"`
URL string `json:"url,omitempty"`
HTMLURL string `json:"html_url,omitempty"`
HTMLContent string `json:"html_content,omitempty"`
Body string `json:"body,omitempty"`
Featured bool `json:"featured,omitempty"`
Conditions []string `json:"conditions,omitempty"`
Permissions []string `json:"permissions,omitempty"`
Limitations []string `json:"limitations,omitempty"`
}
LicenseTemplate represents a license template.
type ListActionRunsOptions ¶ added in v0.5.0
type ListActionRunsOptions struct {
ListOptions
Status string `json:"status,omitempty"` // queued, in_progress, completed
Branch string `json:"branch,omitempty"`
Event string `json:"event,omitempty"`
}
ListActionRunsOptions specifies options for listing action runs.
type ListBranchProtectionOptions ¶
type ListBranchProtectionOptions struct {
ListOptions
}
type ListCommitsOptions ¶
type ListCommitsOptions struct {
ListOptions
Branch string `json:"branch,omitempty"`
Since string `json:"since,omitempty"`
Until string `json:"until,omitempty"`
}
type ListEnterprisePRsOptions ¶
type ListEnterprisePRsOptions struct {
ListOptions
State string `json:"state,omitempty"`
IssueNumber int `json:"issue_number,omitempty"`
Sort string `json:"sort,omitempty"`
Direction string `json:"direction,omitempty"`
}
type ListIssuesOptions ¶
type ListIssuesOptions struct {
ListOptions
State IssueState `json:"state,omitempty"`
Assignee string `json:"assignee,omitempty"`
Creator string `json:"creator,omitempty"`
Milestone string `json:"milestone,omitempty"`
Labels string `json:"labels,omitempty"`
Sort string `json:"sort,omitempty"`
Direction string `json:"direction,omitempty"`
Since string `json:"since,omitempty"`
}
type ListMilestonesOptions ¶
type ListMilestonesOptions struct {
ListOptions
State string `json:"state,omitempty"`
Sort string `json:"sort,omitempty"`
Direction string `json:"direction,omitempty"`
}
type ListNotificationsOptions ¶ added in v0.4.0
type ListNotificationsOptions struct {
ListOptions
All bool `json:"all,omitempty"` // Include read notifications
Since string `json:"since,omitempty"` // Only notifications updated after this time
Before string `json:"before,omitempty"` // Only notifications updated before this time
Status string `json:"status,omitempty"` // unread, read, pinned
}
ListNotificationsOptions specifies options for listing notifications.
type ListOptions ¶
type ListPullRequestsOptions ¶
type ListPullRequestsOptions struct {
ListOptions
State PullRequestState `json:"state,omitempty"`
Sort string `json:"sort,omitempty"`
Direction string `json:"direction,omitempty"`
Head string `json:"head,omitempty"`
Base string `json:"base,omitempty"`
}
type ListRepositoriesOptions ¶
type ListRepositoriesOptions struct {
ListOptions
Owner string `json:"owner,omitempty"`
Type string `json:"type,omitempty"`
Sort string `json:"sort,omitempty"`
}
type ListStarredReposOptions ¶
type ListStarredReposOptions struct {
ListOptions
Sort string `json:"sort,omitempty"`
Direction string `json:"direction,omitempty"`
}
type ListUserIssuesOptions ¶
type MarkNotificationsOptions ¶ added in v0.4.0
type MarkNotificationsOptions struct {
LastReadAt string `json:"last_read_at,omitempty"` // ISO 8601 timestamp
All bool `json:"all,omitempty"`
}
MarkNotificationsOptions specifies options for marking notifications.
type MergePullRequestOptions ¶
type ModifyHistoryEntry ¶ added in v0.4.0
type ModifyHistoryEntry struct {
ID int64 `json:"id"`
Action string `json:"action"`
Field string `json:"field,omitempty"`
OldValue string `json:"old_value,omitempty"`
NewValue string `json:"new_value,omitempty"`
User *User `json:"user"`
Author *User `json:"author"`
CreatedAt time.Time `json:"created_at"`
}
ModifyHistoryEntry represents a modification history entry.
type ModuleSetting ¶
type NoteWebhookEvent ¶
type Notification ¶
type NotificationSubject ¶ added in v0.4.0
type NotificationSubject struct {
Title string `json:"title"`
URL string `json:"url"`
LatestCommentURL string `json:"latest_comment_url"`
Type string `json:"type"` // Issue, PullRequest, Commit, Repository
}
NotificationSubject represents the subject of a notification.
type NotificationThread ¶ added in v0.4.0
type NotificationThread struct {
ID int64 `json:"id"`
Unread bool `json:"unread"`
Pinned bool `json:"pinned,omitempty"`
UpdatedAt time.Time `json:"updated_at"`
Subject *NotificationSubject `json:"subject"`
Repository *Repository `json:"repository"`
URL string `json:"url"`
}
NotificationThread represents a detailed notification thread.
type NullableTime ¶
func (*NullableTime) UnmarshalJSON ¶
func (nt *NullableTime) UnmarshalJSON(data []byte) error
type OAuthClient ¶
type OAuthClient struct {
// contains filtered or unexported fields
}
func NewOAuthClient ¶
func NewOAuthClient(clientID, clientSecret, redirectURI string) *OAuthClient
func (*OAuthClient) AuthorizeURL ¶
func (o *OAuthClient) AuthorizeURL(scope, state string) string
func (*OAuthClient) ExchangeToken ¶
func (o *OAuthClient) ExchangeToken(ctx context.Context, code string) (*OAuthToken, error)
func (*OAuthClient) RefreshToken ¶
func (o *OAuthClient) RefreshToken(ctx context.Context, refreshToken string) (*OAuthToken, error)
func (*OAuthClient) SetBaseURL ¶
func (o *OAuthClient) SetBaseURL(baseURL string)
type OAuthToken ¶
type OrgCustomizedRole ¶ added in v0.4.0
type OrgCustomizedRole struct {
ID int64 `json:"id"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
Permission string `json:"permission,omitempty"`
}
OrgCustomizedRole represents a customized role in an organization.
type OrgDiscussion ¶ added in v0.4.0
type OrgDiscussion struct {
ID int64 `json:"id"`
Number int `json:"number"`
Title string `json:"title"`
Body string `json:"body"`
State string `json:"state"`
User *User `json:"user"`
Author *User `json:"author"`
Labels []*Label `json:"labels"`
HTMLURL string `json:"html_url,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
OrgDiscussion represents a discussion in an organization.
type OrgDiscussionComment ¶ added in v0.4.0
type OrgDiscussionComment struct {
ID int64 `json:"id"`
Body string `json:"body"`
User *User `json:"user"`
Author *User `json:"author"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
OrgDiscussionComment represents a comment on an organization discussion.
type OrgDiscussionCommentReply ¶ added in v0.4.0
type OrgDiscussionCommentReply struct {
ID int64 `json:"id"`
Body string `json:"body"`
User *User `json:"user"`
Author *User `json:"author"`
ReplyToID int64 `json:"reply_to_id,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
OrgDiscussionCommentReply represents a reply to an organization discussion comment.
type OrgEnterprise ¶ added in v0.5.0
type OrgEnterprise struct {
ID int64 `json:"id"`
Name string `json:"name"`
Path string `json:"path"`
URL string `json:"url"`
}
OrgEnterprise represents the enterprise associated with an organization.
type OrgFollowers ¶
type OrgLabel ¶ added in v0.4.0
type OrgLabel struct {
ID int64 `json:"id"`
Name string `json:"name"`
Color string `json:"color"`
Exclusive bool `json:"exclusive,omitempty"`
Template bool `json:"template,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
OrgLabel represents an organization-level label.
type OrgMemberDetail ¶
type OrgWebhook ¶ added in v0.4.0
type OrgWebhook struct {
ID int64 `json:"id"`
URL string `json:"url"`
Events []string `json:"events"`
Active bool `json:"active"`
Config *WebhookConfig `json:"config,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PushEvents bool `json:"push_events"`
TagPushEvents bool `json:"tag_push_events"`
IssuesEvents bool `json:"issues_events"`
NoteEvents bool `json:"note_events"`
MergeRequestsEvents bool `json:"merge_requests_events"`
}
OrgWebhook represents an organization webhook.
type Organization ¶
type PRDiscussionComment ¶ added in v0.4.0
type PRDiscussionComment struct {
ID int64 `json:"id"`
Body string `json:"body"`
User *User `json:"user"`
Author *User `json:"author"`
DiscussionID string `json:"discussion_id,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
PRDiscussionComment represents a reply to a PR review comment.
type PRMergeTemplate ¶ added in v0.4.0
PRMergeTemplate represents a pull request merge template.
type PROperateLog ¶
type PRSettings ¶
type ParticipationStats ¶ added in v0.4.0
ParticipationStats represents participation statistics (weekly commits).
type ProtectedTag ¶ added in v0.5.0
type ProtectedTag struct {
ID int64 `json:"id"`
NamePattern string `json:"name_pattern"`
Owners []*User `json:"owners,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
ProtectedTag represents a protected tag rule.
type PullRequest ¶
type PullRequest struct {
ID int64 `json:"id"`
Number int `json:"number"`
IID int `json:"iid,omitempty"`
Title string `json:"title"`
Body string `json:"body"`
Description string `json:"description,omitempty"`
State PullRequestState `json:"state"`
User *User `json:"user"`
Author *User `json:"author"`
Head *PullRequestBranch `json:"head"`
Base *PullRequestBranch `json:"base"`
Merged bool `json:"merged"`
Mergeable *bool `json:"mergeable"`
HTMLURL string `json:"html_url"`
DiffURL string `json:"diff_url,omitempty"`
PatchURL string `json:"patch_url,omitempty"`
Draft bool `json:"draft,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
ClosedAt NullableTime `json:"closed_at,omitempty"`
MergedAt NullableTime `json:"merged_at,omitempty"`
}
type PullRequestBranch ¶
type PullRequestComment ¶
type PullRequestComment struct {
ID FlexString `json:"id"`
Body string `json:"body"`
User *User `json:"user"`
Author *User `json:"author"`
Path string `json:"path"`
Position int `json:"position"`
Line int `json:"line"`
Side string `json:"side"`
CommitID string `json:"commit_id"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
type PullRequestDiff ¶ added in v0.4.0
type PullRequestDiff struct {
Content string `json:"content"`
}
PullRequestDiff represents the diff of a pull request.
type PullRequestFile ¶
type PullRequestFileChange ¶ added in v0.4.0
type PullRequestFileChange struct {
Filename string `json:"filename"`
PreviousFilename string `json:"previous_filename,omitempty"`
Status string `json:"status"`
Additions int `json:"additions"`
Deletions int `json:"deletions"`
Changes int `json:"changes"`
BlobURL string `json:"blob_url,omitempty"`
RawURL string `json:"raw_url,omitempty"`
ContentsURL string `json:"contents_url,omitempty"`
Patch string `json:"patch,omitempty"`
}
PullRequestFileChange represents a file change in a pull request (JSON format).
type PullRequestReview ¶
type PullRequestReviewRequest ¶ added in v0.4.0
type PullRequestReviewRequest struct {
Reviewers []string `json:"reviewers,omitempty"`
TeamReviewers []string `json:"team_reviewers,omitempty"`
}
PullRequestReviewRequest represents a review request.
type PullRequestState ¶
type PullRequestState string
const ( PullRequestStateOpen PullRequestState = "open" PullRequestStateOpened PullRequestState = "opened" PullRequestStateClosed PullRequestState = "closed" PullRequestStateMerged PullRequestState = "merged" )
type PullRequestWebhookEvent ¶
type PullRequestWebhookEvent struct {
Action string `json:"action"`
Number int `json:"number"`
PullRequest *PullRequest `json:"pull_request"`
Repository *Repository `json:"repository"`
Sender *User `json:"sender"`
}
type PunchCardEntry ¶ added in v0.4.0
type PunchCardEntry []int
PunchCardEntry represents a [day, hour, commits] tuple.
type PushConfig ¶
type Reaction ¶ added in v0.4.0
type Reaction struct {
ID int64 `json:"id"`
User *User `json:"user"`
Content string `json:"content"` // +1, -1, laugh, confused, heart, hooray, rocket, eyes
CreatedAt time.Time `json:"created_at"`
}
Reaction represents an emoji reaction.
type Release ¶
type Release struct {
ID int64 `json:"id"`
TagName string `json:"tag_name"`
TargetCommitish string `json:"target_commitish,omitempty"`
Name string `json:"name"`
Body string `json:"body"`
HTMLURL string `json:"html_url,omitempty"`
Draft bool `json:"draft"`
Prerelease bool `json:"prerelease"`
CreatedAt time.Time `json:"created_at"`
PublishedAt time.Time `json:"published_at,omitempty"`
}
type ReleaseAsset ¶ added in v0.4.0
type ReleaseAsset struct {
ID int64 `json:"id"`
Name string `json:"name"`
ContentType string `json:"content_type"`
Size int64 `json:"size"`
DownloadCount int `json:"download_count"`
BrowserDownloadURL string `json:"browser_download_url"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
ReleaseAsset represents a release asset.
type ReleaseUploadURL ¶ added in v0.5.0
type ReleaseUploadURL struct {
UploadURL string `json:"upload_url"`
AssetID int64 `json:"asset_id,omitempty"`
}
ReleaseUploadURL represents the upload URL for a release asset.
type RemoteMirror ¶ added in v0.4.0
type RemoteMirror struct {
ID int64 `json:"id"`
RemoteURL string `json:"remote_url"`
Enabled bool `json:"enabled"`
OnlyProtected bool `json:"only_protected"`
LastError string `json:"last_error,omitempty"`
LastUpdateAt string `json:"last_update_at,omitempty"`
}
RemoteMirror represents a remote mirror configuration.
type RepoBranchInfo ¶ added in v0.4.0
type RepoBranchInfo struct {
Name string `json:"name"`
Commit *struct {
SHA string `json:"sha"`
URL string `json:"url"`
} `json:"commit"`
Protected bool `json:"protected"`
}
RepoBranchInfo represents branch information for listing.
type RepoCLA ¶ added in v0.4.0
type RepoCLA struct {
ID int64 `json:"id"`
Name string `json:"name"`
Content string `json:"content,omitempty"`
Enabled bool `json:"enabled"`
}
RepoCLA represents a repository CLA (Contributor License Agreement).
type RepoInvitation ¶ added in v0.4.0
type RepoInvitation struct {
ID int64 `json:"id"`
Repo *Repository `json:"repo"`
Invitee *User `json:"invitee"`
Inviter *User `json:"inviter"`
Permission string `json:"permission"`
CreatedAt time.Time `json:"created_at"`
URL string `json:"url"`
HTMLURL string `json:"html_url,omitempty"`
}
RepoInvitation represents a repository invitation.
type RepoLicense ¶ added in v0.4.0
type RepoLicense struct {
Key string `json:"key"`
Name string `json:"name"`
URL string `json:"url,omitempty"`
HTMLURL string `json:"html_url,omitempty"`
Body string `json:"body,omitempty"`
}
RepoLicense represents a repository license.
type RepoSettings ¶
type RepoStats ¶ added in v0.4.0
type RepoStats struct {
Participation *ParticipationStats `json:"participation,omitempty"`
}
RepoStats represents repository statistics.
type Repository ¶
type Repository struct {
ID int64 `json:"id"`
FullName string `json:"full_name"`
Name string `json:"name"`
Path string `json:"path,omitempty"`
Owner *User `json:"owner"`
Namespace *struct {
ID int64 `json:"id"`
Name string `json:"name"`
Path string `json:"path"`
} `json:"namespace,omitempty"`
Description string `json:"description"`
CloneURL string `json:"http_url_to_repo"`
SSHURL string `json:"ssh_url_to_repo"`
HTMLURL string `json:"web_url"`
DefaultBranch string `json:"default_branch"`
Private bool `json:"private"`
Public bool `json:"public,omitempty"`
Fork bool `json:"fork"`
StarsCount int `json:"stargazers_count"`
ForksCount int `json:"forks_count"`
WatchersCount int `json:"watchers_count"`
OpenIssuesCount int `json:"open_issues_count"`
Language string `json:"language,omitempty"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PushedAt *time.Time `json:"pushed_at,omitempty"`
}
type RepositoryContent ¶
type RepositoryContent struct {
Name string `json:"name"`
Path string `json:"path"`
Size int64 `json:"size"`
Type string `json:"type"`
Content string `json:"content,omitempty"`
Encoding string `json:"encoding,omitempty"`
SHA string `json:"sha"`
Links struct {
Self string `json:"self"`
Git string `json:"git"`
} `json:"_links"`
}
type RepositoryTopics ¶ added in v0.4.0
type RepositoryTopics struct {
Topics []string `json:"topics"`
}
RepositoryTopics represents the topics of a repository.
type Reviewer ¶ added in v0.4.0
type Reviewer struct {
ID int64 `json:"id"`
Login string `json:"login"`
Name string `json:"name"`
AvatarURL string `json:"avatar_url"`
}
Reviewer represents a potential reviewer for a pull request.
type ReviewerConfig ¶
type RunActionWorkflowOptions ¶ added in v0.5.0
type RunActionWorkflowOptions struct {
Ref string `json:"ref"`
Inputs map[string]string `json:"inputs,omitempty"`
}
RunActionWorkflowOptions specifies options for manually running a workflow.
type RunnerGroup ¶ added in v0.5.0
type RunnerGroup struct {
ID int64 `json:"id"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
Visibility string `json:"visibility,omitempty"`
RunnersURL string `json:"runners_url,omitempty"`
}
RunnerGroup represents a runner group.
type SearchIssueResult ¶
type SearchIssueResult struct {
ID int64 `json:"id"`
HTMLURL string `json:"html_url"`
Number string `json:"number"`
State string `json:"state"`
Title string `json:"title"`
Body string `json:"body"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Labels []*Label `json:"labels"`
Priority int `json:"priority"`
Comments int `json:"comments"`
Repository *struct {
ID int64 `json:"id"`
FullName string `json:"full_name"`
HumanName string `json:"human_name"`
Path string `json:"path"`
Name string `json:"name"`
URL string `json:"url"`
Owner *User `json:"owner"`
} `json:"repository"`
}
type SearchIssuesOptions ¶
type SearchOptions ¶
type SearchOptions struct {
ListOptions
Query string `json:"q"`
Order string `json:"order,omitempty"`
}
type SearchRepositoryResult ¶
type SearchRepositoryResult struct {
ID int64 `json:"id"`
FullName string `json:"full_name"`
HumanName string `json:"human_name"`
Path string `json:"path"`
Name string `json:"name"`
Description string `json:"description"`
SSHURLToRepo string `json:"ssh_url_to_repo"`
HTTPURLToRepo string `json:"http_url_to_repo"`
WebURL string `json:"web_url"`
ForksCount int `json:"forks_count"`
StargazersCount int `json:"stargazers_count"`
WatchersCount int `json:"watchers_count"`
DefaultBranch string `json:"default_branch"`
OpenIssuesCount int `json:"open_issues_count"`
Private bool `json:"private"`
Public bool `json:"public"`
Fork bool `json:"fork"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PushedAt string `json:"pushed_at"`
Owner *User `json:"owner"`
Namespace *struct {
ID int64 `json:"id"`
Type string `json:"type"`
Name string `json:"name"`
Path string `json:"path"`
HTMLURL string `json:"html_url"`
} `json:"namespace"`
}
type SearchResult ¶
type SearchResult struct {
TotalCount int `json:"total_count"`
Items []*Repository `json:"items"`
}
type SearchUserResult ¶
type SearchUsersOptions ¶
type SearchUsersOptions struct {
ListOptions
Query string `json:"q"`
Sort string `json:"sort,omitempty"`
Order string `json:"order,omitempty"`
}
type TagPushEvent ¶
type TagPushEvent struct {
Ref string `json:"ref"`
Before string `json:"before"`
After string `json:"after"`
Repository *Repository `json:"repository"`
Sender *User `json:"sender"`
}
type TagWithRelease ¶ added in v0.4.0
type TagWithRelease struct {
Name string `json:"name"`
Message string `json:"message,omitempty"`
Commit *struct {
SHA string `json:"sha"`
URL string `json:"url"`
} `json:"commit"`
ZipballURL string `json:"zipball_url,omitempty"`
TarballURL string `json:"tarball_url,omitempty"`
CreatedAt time.Time `json:"created_at,omitempty"`
}
TagWithRelease represents a tag with its associated release info.
type Team ¶ added in v0.4.0
type Team struct {
ID int64 `json:"id"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
Permission string `json:"permission,omitempty"` // read, write, admin
Privacy string `json:"privacy,omitempty"` // closed, secret
CanCreateOrgRepo bool `json:"can_create_org_repo,omitempty"`
HTMLURL string `json:"html_url,omitempty"`
Parent *Team `json:"parent,omitempty"`
}
Team represents an organization team.
type TeamMember ¶ added in v0.4.0
type TeamMember struct {
ID int64 `json:"id"`
Login string `json:"login"`
Name string `json:"name"`
Email string `json:"email"`
AvatarURL string `json:"avatar_url"`
CreatedAt time.Time `json:"created_at"`
}
TeamMember represents a team member.
type Timestamp ¶
func (*Timestamp) UnmarshalJSON ¶
type TransferRepoOptions ¶
type TransferRepoOptions struct {
NewOwner string `json:"new_owner"`
}
type UpdateCommitCommentOptions ¶ added in v0.4.0
type UpdateCommitCommentOptions struct {
Body string `json:"body"`
}
UpdateCommitCommentOptions specifies options for updating a commit comment.
type UpdateCurrentUserOptions ¶ added in v0.4.0
type UpdateCurrentUserOptions struct {
Name string `json:"name,omitempty"`
Email string `json:"email,omitempty"`
Bio string `json:"bio,omitempty"`
Location string `json:"location,omitempty"`
Website string `json:"website,omitempty"`
}
UpdateCurrentUserOptions specifies options for updating the authenticated user's profile.
type UpdateEnterpriseLabelOptions ¶ added in v0.5.0
type UpdateEnterpriseLabelOptions struct {
Name string `json:"name,omitempty"`
Color string `json:"color,omitempty"`
}
UpdateEnterpriseLabelOptions specifies options for updating an enterprise label.
type UpdateEnterpriseMemberOptions ¶
type UpdateEnterpriseMemberOptions struct {
Role string `json:"role"`
}
type UpdateEnterpriseMilestoneOptions ¶ added in v0.5.0
type UpdateEnterpriseMilestoneOptions struct {
Title string `json:"title,omitempty"`
Description string `json:"description,omitempty"`
State string `json:"state,omitempty"`
DueOn string `json:"due_on,omitempty"`
}
UpdateEnterpriseMilestoneOptions specifies options for updating an enterprise milestone.
type UpdateFileOptions ¶
type UpdateIssueOptions ¶
type UpdateIssueOptions struct {
Title string `json:"title,omitempty"`
Body string `json:"body,omitempty"`
State IssueState `json:"state,omitempty"`
StateEvent string `json:"state_event,omitempty"`
Assignee string `json:"assignee,omitempty"`
Assignees []string `json:"assignees,omitempty"`
Milestone int64 `json:"milestone,omitempty"`
Labels []string `json:"labels,omitempty"`
}
type UpdateKanbanBoardItemOptions ¶ added in v0.5.0
type UpdateKanbanBoardItemOptions struct {
Status string `json:"status,omitempty"`
Sort int `json:"sort,omitempty"`
}
UpdateKanbanBoardItemOptions specifies options for updating a kanban board item.
type UpdateKanbanBoardStatusOptions ¶ added in v0.5.0
type UpdateKanbanBoardStatusOptions struct {
Statuses []KanbanBoardStatus `json:"statuses"`
}
UpdateKanbanBoardStatusOptions specifies options for updating a kanban board status.
type UpdateLabelOptions ¶
type UpdateMemberOptions ¶
type UpdateMemberOptions struct {
Permission string `json:"permission"`
}
type UpdateMilestoneOptions ¶
type UpdateOrgLabelOptions ¶ added in v0.4.0
type UpdateOrgLabelOptions struct {
Name string `json:"name,omitempty"`
Color string `json:"color,omitempty"`
Exclusive *bool `json:"exclusive,omitempty"`
Template *bool `json:"template,omitempty"`
}
UpdateOrgLabelOptions specifies options for updating an organization label.
type UpdateOrgOptions ¶
type UpdateOrgWebhookOptions ¶ added in v0.4.0
type UpdateOrgWebhookOptions struct {
URL string `json:"url,omitempty"`
Secret string `json:"secret,omitempty"`
Events []string `json:"events,omitempty"`
Active *bool `json:"active,omitempty"`
Config *WebhookConfig `json:"config,omitempty"`
}
UpdateOrgWebhookOptions specifies options for updating an organization webhook.
type UpdateProtectedTagOptions ¶ added in v0.5.0
type UpdateProtectedTagOptions struct {
NamePattern string `json:"name_pattern,omitempty"`
Owners []string `json:"owners,omitempty"`
}
UpdateProtectedTagOptions specifies options for updating a protected tag.
type UpdatePullRequestOptions ¶
type UpdatePullRequestOptions struct {
Title string `json:"title,omitempty"`
Body string `json:"body,omitempty"`
State PullRequestState `json:"state,omitempty"`
StateEvent string `json:"state_event,omitempty"`
Base string `json:"base,omitempty"`
}
type UpdateReferenceOptions ¶ added in v0.4.0
UpdateReferenceOptions specifies options for updating a reference.
type UpdateReleaseOptions ¶ added in v0.4.0
type UpdateReleaseOptions struct {
TagName string `json:"tag_name,omitempty"`
TargetCommitish string `json:"target_commitish,omitempty"`
Name string `json:"name,omitempty"`
Body string `json:"body,omitempty"`
Draft *bool `json:"draft,omitempty"`
Prerelease *bool `json:"prerelease,omitempty"`
}
UpdateReleaseOptions specifies options for updating a release.
type UpdateRepositoryOptions ¶
type UpdateTeamOptions ¶ added in v0.4.0
type UpdateTeamOptions struct {
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
Permission string `json:"permission,omitempty"`
Privacy string `json:"privacy,omitempty"`
CanCreateOrgRepo *bool `json:"can_create_org_repo,omitempty"`
ParentTeamID int64 `json:"parent_team_id,omitempty"`
}
UpdateTeamOptions specifies options for updating a team.
type UpdateWebhookOptions ¶
type UpdateWikiPageOptions ¶ added in v0.4.0
type UpdateWikiPageOptions struct {
ContentBase64 string `json:"content_base64,omitempty"` // base64 encoded content
Message string `json:"message,omitempty"`
}
UpdateWikiPageOptions specifies options for updating a wiki page.
type UserEvent ¶
type UserEvent struct {
Action int `json:"action"`
ActionName string `json:"action_name"`
AuthorID int64 `json:"author_id"`
AuthorUsername string `json:"author_username"`
ProjectID int64 `json:"project_id"`
ProjectName string `json:"project_name"`
CreatedAt string `json:"created_at"`
PushData *struct {
CommitCount int `json:"commit_count"`
Action string `json:"action"`
RefType string `json:"ref_type"`
Ref string `json:"ref"`
CommitFrom string `json:"commit_from"`
CommitTo string `json:"commit_to"`
CommitTitle string `json:"commit_title"`
} `json:"push_data"`
}
type UserEventsResponse ¶
type UserMembership ¶
type UserMembership struct {
ID int64 `json:"id"`
Path string `json:"path"`
Name string `json:"name"`
URL string `json:"url"`
AvatarURL string `json:"avatar_url"`
User *User `json:"user"`
Active bool `json:"active"`
Role string `json:"role"`
Organization *struct {
ID int64 `json:"id"`
Login string `json:"login"`
Name string `json:"name"`
} `json:"organization"`
}
type Webhook ¶
type Webhook struct {
ID int64 `json:"id"`
URL string `json:"url"`
Events []string `json:"events"`
PushEvents bool `json:"push_events"`
TagPushEvents bool `json:"tag_push_events"`
IssuesEvents bool `json:"issues_events"`
MergeRequestsEvents bool `json:"merge_requests_events"`
NoteEvents bool `json:"note_events"`
Active bool `json:"active"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
type WebhookConfig ¶ added in v0.4.0
type WebhookConfig struct {
URL string `json:"url"`
ContentType string `json:"content_type,omitempty"`
Secret string `json:"secret,omitempty"`
InsecureSSL bool `json:"insecure_ssl,omitempty"`
}
WebhookConfig represents the configuration of a webhook.
type WebhookEvent ¶
type WikiPage ¶ added in v0.4.0
type WikiPage struct {
Title string `json:"title"`
Content string `json:"content,omitempty"`
HTMLURL string `json:"html_url,omitempty"`
CommitSHA string `json:"commit_sha,omitempty"`
Sidebar string `json:"sidebar,omitempty"`
LastCommit *struct {
SHA string `json:"sha"`
Message string `json:"message"`
} `json:"last_commit,omitempty"`
}
WikiPage represents a wiki page.
Source Files
¶
- actions.go
- branches.go
- client.go
- commits_enhanced.go
- dashboard_kanban.go
- enterprise.go
- enterprise_issues.go
- git_refs.go
- git_tags.go
- issues.go
- issues_enhanced.go
- labels.go
- milestones.go
- misc.go
- notifications_enhanced.go
- oauth.go
- org_hooks.go
- org_labels.go
- org_members_enhanced.go
- org_teams.go
- orgs.go
- orgs_enhanced.go
- pulls.go
- pulls_enhanced.go
- releases_enhanced.go
- repos.go
- repos_archive.go
- repos_assignees.go
- repos_collaborators.go
- repos_commits_comments.go
- repos_deploy_keys.go
- repos_discussions.go
- repos_invitations.go
- repos_issues_timeline.go
- repos_protected_tags.go
- repos_reactions.go
- repos_reviewers.go
- repos_statuses.go
- repos_templates.go
- repos_topics.go
- repos_wiki.go
- search.go
- types.go
- user_followers.go
- users.go
- users_enhanced.go
- webhooks.go