If it's a GoPro,
this is probably exactly what you need.
Mounting to the frame rather than the handlebars also means it'll be a lot more stable than it would be if on the handlebars (as it's always pointed where the frame is currently headed, not where the front wheel is pointed this instant), so if you can do that ... you should.
It may catch (in its video) your bars and cables moving around ahead of it, but that's often not a bad thing.