When I use
https://app.asana.com/api/1.0/workspaces/workspace-id/tasks -d "name=this is a new task"
and then also using the POST method... I get a response, but nothing is created in asana...
This is the response in JSON format
{"data":{"id":5480677401703,"created_at":"2013-05-17T12:55:21.298Z","modified_at":"2013-05-17T12:55:21.298Z","name":"","notes":"","completed":false,"assignee_status":"later","completed_at":null,"due_on":null,"workspace":{"id":1337166104874,"name":"mecad.co.za"},"assignee":null,"parent":null,"followers":[{"id":1337166104857,"name":"Andries Koorzen"}],"projects":[],"tags":[]}}
But I don't see anything in asana
I guess you may have problem with the server itself. You would better start the ISS.
Rather, you can control the postLinkClicked method to see if there is a problem.
(I work at Asana) Where do you expect the task to show up? You have not given your new task an assignee or a project, so it will not show up in your My Tasks list, nor will it show up under any project. Try setting something in the assignee or project field.
But it also looks like you have a problem specifying details for the task, since you're attempting to pass a name but it's not being accepted by the system. My guess is something about the way you're doing this is not actually sending the correct POST data to the Asana API.
Related
I am trying to send comments to plannertask but it is not posted. Basically if I had conversation thread id I can reply to that but to send the very first comment, I do not have conversation thread already existing.
I tried PATCHrequest from graph explorer to send the first comments. The response comes back as ok but I go back to that specific task, that I made patch request to, comment is not there.
I tried to PATCH /planner/tasks/{taskid} and /planner/tasks/{taskId}/details and I even tried POST. I have seen people talking about replying to the conversation thread id but nobody has talked about the very first comment.
Basically my code creates plans and tasks in it. some of the task I am trying to send a very first comment. In the beginning, conversation thread comes as null so I could not use that of course
I believe I found an alternative solution to this problem. Since ConversationThreads are at the group level, before even creating a task, I created a conversation thread of that group with api
/groups/{id}/threads.
Now that you have a new Convothread laying around in the group, you can send the patch request for the task or even create a task with that conversation ThreadId.
In that way, you forced a particular task to have a conversationThreadId from the beginning. You can call that convoThreadiID to send as many comments as you want after that. All the comments sent to that convoThreadId would be posted on the task. Since graph api gives null for the threadId at the beginning of the task. I think this would be the best way to go. Let me know if I could explain this further to you.
Thanks #Ashok. I did consider that path but didn't actually try it. Since posting this I have pretty much given up using Planner for the reasons outlined here. Basically, way too many issues like this one wasting way too much time for no actual outcome.
Having said that, I am interested in your approach. I assumed that when I created the conversation it would appear in that group's UI somewhere, but that was an untested assumption on my part. I am not clear from your answer whether you have successfully done this yet. Any side-effects?
Thanks,
Murray
I have a Wufoo form that, when submitted, creates a new Asana task.
Is there a way to make a "date" field in a Wufoo form automatically set the Due Date in an Asana task? My guess is that there would be a CSS layout keyword for it, but perhaps it doesn't exist.
Any ideas?
(I work at Asana)
We haven't added this functionality yet but hope to in the near future - it is one of our top requests for the Wufoo integration. I'll make a note to update this task when we add it.
Im trying to post a task on asana through c#. The Json string that im sending is:
{"workspace":1234567890123,"data": {"name":"Buy eggs","notes":"Testing"}}
and the response I'm getting is:
{"data":{"id":123439968,"created_at":"2015-01-14T21:35:31.288Z","modified_at":"2015-01-14T21:35:31.288Z","name":"Buy
eggs","notes":"Testing","completed":false,"assignee_status":"upcoming","completed_at":null,"due_on":null,"workspace":{"id":12345678901234,"name":"CompanyName"},"num_hearts":0,"assignee":null,"parent":null,"hearts":[],"followers":[{"id":12345689965587,"name":"MyName"}],"projects":[],"tags":[],"hearted":false}}
But when I log into asana the task isn't there, what do I do?
The task has been created, but since it's not assigned to anyone or in any projects, it's not going to show up in any lists. The follower you added ("MyName") should be able to search for the task, but in general you want to specify a project to add to, or at the very least an assignee (so it shows up in their "My Tasks").
I want to make a git hook that will automatically comment on an open issue in asana when someone makes a commit with a specially-formatted message. Something along the lines of:
asana task-id: Fix whatever
The main problem I'm having is I don't know an easy way of getting the task-id. The ids are quite long and the only place I see them being displayed in the user interface is in the URL when you click a task. This is a bit cumbersome and error prone when trying to copy it, and isn't obvious to the user.
Is there an easier way to comment on a task from a shell script (or git hook)?
Well, regardless of how you do it you'd definitely need the task ID (as you pointed out, it's in the URL). What we actually do internally is just paste a link to an Asana task - it contains the ID, identified it as an asana task, and is clickable in many views so you can jump right to the task it's talking about when viewing commit history. Very handy!
We then have what is essentially a commit hook look for https://app.asana.com/..., grab the task ID and post a new comment linking to the commit in our source control and the commit message.
Using URLs means the link goes both ways, which is incredibly convenient.
Do you plan to add possibility to retrieve (via API) all tasks from project including those which are archived?
(I work at Asana)
That would be a useful feature and we are already planning on adding it. However, I can't comment as to when it will be possible.
Until the API officially supports this, you can always query /tasks?completed_since=now to get only incomplete tasks, then query /tasks, and filter for tasks that only appear in the second list.
Archived tasks can be accessed by including the parameter ?include_archived=true in your request for querying tasks by project.
Task section in Asana documentation
I am trying to do this exact same thing as well. We are using a project to track line down events on our manufacturing floor. I found this post helpful and you can append “?include_archived=true” to your query but I found out that you can also do a reverse lookup on tasks by their tag. This will also show achieved tasks as well.