- Documentation
- Key Concepts
- Release Notes
Sample queries: Search
Learn the basic functions of searching for titles and names by using our main search within the graph.
Supported on the Ratings, IMDb Title and Name Essentials, and Box Office API products.
Get the top 5 movie titles that most closely match the search term 'Goodfellas'.
To request the titleText of the top 5 titles that closely match the search term 'Goodfellas', the query would include the following:
- QUERY
- RESULT
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
query {
# Get the top 5 movie titles that most closely match the search term Goodfellas.
mainSearch(
first: 5
options: {
searchTerm: "Goodfellas"
isExactMatch: false
type: TITLE
titleSearchOptions: { type: MOVIE }
}
) {
edges {
node {
entity {
# For returned Titles, get me the id and title text
... on Title {
id
titleText {
text
}
}
}
}
}
}
}
Result size: 464 bytes
The response returns 5 titles that closely match the search term 'Goodfellas'.
Get the top 10 name recommendations that match the search term 'Jennifer'.
To request the nameText of the top 10 names that closely match the search term 'Jennifer', the query would include the following:
- QUERY
- RESULT
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
query {
# Get the top 10 name recommendations that match the search term Jennifer.
mainSearch(
first: 5
options: {
searchTerm: "Jennifer"
type: NAME,
includeAdult:false,
}
) {
edges {
node {
entity {
# For returned Names, get me the id and name text
... on Name {
id
nameText {
text
}
}
}
}
}
}
}
Result size: 423
The response returns 10 names that closely match the search term 'Jennifer'.
Retrieve a list of all action movies that were released after 2010 and have been honored with an Academy Award.
In order to obtain the originalTitleText of action movies that have received Academy Awards after 2010, the query would include the following:
- QUERY
- RESULT
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
query {
advancedTitleSearch(
first: 100
constraints: {
awardConstraint: {
allEventNominations: [
{ eventId: "ev0000003", winnerFilter: WINNER_ONLY }
]
}
genreConstraint: { allGenreIds: ["Action"] }
titleTypeConstraint: { anyTitleTypeIds: ["movie"] }
releaseDateConstraint: { releaseDateRange: { start: "2010-01-01" } }
}
) {
edges {
node {
title {
originalTitleText {
text
}
}
}
}
}
}
Result size: 1,886 bytes
The generated response comprises a comprehensive list of all action movies that have received an Academy Award and were released after 2010.
Explore IMDb data schema and developer documentation for IMDb and Box Office Mojo data products or contact us about APIs and widgets