GET REST Attachment (Excel) from Third party to Service Now

sowmyaa
Tera Guru

Hi All,

I am kind of struck in this. Any help will be appreciated!!

I have REST url of a third party tool which will get me an excel sheet. I tested this URL in POSTMAN it is working fine. But how can i call this URL in ServiceNow to get the excel sheet and import the record which can intern fill a table in service now. I tried configuring REST Outbound message , but it gives me 500 error. But same configuration works fine in POSTMAN.

Can any one suggest how to deal with this?

Appreciate your inputs !

Thank you

Sowmya

1 ACCEPTED SOLUTION

sowmyaa
Tera Guru

Hi Ankur,



Thank you. I was able to resolve the issue. REST configuration was correct. Servicenow was looking for one way authentication. I downloaded the certificate of that third party and uploaded to Service Now. It worked like a charm !!!



Cheers,


Sowmya


View solution in original post

9 REPLIES 9

Hi Sowmya,



Since you are sending Bearer + "generated token" you are using OAuth.


Have you configured this correctly in Rest Message.



Regards


Ankur


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

Yes i have verified the token, if i copy this token to POSTMAN it works fine. Here is the screen shot and


POSTMAN


find_real_file.png



SNOW REST MESSAGE SCRIPT



find_real_file.png



Stack trace Error :


javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target


Hi Sowmya,



It seems some error related to certificate is coming up.


Can you check again on the authentication again?



Regards


Ankur


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

sowmyaa
Tera Guru

Hi Ankur,



Thank you. I was able to resolve the issue. REST configuration was correct. Servicenow was looking for one way authentication. I downloaded the certificate of that third party and uploaded to Service Now. It worked like a charm !!!



Cheers,


Sowmya


gauravbhandari
Giga Contributor

Hi Sowmya,

I have the same requirement to to read the Excel and populate Servicenow table.

Could you please list down the steps how to do this in details. Like what needs to be done in 3rd part system and what needs to be done in Servicenow.

 

Thank You

Gaurav