It works but I want To make it Public please help me with that.
YouTube Videos uploaded by applications which has not completed the verified will be uploaded to private.
If you want to be able to upload public videos you will need to go through the verification process on Google Cloud console. It can take a bit of time to go though the process.
Make sure you have set up the following
- completely fill out the consent screen
- register your domain on search console
- depending upon which scope you are requesting you may need to create a video showing your app in action.