Close recent windows of an application I'm using Selenium in order to control multiple Firefox sessions at the same time.

In this context, the OS handles each Firefox window as a different application.

I want to build a workflow that'll allow me to close all the recent windows of Firefox (leaving the "oldest" one working), but I couldn't find any way to sort them by their opening date.

Any help would be appreciated!
Try to access window menu of Firefox, the oldest window at top of the list