Are you in the loop? Keep up with the latest by making sure you're subscribed to Community Announcements. Just click Watch and select Articles.

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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


I'm trying to add An attachment to an Issue with Rest Api but it returns []


I have a project in Jira Cloud, I'm trying to do a Post Rest API to ad an attachment to an Issue(the issue is present in the jira cloud project) but It return []

I'm using MobaXterm to Call the Api. this is the Curl i'm using:

D- -X POST -H "Authorization: Basic XXX==" -H "X-Atlassian-Token: no-check" -F "file=C:\Users\X\X\X\X\X@name_of_the_attachment.csv"


This is the entire response I got:

HTTP/1.1 200 OK
Server: AtlassianProxy/
vary: Accept-Encoding
cache-control: no-cache, no-store, no-transform
Content-Type: application/json;charset=UTF-8
Strict-Transport-Security: max-age=315360000; includeSubDomains; preload
Date: Wed, 20 Jan 2021 14:38:15 GMT
ATL-TraceId: 5ba6903f5ee805ee
x-arequestid: XXXXXX
x-aaccountid: XXXXXX
X-XSS-Protection: 1; mode=block
Transfer-Encoding: chunked
timing-allow-origin: *
x-envoy-upstream-service-time: 101
X-Content-Type-Options: nosniff
micros-issuer: micros/edge-authenticator
Connection: keep-alive
set-cookie: atlassian.xsrf.token=06039861-b71d-4c38-9150-4fb125074da3_ec11b2a553989320f6e1e4a9b6c2eb3d04170713_lin; Path=/; Secure
Expect-CT: report-uri="", enforce, max-age=86400





Where is the error? is in the Curl? how to change it?




1 answer

1 accepted

0 votes
Answer accepted
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.
Jan 20, 2021

Hi @Riccardo Micozzi,

Don't have a Jira Cloud instance, so I couldn't try this. Please try the following cURL command:

curl -D- -u<api_token> -X POST -H "X-Atlassian-Token: no-check" -F "file=@C:\Users\X\X\X\X\X\name_of_the_attachment.csv"

Suggest an answer

Log in or Sign up to answer
AUG Leaders

Atlassian Community Events