diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2020-02-12 16:48:28 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-12 08:48:28 +0000 |
commit | 83a8944fcf64af9bf5b0a4e233f9a7f917838a4d (patch) | |
tree | ebb4436506a4e36939fcfa358ccb09dfd3a01d3a /routers/routes | |
parent | ea7ad382e78486fc881bf46d9c1c004e3f311163 (diff) | |
download | gitea-83a8944fcf64af9bf5b0a4e233f9a7f917838a4d.tar.gz gitea-83a8944fcf64af9bf5b0a4e233f9a7f917838a4d.zip |
Add feishu webhook support (#10229)
Add feishu webhook support
Diffstat (limited to 'routers/routes')
-rw-r--r-- | routers/routes/routes.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/routers/routes/routes.go b/routers/routes/routes.go index ff9e0da220..679152c0ed 100644 --- a/routers/routes/routes.go +++ b/routers/routes/routes.go @@ -463,6 +463,7 @@ func RegisterRoutes(m *macaron.Macaron) { m.Post("/dingtalk/new", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksNewPost) m.Post("/telegram/new", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksNewPost) m.Post("/msteams/new", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksNewPost) + m.Post("/feishu/new", bindIgnErr(auth.NewFeishuHookForm{}), repo.FeishuHooksNewPost) m.Get("/:id", repo.WebHooksEdit) m.Post("/gitea/:id", bindIgnErr(auth.NewWebhookForm{}), repo.WebHooksEditPost) m.Post("/gogs/:id", bindIgnErr(auth.NewGogshookForm{}), repo.GogsHooksEditPost) @@ -471,6 +472,7 @@ func RegisterRoutes(m *macaron.Macaron) { m.Post("/dingtalk/:id", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksEditPost) m.Post("/telegram/:id", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksEditPost) m.Post("/msteams/:id", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksEditPost) + m.Post("/feishu/:id", bindIgnErr(auth.NewFeishuHookForm{}), repo.FeishuHooksEditPost) }) m.Group("/auths", func() { @@ -568,6 +570,7 @@ func RegisterRoutes(m *macaron.Macaron) { m.Post("/dingtalk/new", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksNewPost) m.Post("/telegram/new", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksNewPost) m.Post("/msteams/new", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksNewPost) + m.Post("/feishu/new", bindIgnErr(auth.NewFeishuHookForm{}), repo.FeishuHooksNewPost) m.Get("/:id", repo.WebHooksEdit) m.Post("/gitea/:id", bindIgnErr(auth.NewWebhookForm{}), repo.WebHooksEditPost) m.Post("/gogs/:id", bindIgnErr(auth.NewGogshookForm{}), repo.GogsHooksEditPost) @@ -576,6 +579,7 @@ func RegisterRoutes(m *macaron.Macaron) { m.Post("/dingtalk/:id", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksEditPost) m.Post("/telegram/:id", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksEditPost) m.Post("/msteams/:id", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksEditPost) + m.Post("/feishu/:id", bindIgnErr(auth.NewFeishuHookForm{}), repo.FeishuHooksEditPost) }) m.Route("/delete", "GET,POST", org.SettingsDelete) @@ -632,6 +636,7 @@ func RegisterRoutes(m *macaron.Macaron) { m.Post("/dingtalk/new", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksNewPost) m.Post("/telegram/new", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksNewPost) m.Post("/msteams/new", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksNewPost) + m.Post("/feishu/new", bindIgnErr(auth.NewFeishuHookForm{}), repo.FeishuHooksNewPost) m.Get("/:id", repo.WebHooksEdit) m.Post("/:id/test", repo.TestWebhook) m.Post("/gitea/:id", bindIgnErr(auth.NewWebhookForm{}), repo.WebHooksEditPost) @@ -641,6 +646,7 @@ func RegisterRoutes(m *macaron.Macaron) { m.Post("/dingtalk/:id", bindIgnErr(auth.NewDingtalkHookForm{}), repo.DingtalkHooksEditPost) m.Post("/telegram/:id", bindIgnErr(auth.NewTelegramHookForm{}), repo.TelegramHooksEditPost) m.Post("/msteams/:id", bindIgnErr(auth.NewMSTeamsHookForm{}), repo.MSTeamsHooksEditPost) + m.Post("/feishu/:id", bindIgnErr(auth.NewFeishuHookForm{}), repo.FeishuHooksEditPost) m.Group("/git", func() { m.Get("", repo.GitHooks) |