UNAUTHORIZED
Missing or invalid API key.
The Scority Transcript API exposes one protected endpoint:GET /v1/youtube/transcript. It works with many public YouTube videos that have accessible captions; it does not guarantee transcripts for every video.
API base URL: https://api.scority.ai. Machine-readable OpenAPI is available at https://api.scority.ai/openapi.json. The human guide for importing that spec is /docs/openapi.
ambiguous_request.invalid_video_url.Send your Scority API key with the x-api-key header. Keep the key server-side. Do not expose it in browser code, mobile apps, public repositories, or screenshots.
curl "https://api.scority.ai/v1/youtube/transcript?video_id=dQw4w9WgXcQ&language=en" \
-H "x-api-key: YOUR_API_KEY"curl "https://api.scority.ai/v1/youtube/transcript?video_id=dQw4w9WgXcQ&language=en" \
-H "x-api-key: YOUR_API_KEY"{
"language": "en",
"source": "captions",
"text": "Never gonna give you up...",
"segments": [
{
"text": "Never gonna give you up",
"start": 18.2,
"duration": 2.1
}
]
}{
"language": "en",
"source": "captions",
"text": "Never gonna give you up...",
"segments": [
{
"text": "Never gonna give you up",
"start": 18.2,
"duration": 2.1
}
]
}{
"error": {
"code": "transcript_not_available",
"message": "Transcript is not available for this video."
}
}{
"error": {
"code": "transcript_not_available",
"message": "Transcript is not available for this video."
}
}The public response intentionally omits cache internals, API key identifiers, proxy details, diagnostics, caption track URLs, and upstream response bodies.
On small screens, errors are shown as cards so each code, status and action stays readable without horizontal dragging.
Missing or invalid API key.
The video_id is not a valid YouTube video ID.
The video_url is not a valid YouTube URL.
video_id and video_url were missing or both provided.
language/lang is malformed or too long.
language and lang were both provided.
No accessible captions were found.
YouTube/upstream transcript fetch failed.
The monthly quota for this key has been reached.
The request exceeded the current rate limit.
Rate limit store is unavailable when fail-closed mode is enabled.
Unexpected transcript fetch failure.
API keys use short-window rate limits and monthly quota controls. Successful transcript responses include X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset. Short-window throttling returns 429 rate_limited with Retry-After. Monthly quota exhaustion returns 429 quota_exceeded.
const response = await fetch(
"https://api.scority.ai/v1/youtube/transcript?video_id=dQw4w9WgXcQ",
{
headers: { "x-api-key": process.env.SCORITY_API_KEY! },
},
)
const result = await response.json()const response = await fetch(
"https://api.scority.ai/v1/youtube/transcript?video_id=dQw4w9WgXcQ",
{
headers: { "x-api-key": process.env.SCORITY_API_KEY! },
},
)
const result = await response.json()import os
import requests
response = requests.get(
"https://api.scority.ai/v1/youtube/transcript",
params={"video_id": "dQw4w9WgXcQ", "language": "en"},
headers={"x-api-key": os.environ["SCORITY_API_KEY"]},
timeout=30,
)
result = response.json()import os
import requests
response = requests.get(
"https://api.scority.ai/v1/youtube/transcript",
params={"video_id": "dQw4w9WgXcQ", "language": "en"},
headers={"x-api-key": os.environ["SCORITY_API_KEY"]},
timeout=30,
)
result = response.json()You can also import the OpenAPI document into Postman, Insomnia, Scalar, or another API client from https://api.scority.ai/openapi.json.