Believe it or not, it's not as complex as you'd think and actually quite scripted, you would simply have an area on the obstacles you want and a raycast to check how far you are away from the obstacle in question. After that, it's all about timing and Godot has code like other engines that allows you to check what frame an animation is on so you know exactly when you need to let the character move normally again. How do I know this? This is what happens when you poke around games for a long time, there are moments where I've caught the big studios messing up their level design and you can sometimes find obstacles that can't be vaulted over when you should be able to.
Think of vaulting in the same vein as wall jumping, it's all just about the timing, you're just doing everything forward and vertical.