Exalate Sync Help: Syncing Incident-Related Jira Issues with Customer Case Data

I have a query that is currently a blocker for us.

We’re using Exalate to sync between ServiceNow and Jira Cloud (both directions).

When a Customer Case is created in ServiceNow, we’ve configured a trigger and used the following sync rules, which are working as expected. The Customer Case fields are syncing correctly to Jira:

ServiceNow Outgoing Sync Script:

if (entity.tableName == “sn_customerservice_case”) {
replica.key = entity.key
replica.summary = entity.short_description
replica.description = entity.description
}

However, we’re facing an issue when an Incident is created.

The flow is:

  1. A Customer Case is created.
  2. From that Customer Case, an Incident is generated.
  3. A trigger on the Incident creates a corresponding Jira issue.

The problem:
For the Jira issue created from the Incident, we want to sync fields from the original Customer Case, not from the Incident itself. This is because agents in ServiceNow work and update information on the Customer Case, not directly on the Incident.

Request:
I need guidance on how to write the ServiceNow Outgoing Sync Script and the corresponding Jira Incoming Sync Script so that the Jira issue created for the Incident receives data from the associated Customer Case.

Hi @Manoj,

I hope you’re doing well.

From what you’ve described, it sounds like the data you ultimately care about is coming from the Customer Case, even though the Incident is the one triggering the creation of the Jira issue.

In that case, would it make more sense to sync the Customer Case directly to Jira instead of syncing from the Incident? That way, you’d ensure that the data source stays aligned with where agents are actually working and updating information.

If there’s a specific reason the sync has to be triggered from the Incident (e.g. for workflow or audit purposes), we could explore a workaround where the Incident’s sync rule explicitly pulls data from the related Customer Case using a GlideRecord lookup. Let me know which direction you’re leaning, and I’d be happy to help tailor the script accordingly.

Kind regards,
@Christophe_De_Beule