@geraintluff and @mespotine thank you so much for your help
I found a solution now. First up, my mind was blown that there is a CLI for reaper. amazing. So 'reaper -renderproject filename' actually renders the file. However, it has one annoying problem that took me a while to figure out: once the project has been rendered, something in the project needs to be changed for it to be rendered again. Hence, just swapping the underlying mediafile (and keeping the same name) will not work.
However, my mind was blown again when I found out that reaper saves its projects in text format <3 ... hence you can manipulate the .rpp with whatever you want.
My weapon of choice is Python, so this is quite simple then:
```
import subprocess
import fileinput
path_to_reaper_install = 'C:\\Program Files\\REAPER (x64)\\reaper'
path_to_reaper_project = 'C:\\test_reaper_project.rpp'
original_mediafile_filename = 'awesome_axe_1'
new_mediafile_filename = 'awesome_axe_2'
original_output_filename = 'track_with_awesome_ax_1'
new_output_filename = 'track_with_awesome_ax_2'
subprocess.call([path_to_reaper_install ,'-renderproject', path_to_reaper_project])
with fileinput.FileInput(path_to_reaper_project, inplace=True, backup='.bak') as file:
for line in file:
new_line = line.replace(original_mediafile_filename, new_mediafile_filename)
new_line = new_line.replace(original_output_filename, new_output_filename)
print(new_line, end='')
subprocess.call([path_to_reaper_install ,'-renderproject', path_to_reaper_project])
```