Yesterday, we had severe performance issues due to multiple running processes on a single user (import orders) that didn’t stop until we manually killed the processes:

Here’s the task that I want to implement on processes that have run longer than a minute or two:

Is there anything I can call in the RESTAPI to achieve this?
Thanks,
Brian