In a call to get recently modified tasks for a project (/api/1.0/projects/{PROJECT_ID}/tasks?modified_since={ONE_DAY_AGO}
), is there a way to include tasks that were deleted and when they were deleted? If not, is there a separate endpoint for querying deleted tasks?
Asana eng here - we don't actually have any APIs that allow access to deleted tasks, to the best of my ability to tell, but it sounds like it could be useful. I've added a task to look into this but as we're currently in the middle of other major API work it may be some time before this gets serious consideration.
One workaround is that you can get the events for a project (see https://asana.com/developers/api-reference/events) to discover when tasks are modified, added, or deleted. Note that you will not get any data about deleted tasks, as deleted tasks become (essentially) invisible to the API. But it will at least tell you when a task you previously knew about was deleted.
You can also receive events as Webhooks if you prefer that to polling for events.