get_youtube_caption

def get_youtube_caption(videoId)

Retrieves the captions for a YouTube video.

Arguments:

  • videoId str - The ID of the YouTube video.

Returns:

  • str - The captions of the YouTube video in text format.

Raises:

  • KeyError - If the RAPID_API_KEY environment variable is not set.