Create node before page load
You should create a custom Controller rather than hook on page load. This way you won't have an overhead on every page load. In the Controller (accessible under movie/{movie_id} route) try to load movie by movie_id (entityQuery), and if it does not exists simply create one based on data from 3rd party service and display in a display mode of your choice.