def get_timestamps(url: str, languages: List[str] = None) -> str:
        """
        Generate timestamps with captions for a YouTube video.
        
        Args:
            url: The URL of the YouTube video
            languages: List of language codes to try (default: ["en"])
            
        Returns:
            Formatted timestamps with captions
        """
        from youtube_transcript_api import YouTubeTranscriptApi
        
        # Default to English if no languages specified
        if not languages:
            languages = ["en"]
            
        video_id = YouTubeVideo.get_video_id(url)
        if not video_id:
            return "Error: Could not extract video ID from URL"
            
        try:
            transcript = YouTubeTranscriptApi.get_transcript(video_id, languages=languages)
            
            timestamps = []
            for line in transcript:
                start_seconds = int(line["start"])
                minutes, seconds = divmod(start_seconds, 60)
                hours, minutes = divmod(minutes, 60)
                
                if hours > 0:
                    time_str = f"{hours}:{minutes:02d}:{seconds:02d}"
                else:
                    time_str = f"{minutes}:{seconds:02d}"
                    
                timestamps.append(f"{time_str} - {line['text']}")
                
            return "\n".join(timestamps)
        except Exception as e:
            return f"Error generating timestamps: {str(e)}"

        Generate timestamps with captions for a YouTube video.
        
        Args:
            url: The URL of the YouTube video
            languages: List of language codes to try (default: ["en"])
            
        Returns:
            Formatted timestamps with captions
        
src/upsonic/tools.py