Swagger docs

This commit is contained in:
2024-10-20 16:16:50 -06:00
parent 3cbd0d1806
commit e2e736e500
12 changed files with 667 additions and 1 deletions

View File

@ -8,6 +8,15 @@ import (
"github.com/labstack/echo/v4"
)
// SSE godoc
// @Summary Server-Sent Events endpoint
// @Description Establishes a Server-Sent Events connection
// @Tags sse
// @Accept json
// @Produce text/event-stream
// @Param channel query string false "Channel name"
// @Success 200 {string} string "Event stream"
// @Router /sse [get]
func SSE(c echo.Context) error {
channel := c.QueryParam("channel")
if channel == "" {