Skip to content

Commit

Permalink
Merge pull request #62 from Shredder121/organization-property
Browse files Browse the repository at this point in the history
Add Organization property to the payloads
  • Loading branch information
Shredder121 committed Feb 22, 2016
2 parents 38612c8 + c24cf0a commit ac936b0
Show file tree
Hide file tree
Showing 42 changed files with 379 additions and 40 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand All @@ -42,6 +43,12 @@ public class PublicPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user who triggered the event.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Comment;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand Down Expand Up @@ -53,6 +54,12 @@ public class CommitCommentPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The actor commenting on the commit.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand Down Expand Up @@ -68,6 +69,12 @@ public class CreatePayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that created the object.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand Down Expand Up @@ -58,6 +59,12 @@ public class DeletePayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that deleted the object.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Deployment;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand Down Expand Up @@ -48,6 +49,12 @@ public class DeploymentPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that requested the deployment.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Deployment;
import com.github.shredder121.gh_event_api.model.DeploymentStatus;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.*;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;

/**
Expand Down Expand Up @@ -54,6 +51,12 @@ public class DeploymentStatusPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that triggered the event.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand Down Expand Up @@ -47,6 +48,12 @@ public class ForkPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The actor forking the Repository.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.WikiPage;
Expand Down Expand Up @@ -49,6 +50,12 @@ public class GollumPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that triggered the change.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Comment;
import com.github.shredder121.gh_event_api.model.Issue;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.*;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;

/**
Expand Down Expand Up @@ -60,6 +57,12 @@ public class IssueCommentPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user commenting on the issue.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Issue;
import com.github.shredder121.gh_event_api.model.Label;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.*;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;

/**
Expand Down Expand Up @@ -54,6 +51,12 @@ public class IssuesPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that created the issue.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Team;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand Down Expand Up @@ -59,6 +60,11 @@ public class MembershipPayload {
*/
@NotNull Team team;

/**
* The organization the team belongs to.
*/
@NotNull Organization organization;

/**
* The person that triggered the event.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.PageBuild;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
Expand Down Expand Up @@ -53,6 +54,12 @@ public class PageBuildPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that triggered the build.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Label;
import com.github.shredder121.gh_event_api.model.PullRequest;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.*;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;

/**
Expand Down Expand Up @@ -59,6 +56,12 @@ public class PullRequestPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The User that invoked the action.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Comment;
import com.github.shredder121.gh_event_api.model.PullRequest;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.*;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;

/**
Expand Down Expand Up @@ -60,6 +57,12 @@ public class PullRequestReviewCommentPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that invoked the action.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.PushCommit;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
import com.google.common.collect.ImmutableList;

Expand Down Expand Up @@ -76,4 +79,20 @@ public class PushPayload {
* The first commit in this push.
*/
PushCommit headCommit;

/**
* The repository that was pushed to.
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user who triggered the event.
*/
@NotNull User sender;
}
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Release;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
Expand Down Expand Up @@ -54,6 +55,12 @@ public class ReleasePayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
* Only non-null with organization webhooks.
*/
Organization organization;

/**
* The user that triggered the release.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.fasterxml.jackson.databind.PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming;
import com.github.shredder121.gh_event_api.model.Organization;
import com.github.shredder121.gh_event_api.model.Repository;
import com.github.shredder121.gh_event_api.model.User;
import com.github.shredder121.gh_event_api.model.json.PropertyBasedJsonCreator;
Expand Down Expand Up @@ -48,6 +49,11 @@ public class RepositoryPayload {
*/
@NotNull Repository repository;

/**
* The organization the repository belongs to.
*/
@NotNull Organization organization;

/**
* The user who triggered the request.
*/
Expand Down
Loading

0 comments on commit ac936b0

Please sign in to comment.