IMDb API Documentation
Documentation and Online Test
Enter your API Key for testing APIs.
Register on site to get free API Key.
- All APIs are not case sensitive. You can using
Search
orsEArcH
! - If you are working with non-English languages, the
lang
parameter is important for the following actions: Title, Report, Subtitles, Wikipedia, Name
Search APIs
Title APIs
Search
Search is same as SearchTitle, search into all titles. It is recommended to use SearchMovie
or SearchSeries
to search for a movie or series.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. For examples "Leon The Professional" or "Inception". You can also search with year (ex: "Inception 2010") |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/Search/k_12345678/Inception 2010
- https://imdb-api.com/API/Search/k_12345678/leon the professional
- https://imdb-api.com/API/Search/k_12345678/lost 2004
Test
Search into all titles. It is recommended to use SearchMovieMovie
or SearchMovieSeries
to SearchMovie for a movie or series.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. For examples "Leon The Professional" or "Inception". You can also SearchTitle with year (ex: "Inception 2010") |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchTitle/k_12345678/Inception 2010
- https://imdb-api.com/en/API/SearchTitle/k_12345678/leon the professional
- https://imdb-api.com/en/API/SearchTitle/k_12345678/lost 2004
Test
Search into all Movies.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. For examples "Leon The Professional" or "Inception". You can also SearchMovie with year (ex: "Inception 2010") |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchMovie/k_12345678/Inception 2010
- https://imdb-api.com/en/API/SearchMovie/k_12345678/leon the professional
- https://imdb-api.com/en/API/SearchMovie/k_12345678/the patriot 2000
Test
Search into all Series TVs.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. For examples "Leon The Professional" or "Inception". You can also SearchSeries with year (ex: "Inception 2010") |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchSeries/k_12345678/lost 2004
- https://imdb-api.com/en/API/SearchSeries/k_12345678/fringe
- https://imdb-api.com/en/API/SearchSeries/k_12345678/The Leftovers 2014
Test
Search into all people.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. Searching people by name (Actors, Actresses, Directors, Writers and ...) |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchName/k_12345678/Jean Reno
- https://imdb-api.com/en/API/SearchName/k_12345678/mel gibson
- https://imdb-api.com/en/API/SearchName/k_12345678/Natalie Portman
Test
Search into all TV Episode titles.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchEpisode/k_12345678/London
- https://imdb-api.com/en/API/SearchEpisode/k_12345678/arsenal
- https://imdb-api.com/en/API/SearchEpisode/k_12345678/gunner
Test
Search into all companies.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchCompany/k_12345678/warner bross
- https://imdb-api.com/en/API/SearchCompany/k_12345678/disney
- https://imdb-api.com/en/API/SearchCompany/k_12345678/ABC Studios
Test
Search into all keywords.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchKeyword/k_12345678/gun
- https://imdb-api.com/en/API/SearchKeyword/k_12345678/battle
- https://imdb-api.com/en/API/SearchKeyword/k_12345678/love
Test
Search into all items (Movies, Series TVs, TV Episodes, Names, Companies, Keywords and more).
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in search action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
expression | Required | Expression for search. |
RESULT | SearchData |
Examples
- https://imdb-api.com/en/API/SearchAl/k_12345678l/Inception
- https://imdb-api.com/en/API/SearchAll/k_12345678/leon
- https://imdb-api.com/en/API/SearchAll/k_12345678/lost
Test
Title
Get Movies or Series TV information.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). PlotLocal and WikipediaPlot properties has been change by your selected language. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
options | Optional | Options to get more information about: FullActor , FullCast , Posters , Images , Trailer , Ratings , Wikipedia . |
RESULT | TitleData |
Tips: You can combine options
with apiKey
. ex: "..../tt1234567/FullCast,Images,k_1234567"Examples
Test
Options
Generate report from Movie or Series TV as PNG
image file.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). PlotLocal and WikipediaPlot properties has been change by your selected language. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
options | Optional | Options to get more information about: FullActor , FullCast , Ratings , Wikipedia . |
RESULT | PNG image file |
Tips: You can combine options
with apiKey
. ex: "..../tt1234567/FullCast,Wikipedia,k_1234567"Examples
Test
Options
Get all subtitles from Subscene as JSON. BETA: Currently only Farsi/Persian (fa) language is supported.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "fa" (Farsi/Persian). Currently only Farsi/Persian (fa) language is supported. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started with tt . |
seasonNumber | Optional | A integer number for get subtitles only on that season. It using for Series TVs. |
RESULT | SubtitleData |
Examples
- https://imdb-api.com/API/Subtitles/k_12345678/tt1375666
- https://imdb-api.com/fa/API/Subtitles/k_12345678/tt0110413
- https://imdb-api.com/fa/API/Subtitles/k_12345678/tt0411008/5
Test
Get full cast/crew and actors/actresses of Movie or Series TV.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | FullCastData |
Examples
- https://imdb-api.com/en/API/FullCast/k_12345678/tt1375666
- https://imdb-api.com/API/FullCast/k_12345678/tt0110413
- https://imdb-api.com/API/FullCast/k_12345678/tt0411008
Test
Get Posters of Movie or Series TV.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | PosterData |
Examples
- https://imdb-api.com/en/API/Posters/k_12345678/tt1375666
- https://imdb-api.com/API/Posters/k_12345678/tt0110413
- https://imdb-api.com/API/Posters/k_12345678/tt0411008
Test
Get images of Movie or Series TV or People (Name) (tt1234567) and Name (nm1234567).
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt or nm . |
options | Optional | Options can Short (default) or Full . Short parameter contains 48 images. Full parameter (tt only) contains all available images. |
RESULT | ImageData |
Examples
- https://imdb-api.com/en/API/Images/k_12345678/tt1375666
- https://imdb-api.com/API/Images/k_12345678/tt0110413/Full
- https://imdb-api.com/API/Images/k_12345678/nm0000154
Test
Options
Get trailers of Movie or Series TV.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | TrailerData |
Examples
- https://imdb-api.com/en/API/Trailer/k_12345678/tt1375666
- https://imdb-api.com/API/Trailer/k_12345678/tt0110413
- https://imdb-api.com/API/Trailer/k_12345678/tt0411008
Test
Get ratings of Movie or Series TV in: IMDb, Metacritic, RottenTomatoes, TheMovieDb and TV.com.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | RatingData |
Examples
- https://imdb-api.com/en/API/Ratings/k_12345678/tt1375666
- https://imdb-api.com/API/Ratings/k_12345678/tt0110413
- https://imdb-api.com/API/Ratings/k_12345678/tt0411008
Test
Get user ratings of Movie or Series TV with count of votes and details.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | UserRatingData |
Examples
- https://imdb-api.com/en/API/UserRatings/k_12345678/tt1375666
- https://imdb-api.com/API/UserRatings/k_12345678/tt0110413
- https://imdb-api.com/API/UserRatings/k_12345678/tt0411008
Test
Get episodes of season in Series TV.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
seasonNumber | Required | Season number to get episodes. |
RESULT | SeasonEpisodeData |
Examples
- https://imdb-api.com/en/API/SeasonEpisodes/k_12345678/tt0411008/1
- https://imdb-api.com/en/API/SeasonEpisodes/k_12345678/tt0411008/2
- https://imdb-api.com/en/API/SeasonEpisodes/k_12345678/tt0411008/3
Test
Get Movie or Series TV in all external sites with Identifier and URL.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | ExternalSiteData |
Examples
- https://imdb-api.com/en/API/ExternalSites/k_12345678/tt1375666
- https://imdb-api.com/API/ExternalSites/k_12345678/tt0110413
- https://imdb-api.com/API/ExternalSites/k_12345678/tt0411008
Test
Get Wikipedia plot of Movie or Series TV (tt1234567) as PlainText and Html.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language is important for return value of wikipedia plot. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | WikipediaData |
Examples
- https://imdb-api.com/en/API/Wikipedia/k_12345678/tt1375666
- https://imdb-api.com/API/Wikipedia/k_12345678/tt0110413
- https://imdb-api.com/API/Wikipedia/k_12345678/nm0000154
Test
Get data from IMDb List.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb List Id. Id started withs ls . |
RESULT | IMDbListData |
Examples
- https://imdb-api.com/en/API/IMDbList/k_12345678/ls004285275
- https://imdb-api.com/API/IMDbList/k_12345678/ls095521504
- https://imdb-api.com/API/IMDbList/k_12345678/ls093462543
Test
Others
Get Top 250 Movies.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | Top250Data |
Test
https://imdb-api.com/en/API/Top250Movies/k_12345678Get Top 250 Series TVs.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | Top250Data |
Test
https://imdb-api.com/en/API/Top250TVs/k_12345678Get Top 100 Most Polular Movies.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | MostPopularData |
Test
https://imdb-api.com/en/API/MostPopularMovies/k_12345678Get Top 100 Most Polular Series TVs.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | MostPopularData |
Test
https://imdb-api.com/en/API/MostPopularTVs/k_12345678Get In Theaters Movies.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | NewMovieData |
Test
https://imdb-api.com/en/API/InTheaters/k_12345678Get Coming Soon Movies.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | NewMovieData |
Test
https://imdb-api.com/en/API/ComingSoon/k_12345678Get Weekend Box Office.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | BoxOfficeWeekendData |
Test
https://imdb-api.com/en/API/BoxOffice/k_12345678Get Box Office in all times.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
RESULT | BoxOfficeAllTimeData |
Test
https://imdb-api.com/en/API/BoxOfficeAllTime/k_12345678Get information of people (actor, actress, director, writers, ...).
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Name Id. Id startd withs nm . |
RESULT | NameData |
Examples
- https://imdb-api.com/en/API/Name/k_12345678/nm0000154
- https://imdb-api.com/API/Name/k_12345678/nm0000606
- https://imdb-api.com/API/Name/k_12345678/nm0000204
Test
Get information of company with movies.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Company Id. Id started withs co . |
RESULT | CompanyData |
Examples
- https://imdb-api.com/en/API/Company/k_12345678/co0002663
- https://imdb-api.com/API/Company/k_12345678/co0178269
- https://imdb-api.com/API/Company/k_12345678/co0159111
Test
Get Movie or Series TVs in this keyword.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Keyword (already founded in SearchKeyword action) |
RESULT | KeywordData |
Examples
- https://imdb-api.com/en/API/Keyword/k_12345678/dramas
- https://imdb-api.com/API/Keyword/k_12345678/ghost-story
- https://imdb-api.com/API/Keyword/k_12345678/arsenal
Test
Get YouTube Trailer URL by IMDb Id.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
id | Required | A valid IMDb Id. Id started withs tt . |
RESULT | YouTubeTrailerData |
Examples
- https://imdb-api.com/en/API/YouTubeTrailer/k_12345678/tt1375666
- https://imdb-api.com/API/YouTubeTrailer/k_12345678/tt0110413
- https://imdb-api.com/API/YouTubeTrailer/k_12345678/tt0411008
Test
YouTube Downloader by Video Id or URL.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
v | Required | A valid YouTube Video Id or YouTube URL |
RESULT | YouTubeData |
Examples
- https://imdb-api.com/en/API/YouTube/k_12345678/8hP9D6kZseM
- https://imdb-api.com/API/YouTube?apiKey=k_12345678&v=https://www.youtube.com/watch?v=8hP9D6kZseM
- https://imdb-api.com/API/YouTube?apiKey=k_12345678&v=8hP9D6kZseM
Test
YouTube Downloader by Playlist Id or URL.
Parameters | Required | Description |
---|---|---|
lang | Optional | Language of results. Default value is "en" (English). Language change is not important in this action. |
apiKey | Required | API Key required for all API calls. Register on site to get free API Key. |
list | Required | A valid YouTube Playlist Id or YouTube Playlist URL |
RESULT | YouTubePlaylistData |
Examples
- https://imdb-api.com/en/API/YouTubePlaylist/k_12345678/PLReL099Y5nRd28Yv6c-Am9qURCrLMxBmK
- https://imdb-api.com/API/YouTubePlaylist?apiKey=k_12345678&list=https://www.youtube.com/playlist?list=PLReL099Y5nRd28Yv6c-Am9qURCrLMxBmK
- https://imdb-api.com/API/YouTubePlaylist?apiKey=k_12345678&list=PLReL099Y5nRd28Yv6c-Am9qURCrLMxBmK
Test
Download
Get Images by sizes.
Parameters | Required | Description |
---|---|---|
size | Required | Size of Image. default value is original. Examples: 8x11, 16x22, 32x44, 64x88, ... (Width x Height) |
RESULT | JPG image file |
Examples
- https://imdb-api.com/Images/original/MV5BMjAxMzY3NjcxNF5BMl5BanBnXkFtZTcwNTI5OTM0Mw@@._V1_Ratio0.6791_AL_.jpg
- https://imdb-api.com/Images/32x44/MV5BMjAxMzY3NjcxNF5BMl5BanBnXkFtZTcwNTI5OTM0Mw@@._V1_Ratio0.6791_AL_.jpg
- https://imdb-api.com/Images/192x264/MV5BMjAxMzY3NjcxNF5BMl5BanBnXkFtZTcwNTI5OTM0Mw@@._V1_Ratio0.6791_AL_.jpg
Test
Get Posters by sizes.
Parameters | Required | Description |
---|---|---|
size | Required | Size of Poster. default value is original. Supported Sizes Wide - Ratio 6:9/9:6 : original, w45, w92, w154, w185, w200, w300, w342, w400, w500, w780 and w1280 Square - Ratio 1:1 : s32, s45, s50, s64, s66, s90, s100, s115, s128, s132, s150, s180, s230, s235, s264, s300, s375, s470 |
RESULT | JPG image file |
Examples
- Posters
- https://imdb-api.com/Posters/original/n9dwu1p5G4qJ4DI5eHJMUbAdOfA.jpg
- https://imdb-api.com/Posters/w300/n9dwu1p5G4qJ4DI5eHJMUbAdOfA.jpg
- https://imdb-api.com/Posters/s300/n9dwu1p5G4qJ4DI5eHJMUbAdOfA.jpg
- Backdrops
- https://imdb-api.com/Posters/original/s2bT29y0ngXxxu2IA8AOzzXTRhd.jpg
- https://imdb-api.com/Posters/w300/s2bT29y0ngXxxu2IA8AOzzXTRhd.jpg
- https://imdb-api.com/Posters/s300/s2bT29y0ngXxxu2IA8AOzzXTRhd.jpg
Test
Code Snippet
Click on Language Programming to active
// IMDbApiLib Package on Nuget : https://nuget.org/packages/IMDbApiLib
var apiLib = new ApiLib("API-Key");
var data = await apiLib.TitleAsync("tt0110413");
var client = new RestClient("https://imdb-api.com/en/API/Title/k_1234567/tt1832382");
client.Timeout = -1;
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
CURL *curl;
CURLcode res;
curl = curl_easy_init();
if(curl) {
curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(curl, CURLOPT_URL, "https://imdb-api.com/en/API/Title/k_1234567/tt1832382");
curl_easy_setopt(curl, CURLOPT_FOLLOWLOCATION, 1L);
curl_easy_setopt(curl, CURLOPT_DEFAULT_PROTOCOL, "https");
struct curl_slist *headers = NULL;
curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
res = curl_easy_perform(curl);
}
curl_easy_cleanup(curl);
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://imdb-api.com/en/API/Title/k_1234567/tt1832382"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
OkHttpClient client = new OkHttpClient().newBuilder()
.build();
Request request = new Request.Builder()
.url("https://imdb-api.com/en/API/Title/k_1234567/tt1832382")
.method("GET", null)
.build();
Response response = client.newCall(request).execute();
Unirest.setTimeouts(0, 0);
HttpResponse response = Unirest.get("https://imdb-api.com/en/API/Title/k_1234567/tt1832382")
.asString();
var requestOptions = {
method: 'GET',
redirect: 'follow'
};
fetch('https://imdb-api.com/en/API/Title/k_1234567/tt1832382', requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));
var settings = {
"url": "https://imdb-api.com/en/API/Title/k_1234567/tt1832382",
"method": "GET",
"timeout": 0,
};
$.ajax(settings).done(function (response) {
console.log(response);
});
var xhr = new XMLHttpRequest();
xhr.addEventListener("readystatechange", function() {
if(this.readyState === 4) {
console.log(this.responseText);
}
});
xhr.open("GET", "https://imdb-api.com/en/API/Title/k_1234567/tt1832382");
xhr.send();
var https = require('follow-redirects').https;
var fs = require('fs');
var options = {
'method': 'GET',
'hostname': 'imdb-api.com',
'port': 443,
'path': '/en/API/Title/k_1234567/tt1832382',
'headers': {
},
'maxRedirects': 20
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
var request = require('request');
var options = {
'method': 'GET',
'url': 'https://imdb-api.com/en/API/Title/k_1234567/tt1832382',
'headers': {
}
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
var unirest = require('unirest');
var req = unirest('GET', 'https://imdb-api.com/en/API/Title/k_1234567/tt1832382')
.end(function (res) {
if (res.error) throw new Error(res.error);
console.log(res.raw_body);
});
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://imdb-api.com/en/API/Title/k_1234567/tt1832382",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
<?php
require_once 'HTTP/Request2.php';
$request = new HTTP_Request2();
$request->setUrl('https://imdb-api.com/en/API/Title/k_1234567/tt1832382');
$request->setMethod(HTTP_Request2::METHOD_GET);
$request->setConfig(array(
'follow_redirects' => TRUE
));
try {
$response = $request->send();
if ($response->getStatus() == 200) {
echo $response->getBody();
} else {
echo 'Unexpected HTTP status: ' . $response->getStatus() . ' ' .
$response->getReasonPhrase();
}
} catch(HTTP_Request2_Exception $e) {
echo 'Error: ' . $e->getMessage();
}
<?php
$client = new http\Client;
$request = new http\Client\Request;
$request->setRequestUrl('https://imdb-api.com/en/API/Title/k_1234567/tt1832382');
$request->setRequestMethod('GET');
$request->setOptions(array());
$client->enqueue($request)->send();
$response = $client->getResponse();
echo $response->getBody();
$response = Invoke-RestMethod 'https://imdb-api.com/en/API/Title/k_1234567/tt1832382' -Method 'GET' -Headers $headers -Body $body
$response | ConvertTo-Json
import http.client
import mimetypes
conn = http.client.HTTPSConnection("imdb-api.com", 443)
payload = ''
headers = {}
conn.request("GET", "/en/API/Title/k_1234567/tt1832382", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
import requests
url = "https://imdb-api.com/en/API/Title/k_1234567/tt1832382"
payload = {}
headers= {}
response = requests.request("GET", url, headers=headers, data = payload)
print(response.text.encode('utf8'))
require "uri"
require "net/http"
url = URI("https://imdb-api.com/en/API/Title/k_1234567/tt1832382")
https = Net::HTTP.new(url.host, url.port);
https.use_ssl = true
request = Net::HTTP::Get.new(url)
response = https.request(request)
puts response.read_body
import Foundation
var semaphore = DispatchSemaphore (value: 0)
var request = URLRequest(url: URL(string: "https://imdb-api.com/en/API/Title/k_1234567/tt1832382")!,timeoutInterval: Double.infinity)
request.httpMethod = "GET"
let task = URLSession.shared.dataTask(with: request) { data, response, error in
guard let data = data else {
print(String(describing: error))
return
}
print(String(data: data, encoding: .utf8)!)
semaphore.signal()
}
task.resume()
semaphore.wait()