Asana stopped sending web hooks for one of the targets

One of the webhooks stopped working without any errors.
I just don’t get any requests anymore. Tried to recreate it, didn’t help.

Also I noticed an odd behavior. I successfully created webhook for one project, but get error with the same configuration for another project.
“resource”: {project_id},
“filters”: [
“action”: “added”,
“resource_subtype”: “tag”,
“resource_type”: “task”

"target": "target"

asana.error.InvalidRequestError: Invalid Request: The resource_subtype tag is invalid for the given task resource_type
But yesterday I’ve create 5 web hooks for different projects with this configuration.

@Ross_Grambo can you help? I think this is going to require some Asana-centered help…

I believe this is because subtype filtering was not working until yesterday/today.

The error right now makes sense to me. As there is no subtype of tag on tasks. I assume we were simply ignoring the subtype until this fix went in.

Are you trying to watch for tag changes on a task? I believe your filter should look like:

“action”: “added”,
“resource_type”: “tag”

As the project webhook gets all events under it, and the event here is a tag being added to a task.

Yes, I’m trying to watch tags added to task. And now my filter looks like this
{'resource_type': 'tag', 'resource_subtype': None, 'action': 'added', 'fields': None}
I checked it by getting webhook by gid.
And I still don’t get any requests to my webhook handler.
I also checked that handler works with direct request

Also I checked my other webhook that listens to tags changes. It also stopped working.
I get the request but events are empty
{'events': []}

@Ross_Grambo I still can’t create webhook that listens to tags adding to task. What is the valid config? Could you provide an example, please?

I spoke incorrectly before when I thought it would be “tag” for resource type. Turns out your adding the task to the tag, rather than the tag being added to the task.

This request works for me:

POST /webhooks

	"data": {
		"resource": "1233445667890",
		"target": "",
		"filters": [
				"resource_type": "task",
				"action": "added"

Within your webhook handler, you’d need to check if parent.resource_type == “tag”. Without this extra filtering, you’ll also see new tasks being added to the project and existing tasks be added to other projects.


This helped! Thank you!
Would be nice to have such examples in documentation)

1 Like