Skip to content

YouTube Summarizer API

The YouTube Summarizer API leverages advanced AI technology to generate intelligent summaries from YouTube video transcripts. Whether you need a brief overview, detailed analysis, bullet points, or key takeaways, this API delivers high-quality summaries in the video’s original language.

Base URL: https://youtube-summarizer-api1.p.rapidapi.com

  • Driven by advanced AI technology
  • 4 summary types: Brief, Detailed, Bullet Points, Key Takeaways
  • Automatic language detection and matching
  • Maximum video duration: 1 hour (60 minutes) for all plans
  • Fast processing with key rotation system
  • Works with regular videos AND YouTube Shorts
  • Comprehensive metadata and analytics
  • Automatic fallback to English if needed

All requests must include your RapidAPI key in the headers:

Terminal window
x-rapidapi-key: YOUR_RAPIDAPI_KEY
x-rapidapi-host: youtube-summarizer-api1.p.rapidapi.com

Example 1: Long Video (15 min) - Brief Summary

Section titled “Example 1: Long Video (15 min) - Brief Summary”
Terminal window
curl -X POST "https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=https://www.youtube.com/watch?v=z_bX3runikk&type=brief&language=en" \
-H "x-rapidapi-host: youtube-summarizer-api1.p.rapidapi.com" \
-H "x-rapidapi-key: YOUR_RAPIDAPI_KEY"

Response:

{
"success": true,
"video_id": "z_bX3runikk",
"video_title": "Matthew McConaughey's Concerns Over AI",
"video_duration": 914,
"detected_language": "en",
"language_name": "English",
"summary_type": "brief",
"summary": "In this Joe Rogan Experience episode, Matthew McConaughey discusses his concerns about artificial intelligence and its potential impact on humanity. He explores how AI might become our future governor or president, raising questions about human agency and control.",
"processing_time_ms": 3421,
"total_characters": 15409,
"total_segments": 469,
"was_truncated": false
}

Example 2: YouTube Short (34 sec) - Detailed Summary

Section titled “Example 2: YouTube Short (34 sec) - Detailed Summary”
Terminal window
curl -X POST "https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=https://www.youtube.com/shorts/ivTdEQ6wseU&type=detailed&language=en" \
-H "x-rapidapi-host: youtube-summarizer-api1.p.rapidapi.com" \
-H "x-rapidapi-key: YOUR_RAPIDAPI_KEY"

Response:

{
"success": true,
"video_id": "ivTdEQ6wseU",
"video_title": "Are We Living in a Simulation Within a Simulation?",
"video_duration": 34,
"detected_language": "en",
"language_name": "English",
"summary_type": "detailed",
"summary": "This short video explores the fascinating concept of simulation theory...\n\nThe discussion delves into philosophical questions...\n\nThe video concludes with thought-provoking ideas about reality...",
"processing_time_ms": 2847,
"total_characters": 786,
"total_segments": 22,
"was_truncated": false
}

Terminal window
curl -X POST "https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=https://www.youtube.com/watch?v=z_bX3runikk&type=bullet_points&language=en" \
-H "x-rapidapi-host: youtube-summarizer-api1.p.rapidapi.com" \
-H "x-rapidapi-key: YOUR_RAPIDAPI_KEY"

Terminal window
curl -X POST "https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=https://www.youtube.com/shorts/ivTdEQ6wseU&type=key_takeaways&language=en" \
-H "x-rapidapi-host: youtube-summarizer-api1.p.rapidapi.com" \
-H "x-rapidapi-key: YOUR_RAPIDAPI_KEY"

GET /

Get API information and usage instructions.

Response:

{
"name": "YouTube Summarizer API",
"version": "1.0.0",
"description": "Generate AI-Driven summaries from any YouTube video.",
"endpoints": {
"POST /summarize": "Generate summary from YouTube URL (use query parameters: ?url=VIDEO_URL&type=detailed&language=en)",
"GET /health": "Health check"
},
"summary_types": ["brief", "detailed", "bullet_points", "key_takeaways"],
"example": {
"method": "POST",
"endpoint": "/summarize?url=https://www.youtube.com/watch?v=z_bX3runikk&type=detailed&language=en"
}
}

GET /health

Check if the API is operational.

Response:

{
"status": "ok",
"timestamp": 1704067200000
}

POST /summarize

Generate an AI-Driven summary from a YouTube video.

Query Parameters Required

All parameters must be sent as query parameters in the URL, not in the request body.

Query Parameters:

ParameterTypeRequiredDescription
urlstringYesFull YouTube video URL
typestringNoSummary type: brief, detailed, bullet_points, key_takeaways (default: detailed)
languagestringNoPreferred language code (default: en)

Successful Response (200 OK):

{
"success": true,
"video_id": "z_bX3runikk",
"video_title": "Matthew McConaughey's Concerns Over AI",
"video_duration": 914,
"detected_language": "en",
"language_name": "English",
"summary_type": "detailed",
"summary": "This video explores...",
"processing_time_ms": 3421,
"total_characters": 15409,
"total_segments": 469,
"was_truncated": false
}

Response Fields:

FieldTypeDescription
successbooleanWhether the request was successful
video_idstringYouTube video ID
video_titlestringTitle of the video
video_durationintegerVideo duration in seconds
detected_languagestringDetected language code
language_namestringFull language name
summary_typestringType of summary generated
summarystringThe AI-generated summary
processing_time_msintegerProcessing time in milliseconds
total_charactersintegerTotal characters in transcript
total_segmentsintegerNumber of subtitle segments
was_truncatedbooleanWhether transcript was truncated for length

2-3 sentences maximum - Quick overview of the main idea.

Best for:

  • Quick content screening
  • Social media posts
  • Short descriptions
  • Executive overviews

Example:

{
"type": "brief",
"summary": "This video explores the fundamentals of machine learning, explaining how algorithms learn from data. It covers supervised and unsupervised learning methods with practical examples."
}

5-8 paragraphs - Comprehensive analysis covering all aspects.

Includes:

  • Main topic and purpose
  • Key points and arguments
  • Important details and examples
  • Conclusions or final thoughts

Best for:

  • Research and analysis
  • Content review
  • Learning and education
  • Complete understanding

8-12 key points - Organized, scannable format.

Best for:

  • Quick reference
  • Study notes
  • Meeting summaries
  • Action items

5-7 main lessons - Actionable insights and important points.

Best for:

  • Educational content
  • Training materials
  • Decision-making
  • Knowledge retention

The API accepts various YouTube URL formats:

  • https://www.youtube.com/watch?v=VIDEO_ID
  • https://youtu.be/VIDEO_ID
  • https://www.youtube.com/shorts/VIDEO_ID
  • https://www.youtube.com/embed/VIDEO_ID
  • https://www.youtube.com/v/VIDEO_ID

The API automatically detects the video’s language and generates summaries in that same language.

Common Language Codes:

  • en - English
  • es - Spanish
  • fr - French
  • de - German
  • it - Italian
  • pt - Portuguese
  • ja - Japanese
  • ko - Korean
  • zh - Chinese
  • ru - Russian

Missing URL:

{
"error": "URL is required as query parameter: ?url=VIDEO_URL&type=detailed&language=en"
}

Invalid YouTube URL:

{
"error": "Invalid YouTube URL"
}

Invalid Summary Type:

{
"error": "Invalid summary type. Valid types: brief, detailed, bullet_points, key_takeaways"
}

Not from RapidAPI:

{
"error": "Forbidden - Access only through RapidAPI"
}

No Captions Available:

{
"success": false,
"error": "Could not fetch subtitles: No captions available for this video",
"video_id": "z_bX3runikk",
"suggestion": "Make sure the video has captions/subtitles enabled. Try with a popular video like: https://www.youtube.com/watch?v=z_bX3runikk"
}

Perfect for personal projects

  • Price: $2.99/month
  • Monthly Requests: 100 (Hard Limit)
  • Rate Limit: 5 requests/hour
  • Summary Types: All
  • Support: Community

Ideal for content creators

  • Price: $9.99/month
  • Monthly Requests: 1,000 (Hard Limit)
  • Rate Limit: 20 requests/hour
  • Summary Types: All
  • Support: Email

Best for businesses and researchers

  • Price: $39.99/month
  • Monthly Requests: 5,000 (Hard Limit)
  • Rate Limit: 50 requests/hour
  • Summary Types: All
  • Support: Priority Email

Enterprise-grade AI summaries

  • Price: $119.99/month
  • Monthly Requests: 20,000 (Hard Limit)
  • Rate Limit: 100 requests/hour
  • Summary Types: All

Always pass parameters in the URL as query parameters:

const videoUrl = 'https://www.youtube.com/watch?v=z_bX3runikk';
const type = 'brief';
const language = 'en';
const apiUrl = `https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=${encodeURIComponent(videoUrl)}&type=${type}&language=${language}`;

Cache generated summaries to avoid redundant API calls for the same video.

Always implement error handling for cases where summaries cannot be generated.


async function generateSummary(videoUrl, type = 'detailed', language = 'en') {
const apiUrl = `https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=${encodeURIComponent(videoUrl)}&type=${type}&language=${language}`;
const response = await fetch(apiUrl, {
method: 'POST',
headers: {
'x-rapidapi-key': 'YOUR_RAPIDAPI_KEY',
'x-rapidapi-host': 'youtube-summarizer-api1.p.rapidapi.com'
}
});
const data = await response.json();
if (data.success) {
console.log(`Video: ${data.video_title}`);
console.log(`Type: ${data.summary_type}`);
console.log(`Language: ${data.language_name}`);
return data.summary;
} else {
throw new Error(data.error);
}
}
generateSummary('https://www.youtube.com/watch?v=z_bX3runikk', 'brief')
.then(summary => console.log(summary))
.catch(error => console.error(error));
import requests
from urllib.parse import urlencode, quote
def generate_summary(video_url, summary_type='detailed', language='en'):
base_url = 'https://youtube-summarizer-api1.p.rapidapi.com/summarize'
params = {
'url': video_url,
'type': summary_type,
'language': language
}
headers = {
'x-rapidapi-key': 'YOUR_RAPIDAPI_KEY',
'x-rapidapi-host': 'youtube-summarizer-api1.p.rapidapi.com'
}
url = f"{base_url}?{urlencode(params, quote_via=quote)}"
response = requests.post(url, headers=headers)
data = response.json()
if data.get('success'):
print(f"Video: {data['video_title']}")
print(f"Type: {data['summary_type']}")
print(f"Language: {data['language_name']}")
return data['summary']
else:
raise Exception(data.get('error', 'Unknown error'))
summary = generate_summary(
'https://www.youtube.com/watch?v=z_bX3runikk',
summary_type='bullet_points'
)
print(summary)
const axios = require('axios');
async function generateSummary(videoUrl, type = 'detailed', language = 'en') {
try {
const encodedUrl = encodeURIComponent(videoUrl);
const url = `https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=${encodedUrl}&type=${type}&language=${language}`;
const response = await axios.post(url, null, {
headers: {
'x-rapidapi-key': 'YOUR_RAPIDAPI_KEY',
'x-rapidapi-host': 'youtube-summarizer-api1.p.rapidapi.com'
}
});
if (response.data.success) {
console.log(`Video: ${response.data.video_title}`);
console.log(`Type: ${response.data.summary_type}`);
console.log(`Language: ${response.data.language_name}`);
return response.data.summary;
}
} catch (error) {
console.error('Error:', error.response?.data || error.message);
throw error;
}
}
generateSummary(
'https://www.youtube.com/shorts/ivTdEQ6wseU',
'key_takeaways'
)
.then(summary => console.log(summary))
.catch(console.error);
<?php
function generateSummary($videoUrl, $type = 'detailed', $language = 'en') {
$encodedUrl = urlencode($videoUrl);
$url = "https://youtube-summarizer-api1.p.rapidapi.com/summarize?url={$encodedUrl}&type={$type}&language={$language}";
$headers = [
'x-rapidapi-key: YOUR_RAPIDAPI_KEY',
'x-rapidapi-host: youtube-summarizer-api1.p.rapidapi.com'
];
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
$data = json_decode($response, true);
if ($data['success']) {
echo "Video: {$data['video_title']}\n";
echo "Type: {$data['summary_type']}\n";
echo "Language: {$data['language_name']}\n";
return $data['summary'];
} else {
throw new Exception($data['error']);
}
}
$summary = generateSummary('https://www.youtube.com/watch?v=z_bX3runikk', 'detailed');
echo $summary;
?>
require 'net/http'
require 'json'
require 'uri'
def generate_summary(video_url, summary_type = 'detailed', language = 'en')
encoded_url = URI.encode_www_form_component(video_url)
url = URI("https://youtube-summarizer-api1.p.rapidapi.com/summarize?url=#{encoded_url}&type=#{summary_type}&language=#{language}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request['x-rapidapi-key'] = 'YOUR_RAPIDAPI_KEY'
request['x-rapidapi-host'] = 'youtube-summarizer-api1.p.rapidapi.com'
response = http.request(request)
data = JSON.parse(response.body)
if data['success']
puts "Video: #{data['video_title']}"
puts "Type: #{data['summary_type']}"
puts "Language: #{data['language_name']}"
return data['summary']
else
raise StandardError, data['error']
end
end
summary = generate_summary('https://www.youtube.com/shorts/ivTdEQ6wseU', 'brief')
puts summary

  • Generate video descriptions
  • Create social media posts
  • Plan follow-up content
  • Audience engagement insights
  • Analyze educational videos
  • Extract key concepts
  • Literature review assistance
  • Quick content evaluation
  • Competitor analysis
  • Market research
  • Training material summaries
  • Content curation
  • Create study guides
  • Lesson planning
  • Student resources
  • Course material development

Q: Why do I need to use query parameters instead of request body?
A: All parameters must be passed in the URL as query parameters for the API to work correctly with RapidAPI’s infrastructure.

Q: How accurate are the summaries?
A: Summaries are generated using state-of-the-art AI technology, providing high accuracy based on the video’s transcript quality.

Q: Can I customize the summary length?
A: Each summary type has a predefined structure. Choose the type that best matches your needs: brief (shortest), detailed (longest), bullet_points, or key_takeaways.

Q: What happens if the video is in a language other than English?
A: The API automatically detects the language and generates summaries in the same language.

Q: Does it work with YouTube Shorts?
A: Yes! The API works with both regular YouTube videos and YouTube Shorts.

Q: What if the video has no captions?
A: The API requires captions/subtitles to function. Videos without captions will return an error.


Need help? We’re here for you:


By using this API, you agree to:

  • Use the service only through RapidAPI
  • Not exceed your plan’s rate limits
  • Comply with YouTube’s Terms of Service
  • Use AI-generated summaries responsibly

Last updated: October 2025