streaming-availability
Version:
Streaming Availability API allows getting streaming availability information of movies and series; and querying the list of available shows on streaming services such as Netflix, Disney+, Apple TV, Max and Hulu across 60 countries!
184 lines (183 loc) • 10.1 kB
TypeScript
/**
* Streaming Availability API
* Streaming Availability API allows getting streaming availability information of movies and series; and querying the list of available shows on streaming services such as Netflix, Disney+, Apple TV, Max and Hulu across 60 countries!
*
* The version of the OpenAPI document: 4.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import * as runtime from '../runtime';
import type { OrderDirection, SearchResult, Show, ShowType } from '../models/index';
export interface GetShowRequest {
id: string;
country?: string;
seriesGranularity?: GetShowSeriesGranularityEnum;
outputLanguage?: GetShowOutputLanguageEnum;
}
export interface GetTopShowsRequest {
country: string;
service: string;
outputLanguage?: GetTopShowsOutputLanguageEnum;
showType?: ShowType;
}
export interface SearchShowsByFiltersRequest {
country: string;
catalogs?: Array<string>;
outputLanguage?: SearchShowsByFiltersOutputLanguageEnum;
showType?: ShowType;
genres?: Array<string>;
genresRelation?: SearchShowsByFiltersGenresRelationEnum;
showOriginalLanguage?: string;
yearMin?: number;
yearMax?: number;
ratingMin?: number;
ratingMax?: number;
keyword?: string;
seriesGranularity?: SearchShowsByFiltersSeriesGranularityEnum;
orderBy?: SearchShowsByFiltersOrderByEnum;
orderDirection?: OrderDirection;
cursor?: string;
}
export interface SearchShowsByTitleRequest {
title: string;
country: string;
showType?: ShowType;
seriesGranularity?: SearchShowsByTitleSeriesGranularityEnum;
outputLanguage?: SearchShowsByTitleOutputLanguageEnum;
}
/**
*
*/
export declare class ShowsApi extends runtime.BaseAPI {
/**
* Get the details of a show via id, imdbId or tmdbId, including the global streaming availability info.
* Get a Show
*/
getShowRaw(requestParameters: GetShowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Show>>;
/**
* Get the details of a show via id, imdbId or tmdbId, including the global streaming availability info.
* Get a Show
*/
getShow(requestParameters: GetShowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Show>;
/**
* Get the official top shows in a service. Top shows are determined by the streaming service itself. Supported streaming services are: - Netflix: netflix - Amazon Prime Video: prime - Disney+: disney - Apple TV: apple - Max: hbo For unsupported services, this endpoint will return an empty list. Series granularity is always show for this endpoint, meaning that the output will not include season and episode info.
* Get Top Shows
*/
getTopShowsRaw(requestParameters: GetTopShowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<Show>>>;
/**
* Get the official top shows in a service. Top shows are determined by the streaming service itself. Supported streaming services are: - Netflix: netflix - Amazon Prime Video: prime - Disney+: disney - Apple TV: apple - Max: hbo For unsupported services, this endpoint will return an empty list. Series granularity is always show for this endpoint, meaning that the output will not include season and episode info.
* Get Top Shows
*/
getTopShows(requestParameters: GetTopShowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<Show>>;
/**
* Search through the catalog of the given streaming services in the given country. Provides filters such as show language, genres, keyword and release year. Output includes all the information about the shows, such as title, IMDb ID, TMDb ID, release year, deep links to streaming services, available subtitles, audios, available video quality and many more! Apart from the info about the given country-service combinations, output also includes information about streaming availability in the other services for the given country. Streaming availability info from the other countries are not included in the response. When show_type is movie or series_granularity is show, items per page is 20. When show_type is series and series_granularity is episode items per page is 10. Otherwise, items per page is 15.
* Search Shows by filters
*/
searchShowsByFiltersRaw(requestParameters: SearchShowsByFiltersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SearchResult>>;
/**
* Search through the catalog of the given streaming services in the given country. Provides filters such as show language, genres, keyword and release year. Output includes all the information about the shows, such as title, IMDb ID, TMDb ID, release year, deep links to streaming services, available subtitles, audios, available video quality and many more! Apart from the info about the given country-service combinations, output also includes information about streaming availability in the other services for the given country. Streaming availability info from the other countries are not included in the response. When show_type is movie or series_granularity is show, items per page is 20. When show_type is series and series_granularity is episode items per page is 10. Otherwise, items per page is 15.
* Search Shows by filters
*/
searchShowsByFilters(requestParameters: SearchShowsByFiltersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SearchResult>;
/**
* Search for movies and series by a title. Maximum amount of items returned are 20 unless there are more than 20 shows with the exact given title input. In that case all the items have 100% match with the title will be returned. Streaming availability info for the target country is included in the response, but not for the other countries. Results might include shows that are not streamable in the target country. Only criteria for the search are the title and the show type. No pagination is supported.
* Search Shows by title
*/
searchShowsByTitleRaw(requestParameters: SearchShowsByTitleRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<Show>>>;
/**
* Search for movies and series by a title. Maximum amount of items returned are 20 unless there are more than 20 shows with the exact given title input. In that case all the items have 100% match with the title will be returned. Streaming availability info for the target country is included in the response, but not for the other countries. Results might include shows that are not streamable in the target country. Only criteria for the search are the title and the show type. No pagination is supported.
* Search Shows by title
*/
searchShowsByTitle(requestParameters: SearchShowsByTitleRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<Show>>;
}
/**
* @export
*/
export declare const GetShowSeriesGranularityEnum: {
readonly Show: "show";
readonly Season: "season";
readonly Episode: "episode";
};
export type GetShowSeriesGranularityEnum = typeof GetShowSeriesGranularityEnum[keyof typeof GetShowSeriesGranularityEnum];
/**
* @export
*/
export declare const GetShowOutputLanguageEnum: {
readonly En: "en";
readonly Es: "es";
readonly Tr: "tr";
readonly Fr: "fr";
};
export type GetShowOutputLanguageEnum = typeof GetShowOutputLanguageEnum[keyof typeof GetShowOutputLanguageEnum];
/**
* @export
*/
export declare const GetTopShowsOutputLanguageEnum: {
readonly En: "en";
readonly Es: "es";
readonly Tr: "tr";
readonly Fr: "fr";
};
export type GetTopShowsOutputLanguageEnum = typeof GetTopShowsOutputLanguageEnum[keyof typeof GetTopShowsOutputLanguageEnum];
/**
* @export
*/
export declare const SearchShowsByFiltersOutputLanguageEnum: {
readonly En: "en";
readonly Es: "es";
readonly Tr: "tr";
readonly Fr: "fr";
};
export type SearchShowsByFiltersOutputLanguageEnum = typeof SearchShowsByFiltersOutputLanguageEnum[keyof typeof SearchShowsByFiltersOutputLanguageEnum];
/**
* @export
*/
export declare const SearchShowsByFiltersGenresRelationEnum: {
readonly And: "and";
readonly Or: "or";
};
export type SearchShowsByFiltersGenresRelationEnum = typeof SearchShowsByFiltersGenresRelationEnum[keyof typeof SearchShowsByFiltersGenresRelationEnum];
/**
* @export
*/
export declare const SearchShowsByFiltersSeriesGranularityEnum: {
readonly Show: "show";
readonly Season: "season";
readonly Episode: "episode";
};
export type SearchShowsByFiltersSeriesGranularityEnum = typeof SearchShowsByFiltersSeriesGranularityEnum[keyof typeof SearchShowsByFiltersSeriesGranularityEnum];
/**
* @export
*/
export declare const SearchShowsByFiltersOrderByEnum: {
readonly OriginalTitle: "original_title";
readonly ReleaseDate: "release_date";
readonly Rating: "rating";
readonly PopularityAlltime: "popularity_alltime";
readonly Popularity1year: "popularity_1year";
readonly Popularity1month: "popularity_1month";
readonly Popularity1week: "popularity_1week";
};
export type SearchShowsByFiltersOrderByEnum = typeof SearchShowsByFiltersOrderByEnum[keyof typeof SearchShowsByFiltersOrderByEnum];
/**
* @export
*/
export declare const SearchShowsByTitleSeriesGranularityEnum: {
readonly Show: "show";
readonly Season: "season";
readonly Episode: "episode";
};
export type SearchShowsByTitleSeriesGranularityEnum = typeof SearchShowsByTitleSeriesGranularityEnum[keyof typeof SearchShowsByTitleSeriesGranularityEnum];
/**
* @export
*/
export declare const SearchShowsByTitleOutputLanguageEnum: {
readonly En: "en";
readonly Es: "es";
readonly Tr: "tr";
readonly Fr: "fr";
};
export type SearchShowsByTitleOutputLanguageEnum = typeof SearchShowsByTitleOutputLanguageEnum[keyof typeof SearchShowsByTitleOutputLanguageEnum];