I'd like the criteria for the event subscription filter of the objCode = DOCU and I'd only like to receive the payload if the document is created in a project with a specific group. How do you do this?
I've tried something like this but it does not send a payload. Is it even possible with a 2 level filter?
{"objCode": "DOCU",
"eventType": "CREATE",
"url": "https://eventfilter.yourendpoint.com",
"authToken": "EauthTokenWorkfrontRocks1234_",
"filters": [
{
"fieldName": "project:groupID",
"fieldValue": "IDxsfdsfasfsafafvalue"
}
}
Topics help categorize Community content and increase your ability to discover relevant content.
Views
Replies
Total Likes
Hi Polly,
I think you can only filter by the resource fields available in the event subscription API. So for the Document resource, the 'groups' field would be the only one that could meet your use case. So your query would look like this.
{"objCode": "DOCU",
"eventType": "CREATE",
"url": "https://eventfilter.yourendpoint.com",
"authToken": "EauthTokenWorkfrontRocks1234_",
"filters": [
{
"fieldName": "groups",
"fieldValue": "IDxsfdsfasfsafafvalue"
}
}
Whenever a document is added to a project, it is automatically associated with the project's group ID. However having said that, 'groups' is a collection and i'm not sure in what circumstances Workfront would associate a document with more than one group. If / when there is a scenario when there is more than one group, i'm not sure whether this would meet the filter criteria of your event subscription - some testing needed I think!
Hope this helps.
Best Regards,
Rich.
Views
Replies
Total Likes
Thanks for the response Rich. I didn't think that there is a group associated with the document itself when querying for DOCU via API so I thought I can't use that. I'll give this a whirl and see whether it could work.
Views
Replies
Total Likes
I know this is an old post but thought I would ask, did the above filter work for your use case? I have the same exact use case and tried filtering by what Richard suggested but it did not work.
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies