{"_id":"@dofy/youtube-caption-extractor","_rev":"9-cbf9d10891c3d58ffe612752ff7dad24","name":"@dofy/youtube-caption-extractor","dist-tags":{"latest":"1.5.11"},"versions":{"1.5.0":{"name":"@dofy/youtube-caption-extractor","version":"1.5.0","keywords":["youtube","captions","subtitles","scraper","parser","video","transcript"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.0","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"4b96adf642a591ba04380cc8dd0e017120c36f4a","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.0.tgz","fileCount":26,"integrity":"sha512-AknL1zrSKRSvbBhlLxrgvFo9SakmY5VMlm1lXjx+dTYuf/kwAkLg5VpLjL7HuPaHVDib5k/4bLhe1uVo8XmwVA==","signatures":[{"sig":"MEYCIQC7ceRn23TazPB3Di6vTX6rcVxQAlQdhG1m4IlvD1HR3QIhAJ2GKob0gM8OVhttvXGzb0YhAfpKr1XofZqRrHfpmnWR","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":145122},"main":"dist/index.js","types":"./dist/index.d.ts","gitHead":"f6a1932487a10ef31af6adfe054c28b1bf6cb688","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","@types/he":"^1.2.0","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.0_1723543132600_0.8175792439916263","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.2":{"name":"@dofy/youtube-caption-extractor","version":"1.5.2","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.2","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"178cc5415d4b637ab1d55e353910d930b04bda8c","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.2.tgz","fileCount":26,"integrity":"sha512-TpK2ole+Y6Z8ezvAXcKae5JlJ7BQm1klfHo8H+yiV+khXLbZPt6hL5vX+IdZ36MD1NR3bHGLrh4LoQbX7rzNNg==","signatures":[{"sig":"MEUCIQCOtMRaT9KGfcNt54EMi+Os06upc52fikkEgh7c9eoYJAIgZge4Prhb8iV4KocK7O5ew9+Q0V7nP7KaJSsz4jaROGo=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":145305},"main":"dist/index.js","types":"./dist/index.d.ts","gitHead":"a8cf1a87831f60d0313353f30e635ba2033d0207","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","@types/he":"^1.2.0","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.2_1723544192763_0.412023875088497","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.4":{"name":"@dofy/youtube-caption-extractor","version":"1.5.4","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.4","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"3a70e4727c019a64f85c63ce84be2ca5f7c49f84","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.4.tgz","fileCount":26,"integrity":"sha512-pZOwtb+qGzcwiDWyHmeBAObr3KxPdavXwKeMohJnXsJI6vwssT4Wx8ZcJ+wwGLbofMmt8DVLmYAv8zdqIoNL5g==","signatures":[{"sig":"MEYCIQCmXXe/12XMp+KmKNgqiaPd41RrDCEziRcoDgLyCssDdgIhAMazPETXaobEbmtqSkvm7NVqsVDj+W3NVjIZurowoyu8","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":145305},"main":"dist/index.js","types":"./dist/index.d.ts","gitHead":"cdff1f33a691e6664d3c0a09c1b6ab8c72617ee5","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","@types/he":"^1.2.0","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.4_1723547102374_0.6729482452753706","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.5":{"name":"@dofy/youtube-caption-extractor","version":"1.5.5","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.5","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"929046b5f9658a156382ef811a22b80b30ac6457","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.5.tgz","fileCount":26,"integrity":"sha512-QdN0SQwJ7S8KxRhIgg4d7oI0yPinVyq6MvYTQa8JYZI25Mm58FQ0+EORwv0x8Gx1Zr23iLjxX7wjAj6d6jkW7Q==","signatures":[{"sig":"MEUCIEN+d2kELtNrsexmNK2Ga4ROh4vHqgl10RFFieu6xvvWAiEA5kYlhLBY3baAZEcFpig4ohYZlcxVOyjg1GsBObxjPXo=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":145305},"main":"dist/index.js","types":"./dist/index.d.ts","gitHead":"1e160f952d118dfc5a677e2ee39d6e92adb70069","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@types/he":"^1.2.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.5_1723562532398_0.1509121950989838","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.7":{"name":"@dofy/youtube-caption-extractor","version":"1.5.7","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.7","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"7306fe94357e3fbc34dce17f1afe3f8443ee364c","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.7.tgz","fileCount":26,"integrity":"sha512-pGqc5SMFha0Y2qE0cv+fYmjaRbl51cz65GReb22uLiEImCRSO6hyhUYrKe2mv7crQf4ijkU376ElJzQ34EU5KQ==","signatures":[{"sig":"MEYCIQCaZub7+aenxAAk/aHGAnqE+9f1vjNn5RheOskWmueM1AIhALKAPpKvdxN7vGBLm41amBouROafrILVWi9QVTN3Bys6","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":144794},"main":"dist/index.js","types":"./dist/index.d.ts","gitHead":"1e160f952d118dfc5a677e2ee39d6e92adb70069","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","@types/he":"^1.2.0","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.7_1723564212297_0.9949445012685079","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.8":{"name":"@dofy/youtube-caption-extractor","version":"1.5.8","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.8","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"8198bd46f9f546780ed33a92bca8fc8c415a986f","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.8.tgz","fileCount":26,"integrity":"sha512-VBlVQEJ+AeUyclf3iAo/P+VEncIlex5Cm3rqfz7ngFnl6ZIAnRzxt1dRG1K2ulF/sztTZ5Yz3yux5NVEW2ESDA==","signatures":[{"sig":"MEYCIQCLOoEomYmZL1uRzfSm3bDw4KGNwpq25lWZLlJaakJwQgIhAOPI7oItL97mf59IoBgtajLE3zm+Z+xCGa8Ug7VgQwUJ","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":144926},"main":"dist/index.js","types":"./dist/index.d.ts","gitHead":"1e160f952d118dfc5a677e2ee39d6e92adb70069","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@types/he":"^1.2.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.8_1723565360435_0.42760428616569945","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.9":{"name":"@dofy/youtube-caption-extractor","version":"1.5.9","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.9","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"d67ef119019522b5f284c4ef86f135bbd6a70749","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.9.tgz","fileCount":26,"integrity":"sha512-HMaAxaUpGlQxoigbyLY+IM0w41bPdxGwNtgycqYpoS6eYzJiRLUOAyyX36qv497yrEO/dR0/rMeQq7C9jhS4cw==","signatures":[{"sig":"MEQCIGs7n9Ty7wIwtgvZbGZIMCxWfAgoZCZvbLPibc8SwQC4AiB2p1y5I+qVNI4ATStcc8oxeWg07GMJ25dPpdjnAQEIVQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":144926},"main":"dist/index.js","types":"./dist/index.d.ts","gitHead":"1e160f952d118dfc5a677e2ee39d6e92adb70069","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","@types/he":"^1.2.0","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.9_1723565697702_0.5390294595558123","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.10":{"name":"@dofy/youtube-caption-extractor","version":"1.5.10","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.10","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"b563704dad521dc2c44bfdf3c1032bac60ebbb8d","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.10.tgz","fileCount":26,"integrity":"sha512-AbZd4LPQgrDIG4Kb8RQDrsWG0LDK5kTvyBl+XI69KNZ2Au7/a61BGFHccU0MV9MjQ6Ndn7IidJ+/ssusNhD+/w==","signatures":[{"sig":"MEUCIQDfjgXvisGWt0pRgekvLJ2SjOSaSkw4cCSoLUOE3xveXQIgXNEh1W3RslDiV6H8EFsfLI/oyTrZDjQpSOBfyrmT5rU=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":144947},"main":"dist/index.js","type":"module","types":"./dist/index.d.ts","gitHead":"1e160f952d118dfc5a677e2ee39d6e92adb70069","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@types/he":"^1.2.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.10_1723565921771_0.18235225886741002","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"1.5.11":{"name":"@dofy/youtube-caption-extractor","version":"1.5.11","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","_id":"@dofy/youtube-caption-extractor@1.5.11","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"homepage":"https://github.com/dofy/youtube-caption-extractor","bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"dist":{"shasum":"90a2aa571560dca85c035a6c56bf72832c0d4741","tarball":"https://registry.npmjs.org/@dofy/youtube-caption-extractor/-/youtube-caption-extractor-1.5.11.tgz","fileCount":26,"integrity":"sha512-DlGi8T5xw/oyJhfl1fJVD3cDvVaUv4XCDG+q5pFf+YjPkWb8TKz3Xsit0MkQ5dbGdXJZgu+n3/4aMEPorBOorg==","signatures":[{"sig":"MEUCIQDIPTfQBXepH+o5bgEGKwPTfhVJAYdpfgBgBuIGVZwxYAIgSOYYqbYqd+qNxTXMjtd7QDtjwcRXLjIL/mXdCeHpmRQ=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":144874},"main":"dist/index.js","type":"module","types":"./dist/index.d.ts","gitHead":"d2a01c2a5e5281d4a8a0250d6660495e07ec3688","scripts":{"test":"jest","build":"tsc"},"_npmUser":{"name":"dofy","email":"dofyyu@gmail.com"},"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"_npmVersion":"10.5.0","description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","directories":{},"_nodeVersion":"21.7.3","dependencies":{"he":"^1.2.0","ts-node":"^10.9.1","@types/he":"^1.2.0","striptags":"^3.2.0","node-fetch":"^3.3.2","typescript":"^5.0.4","https-proxy-agent":"^7.0.5"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.5.0","ts-jest":"^29.1.0","@jest/types":"^29.5.0","@types/jest":"^29.5.12"},"_npmOperationalInternal":{"tmp":"tmp/youtube-caption-extractor_1.5.11_1723569880728_0.5472106444616194","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."}},"time":{"created":"2024-08-13T09:58:52.471Z","modified":"2024-08-20T08:57:05.305Z","1.5.0":"2024-08-13T09:58:52.755Z","1.5.2":"2024-08-13T10:16:32.934Z","1.5.4":"2024-08-13T11:05:02.575Z","1.5.5":"2024-08-13T15:22:12.555Z","1.5.7":"2024-08-13T15:50:12.495Z","1.5.8":"2024-08-13T16:09:20.642Z","1.5.9":"2024-08-13T16:14:57.914Z","1.5.10":"2024-08-13T16:18:42.012Z","1.5.11":"2024-08-13T17:24:40.971Z"},"bugs":{"url":"https://github.com/dofy/youtube-caption-extractor/issues"},"author":{"url":"https://github.com/dofy","name":"Seven Yu","email":"dofyyu@gmail.com"},"license":"ISC","homepage":"https://github.com/dofy/youtube-caption-extractor","keywords":["youtube","captions","subtitles","scraper","parser","video","transcription","proxy"],"repository":{"url":"git+https://github.com/dofy/youtube-caption-extractor.git","type":"git"},"description":"A simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options.","maintainers":[{"name":"dofy","email":"dofyyu@gmail.com"}],"readme":"# YouTube Caption Extractor\n\nA simple and efficient package to scrape and parse captions (subtitles) from YouTube videos, supporting both user-submitted and auto-generated captions with language options. In addition, it can also retrieve the title and description of the YouTube video.\n\n## What's new in v1.5.x\n\n- Proxy Agent support: The package now supports using a proxy agent to make requests, allowing you to fetch subtitles from YouTube behind a proxy server.\n\n## What's new in v1.4.3\n\n- TypeScript batteries included 🔋: The package is now shipped with TypeScript type definitions, making it easier to use in TypeScript projects.\n- Node.js and Edge runtime support: The package now supports both Node.js and Edge runtime environments, expanding its usability across different platforms.\n- Enhanced data extraction: The new `getVideoDetails` API can fetch not just the subtitles, but also the video's title and description.\n\n## Installation\n\n```sh\nnpm install @dofy/youtube-caption-extractor\n```\n\n## Usage\n\nIn a server-side environment or Node.js\n\n```js\nimport { getSubtitles, getVideoDetails } from \"@dofy/youtube-caption-extractor\";\n\n// Fetching Subtitles\nconst fetchSubtitles = async (videoID, lang = \"en\", proxyUrl) => {\n  try {\n    const subtitles = await getSubtitles({ videoID, lang, proxyUrl });\n    console.log(subtitles);\n  } catch (error) {\n    console.error(\"Error fetching subtitles:\", error);\n  }\n};\n\n// Fetching Video Details\nconst fetchVideoDetails = async (videoID, lang = \"en\", proxyUrl) => {\n  try {\n    const videoDetails = await getVideoDetails({ videoID, lang, proxyUrl });\n    console.log(videoDetails);\n  } catch (error) {\n    console.error(\"Error fetching video details:\", error);\n  }\n};\n\nconst videoID = \"video_id_here\";\nconst lang = \"en\"; // Optional, default is 'en' (English)\nconst proxyUrl = \"http://your-proxy-server-url.com\"; // Optional, default is undefined\n\nfetchSubtitles(videoID, lang, proxyUrl);\nfetchVideoDetails(videoID, lang, proxyUrl);\n```\n\n## API\n\n### getSubtitles({ videoID, lang, proxyUrl })\n\n- `videoID` (string) - The YouTube video ID\n- `lang` (string) - Optional, the language code for the subtitles (e.g., 'en', 'fr', 'de'). Default is 'en' (English)\n- `proxyUrl` (string) - Optional, the URL of the proxy server to use for making requests. Default is `undefined`\n\nReturns a promise that resolves to an array of subtitle objects with the following properties:\n\n- `start` (string) - The start time of the caption in seconds\n- `dur` (string) - The duration of the caption in seconds\n- `text` (string) - The text content of the caption\n\n### getVideoDetails({ videoID, lang, proxyUrl })\n\n- `videoID` (string) - The YouTube video ID\n- `lang` (string) - Optional, the language code for the subtitles (e.g., 'en', 'fr', 'de'). Default is 'en' (English)\n- `proxyUrl` (string) - Optional, the URL of the proxy server to use for making requests. Default is `undefined`\n\nReturns a promise that resolves to a VideoDetails object with the following properties:\n\n- `title` (string) - The title of the video\n- `description` (string) - The description of the video\n- `subtitles (Subtitle[])` - An array of subtitle objects\n\n**Note:** The description is retrieved from the meta tags on the page, and may not be complete.\n\n## Handling CORS issues in client-side applications\n\nWhen using this package in a client-side application, you might encounter CORS (Cross-Origin Resource Sharing) issues. To handle these issues, it's recommended to create a server-side API route that fetches subtitles on behalf of the client. This way, you can ensure that your application respects CORS policies while still being able to fetch subtitles and video details.\n\nFor example, in a Next.js project you can create an API route like this:\n\n1. Create a new file under the pages/api folder, e.g., `pages/api/fetch-subtitles.js`.\n2. Inside the `fetch-subtitles.js` file, add the following code:\n\n```js\nimport { getSubtitles, getVideoDetails } from \"@dofy/youtube-caption-extractor\";\n\nexport default async function handler(req, res) {\n  const { videoID, lang } = req.query;\n\n  try {\n    const subtitles = await getSubtitles({ videoID, lang }); // call this if you only need the subtitles\n    const videoDetails = await getVideoDetails({ videoID, lang }); // call this if you need the video title and description, along with the subtitles\n    res.status(200).json({ subtitles, videoDetails });\n  } catch (error) {\n    res.status(500).json({ error: error.message });\n  }\n}\n```\n\n3. Now, in your client-side component, you can fetch subtitles using the API route:\n\n```js\nimport { useEffect, useState } from \"react\";\n\nconst MyComponent = () => {\n  const [subtitles, setSubtitles] = useState([]);\n  const [videoDetails, setVideoDetails] = useState({});\n\n  const videoID = \"video_id_here\";\n  const lang = \"en\"; // Optional, default is 'en' (English)\n\n  useEffect(() => {\n    const fetchSubtitles = async (videoID, lang = \"en\") => {\n      try {\n        const response = await fetch(\n          `/api/fetch-subtitles?videoID=${videoID}&lang=${lang}`\n        );\n        const data = await response.json();\n        setSubtitles(data.subtitles);\n        setVideoDetails(data.videoDetails);\n      } catch (error) {\n        console.error(\"Error fetching subtitles:\", error);\n      }\n    };\n\n    fetchSubtitles(videoID, lang);\n  }, [videoID, lang]);\n\n  // Render your component with the fetched subtitles\n};\n```\n\n## License\n\nISC\n","readmeFilename":"README.md"}