Enum EventType

Source
pub enum EventType {
Show 44 variants Wildcard, Ping, CheckRun, CheckSuite, CommitComment, ContentReference, Create, Delete, Deployment, DeploymentStatus, Fork, GitHubAppAuthorization, Gollum, Installation, IntegrationInstallation, InstallationRepositories, IntegrationInstallationRepositories, IssueComment, Issues, Label, MarketplacePurchase, Member, Membership, Milestone, Organization, OrgBlock, PageBuild, ProjectCard, ProjectColumn, Project, Public, PullRequest, PullRequestReviewComment, PullRequestReview, Push, Release, Repository, RepositoryImport, RepositoryVulnerabilityAlert, SecurityAdvisory, Status, Team, TeamAdd, Watch,
}
Expand description

GitHub events that are specified in the X-Github-Event header.

Variants§

§

Wildcard

(Special event.) Any time any event is triggered (Wildcard Event).

§

Ping

(Special event.) Sent when a webhook is added.

§

CheckRun

Triggered when a check run is created, rerequested, completed, or has a requested_action.

§

CheckSuite

Triggered when a check suite is completed, requested, or rerequested.

§

CommitComment

Any time a Commit is commented on.

§

ContentReference

Triggered when the body or comment of an issue or pull request includes a URL that matches a configured content reference domain. Only GitHub Apps can receive this event.

§

Create

Any time a Branch or Tag is created.

§

Delete

Any time a Branch or Tag is deleted.

§

Deployment

Any time a Repository has a new deployment created from the API.

§

DeploymentStatus

Any time a deployment for a Repository has a status update from the API.

§

Fork

Any time a Repository is forked.

§

GitHubAppAuthorization

Triggered when someone revokes their authorization of a GitHub App.

§

Gollum

Any time a Wiki page is updated.

§

Installation

Any time a GitHub App is installed or uninstalled.

§

IntegrationInstallation

Same as Installation, but deprecated. This event is sent alongside the Installation event, but can always be ignored.

§

InstallationRepositories

Any time a repository is added or removed from an installation.

§

IntegrationInstallationRepositories

Same as InstallationRepositories, but deprecated. This event is sent alongside the InstallationRepositories event, but can always be ignored.

§

IssueComment

Any time a comment on an issue is created, edited, or deleted.

§

Issues

Any time an Issue is assigned, unassigned, labeled, unlabeled, opened, edited, milestoned, demilestoned, closed, or reopened.

§

Label

Any time a Label is created, edited, or deleted.

§

MarketplacePurchase

Any time a user purchases, cancels, or changes their GitHub Marketplace plan.

§

Member

Any time a User is added or removed as a collaborator to a Repository, or has their permissions modified.

§

Membership

Any time a User is added or removed from a team. Organization hooks only.

§

Milestone

Any time a Milestone is created, closed, opened, edited, or deleted.

§

Organization

Any time a user is added, removed, or invited to an Organization. Organization hooks only.

§

OrgBlock

Any time an organization blocks or unblocks a user. Organization hooks only.

§

PageBuild

Any time a Pages site is built or results in a failed build.

§

ProjectCard

Any time a Project Card is created, edited, moved, converted to an issue, or deleted.

§

ProjectColumn

Any time a Project Column is created, edited, moved, or deleted.

§

Project

Any time a Project is created, edited, closed, reopened, or deleted.

§

Public

Any time a Repository changes from private to public.

§

PullRequest

Any time a pull request is assigned, unassigned, labeled, unlabeled, opened, edited, closed, reopened, or synchronized (updated due to a new push in the branch that the pull request is tracking). Also any time a pull request review is requested, or a review request is removed.

§

PullRequestReviewComment

Any time a comment on a pull request’s unified diff is created, edited, or deleted (in the Files Changed tab).

§

PullRequestReview

Any time a pull request review is submitted, edited, or dismissed.

§

Push

Any Git push to a Repository, including editing tags or branches. Commits via API actions that update references are also counted. This is the default event.

§

Release

Any time a Release is published in a Repository.

§

Repository

Any time a Repository is created, deleted (organization hooks only), archived, unarchived, made public, or made private.

§

RepositoryImport

Triggered when a successful, cancelled, or failed repository import finishes for a GitHub organization or a personal repository. To receive this event for a personal repository, you must create an empty repository prior to the import. This event can be triggered using either the GitHub Importer or the Source imports API.

§

RepositoryVulnerabilityAlert

Triggered when a security alert is created, dismissed, or resolved.

§

SecurityAdvisory

Triggered when a new security advisory is published, updated, or withdrawn. A security advisory provides information about security-related vulnerabilities in software on GitHub. Security Advisory webhooks are available to GitHub Apps only.

§

Status

Any time a Repository has a status update from the API.

§

Team

Any time a team is created, deleted, modified, or added to or removed from a repository. Organization hooks only

§

TeamAdd

Any time a team is added or modified on a Repository.

§

Watch

Any time a User stars a Repository.

Implementations§

Source§

impl EventType

Source

pub fn name(self) -> &'static str

Returns a static string for the event name.

Trait Implementations§

Source§

impl Clone for EventType

Source§

fn clone(&self) -> EventType

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for EventType

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for EventType

Source§

fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
where D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Display for EventType

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl FromStr for EventType

Source§

type Err = &'static str

The associated error which can be returned from parsing.
Source§

fn from_str(s: &str) -> Result<Self, Self::Err>

Parses a string s to return a value of this type. Read more
Source§

impl Hash for EventType

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Ord for EventType

Source§

fn cmp(&self, other: &EventType) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · Source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized,

Restrict a value to a certain interval. Read more
Source§

impl PartialEq for EventType

Source§

fn eq(&self, other: &EventType) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl PartialOrd for EventType

Source§

fn partial_cmp(&self, other: &EventType) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · Source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · Source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · Source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · Source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl Copy for EventType

Source§

impl Eq for EventType

Source§

impl StructuralPartialEq for EventType

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,