15 lines
220 B
Go
15 lines
220 B
Go
|
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
|
||
|
}
|