Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MSTeams ¶
type MSTeams struct { // TeamsWebhookURL is the webhook url of the Teams connector TeamsWebhookURL string }
Default handler implements Handler interface, print each event with JSON format
func (*MSTeams) ObjectCreated ¶
func (ms *MSTeams) ObjectCreated(obj interface{})
Notify on object creation
func (*MSTeams) ObjectDeleted ¶
func (ms *MSTeams) ObjectDeleted(obj interface{})
Notify on object deletion
func (*MSTeams) ObjectUpdated ¶
func (ms *MSTeams) ObjectUpdated(oldObj, newObj interface{})
Notify on object update
func (*MSTeams) TestHandler ¶
func (ms *MSTeams) TestHandler()
TestHandler tests the handler configurarion by sending test messages.
type TeamsMessageCard ¶
type TeamsMessageCard struct { Type string `json:"@type"` Context string `json:"@context"` ThemeColor string `json:"themeColor"` Summary string `json:"summary"` Title string `json:"title"` Text string `json:"text,omitempty"` Sections []TeamsMessageCardSection `json:"sections"` }
TeamsMessageCard is for the Card Fields to send in Teams The Documentation is in https://docs.microsoft.com/en-us/outlook/actionable-messages/card-reference#card-fields
type TeamsMessageCardSection ¶
type TeamsMessageCardSection struct { ActivityTitle string `json:"activityTitle"` Facts []TeamsMessageCardSectionFacts `json:"facts"` Markdown bool `json:"markdown"` }
TeamsMessageCardSection is placed under TeamsMessageCard.Sections Each element of AlertWebHook.Alerts will the number of elements of TeamsMessageCard.Sections to create
type TeamsMessageCardSectionFacts ¶
TeamsMessageCardSectionFacts is placed under TeamsMessageCardSection.Facts