Agile Central: Lookback API: Find all artifacts that were restored from recycle bin

Document ID : KB000111797
Last Modified Date : 21/08/2018
Show Technical Document Details
Question:
Can we find all artifacts that were restored from Recycle Bin? How?
Can we further filter it by a date range or artifact type?
Answer:
You can find out the artifacts that were restored from the Recycle Bin using Lookback API.

Any update to the artifacts creates a new snapshot which can be queried by the Lookback API. The snapshots are categorized by a field: _SnapshotType which marks the type of snapshot it is. The Restore event is marked with a value of 'RESTORE' per the _SnapshotType. Therefore, you can query by that value to find the restored artifacts:

https://rally1.rallydev.com/analytics/v2.0/service/rally/workspace/<<Workspace Object ID>>/artifact/snapshot/query.js?find={"_SnapshotType":"RESTORE"}&fields=true&compress=true

You can further narrow down your query filter by artifact type or by date range. Here is another example of finding the restored artifacts
for a date range of 04.20.2018 - 05.16.2018:

https://rally1.rallydev.com/analytics/v2.0/service/rally/workspace/<<Workspace Object ID>>/artifact/snapshot/query.js?find={$and: [{"_SnapshotType":"RESTORE"}, {"_ValidFrom": {$gt: "2018-04-20T00:00:00.000Z"}}, {"_ValidTo": {$gt: "2018-05-16T00:00:00.000Z"}}]}&fields=true&compress=true


 
Additional Information:
More on Lookback API: https://rally1.rallydev.com/analytics/doc/#/manual