Can also write:

    List responseProblems = problems.map((p) => p.toMap()).toList();