I have to send attachment from one instance to another instance.

niveditakumari
Mega Sage

Hi, 

 

I have to send attachment from one instance to another instance. I'm creating one incident having attachment in source instance and I need that incident to be created in target instance with having all details short description, attachment in source instance using REST api. 

Can anyone please help me to achieve that. 

 

Regards, 

Nivedita

 

 

1 REPLY 1

Tony Chatfield1
Kilo Patron

Hi, I think you have 2 options available to you.
1/ Replication - Available from SNC and other vendors via the SNC store.

ServiceNow Store
2/ Integration with REST API, OOB functionality.

REST API | ServiceNow Developers

You would integrate the task using the table API and then once you have returned a sys_id for the record involved, you can use the attachment API to integrate your file\attachment.
My preference is always to integration\POST to a temporary endpoint or data table, and to use scripted rest API Product Documentation | ServiceNow 

and/or OOB data import\transform

Imports (servicenow.com)

to ensure that your 2 instances are correctly mapped for reference data/choices and process (if any of these differ).