The CreatorCon Call for Content is officially open! Get started here.

Copy Attachment from servicenow to third party application

Mark Wood
Tera Contributor

Hello Experts,

I am new to ServiceNow integration.

I want to copy an attachment from ServiceNow to the Aha third-party application.

I reviewed the Aha API documentation but couldn't figure out how to send an attachment to a third party. What should the content be for sending the attachment? I have attached the third-party Aha documentation link for your reference. Can anyone guide me on this?

Thank you.

Aha API  Link:

https://www.aha.io/api/resources/attachments/create_an_attachment_on_a_comment

 

8 REPLIES 8

To start with, I'd recommend using Postman to craft the API call needed, and validate that adding an attachment does what you want/expected. For me, this is a nice stepping stone to understand the limitations of a vendors API as the Postman interface is a simple GUI vs SN's need to script (unless you use IntegrationHub).

 

multipart/form-data uses Base64 as far as I know, which is achievable in SN

Hello @Kieran Anson 

Thank you for your assistance! I successfully sent the attachment using the Postman tool.

While Postman supports attaching files, I'm uncertain about how to accomplish this in ServiceNow. Could you please provide guidance on sending attachments through ServiceNow? Your help is greatly appreciated; I'm nearly finished with integrating attachments.

 

@Mark Wood 

whatever attachment format they are supporting you need to send that

did you check any example json request on their website?

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

Please find below an example JSON request for your reference. I am new to ServiceNow integration and am having difficulty understanding how to proceed. Your guidance on this would be very helpful.

Thank you.

{
"attachment": {
"file_url": "http://www.aha.io/",
"content_type": "text/html",
"file_name": "home_page.html"
}
}