Use basePath to determine route