72 lines
1.9 KiB
Go
72 lines
1.9 KiB
Go
|
package cihook
|
||
|
|
||
|
import "time"
|
||
|
|
||
|
type PipelineEvent struct {
|
||
|
ID string `json:"id"`
|
||
|
EventType string `json:"eventType"`
|
||
|
PublisherID string `json:"publisherId"`
|
||
|
Message struct {
|
||
|
Text string `json:"text"`
|
||
|
HTML string `json:"html"`
|
||
|
Markdown string `json:"markdown"`
|
||
|
} `json:"message"`
|
||
|
DetailedMessage struct {
|
||
|
Text string `json:"text"`
|
||
|
HTML string `json:"html"`
|
||
|
Markdown string `json:"markdown"`
|
||
|
} `json:"detailedMessage"`
|
||
|
Resource struct {
|
||
|
Run struct {
|
||
|
Links struct {
|
||
|
Self struct {
|
||
|
Href string `json:"href"`
|
||
|
} `json:"self"`
|
||
|
Web struct {
|
||
|
Href string `json:"href"`
|
||
|
} `json:"web"`
|
||
|
PipelineWeb struct {
|
||
|
Href string `json:"href"`
|
||
|
} `json:"pipeline.web"`
|
||
|
Pipeline struct {
|
||
|
Href string `json:"href"`
|
||
|
} `json:"pipeline"`
|
||
|
} `json:"_links"`
|
||
|
Pipeline struct {
|
||
|
URL string `json:"url"`
|
||
|
ID int `json:"id"`
|
||
|
Revision int `json:"revision"`
|
||
|
Name string `json:"name"`
|
||
|
Folder string `json:"folder"`
|
||
|
} `json:"pipeline"`
|
||
|
State string `json:"state"`
|
||
|
Result string `json:"result"`
|
||
|
CreatedDate time.Time `json:"createdDate"`
|
||
|
FinishedDate time.Time `json:"finishedDate"`
|
||
|
URL string `json:"url"`
|
||
|
ID int `json:"id"`
|
||
|
Name string `json:"name"`
|
||
|
} `json:"run"`
|
||
|
Pipeline struct {
|
||
|
URL string `json:"url"`
|
||
|
ID int `json:"id"`
|
||
|
Revision int `json:"revision"`
|
||
|
Name string `json:"name"`
|
||
|
Folder string `json:"folder"`
|
||
|
} `json:"pipeline"`
|
||
|
} `json:"resource"`
|
||
|
ResourceVersion string `json:"resourceVersion"`
|
||
|
ResourceContainers struct {
|
||
|
Collection struct {
|
||
|
ID string `json:"id"`
|
||
|
} `json:"collection"`
|
||
|
Account struct {
|
||
|
ID string `json:"id"`
|
||
|
} `json:"account"`
|
||
|
Project struct {
|
||
|
ID string `json:"id"`
|
||
|
} `json:"project"`
|
||
|
} `json:"resourceContainers"`
|
||
|
CreatedDate time.Time `json:"createdDate"`
|
||
|
}
|