One of the Freshservice customers wanted to understand whether the API supports the below filter which includes NOT IN, LIKE, etc.
WHERE
Status NOT IN (‘Resolved’,‘Closed’, ‘Cancelled’)
AND OwnerTeamValue = ‘Retail Systems Operations’
AND (Owner IS NULL OR Owner = ‘’)
AND Category = ‘Mainframe Batch’
AND SubCategory = ‘Auto Alert’
AND Subject LIKE ‘%Subscription/Import%’
AND Type=‘Incident’
I already reviewed below API documentation, but couldn’t find any way to filter the tickets the way the customer is looking for. Please let me know if any alternative way to support this ask from the customer.
It sounds like API doesn’t support NOT IN(…) and LIKE operators. Anyway, I will wait for the response from the Freshservice team. Meanwhile, I have proposed the below workaround to the customer
/api/v2/tickets/filter?query="agent_id :< 1 AND (status : 2 OR status : 3 OR status : 6 OR status : 7 OR status : 10) AND group_id:52000087584 AND business_unit:'IT' AND created_at:>'2022-09-05'"