Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Send Web Request with Attach

Simone Esposito
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 28, 2024

Hi, we are trying to send a ticket attachements to a third-party platform (Service Now) using Jira Automation.

This 3rd party application exposes an API that accepts any type of attachments In the body of the request it is expected that the content of the file must be sent (text, pdf, img, etc)

We noted that JSM when sending files, sends a different Content-Length and this causes, according to our analysis, an incorrect reception of the file by the third-party application

We have noticed that with a normal client, for example cURL, the Content-Length is correct and the file is received by the third-party application.

We also tried to overwrite the Content-Length header in the SendWebRequest Action, but the client does not make the request (generates a 500 error)

Could you help us , please ?

Greetings

1 answer

0 votes
Marc - Devoteam
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 28, 2024

HI @Simone Esposito 

Contact SN support why there is an issue on there API if a content length differs.

Seems the 3rd party API can't handle this.

Simone Esposito
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 29, 2024

Hi @Marc - Devoteam 

Jira SendWebRequest Action send a wrong Content-Length when we send a binary file. We maked the same http request with Jira SendWebRequest to our mock web service for debug, and Content-Length was wrong

Marc - Devoteam
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 29, 2024

Hi @Simone Esposito 

Check this community post, it might help you solve your issue

Send-web-request-HTTP-Status-500 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events