Skip to main content
Solved

How to Ensure Reliable Klaviyo-Salesforce Sync?

  • January 30, 2025
  • 1 reply
  • 39 views

Forum|alt.badge.img+1

Hi,

I’m integrating Klaviyo into an e-commerce website for a client for the first time. I’ve synchronized their Salesforce CRM using Klaviyo’s native integrations, but since they’ll continue to use Salesforce alongside Klaviyo, I need to ensure the two systems stay constantly and reliably synchronized.

Here are some key requirements:

  • If a user unsubscribes from the newsletter, the CRM must be updated to reflect the change in marketing consent.
  • If a user registers through a Klaviyo sign-up form, the new user needs to be created in the CRM.
  • Similar scenarios where updates need to be reflected bidirectionally.

I noticed that Klaviyo allows the use of webhooks within flows, but I currently don’t have the ability to handle complex programming logic—I can only forward the request body to an external endpoint. For this reason, I opted to use Klaviyo’s "Code" integration, which allows me to write custom functions, for instance, to retrieve the token and make API calls to update account data in the CRM.

However, I have a concern: what happens if an API call fails or is interrupted due to its duration? This could lead to discrepancies between the accounts in Klaviyo and those synchronized in the CRM.

I’m wondering if there are better ways to handle this synchronization more reliably or if you have any suggestions for optimizing the current solution while minimizing the risk of errors.

Best answer by Byrne C

Hi ​@intmonna 

Thanks for the question! Our webhooks do retry themselves up to 17 times over the course of 24 hours after certain failure codes. You can take a look at the retryable codes here. That being said, for API calls not associated with webhooks in flows, we do recommend implementing a retry mechanism on your own.

When webhooks retry, they’ll retry at a decreasing rate based on the number of retries that have already occurred. 

How have you fared in building out this outbound connection to Salesforce so far? Anything else I can help out with regarding this?

-Byrne

View original
Did this topic or the replies in the thread help you find an answer to your question?

1 reply

Byrne C
Community Manager
Forum|alt.badge.img+10
  • Community Manager
  • 71 replies
  • Answer
  • February 4, 2025

Hi ​@intmonna 

Thanks for the question! Our webhooks do retry themselves up to 17 times over the course of 24 hours after certain failure codes. You can take a look at the retryable codes here. That being said, for API calls not associated with webhooks in flows, we do recommend implementing a retry mechanism on your own.

When webhooks retry, they’ll retry at a decreasing rate based on the number of retries that have already occurred. 

How have you fared in building out this outbound connection to Salesforce so far? Anything else I can help out with regarding this?

-Byrne