service

package
v1.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2023 License: Apache-2.0 Imports: 10 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bitbucket

type Bitbucket struct {
	Config *config.Config
}

func NewBitbucket

func NewBitbucket(config *config.Config) *Bitbucket

func (*Bitbucket) CanMerge

func (b *Bitbucket) CanMerge(project, repoSlug string, prID int) (models.Merge, error)

type ErrorResponse

type ErrorResponse struct {
	Errors []struct {
		Context       interface{} `json:"context"`
		Message       string      `json:"message"`
		ExceptionName string      `json:"exceptionName"`
	} `json:"errors"`
}

func (ErrorResponse) Error

func (e ErrorResponse) Error() string

type Notifier

type Notifier struct {
	RTM       *slack.RTM
	Slack     *slack.Client
	Bitbucket *Bitbucket
}

func NewNotifier

func NewNotifier(s *slack.Client, rtm *slack.RTM, bitbucket *Bitbucket) *Notifier

func (*Notifier) ProcessWebhook

func (n *Notifier) ProcessWebhook(b *models.WebhookBody) error

ProcessWebhook is called when we get a new webhook request from bitbucket with a body.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL