Updated REST API with root folder method.