Restart failed autorouting jobs

Hello there.
I will start a new topic so that my problem is clearer. as we learned here: https://groups.google.com/forum/#!topic/orthanc-users/lKYAEWULz5o

Orthanc saves failed jobs, later they can be done manually in the “Jobs” section.
So knowing all this, I have a question, what is needed for the failed jobs to be completed automatically later. for example, once every couple of hours, check if the modality is available, make an attempt to complete all failed jobs. Please help =)

Hello,

It is up to you to implement such an “auto-restart” logic using the REST API of Orthanc (for instance in a cron job):
https://book.orthanc-server.com/users/advanced-rest.html#monitoring-jobs

https://book.orthanc-server.com/users/advanced-rest.html#interacting-with-jobs

Yes, I already understood that. But I posted this topic in the hope that someone has already solved this problem, maybe there is already a python script written by someone from the community.
I will look in this direction, if I find a solution, I will post it here