Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Sending message on Intercom on user's behalf

does anyone know how to send a message from intercom(https://www.intercom.com/) on user's behalf? I need to set up an event listener that opens intercom chat window and sends a message when a some button is clicked.

i am working with react version of intercom if it helps.

will be very grateful for any hints.

like image 817
Petro Avatar asked Dec 13 '16 11:12

Petro


People also ask

Can you send emails from intercom?

With Intercom Messages, you can send targeted emails to your customers and leads. Whether you customize a pre-made template, or import your own HTML, the emails you send will look great. A/B testing and goals let you optimize your email performance and ensure effectiveness.

How do I add an intercom user?

Under 'Contacts', go to your people list, and click “New users or leads” in the top right corner: Then, choose to create a new user or a new lead: Note: In this example, we're creating a new user, but the process is the same to create a new lead.


2 Answers

If you are using the Intercom chat widget, you can pre-populate a custom message in the widget on the user's behalf like so

const myCustomMessage = 'Hi there!'

window.Intercom('showNewMessage', myCustomMessage)

Of course, the user still has to actually send the message. This might not be exactly what you wanted but it's an alternative in case you want to fully automate everything except the decision to send the message (which is the right UX in a lot of situations).

Documentation is here.

like image 105
davnicwil Avatar answered Sep 21 '22 21:09

davnicwil


for those who are in the same trouble:

https://developers.intercom.com/reference#user-or-contact-initiated-conversation

like image 27
Petro Avatar answered Sep 24 '22 21:09

Petro