contractor/internal/models/requests.go
kjuulh 65fba21285
Some checks failed
continuous-integration/drone/pr Build is passing
continuous-integration/drone/push Build is failing
refactor(app): split the main command file into multiples
Signed-off-by: kjuulh <contact@kjuulh.io>
2023-08-08 19:41:19 +02:00

41 lines
1.3 KiB
Go

package models
const (
MessageTypeRefreshRepository = "refresh_repository"
MessageTypeRefreshRepositoryDone = "refresh_repository_done"
)
type CreateHook struct {
Active bool `json:"active"`
AuthorizationHeader string `json:"authorization_header"`
BranchFilter string `json:"branch_filter"`
Config map[string]string `json:"config"`
Events []string `json:"events"`
Type string `json:"type"`
}
type RefreshRepositoryRequest struct {
Repository string `json:"repository"`
Owner string `json:"owner"`
PullRequestID int `json:"pullRequestId"`
CommentID int `json:"commentId"`
CommentBody string `json:"commentBody"`
ReportProgress bool `json:"reportProgress"`
}
type RefreshDoneRepositoryRequest struct {
Repository string `json:"repository"`
Owner string `json:"owner"`
PullRequestID int `json:"pullRequestId"`
CommentID int `json:"commentId"`
CommentBody string `json:"commentBody"`
ReportProgress bool `json:"reportProgress"`
Status string `json:"status"`
Error string `json:"error"`
}
type AddCommentResponse struct {
Body string `json:"body"`
ID int `json:"id"`
}