public async Task <JsonResult> Get() { var mongoDbService = new MongoDbService(DatabaseName, "Todos", DatabaseUrl); var allTodos = await mongoDbService.GetAllTodos(); return(Json(allTodos)); }