TMDB API endpoint
Searches TMDB movies, TV shows, people, and collections. An unscoped query interleaves results across all four types rather than returning whichever type happens to rank first.
/tmdb/searchQuery parameters:
query (required) — search query.type (optional) — result type filter. Allowed values: movie, tv, person, collection. Omit for mixed results.page (optional, default 1) — 1-based results page.limit (optional, default 10, max 20).Response includes page, has_next_page, and results[]. Field availability on each result varies by type: movie/tv hits carry release_date and overview; collection hits carry overview; person hits are title+uri only. Scoped searches use TMDB's dedicated result page for that type.
TMDB's search page groups hits into per-type sections rather than a single relevance-ranked list, and section order varies by query. An unscoped (mixed) search round-robins across movie/tv/person/collection so the response is an actual mix, rather than exhausting limit on whichever section happens to come first upstream for a given query.
| Field | Filled in, of 20 checked | Values in the sample |
|---|---|---|
| type | 20 | movie (11), tv (8), person (1) |
| id | 20 | |
| title | 20 | “Inception” and 15 other values |
| release_date | 16 | “July 15, 2010” and 14 other values |
| overview | 18 | median 230 characters |
| uri | 20 | themoviedb.org |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| query | string | Yes | Search query | Inception | |
| type | string | No | Optional result type filter Allowed values: movie, tv, person, collection. | ||
| page | integer | No | 1-based results page, default 1 | ||
| limit | integer | No | Max results, default 10, max 20 | ||
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/tmdb/search?query=Inception&type=movie&page=1&limit=10" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"query": "batman",
"page": 2,
"has_next_page": true,
"results": [
{
"type": "movie",
"id": "268",
"title": "Batman",
"release_date": "June 21, 1989",
"overview": "Having witnessed his parents' brutal murder as a child, mill...",
"uri": "https://www.themoviedb.org/movie/268-batman"
},
{
"type": "tv",
"id": "2287",
"title": "Batman",
"release_date": "January 12, 1966",
"uri": "https://www.themoviedb.org/tv/2287-batman"
},
{
"type": "collection",
"id": "120794",
"title": "Batman Collection",
"overview": "A collection of Batman films.",
"uri": "https://www.themoviedb.org/collection/120794-batman-collection"
},
{
"type": "person",
"id": "3568848",
"title": "batman",
"uri": "https://www.themoviedb.org/person/3568848-batman"
}
],
"source_url": "https://www.themoviedb.org/search?page=2&query=batman"
}
}Request schema
No body schema
Response schema
#/definitions/tmdb.searchResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | 200 | |||
| data | tmdb.SearchResponse | No | ||||
| data.has_next_page | boolean | No | True when more pages of results are available. | |||
| data.page | integer | No | Page number returned. | |||
| data.query | string | No | Search text that was run. | |||
| data.results | array | No | Search hits on this page, one item per movie, TV show, person or collection. | |||
| data.results[].id | string | No | TMDB id of the hit. Use it with the matching detail endpoint. | |||
| data.results[].overview | string | No | Short plot summary or description. Present for movie, TV and collection hits. | |||
| data.results[].release_date | string | No | Release or first air date as TMDB shows it. Present for movie and TV hits. | |||
| data.results[].title | string | No | Title of the movie, TV show or collection, or name of the person. | |||
| data.results[].type | string | No | movie | Kind of hit: `movie`, `tv`, `person` or `collection`. | ||
| data.results[].uri | string | No | Link to the hit's page on TMDB. | |||
| data.source_url | string | No | URL the data was read from. | |||
| data.type | string | No | Result type the search was limited to: `movie`, `tv`, `person` or `collection`. Omitted for a mixed search. | |||
| msg | string | No | OK |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 500 | Internal Server Error | #/definitions/app.Response |
| 503 | Service Unavailable | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/tmdb/search?query=Inception&type=movie&page=1&limit=10" \
-H "x-api-key: $CRAWLORA_API_KEY"