Microsoft Graph Task Details Not Returning the Checklist Items

John M. Murry 0 Reputation points
2024-05-27T14:16:09.2266667+00:00

I need to make an Azure Function app which creates the Excel export automatically. I have gotten everything looking like the UI Excel export function found on the Planner, however I cannot get the checklist if the task has one. Here is my code requesting the task details:

 internal async Task<PlannerTaskDetails> GetTaskDetailsById(string? taskId)
 {
     log.LogInformation("START GetTaskDetailsById");

     _ = _userClient ??
         throw new System.NullReferenceException("Graph has not been initialized for user auth");

     try
     {
         log.LogInformation("Getting all task details from planner with this id: " + taskId + ".");
         var result = await _userClient.Planner.Tasks[taskId].Details.GetAsync();
         return result;
     }
     catch (Exception ex)
     {
         log.LogError(ex.Message, ex);
         log.LogInformation("END GetTaskDetailsById");
         return null;
     }
 }

I am using Microsoft.Graph API version 5.54 and this is the results of the checklist:
User's image

What is this "Microsoft.Kiota.Abstractions.Serialization.UntypedObject". I do not understand why the results are not what is expect when using the instructions from https://learn.microsoft.com/en-us/graph/api/plannertaskdetails-get?view=graph-rest-1.0&tabs=http.

Can anyone help?

Microsoft Security | Microsoft Graph
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.