add rest routes and partials