how to work with archieve?


Our HDD is full and we need to clear some space. Is it possible to delete whole year of studies in Orthanc?

Can i download all studies using one button? or better specific gap of data like 2018-08-03 - 2018-09-03?

We have a lot of studies and this a little bit frustrating to click download zip/delete study on all of them one by one.

This is precisely the reason why Orthanc features scripting capabilities using its REST API:

You can find sample Python scripts in the source distribution of Orthanc:

The following commands work fine on Ubuntu 16.04:

mkdir /tmp/test

cd ~/orthanc/Resources/Samples/Python/

python2.7 20120417 20190418 /tmp/test

Where “~/orthanc” is the local path to the source repository of Orthanc:

Thank you very much, all scripts works great. Still have one question - is there any way to import studies back to orthanc from zip archives without unpacking them.
Trying this one
but it’s dont recognize dcm files in zip archives

The “” is a sample script that demonstrates how to use the REST API of Orthanc.

In your scenario, you can easily decompress the archive it by calling the “zipfile” Python library whenever you detect the presence of a “.zip” file extension: