14 lines
220 B
Go
Executable file
14 lines
220 B
Go
Executable file
package channel
|
|
|
|
import (
|
|
"github.com/go-chi/chi"
|
|
)
|
|
|
|
func APIRoutes(s Service) *chi.Mux {
|
|
router := chi.NewRouter()
|
|
|
|
router.Get("/{id}", ChannelAPIHandler(s))
|
|
router.Get("/", ChannelsAPIHandler(s))
|
|
|
|
return router
|
|
}
|