anton-fedosieiev-sdk
Version:
59 lines (58 loc) • 2.29 kB
TypeScript
import { BookService, MovieService, CharacterService, QuoteService, ChapterService } from './apiServices';
import { UserRequestParams } from './types';
declare type InitParams = {
apiKey?: string;
};
export declare class LotrSdk {
readonly _apiKey: string | undefined;
readonly _bookService: BookService;
readonly _movieService: MovieService;
readonly _characterService: CharacterService;
readonly _quotesService: QuoteService;
readonly _chaptersService: ChapterService;
constructor({ apiKey }?: InitParams);
getBooksList(params?: UserRequestParams): Promise<import("./types").BooksListResponse>;
getBook(id: string): Promise<import("./types").Book>;
getBookChapters(id: string, params?: UserRequestParams): Promise<import("./types").ChaptersListResponse>;
getMoviesList(params?: UserRequestParams): Promise<{
success: boolean;
message: string;
} | import("./types").MoviesListResponse>;
getMovie(id: string): Promise<{
success: boolean;
message: string;
} | import("./types").Movie>;
getMovieQuotes(id: string, params?: UserRequestParams): Promise<{
success: boolean;
message: string;
} | import("./types").ChaptersListResponse>;
getCharactersList(params?: UserRequestParams): Promise<{
success: boolean;
message: string;
} | import("./types").MoviesListResponse>;
getCharacter(id: string): Promise<{
success: boolean;
message: string;
} | import("./types").Movie>;
getCharacterQuotes(id: string, params?: UserRequestParams): Promise<{
success: boolean;
message: string;
} | import("./types").ChaptersListResponse>;
getQuotesList(params?: UserRequestParams): Promise<{
success: boolean;
message: string;
} | import("./types").QuotesListResponse>;
getQuote(id: string): Promise<{
success: boolean;
message: string;
} | import("./types").Quote>;
getChaptersList(params?: UserRequestParams): Promise<{
success: boolean;
message: string;
} | import("./types").ChaptersListResponse>;
getChapter(id: string): Promise<{
success: boolean;
message: string;
} | import("./types").Chapter>;
}
export * from './types';