How can i add a comment using GRAPH API in Planner

Brass Contributor



I'm having issues adding comments to tasks in planner using the graph api. I tried looking at the conversation id and tried posting to corresponding O365 but had no succes on adding comments to tasks. Can anybody help me out with this?




9 Replies

@Eray Chou, do you know who might be able to help answer this question?

Yes I would like this answer too. It's not clear from the MetaData in Graph where the description field resides. Doesn't seem to be part of the Task but there is a "hasDescription" field set to true when a description is added through the UI.

Maybe @SanthoshB1 could help here

You need to use POST /groups/<id>/threads to post the conversation

To update that conversation to task use conversationThreadId
Unfortunately getting them works, but the post doe not. It adds them to the office 365 group but they are not visible in the planner


Sorry "A year later", I was looking to do the same thing and find this post.
I used to understand how to publish a new comment from Graph

with POST[GroupID]/threads/[ConversationID]/reply


And body content like

  "post": {
    "body": {
      "contentType": "1",
      "content": "Hello from Graph"

To find the conversationID i use:[GroupID]/threads



To find PlanID or GroupId, just browse to you planner, it's in the URL


Let's play with this :)


I tried with graph explorer it shows success but it doesnot post the comment in the planner task@Christophe DION What am I missing here. Problem is I can get conversation thread id once the first comment is posted but to post the first comment your way is not working

Christophe's method works great for tasks that already have a conversationId, but can't be used to post the first comment on a new task.
If there is no conversationId you can create a new conversation thread for the group corresponding to the plan. Afterwards update the conversationId of the task.

Keep in mind - This requires Group scopes which require an admin consent. So if you are building an app which should not use admin consent, sending comments is currently not possible.