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.
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.
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.
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.
for those who are in the same trouble:
https://developers.intercom.com/reference#user-or-contact-initiated-conversation
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With