Below is an explanation of the problem, would be great if someone could explain me workflow and any possible API to use for it.
I am writing online education app for my Course project at Uni on SpringBoot + ReactJS. User can purchase course and each course has many videos. All videos are hosted on YouTube with private access. The moment User purchases the course, I want to give access to user's email automatically and then user can watch it.
Is there any other way to keep videos private so only those who purchased can watch them (I don't have time to write video player)?