I'm building an Android/iOS (using Angular/Ionic/Cordova under the hood) app where I'd like any user to be able to record a video and:
- Either livestream or upload (after filming) the video to my app's private/official YouTube channel
- All videos on this channel would preferably be private/not viewable to anyone other than "my app"
- Then, inside of my app, the app backend would be integrated with my YouTube channel (via YouTube API) and would be allow users to search for and view my private videos from inside my app
So basically I'm trying to allow my app's backend to offer private video hosting/viewing but without having to solve video hosting myself, and to use YouTube as the video store instead.
My requirement for the videos to be private/unviewable from outside my app is not a hard requirement, just preferred if at all possible. My app architecture will be the following:
- Android & iOS app frontends (with embedded YouTube players)
- Java backend
- YouTube for video hosting
Things I'm not too concerned about:
- I know its possible via Android/iOS to access the camera from inside the app, I can figure out how to do this
- I know its possible via the YouTube API for my Java backend to query YouTube for the correct videos to display and then present them to the end user inside the app/frontends; I can figure out how to do this
- I know its possible to embed the YouTube player inside an Android/iOS app and to view a YouTube video from inside my app, I can figure out how to do this
But what I'm hung up on is:
How to allow my end users (in my app) to specify livestream vs bulk upload mode (I assume this is a config setting inside the YouTube API client) and then actually upload them to YouTube without exposing the channel's access/credential info to the end user.
I'm actually using Ionic/Cordova under the hood so if there's a library to help manage API integration and livestream/upload of videos that would be great but I didn't see any.