Hi!
I work with motion 3.2.3.
According to the motion guide, the option %f specifies the full path name.
Unfortunately, it does not replace it but only uses '%f' instead of a filename if I call my script.
The code in my motion.conf looks like this:
on_movie_end script.py %f
(works for %v, etc....)