Automatically export Worktitems
2 answers
You should investigate the reportable REST API: https://jazz.net/wiki/bin/view/Main/ReportsRESTAPI
This is what is used to populate the data warehouse via RRDI or Insight. A REST call such as this:
https://<host:port>/ccm/rpt/repository/workitem?fields=workitem/workItem[id=123]/(id|summary|itemHistory/comments/content)
will return the id and summary of the workitem, as well as all comment contents from each version of the workitem for workitem 123. The API is quite powerful and you can customize the sample REST call above to return more attributes from more workitems and include search predicates (including based on modified date) so that you are not retrieving the full contents of your repository every time you run it.
This is what is used to populate the data warehouse via RRDI or Insight. A REST call such as this:
https://<host:port>/ccm/rpt/repository/workitem?fields=workitem/workItem[id=123]/(id|summary|itemHistory/comments/content)
will return the id and summary of the workitem, as well as all comment contents from each version of the workitem for workitem 123. The API is quite powerful and you can customize the sample REST call above to return more attributes from more workitems and include search predicates (including based on modified date) so that you are not retrieving the full contents of your repository every time you run it.
Comments
Fabien Araktingi
Apr 17 '14, 12:18 p.m.Thanks for your answer Sam.
I suppose that this way does not allow to get the full history of a workitem (e.g. the different comments, activity history linked to the status).
Thanks for any feedback.
sam detweiler
Apr 17 '14, 12:22 p.m.correct.. only Export can get comments.. nothing will export history
Ralph Schoon
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER Apr 28 '14, 8:21 a.m.If you want to export the full history, you would have to compute it e.g. using the API. A work item has up to two predecessor "states" and you can iterate from the current "State" to when it was created. The history view does exactly that. The information is there, but you would have to create your own export tool, if you want to export that too. You would need a different format than CSV to store all this information too.
sam detweiler
Apr 28 '14, 8:29 a.m.right.. didn't say it wasn't possible, just that nothing provides this function today.