Today we launched another feature in our API: the ability to view and modify dependencies between tasks. Dependencies (and dependents) are available as a field on task objects and we have also added new endpoints to create and remove these relationships.
Have a look at the docs and let us know what you think!
I canāt wait for instagantt to implement this so we can see when project menager set dependencies we can see it in Asana and not just in instagantt app.
Thanks for asking! We generate all of our client libraries from an upstream source, so supporting them all at the same time means we currently have a backlog on newer API features. In the meantime, you can use the workaround of using the post method on the client, i.e. instead of having something like
When our libraries are updated the underlying implementation will end up looking very similar to, say, self.tasks.addProject which you can use for a hint about what the API call directly on our client will look like. You can just do the equivalent 2 lines of code, and replace it with the clearer/nicer one on the next client library release.
Thanks, and we hope to catch up our client libraries to the new dependencies endpoints soon! In the medium term, weāre working to get to a state where our client libraries are easier to keep in sync with API endpoints, so thanks for your patience for now.
The options variable is an example of a keyword argument - itās often seen in method calls as kwargs instead of options. It basically says āSlurp up any additional arguments as key=value pairs into a Python dictionaryā. We use it in cases like this (overriding the page size):
asn.client.tasks.create({projects=[12345]}, page_size=25)
^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^
These are `params` These are the **options
In this case, you donāt need it. If you had any additional arguments, like overriding the default pagination size of 50, you can pass them here, but itās not required.
So I think the code that you wrote should work, assuming that task_dependencie is a JSON response of a task from a previous API call, with only one change: the client will automatically append the path on a built-in base URL. So try this:
@Joe_Trollo
Are dependency conflicts exposed in the API?
In the Gantt, conflicting dependencies are in red. (A task ends after the start of the blocked task). I want to be see in the API whether the dependency is conflicted (red) or not.
If not, which I donāt believe it is, how hard would it be to get this added?
Obviously Iām not the Asana guys so they may weigh in, but I would say donāt expect it in the API as the API is a reflection of and just exposes functionality in the underlying web product, and thereās no functionality in the web product to report conflicting dependencies, soā¦