Package org.kohsuke.github
Class GHEventPayload
- java.lang.Object
-
- org.kohsuke.github.GHEventPayload
-
- Direct Known Subclasses:
GHEventPayload.CheckRun,GHEventPayload.CheckSuite,GHEventPayload.CommitComment,GHEventPayload.Create,GHEventPayload.Delete,GHEventPayload.Deployment,GHEventPayload.DeploymentStatus,GHEventPayload.Discussion,GHEventPayload.Fork,GHEventPayload.Installation,GHEventPayload.InstallationRepositories,GHEventPayload.Issue,GHEventPayload.IssueComment,GHEventPayload.Label,GHEventPayload.Ping,GHEventPayload.ProjectsV2Item,GHEventPayload.Public,GHEventPayload.PullRequest,GHEventPayload.PullRequestReview,GHEventPayload.PullRequestReviewComment,GHEventPayload.Push,GHEventPayload.Release,GHEventPayload.Repository,GHEventPayload.Star,GHEventPayload.Status,GHEventPayload.WorkflowDispatch,GHEventPayload.WorkflowJob,GHEventPayload.WorkflowRun
public abstract class GHEventPayload extends Object
Base type for types used in databinding of the event payload.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classGHEventPayload.CheckRunA check run event has been created, rerequested, completed, or has a requested_action.static classGHEventPayload.CheckSuiteA check suite event has been requested, rerequested or completed.static classGHEventPayload.CommentChangesWrapper for changes on issue and pull request review comments action="edited".static classGHEventPayload.CommitCommentA comment was added to a commit.static classGHEventPayload.CreateA repository, branch, or tag was created.static classGHEventPayload.DeleteA branch, or tag was deleted.static classGHEventPayload.DeploymentA deployment.static classGHEventPayload.DeploymentStatusA deployment status.static classGHEventPayload.DiscussionA discussion was created, edited, deleted, pinned, unpinned, locked, unlocked, transferred, category_changed, answered, or unanswered.static classGHEventPayload.ForkA user forked a repository.static classGHEventPayload.InstallationAn installation has been installed, uninstalled, or its permissions have been changed.static classGHEventPayload.InstallationRepositoriesA repository has been added or removed from an installation.static classGHEventPayload.IssueA Issue has been assigned, unassigned, labeled, unlabeled, opened, edited, milestoned, demilestoned, closed, or reopened.static classGHEventPayload.IssueCommentA comment was added to an issue.static classGHEventPayload.LabelA label was created, edited or deleted.static classGHEventPayload.PingA ping.static classGHEventPayload.ProjectsV2ItemA project v2 item was archived, converted, created, edited, restored, deleted, or reordered.static classGHEventPayload.PublicA repository was made public.static classGHEventPayload.PullRequestA pull request status has changed.static classGHEventPayload.PullRequestReviewA review was added to a pull request.static classGHEventPayload.PullRequestReviewCommentA review comment was added to a pull request.static classGHEventPayload.PushA commit was pushed.static classGHEventPayload.ReleaseA release was added to the repo.static classGHEventPayload.RepositoryA repository was created, deleted, made public, or made private.static classGHEventPayload.StarA star was created or deleted on a repository.static classGHEventPayload.StatusA git commit status was changed.static classGHEventPayload.WorkflowDispatchOccurs when someone triggered a workflow run or sends a POST request to the "Create a workflow dispatch event" endpoint.static classGHEventPayload.WorkflowJobA workflow job has been queued, is in progress, or has been completed.static classGHEventPayload.WorkflowRunA workflow run was requested or completed.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description StringgetAction()Gets the action for the triggered event.GHAppInstallationgetInstallation()Gets installation.GHOrganizationgetOrganization()Gets organization.GHRepositorygetRepository()Gets repository.GitHubgetRoot()Deprecated.For access to theGitHubinstance, use a local copy instead of pulling it out of objects.GHUsergetSender()Gets the sender ornullif accessed via the events API.voidsetOrganization(GHOrganization organization)Deprecated.Do not use this method.voidsetRepository(GHRepository repository)Deprecated.Do not use this method.voidsetSender(GHUser sender)Deprecated.Do not use this method.
-
-
-
Method Detail
-
getAction
public String getAction()
Gets the action for the triggered event. Most but not all webhook payloads contain an action property that contains the specific activity that triggered the event.- Returns:
- event action
-
getSender
public GHUser getSender()
Gets the sender ornullif accessed via the events API.- Returns:
- the sender or
nullif accessed via the events API.
-
setSender
@Deprecated public void setSender(GHUser sender)
Deprecated.Do not use this method. It was added due to incomplete understanding of Jackson binding.Sets sender.- Parameters:
sender- the sender
-
getRepository
public GHRepository getRepository()
Gets repository.- Returns:
- the repository
-
setRepository
@Deprecated public void setRepository(GHRepository repository)
Deprecated.Do not use this method. It was added due to incomplete understanding of Jackson binding.Sets repository.- Parameters:
repository- the repository
-
getOrganization
public GHOrganization getOrganization()
Gets organization.- Returns:
- the organization
-
setOrganization
@Deprecated public void setOrganization(GHOrganization organization)
Deprecated.Do not use this method. It was added due to incomplete understanding of Jackson binding.Sets organization.- Parameters:
organization- the organization
-
getInstallation
public GHAppInstallation getInstallation()
Gets installation.- Returns:
- the installation
-
getRoot
@Deprecated public GitHub getRoot()
Deprecated.For access to theGitHubinstance, use a local copy instead of pulling it out of objects.Get the rootGitHubinstance for this object.- Returns:
- the root
GitHubinstance
-
-