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

Is there a command line option available to download attachments of a work item?

If there is a file attached in the links section of a work item. is there any way to download it using command line?

0 votes


Accepted answer

Permanent link
Hi,

no, there is no command line tool available for work items and also no tool to download attachments OOTB. You can write a tool using the Plain Java Client Libraries. See https://rsjazz.wordpress.com/2012/08/01/uploading-attachments-to-work-items/ for the reverse operation. I assume you could figure out how to download from that.
Ralph Schoon selected this answer as the correct answer

1 vote

Comments

Thank you for your answers. Will look at the proposed solution.

Chethna, please accept an answer you find most appropriate in the future. this helps keeping the forums maintained.


2 other answers

Permanent link
 There's also the OSLC CM API.  For example, https://jazz.net/jazz/oslc/workitems/74964?OSLC-Core-Version=2.0 contains:
<rtc_cm:com.ibm.team.workitem.linktype.attachment.attachment rdf:ID="n4"rdf:resource="https://jazz.net/jazz/resource/itemOid/com.ibm.team.workitem.Attachment/_0g3i8BfSEd63kMlrUwKMrg"/>

Unfortunately that request is blocked by out whitelist on jazz.net, but it may work for your server.
I would return an item describing the attachment, not the attachment contents itself, but should contain the content id.  The content could then be fetched using <repo root>/content/<contentId>.

I'm having trouble giving a better example at the moment because my VPN is down.

0 votes

Comments

Note that the rtc_cm:...attachment property is RTC-specific, so this approach would not work with any other OSLC CM provider.


Permanent link
See also existing enhancement request Command line interface for work items (83846)

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
× 12,019

Question asked: Aug 30 '12, 5:36 a.m.

Question was seen: 5,562 times

Last updated: Sep 20 '12, 2:03 p.m.

Confirmation Cancel Confirm