From 4f2ae7b73f967e1d5448094f07f472405341ab71 Mon Sep 17 00:00:00 2001 From: Wim Date: Fri, 23 Feb 2018 00:48:25 +0100 Subject: Add slack attachment support to matterhook --- matterhook/matterhook.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/matterhook/matterhook.go b/matterhook/matterhook.go index 1877cd3e..11453e34 100644 --- a/matterhook/matterhook.go +++ b/matterhook/matterhook.go @@ -7,6 +7,7 @@ import ( "encoding/json" "fmt" "github.com/gorilla/schema" + "github.com/nlopes/slack" "io" "io/ioutil" "log" @@ -22,7 +23,7 @@ type OMessage struct { IconEmoji string `json:"icon_emoji,omitempty"` UserName string `json:"username,omitempty"` Text string `json:"text"` - Attachments interface{} `json:"attachments,omitempty"` + Attachments []slack.Attachment `json:"attachments,omitempty"` Type string `json:"type,omitempty"` Props map[string]interface{} `json:"props"` } -- cgit v1.2.3