I created a webhook that was intended to only receive events for new tasks created in a project.
My webhook:
{
"data": {
"gid": "1190556847551699",
"resource": {
"gid": "1176025284768073",
"resource_type": "project"
},
"filters": [
{
"resource_type": "task",
"resource_subtype": null,
"action": "added",
"fields": null
}
]
}
}
When I create a task I receive a couple events that ARE expected:
[ { user: { gid: '282438369766', resource_type: 'user' },
created_at: '2020-08-25T12:27:25.920Z',
action: 'added',
resource:
{ gid: '1190550948766979',
resource_type: 'task',
resource_subtype: 'default_task' },
parent: { gid: '1176025284768073', resource_type: 'project' } },
{ user: { gid: '282438369766', resource_type: 'user' },
created_at: '2020-08-25T12:27:25.999Z',
action: 'added',
resource:
{ gid: '1190550948766979',
resource_type: 'task',
resource_subtype: 'default_task' },
parent: { gid: '1176025284768074', resource_type: 'section' } } ]
And then a minute later I receive another event that ISNT expected:
[ { user: { gid: '282438369766', resource_type: 'user' },
created_at: '2020-08-25T12:28:26.179Z',
action: 'added',
resource:
{ gid: '1190550948766979',
resource_type: 'task',
resource_subtype: 'default_task' },
parent: { gid: '1172041058567626', resource_type: 'project' } } ]
The parent gid on that event tells me it’s My Tasks ‘project’ (if you can call it that) on the workspace.
Then if I do something like add a tag to that task or assign a user to the task, I also receive an event, which is NOT expected:
[ { user: { gid: '282438369766', resource_type: 'user' },
created_at: '2020-08-25T12:37:53.513Z',
action: 'added',
resource:
{ gid: '1190550948766979',
resource_type: 'task',
resource_subtype: 'default_task' },
parent: { gid: '1176149662208545', resource_type: 'tag' } } ]
Did I set up my webhook incorrectly that I’m receiving all of this extra stuff and not just the initial event for when the task is created?