Add route(routes, path, query) function