Want to download attachments in a zip file according to the RITM no associated to it. I don't want to go with ui action option.

Nikita9
Mega Expert

Hi All,

I want to download attachments in a zip file according to the RITM no associated to it. I don't want to go with ui action option.

 

I tried to use attachment API but couldn't find a way to download the attachments. All i was able to see was metadata.

I want the exact attachment that is attached to the RITM

Example; if i have 20 RITMs. If i hot an API, then 20 zip files should be created locally storing the respective attachments.

 

Pls help.

 

Regards,

Nikita

10 REPLIES 10

Hi Nikita,

I believe you will have to create scripted REST API to achieve this.

It would accept the 5 RITM record numbers and then use the script to attach the files

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi Ankur,

Can you help me with the code to download attachments in zip file.

 

Regards,

Nikita

Hi Nikita,

I haven't tried it personally. the links above should help you get started.

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi Ankur,

 

Could you please guide me through the code to download an attachment?

 

 

Regards,

Nikita

Hi Nikita,

I believe you should get help from above links.

haven't tried it yet.

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader