Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

How to upload file using REST API?

Hi , 

i need to upload a file to the RTC server. what i am trying to do is using http request POST , and post a xml file with all the required fields of the ticket.

i will use this prefix : rtc_cm:com.ibm.team.workitem.linktype.attachment.attachment , and then add the rdf:resource="The link of the file in the server".

i just need a way to automate the uploading of the file , and get a url to download it from the server.

Thank you.
Wasim.

0 votes



2 answers

Permanent link
Wasim,

if you hope for people to look at your question and spend their personal time on providing an answer, you want to provide a good title, and, if possible good tagging.
A good title could have been: "Uploading a work item attachment using REST API"

Having said that, there is as far as I am aware no published API for uploading an attachment to a work item. You can trace the communication and use the protocol that is used. Here is my current understanding on uploading attachments:
https://rsjazz.wordpress.com/2012/08/01/uploading-attachments-to-work-items/

I know others have figured the REST interface, but it is not published as far as I can tell and can change.
The post above will, at best, only make the uploaded resource available on the work item if you have a valid resource reference.

1 vote


Permanent link
Only notice that this is an old post when I am about to give an answer. But anyway, the linked post has two methods included.
https://jazz.net/forum/questions/150849/how-to-upload-an-attachment-to-a-work-item-via-rest-api

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,938
× 479

Question asked: Oct 06 '14, 6:26 a.m.

Question was seen: 7,552 times

Last updated: Nov 18 '14, 7:51 p.m.

Confirmation Cancel Confirm