Share via

Planner CheckList .Net SDK error - Value cannot be null. Parameter name: qualifiedName

2023-08-01T14:39:06.7666667+00:00

Hi,

I am having an error when using the Microsoft Graph. I am using the .NET SDK version 5.19.0.

I am using the Graph with the application permissions: Task.ReadAll, Task.ReadWriteAll

I am trying to create or update a PlannerDetails item which is a ChecklistItem using the code below:

public async Task<PlannerTask> InsertTarefa(string bucketId, string idPlanner, Dictionary<string, string> conteudoTask)
        {

            GraphServiceClient graphClient = CriarGraphClient(await gah.ObterTokenGraphAsync());

            var requestBody = new PlannerTask
            {
                PlanId = idPlanner,
                BucketId = bucketId,
                Title = conteudoTask["titulo"], 
                DueDateTime = DateTime.Parse(conteudoTask["dataFim"]),
                StartDateTime = DateTime.UtcNow,
                Details = new PlannerTaskDetails
                {
                    Description = conteudoTask["descricao"],
                    
                    Checklist = new PlannerChecklistItems()
                    {
                        AdditionalData = new Dictionary<string, object>
                        {
                            {
                                "95e27074-6c4a-447a-aa24-9d718a0b86fa", new
                                {
                                    OdataType = "microsoft.graph.plannerChecklistItem",
                                    Title = "Update task details",
                                    IsChecked = true
                                }
                            }
                        }
                    }
                }
            };
            try
            {
                return await graphClient.Planner.Tasks.PostAsync(requestBody);
            }
            catch (ODataError error)
            {
                Console.WriteLine(error.Error.Message);
                throw new Exception(error.Error.Message);
            }

        }

I used the example on the Learn website to create my request:

https://learn.microsoft.com/pt-br/graph/api/plannertaskdetails-update?view=graph-rest-1.0&tabs=csharp

I always get the following error:

"The request is invalid:\r\nValue cannot be null.\r\nParameter name: qualifiedName"

I have tried to search for information on these issues and the most I could find was addressed in this issue:

https://learn.microsoft.com/en-us/answers/questions/1192857/planner-task-assigned-to-user-using-graph-api

In the above case, the parameter has a corresponding class. The checklist parameter does not.

Microsoft Security | Microsoft Graph
0 comments No comments

1 answer

Sort by: Most helpful
  1. Anonymous
    2023-08-15T14:15:40.94+00:00

    Hello Guilherme Marciano Gonçalves,

    Thanks for reaching out. For SDK related questions please post them on the respective Graph SDK Github Forum.

    Are you able to reproduce the issue with Graph Explorer or Postman applications.

    Thanks.

    Was this answer helpful?

    0 comments No comments

Your answer

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