Library

Search indexed transcript passages in exactly one channel or video

Zero-credit BM25-ranked source-caption passages with timestamp watch URLs. Requires a Bearer API key and exactly one channel or video_id; the scope is applied during the index search. Channel membership requires confirmed public-listing provenance. A URL-only fetched video stays searchable by video_id until a listing confirms its channel; player metadata alone does not establish membership. ID-only membership records prior listing, not current public visibility, and survives the original 30-day expiry of titles and publication dates. No site-wide or cross-channel search. Queries support words, quoted phrases, and prefix terms only, up to 500 characters and 32 terms/phrases. Prefixes require at least three characters in the final word, including quoted phrase prefixes; shorter prefixes return 400 InvalidInput. Free allowance: 500 searches/key/UTC day; paid: 20,000. Repeated valid searches count. The daily allowance is enforced before upstream work; exhaustion returns 429 QuotaExceeded with Retry-After until 00:00 UTC. Normal key RPM also applies. Translation output is not indexed; coverage can lag cache delivery. Channel coverage is read from stored channel totals, without scanning the full video list or processing pending enumeration during search. API listing pages, RSS reads, indexing, coverage refreshes, and bounded background synchronization maintain the counters. Listings captured only through the free site can lag until synchronization.

get/v1/library/search

Request

  • Base URL: https://api.scripthaul.com
  • URL: https://api.scripthaul.com/v1/library/search
  • Auth: HTTP bearer

Query parameters

qstring required

Words, quoted phrases, or prefix terms, up to 32 terms or phrases. Prefixes need at least three characters in the final word, including quoted phrase prefixes. For example, educat* and "public pol"* are valid; e* is not.

channelstring

Channel scope, requiring confirmed public-listing membership for each video; mutually exclusive with video_id. Prior membership does not guarantee current public visibility.

video_idstring

Single-video scope; mutually exclusive with channel. Can search indexed captions for a URL-only fetched video without public-listing provenance.

limitinteger

Passages per page.

offsetinteger

Passage offset.

Response

Ranked passages; an empty results array means no match in indexed captions, not complete coverage.

okunknown required
querystring required
channelstring nullable required
video_idstring nullable required
limitinteger required
offsetinteger required

Changes

No recorded changes to this operation across all 1 revision of this API.