devrnt / react-use-intercom

☎️ React Intercom integration without the hassle, powered by hooks.
https://devrnt.github.io/react-use-intercom/#/useIntercom
MIT License
337 stars 43 forks source link

Open custom bot #570

Closed simon-v-swyftx closed 1 year ago

simon-v-swyftx commented 2 years ago

Is your feature request related to a problem? Please describe. I'm trying trigger a custom bot https://www.intercom.com/help/en/articles/2785347-engage-high-intent-visitors-with-custom-bots-from-buttons Their implementation hooks onto a css path, so I've added in a css class, however it's not always triggering. I'm unsure if it's due to intercom's import order, of if elements on the page are not visible onload and thus the event handler hook onto the button.

Describe the solution you'd like Would it be possible to supply show() with a bot ID or something to trigger that flow directly.

Describe alternatives you've considered Tried the method in the intercom docs, but it's really flaky.

devrnt commented 1 year ago

Hi, thanks for creating this issue.

This library tries to stay close to the vanilla IntercomJS API. So as long as it's not mentioned in the IntercomJS docs it won't be implemented in this library. Maybe it's in there somewhere and I haven't found it? If so I'm happy to pick this up

simon-v-swyftx commented 1 year ago

Hmm can't seem to find anything, so will close as the other PR is merged 😄