-
Notifications
You must be signed in to change notification settings - Fork 271
Expand file tree
/
Copy pathdoc.go
More file actions
33 lines (24 loc) · 655 Bytes
/
doc.go
File metadata and controls
33 lines (24 loc) · 655 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/*
Package matrix provides message notification integration for Matrix.
Usage:
package main
import (
"log"
"github.com/nikoksr/notify"
"github.com/nikoksr/notify/service/matrix"
)
func main() {
matrixSvc, err := matrix.New("fake-user-id", "fake-room-id", "fake-home-server", "fake-access-token")
if err != nil {
log.Fatalf("matrix.New() failed: %s", err.Error())
}
notifier := notify.New()
notifier.UseServices(matrixSvc)
err = notifier.Send(context.Background(), "subject", "message")
if err != nil {
log.Fatalf("notifier.Send() failed: %s", err.Error())
}
log.Println("notification sent")
}
*/
package matrix