Trigger web hook before finishing response

Hi is there any way to make a webhook request before response is finished. Basically I want get a response from a user, with the response make a get request using web hooks, upon response back from from get request conditionally ask user a question or send a different response.

  1. Ask question
  2. send get request using web hooks from users response
  3. get response back from get request
  4. conditionally send a response based on get request response

Is there any way to trigger a web hook from the collect chat js code?

Thanks

Hi Andrew,

Are you looking for a backend communication here? Trying to fetch a result and show it inside the conversation?

If that’s the case, it will be possible via some code.

It’s not possible via the dashboard. We have an ongoing feature request on the same - https://feedback.collect.chat/posts/8/allow-external-processing-during-chat

If you are interested to know how you can achieve this via code, please write to care@collect.chat with your requirement in detail and we will be able to guide you.

Thanks and regards,
Aslam

Ah yes thank you. I believe I’ve figured out how to implement though code on js frontend.