Update itctl to use api

This commit is contained in:
2021-10-23 18:41:03 -07:00
parent e198b769f9
commit ef29b9bee4
10 changed files with 71 additions and 294 deletions

14
api/notify.go Normal file
View File

@@ -0,0 +1,14 @@
package api
import "go.arsenm.dev/itd/internal/types"
func (c *Client) Notify(title string, body string) error {
_, err := c.request(types.Request{
Type: types.ReqTypeNotify,
Data: types.ReqDataNotify{
Title: title,
Body: body,
},
})
return err
}