Messages: Sample Use Cases and Flows

This article shares a possible use case your app or site could support, as well as a sample flow. This can be a helpful jumping-off point.

Check that a response has been sent to every message from the site visitor

To check that a response has been sent to every message from the site visitor:

  1. Call List Messages.
  2. Create a copy of the messages returned in the response to include only messages sent by the site visitor. Call these "questions".
  3. For each "question", iterate over the messages returned in the response to check if one exists that's an answerTo the "questions".
  4. Call Bulk Create Messages to send "answers" to all the unanswered "questions".
Did this help?