dynamic routes, config refactoring