Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Consumers = map[string]func(EventPayload) error{ string(Install): consumeInstallEvent, string(Ping): consumePingEvent, string(Push): consumePushEvent, string(PullRequest): consumePullRequestEvent, }
View Source
var Events = []Event{ Install, Ping, Push, PullRequest, }
Functions ¶
func ConsumeEvent ¶
func VerifySignature ¶
Types ¶
type EventPayload ¶
type EventPayload struct { Ref string `json:"ref"` Before string `json:"before"` After string `json:"after"` Repository struct { ID int `json:"id"` Name string `json:"name"` FullName string `json:"full_name"` Private bool `json:"private"` Owner struct { Name string `json:"name"` Email string `json:"email"` Login string `json:"login"` ID int `json:"id"` } `json:"owner"` } `json:"repository"` Pusher struct { Name string `json:"name"` Email string `json:"email"` } `json:"pusher"` Commits []struct { ID string `json:"id"` TreeID string `json:"tree_id"` Message string `json:"message"` Timestamp time.Time `json:"timestamp"` Author struct { Name string `json:"name"` Email string `json:"email"` Username string `json:"username"` } `json:"author"` Committer struct { Name string `json:"name"` Email string `json:"email"` Username string `json:"username"` } `json:"committer"` Added []string `json:"added"` Removed []interface{} `json:"removed"` Modified []string `json:"modified"` } `json:"commits"` HeadCommit struct { ID string `json:"id"` TreeID string `json:"tree_id"` Message string `json:"message"` Timestamp time.Time `json:"timestamp"` Author struct { Name string `json:"name"` Email string `json:"email"` Username string `json:"username"` } `json:"author"` Committer struct { Name string `json:"name"` Email string `json:"email"` Username string `json:"username"` } `json:"committer"` Added []string `json:"added"` Removed []interface{} `json:"removed"` Modified []string `json:"modified"` } `json:"head_commit"` }
Click to show internal directories.
Click to hide internal directories.