Workfront API query with AND and OR conditions

19 views Asked by At

I am trying to fetch document approvals from Workfront which match following criteria:

approvalDate after 2024-02-27T18:32:00:000 AND ((document:categoryID is x) OR (document:categoryID is y))

The following query is not working:

status=APPROVED
&AND:3:approvalDate=2024-02-27T18:32:00:000
&AND:3:approvalDate_Mod=gte
&OR:1:document:categoryID=x
&OR:2:document:categoryID=y
&OR:2:document:categoryID_Mod=eq
&OR:1:document:categoryID_Mod=eq
1

There are 1 answers

0
Prashant Onkar On

Following query worked:

OR:1:status=APPROVED
&OR:1:approvalDate=2024-02-28T16:23:00:000
&OR:1:approvalDate_Mod=gte
&OR:1:document:categoryID=x
&OR:2:document:categoryID=y
&OR:2:status=APPROVED
&OR:2:approvalDate=2024-02-28T16:23:00:000
&OR:2:approvalDate_Mod=gte