Is there a way to record syncronized screen capture and camera pose to file in unreal engine 5.4.2?

(Preferable in script mode)
What I have tried so far:
I set up an event loop that takes a screenshot and records the camera pose every 0.5 seconds. However, I am unable to export that screenshot to a file.