zenpy
zenpy copied to clipboard
Zenpy Search Endpoint does not handle side loading
The Search Endpoint does not support side loading although the zendesk api documentation shows that it should. https://developer.zendesk.com/api-reference/ticketing/ticket-management/search/#side-loading
I get zero results when I use the "include" kwarg:
# With side loading
res = zendesk_client.search(query="test", type="ticket", include=["tickets(users)"])
In [3]: res.count
Out[3]: 0
# Without side loading
res = zendesk_client.search(query="test", type="ticket")
In [6]: res.count
Out[6]: 7933
the include parameter works on the zendesk_client.tickets endpoint.
we ran into the same issue last year.
we have been doing a call to the search endpoint and then using the include parameter with tickets (e.g. get fetch using ids returned from search).
it'd be great if this worked straight from search, though.