Issue symptoms
I enabled Accounts to Organization data sync from Salesforce to Zendesk but it doesn't sync. How do I resolve this?
Explanation and example
The Zendesk external ID is a system field which is required to be unique across all organizations for a Zendesk account. If one organization with a given external ID already exists, an attempt to create a second will fail outright due to a conflict.
This conflict occurs when an organization has its external ID set because of a previous Salesforce legacy integration. An example of how this can happen is explained below.
- The legacy Salesforce integration syncs Spiffy Corp account to create an organization in Zendesk with the name Spiffy Corp and an external ID of 0011H000026CXpiQAG.
- The legacy integration sync is disabled and the new Salesforce integration is enabled.
- The account name in Salesforce is changed to Spiffy Corp, Inc.
- Since the new integration has never synced this account before, it looks for a match based on matching criteria (typically account name to organization name).
- Because there is no organization named Spiffy Corp, Inc, the integration attempts to create a new organization with the name Spiffy Corp, Inc and the same external ID.
- The sync attempt fails as the external ID is already in use by the original Spiffy Corp organization.
To confirm the sync failure is due to this conflict
- In Admin Center, check the matching criteria in Platform > Salesforce > Data Sync > Accounts to Organizations sync > Matching criteria. This is commonly associated with name-matching but could also occur with other matching criteria.
- Find the account ID from the URL of the Salesforce account that's failed to sync.
- Use the URL below to see if there are any organizations in Zendesk with that as their external ID. {YOUR_ACCOUNT_ID} is the account ID from your Salesforce account URL.
http://SUBDOMAIN.zendesk.com/api/v2/organizations/show_many.json?external_ids={YOUR_ACCOUNT_ID}
The search function doesn't support the search of organizations based on the external ID. So instead, the organization endpoint is used. - Use the result from the above API request and compare the matched criterion (likely name) to the matched SFDC field under Matching criteria.
How to fix it
There are a few possible solutions to the conflict.
- Stop syncing the Account-ID into the external ID.
Disable Populate Zendesk organization external ID which should prevent the collision.
Note: If the ID present in Zendesk is required, create a custom organization field and sync the account ID to a field in the standard field mappings instead. - Remove the external_id value from current organizations
You can remove the external_id using the organizations API or by using the organizations bulk import via CSV. - Correct the account names so that the account with given account ID syncs successfully with the organization that matches the external ID
This is the most labor-intensive but guarantees that IDs will sync successfully. Once an account is successfully matched to an organization, subsequent changes to that account's name should update the organization's name (instead of making a new organization).
7 Comments
Hi Dwight Bussman
We've just recently connected our Salesforce sandbox to our Zendesk Sandbox, and we're experiencing issues where the integration is syncing one or two accounts we test but will not sync other accounts we create.
The accounts that have synced work and we're able to push all updates from Salesforce to Zendesk when mapped fields are updated from Salesforce.
Are there any known issues where the integration is only syncing some Salesforce accounts and not others?
We've followed all the documentation to create this integration and are confused to why it's not working as expected.
Hi Adam,
I see you've reached out to our Support team already which is definitely the right move here. There are a few reasons this might happen. The external_id conflict described in this article is just one of the potential conflicts. It may be worthwhile for me to expand this article to include some of the other frequent causes of this issue.
Dwight Bussman
As mentioned in your comment on our ticket, it was the mapping from domain name to domain that caused the break as we still had (http://) on the domain in Salesforce, stripping that out to just have the apex domain fixed it.
It would be very helpful. I have setup the sync for Orgs-Accounts also and whatever is misconfigured or failing is completely opaque. Nothing in the Integration Logs on Zendesk side. The integration isn't using any special fields per se. It's matching criteria is simply Account Name (SF) to Name (ZD). Mapping fields are Account Name (SF) to Name (ZD) and an additional text field I added to my Salesforce Account object called "sf2zd" (SF) which maps to a corresponding field called "SF Test Account" (ZD). As far as I can tell all of the settings related to permissions are set in SF. And here I sit with no idea what is actually failing. Help is appreciated. I have submitted a support request as well from this same email.
HeyO Russell,
That definitely sounds like a misbehavior to me, and one into which we'll want to take a closer look. I'll check in with that ticket you raised to see where it's at and that someone responds to you shortly. If there's a more general bit of information raised in that investigation which seems relevant to the group, I'll be sure to share the gist back to this thread.
Hi Dwight Bussman
I have one question related to a failed ticket sync. This is the error and the issue seem to be for just this one.
Nevena Imetska
Thanks for that information. This sounds like an issue for which a deeper investigation is in order. I'm going to reach out to you in a ticket to continue this conversation privately once I've had a chance to look through our back-end logs. Thanks for bringing this to our attention.
Please sign in to leave a comment.