mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-10-18 17:51:28 +00:00
feat: able to send alert message via message pusher (close #993)
This commit is contained in:
2
main.go
2
main.go
@@ -9,6 +9,7 @@ import (
|
||||
"github.com/songquanpeng/one-api/common"
|
||||
"github.com/songquanpeng/one-api/common/config"
|
||||
"github.com/songquanpeng/one-api/common/logger"
|
||||
"github.com/songquanpeng/one-api/common/message"
|
||||
"github.com/songquanpeng/one-api/controller"
|
||||
"github.com/songquanpeng/one-api/middleware"
|
||||
"github.com/songquanpeng/one-api/model"
|
||||
@@ -87,6 +88,7 @@ func main() {
|
||||
logger.SysLog("metric enabled, will disable channel if too much request failed")
|
||||
}
|
||||
openai.InitTokenEncoders()
|
||||
_ = message.SendMessage("One API", "", fmt.Sprintf("One API %s started", common.Version))
|
||||
|
||||
// Initialize HTTP server
|
||||
server := gin.New()
|
||||
|
Reference in New Issue
Block a user