diff --git a/echo.go b/echo.go index 1466c661a..54f6dec0e 100644 --- a/echo.go +++ b/echo.go @@ -325,11 +325,16 @@ func (e *Echo) NewContext(r *http.Request, w http.ResponseWriter) Context { } } -// Router returns router. +// Router returns the default router. func (e *Echo) Router() *Router { return e.router } +// Routers returns the map of host => router. +func (e *Echo) Routers() map[string]*Router { + return e.routers +} + // DefaultHTTPErrorHandler is the default HTTP error handler. It sends a JSON response // with status code. func (e *Echo) DefaultHTTPErrorHandler(err error, c Context) {