2.0.26 • Published 4 months ago

youtube-videos-uploader v2.0.26

Weekly downloads
43
License
MIT
Repository
github
Last release
4 months ago

npm version


In the name of God, who has guided me to do this work

Note1: In case you find any issue, please raise an issue, So that I can fix it.

Please star this repo by clicking on :star: button above :arrow_upper_right:

Features:

  • No upload Limits (50+ videos/day limit set by youtube for every channel)
  • Free & Easy to use

Prerequisite:

Installation:

npm i youtube-videos-uploader

Youtube Setup:

  1. Go to your Google Security settings and note down your recovery email and delete recovery phone from your google settings
  2. Go to your Youtube settings and Setup your upload defaults Settings:

Upload Defaults Settings

Usage:

  • Uploading a Video:

import { upload } from 'youtube-videos-uploader' //Typescript
//OR
const { upload } = require('youtube-videos-uploader'); //vanilla javascript

// recoveryemail is optional, only required to bypass login with recovery email if prompted for confirmation
const credentials = { email: 'Your Email', pass: 'Your Password', recoveryemail: 'Your Recovery Email' }

// minimum required options to upload video
const video1 = { path: 'video1.mp4', title: 'title 1', description: 'description 1' }

const onVideoUploadSuccess = (videoUrl) => {
    // ..do something..
}
// Extra options like tags, thumbnail, language, playlist etc
const video2 = { path: 'video2.mp4', title: 'title 2', description: 'description 2', thumbnail:'thumbnail.png', language: 'english', tags: ['video', 'github'], playlist: 'playlist name', channelName: 'Channel Name', onSuccess:onVideoUploadSuccess, skipProcessingWait: true, onProgress: (progress) => { console.log('progress', progress) }, uploadAsDraft: false, isAgeRestriction: false, isNotForKid: false, publishType: 'PUBLIC', isChannelMonetized: false }


// Returns uploaded video links in array
upload (credentials, [video1, video2]).then(console.log)

// OR
// This package uses Puppeteer, you can also pass Puppeteer launch configuration
upload (credentials, [video1, video2], {headless:false}).then(console.log)

// Refer Puppeteer documentation for more launch configurations like proxy etc
// https://pptr.dev/#?product=Puppeteer&version=main&show=api-puppeteerlaunchoptions

       Output:

[ 'https://youtu.be/fh2Kreex5Eg', 'https://youtu.be/fh2Krefx5Eg' ]
  • Updating Metadata of a Youtube Video:

import { update } from 'youtube-videos-uploader' //Typescript //OR const { update } = require('youtube-videos-uploader'); //vanilla javascript

const credentials = { email: 'Your Email', pass: 'Your Password', recoveryemail: 'Your Recovery Email' }

const videoUpdate1 = { link: 'https://www.youtube.com/watch?v=w3jLJU7DT5E', title: 'Your New Title' }

const onVideoUpdateSuccess = (videoUrl) => { // ..do something.. } // Extra options like tags, thumbnail, language, playlist etc const videoUpdate2 = { link: 'https://www.youtube.com/watch?v=w3jLJU7DT5E', title: 'title 2', description: 'description 2', thumbnail: 'thumbnail.png', language: 'english', tags: 'video', 'github', replaceTags: 'mytag', playlist: 'playlist name', channelName: 'Channel Name', publishType: 'unlisted', publishToSubscriptionFeedAndNotifySubscribers: false , onSuccess: onVideoUpdateSuccess }

update(credentials, videoUpdate1, videoUpdate2).then(console.log) // OR update(credentials, videoUpdate1, videoUpdate2, { headless: false }).then(console.log)

  
- #### Making a comment to youtube video:    
  
 ```js

import { comment } from 'youtube-videos-uploader' //Typescript
//OR
const { comment } = require('youtube-videos-uploader'); //vanilla javascript
  
const credentials = { email: 'Your Email', pass: 'Your Password', recoveryemail: 'Your Recovery Email' }
   
const comment1 = { link: 'https://www.youtube.com/watch?v=jEevRjRglFY', comment: 'Your comment', pin: false }

comment(credentials, [comment1]).then(console.log)  
//OR
comment(credentials, [comment1], {headless:false}).then(console.log)

Contributors 🎉:

2.0.26

4 months ago

2.0.24

7 months ago

2.0.25

6 months ago

2.0.22

8 months ago

2.0.23

7 months ago

2.0.20

10 months ago

2.0.9

1 year ago

2.0.16

1 year ago

2.0.14

1 year ago

2.0.12

1 year ago

2.0.10

1 year ago

2.0.19

1 year ago

2.0.17

1 year ago

2.0.18

1 year ago

2.0.5

1 year ago

2.0.4

1 year ago

2.0.7

1 year ago

2.0.8

1 year ago

2.0.3

2 years ago

2.0.2

2 years ago

2.0.1

2 years ago

2.0.0

2 years ago

1.3.53

2 years ago

1.3.54

2 years ago

1.3.51

2 years ago

1.3.52

2 years ago

1.3.57

2 years ago

1.3.58

2 years ago

1.3.55

2 years ago

1.3.56

2 years ago

1.3.60

2 years ago

1.3.61

2 years ago

1.3.64

2 years ago

1.3.65

2 years ago

1.3.62

2 years ago

1.3.68

2 years ago

1.3.69

2 years ago

1.3.66

2 years ago

1.3.71

2 years ago

1.3.72

2 years ago

1.3.70

2 years ago

1.3.75

2 years ago

1.3.76

2 years ago

1.3.73

2 years ago

1.3.74

2 years ago

1.3.79

2 years ago

1.3.77

2 years ago

1.3.78

2 years ago

1.3.50

2 years ago

1.3.49

2 years ago

1.3.46

2 years ago

1.3.47

2 years ago

1.3.45

2 years ago

1.3.48

2 years ago

1.3.42

2 years ago

1.3.43

2 years ago

1.3.44

2 years ago

1.3.36

3 years ago

1.3.39

3 years ago

1.3.37

3 years ago

1.3.38

3 years ago

1.3.40

2 years ago

1.3.41

2 years ago

1.3.28

3 years ago

1.3.29

3 years ago

1.3.26

3 years ago

1.3.27

3 years ago

1.3.31

3 years ago

1.3.32

3 years ago

1.3.30

3 years ago

1.3.35

3 years ago

1.3.33

3 years ago

1.3.34

3 years ago

1.3.21

3 years ago

1.3.24

3 years ago

1.3.25

3 years ago

1.3.22

3 years ago

1.3.19

3 years ago

1.3.13

3 years ago

1.3.12

3 years ago

1.3.17

3 years ago

1.3.18

3 years ago

1.3.15

3 years ago

1.3.16

3 years ago

1.3.11

3 years ago

1.3.9

3 years ago

1.3.7

3 years ago

1.3.6

3 years ago

1.3.5

3 years ago

1.3.4

3 years ago

1.3.3

3 years ago

1.3.2

3 years ago

1.3.1

3 years ago

1.2.7

3 years ago

1.2.6

3 years ago

1.2.5

3 years ago

1.2.4

3 years ago

1.2.3

3 years ago

1.3.0

3 years ago

1.2.2

3 years ago

1.2.0

3 years ago

1.2.1

3 years ago

1.1.9

3 years ago

1.1.10

3 years ago

1.1.8

3 years ago

1.1.7

3 years ago

1.1.6

3 years ago

1.1.5

3 years ago

1.1.4

3 years ago

1.1.3

3 years ago

1.1.1

3 years ago

1.1.0

3 years ago

1.1.2

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago