Best practices for designing Integrations

When building an application that integrates with 360dialog's API, it is important to consider a number of factors to ensure that it will work reliably in production, or in other words, design it in a way to prevent issues that can negatively impact your users experience. To help ensure that your integration is successful, it is recommended to follow a set of best practices.

For messages sending, we recommend a message queue, with a retry mechanism with an exponential backoff: correctly implemented, it can ensure that messages are never lost, and if the delivery of a message to 360dialog's API fails, it will be retried by design.

For messages and notifications receiving, we recommend a web-hook receiving endpoint that works asynchronously: by decoupling the storing of the payload and the response to 360dialog's systems from the processing of the payload, your endpoint ensures the fastest possible and constant response time, and will not risk to overload your WhatsApp number and its subsequent disconnection by the WhatsApp network.

While designing your application, you will also have to dimension your environments based on the expected throughput of your use cases: it will again make sure that your WhatsApp number will not get overloaded by too many operations, thus ultimately resulting in a disconnection by the WhatsApp network.

By following these best practices, you can ensure that your integration with 360dialog's API is reliable and robust, providing a positive user experience for your customers.

Last updated