Skip to main content
Answered

Issue with searching tickets containing spaces in Intercom API

  • February 27, 2025
  • 1 reply
  • 4 views

I'm experiencing an issue when using the Intercom API to search for tickets. When I try to search for a title that contains spaces, the API does not return the expected results. For example:

  1. The query below returns the ticket correctly:

{ "query": { "field": "title", "operator": "~", "value": "Atraso" } }

  1. However, when I add a space after "Atraso", no results are returned:

{ "query": { "field": "title", "operator": "~", "value": "Atraso " } }

I have already tried the following approaches without success:

  • Using regular expressions with \b

  • Encoding the space as %20

  • Using the exact match operator "="

Expected result :

[ { "type": "ticket.list", "pages": { "type": "pages", "page": 1, "per_page": 20, "total_pages": 1 }, "total_count": 1, "tickets": [ { "type": "ticket", "id": "9", "ticket_id": "3", "ticket_attributes": { "_default_title_": "Atraso na criação de atividades no Pipedrive", "_default_description_": "Solicitação de análise urgente de atraso na criação de atividades no Pipedrive, impactando a organização do time. Cliente aguarda retorno sobre a resolução do problema.", ...

Endpoint of this request:
https://api.intercom.io/tickets/search
Docs of this API application:
https://developers.intercom.com/docs/references/2.10/rest-api/api.intercom.io/tickets/searchtickets

The expected behavior would be for the API to return results even with extra spaces. How can I resolve this issue to effectively search for ticket titles containing spaces?

Best answer by Jacques Reynolds

Hey ​@Matheus Simonaci 👋 Jacques here from Intercom Support. I hope all is well today!

This seems like a bug to me. Would you be able to reach out to Intercom Support via the Messenger and outline this issue to them? They’ll be able to look in our logs for those calls and get a report written up for our engineering team.

Thanks for flagging this!

View original
Did this topic help you find an answer to your question?

1 reply

Jacques Reynolds
Intercom Team
Forum|alt.badge.img+4

Hey ​@Matheus Simonaci 👋 Jacques here from Intercom Support. I hope all is well today!

This seems like a bug to me. Would you be able to reach out to Intercom Support via the Messenger and outline this issue to them? They’ll be able to look in our logs for those calls and get a report written up for our engineering team.

Thanks for flagging this!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings