Service Bridge question

JosipK
Tera Expert

Is there a way to transfer attachments, work notes, and comments created before the service bridge connection was established? For us, only comments and attachments added after the service bridge was created (condition was met) are transferred.

1 ACCEPTED SOLUTION

Ryan Palamara
ServiceNow Employee
ServiceNow Employee

OOTB it will only transfer attachments, work notes, and comments on/after the connection is established for the record. However you could add your own logic to send the pre-existing content to the Remote Task which would then send it over. 

 

For Work Notes and Comments, you will have to query the journal to get the pre-existing entries since they will not be directly in the record. Same for attachments, find any associated associated. I will see if I can find any examples. 

View solution in original post

5 REPLIES 5

SrdanMatijevic
Kilo Sage

You are using the new (Nov 2023) version of the Service Bridge, I assume?


I live for thumbs ups.

Correct

Ryan Palamara
ServiceNow Employee
ServiceNow Employee

OOTB it will only transfer attachments, work notes, and comments on/after the connection is established for the record. However you could add your own logic to send the pre-existing content to the Remote Task which would then send it over. 

 

For Work Notes and Comments, you will have to query the journal to get the pre-existing entries since they will not be directly in the record. Same for attachments, find any associated associated. I will see if I can find any examples. 

Thanks. If I understand correctly, the design pattern for the business rule would be:

  •  Trigger: a record on the consumer side satisfies the criteria for the Service Bridge integration i.e. the related remote task on the consumer side is created. In our use case, we are bonding the incident records that have a specific assignment group.
    • The code would be run on afterUpdate to make sure that a consumer remote task is created.
  • Logic: copy all attachments, work note and comments from the consumer eBonded incident records to the related remote task

The Service Bridge would then automatically do its magic and copy them to the corresponding remote task on the provider side. 

Comments and attachments would then automatically be copied to the target record on the provider side. For the work notes, additional code is needed and you have already posted an article on how to do that.

Does this sound right?

Of course, any code examples would be welcome, as always 😁


I live for thumbs ups.