Skip to main content
Answered

Fetching specific conversations of one user does not work

  • September 1, 2024
  • 2 replies
  • 19 views

I want to fetch a user's conversations with this endpoint, but it currently returns all the conversations my team has had. I implemented this code using Intercom’s documentation but it does not work as expected: https://developers.intercom.com/docs/references/1.2/rest-api/conversations/list-conversations

const response = await fetch(`https://api.intercom.io/conversations?type=user&intercom_user_id=${user.intercomId}`, {

method: 'GET',

headers: {

'Authorization': `Bearer ${accessToken}`,

'Accept': 'application/json'

}

})

Best answer by Jacques Reynolds

Hey @canbalkaya 👋 Jacques here from support engineering.

You can actually use the Search Conversations endpoint to retrieve a list of Conversations based on the User associated with it.

You can specify the contact_id to get the User ID associated with those conversations and it will return only those Conversations :)

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

2 replies

Diana Tripac
Intercom Team
Forum|alt.badge.img+2
  • Senior Community Program Manager @Intercom
  • 151 replies
  • September 4, 2024

Hi @Nathan Sudds @Milan adding you here in case you have any ideas on that 🙌


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

Hey @canbalkaya 👋 Jacques here from support engineering.

You can actually use the Search Conversations endpoint to retrieve a list of Conversations based on the User associated with it.

You can specify the contact_id to get the User ID associated with those conversations and it will return only those Conversations :)


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