npm install youtube-transcript-dev
import { YoutubeTranscript } from "../src";
const videoId = "x3JbuuEz66I"; // videoId
const yt = new YoutubeTranscript(proxyUrl?): // may add proxyUrl
const [videoDetail, videoCaptions] = await yt.getVideoData(videoId);
console.log(videoDetail);
console.log(videoCaptions);