LibraryApi - functional programming interface

  • Parameters

    Returns {
        deleteItem(itemId: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
        deleteItems(ids?: string[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
        getAncestors(itemId: string, userId?: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDto[]>)>;
        getCriticReviews(itemId: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getDownload(itemId: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<File>)>;
        getFile(itemId: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<File>)>;
        getItemCounts(userId?: string, isFavorite?: boolean, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<ItemCounts>)>;
        getLibraryOptionsInfo(libraryContentType?: CollectionType, isNewLibrary?: boolean, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<LibraryOptionsResultDto>)>;
        getMediaFolders(isHidden?: boolean, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getPhysicalPaths(options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<string[]>)>;
        getSimilarAlbums(itemId: string, excludeArtistIds?: string[], userId?: string, limit?: number, fields?: ItemFields[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getSimilarArtists(itemId: string, excludeArtistIds?: string[], userId?: string, limit?: number, fields?: ItemFields[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getSimilarItems(itemId: string, excludeArtistIds?: string[], userId?: string, limit?: number, fields?: ItemFields[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getSimilarMovies(itemId: string, excludeArtistIds?: string[], userId?: string, limit?: number, fields?: ItemFields[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getSimilarShows(itemId: string, excludeArtistIds?: string[], userId?: string, limit?: number, fields?: ItemFields[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getSimilarTrailers(itemId: string, excludeArtistIds?: string[], userId?: string, limit?: number, fields?: ItemFields[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>;
        getThemeMedia(itemId: string, userId?: string, inheritFromParent?: boolean, sortBy?: ItemSortBy[], sortOrder?: SortOrder[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<AllThemeMediaResult>)>;
        getThemeSongs(itemId: string, userId?: string, inheritFromParent?: boolean, sortBy?: ItemSortBy[], sortOrder?: SortOrder[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<ThemeMediaResult>)>;
        getThemeVideos(itemId: string, userId?: string, inheritFromParent?: boolean, sortBy?: ItemSortBy[], sortOrder?: SortOrder[], options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<ThemeMediaResult>)>;
        postAddedMovies(tmdbId?: string, imdbId?: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
        postAddedSeries(tvdbId?: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
        postUpdatedMedia(mediaUpdateInfoDto: MediaUpdateInfoDto, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
        postUpdatedMovies(tmdbId?: string, imdbId?: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
        postUpdatedSeries(tvdbId?: string, options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
        refreshLibrary(options?: RawAxiosRequestConfig): Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>;
    }

    • deleteItem:function
      • Parameters

        • itemId: string

          The item id.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Deletes an item from the library and filesystem.

    • deleteItems:function
      • Parameters

        • Optionalids: string[]

          The item ids.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Deletes items from the library and filesystem.

    • getAncestors:function
      • Parameters

        • itemId: string

          The item id.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDto[]>)>

        Gets all parents of an item.

    • getCriticReviews:function
      • Parameters

        • itemId: string
        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets critic review for an item.

    • getDownload:function
      • Parameters

        • itemId: string

          The item id.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<File>)>

        Downloads item media.

    • getFile:function
      • Parameters

        • itemId: string

          The item id.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<File>)>

        Get the original file of an item.

    • getItemCounts:function
      • Parameters

        • OptionaluserId: string

          Optional. Get counts from a specific user&#39;s library.

        • OptionalisFavorite: boolean

          Optional. Get counts of favorite items.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<ItemCounts>)>

        Get item counts.

    • getLibraryOptionsInfo:function
      • Parameters

        • OptionallibraryContentType: CollectionType

          Library content type.

        • OptionalisNewLibrary: boolean

          Whether this is a new library.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<LibraryOptionsResultDto>)>

        Gets the library options info.

    • getMediaFolders:function
      • Parameters

        • OptionalisHidden: boolean

          Optional. Filter by folders that are marked hidden, or not.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets all user media folders.

    • getPhysicalPaths:function
      • Parameters

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<string[]>)>

        Gets a list of physical paths from virtual folders.

    • getSimilarAlbums:function
      • Parameters

        • itemId: string

          The item id.

        • OptionalexcludeArtistIds: string[]

          Exclude artist ids.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • Optionallimit: number

          Optional. The maximum number of records to return.

        • Optionalfields: ItemFields[]

          Optional. Specify additional fields of information to return in the output. This allows multiple, comma delimited. Options: Budget, Chapters, DateCreated, Genres, HomePageUrl, IndexOptions, MediaStreams, Overview, ParentId, Path, People, ProviderIds, PrimaryImageAspectRatio, Revenue, SortName, Studios, Taglines, TrailerUrls.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets similar items.

    • getSimilarArtists:function
      • Parameters

        • itemId: string

          The item id.

        • OptionalexcludeArtistIds: string[]

          Exclude artist ids.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • Optionallimit: number

          Optional. The maximum number of records to return.

        • Optionalfields: ItemFields[]

          Optional. Specify additional fields of information to return in the output. This allows multiple, comma delimited. Options: Budget, Chapters, DateCreated, Genres, HomePageUrl, IndexOptions, MediaStreams, Overview, ParentId, Path, People, ProviderIds, PrimaryImageAspectRatio, Revenue, SortName, Studios, Taglines, TrailerUrls.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets similar items.

    • getSimilarItems:function
      • Parameters

        • itemId: string

          The item id.

        • OptionalexcludeArtistIds: string[]

          Exclude artist ids.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • Optionallimit: number

          Optional. The maximum number of records to return.

        • Optionalfields: ItemFields[]

          Optional. Specify additional fields of information to return in the output. This allows multiple, comma delimited. Options: Budget, Chapters, DateCreated, Genres, HomePageUrl, IndexOptions, MediaStreams, Overview, ParentId, Path, People, ProviderIds, PrimaryImageAspectRatio, Revenue, SortName, Studios, Taglines, TrailerUrls.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets similar items.

    • getSimilarMovies:function
      • Parameters

        • itemId: string

          The item id.

        • OptionalexcludeArtistIds: string[]

          Exclude artist ids.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • Optionallimit: number

          Optional. The maximum number of records to return.

        • Optionalfields: ItemFields[]

          Optional. Specify additional fields of information to return in the output. This allows multiple, comma delimited. Options: Budget, Chapters, DateCreated, Genres, HomePageUrl, IndexOptions, MediaStreams, Overview, ParentId, Path, People, ProviderIds, PrimaryImageAspectRatio, Revenue, SortName, Studios, Taglines, TrailerUrls.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets similar items.

    • getSimilarShows:function
      • Parameters

        • itemId: string

          The item id.

        • OptionalexcludeArtistIds: string[]

          Exclude artist ids.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • Optionallimit: number

          Optional. The maximum number of records to return.

        • Optionalfields: ItemFields[]

          Optional. Specify additional fields of information to return in the output. This allows multiple, comma delimited. Options: Budget, Chapters, DateCreated, Genres, HomePageUrl, IndexOptions, MediaStreams, Overview, ParentId, Path, People, ProviderIds, PrimaryImageAspectRatio, Revenue, SortName, Studios, Taglines, TrailerUrls.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets similar items.

    • getSimilarTrailers:function
      • Parameters

        • itemId: string

          The item id.

        • OptionalexcludeArtistIds: string[]

          Exclude artist ids.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • Optionallimit: number

          Optional. The maximum number of records to return.

        • Optionalfields: ItemFields[]

          Optional. Specify additional fields of information to return in the output. This allows multiple, comma delimited. Options: Budget, Chapters, DateCreated, Genres, HomePageUrl, IndexOptions, MediaStreams, Overview, ParentId, Path, People, ProviderIds, PrimaryImageAspectRatio, Revenue, SortName, Studios, Taglines, TrailerUrls.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<BaseItemDtoQueryResult>)>

        Gets similar items.

    • getThemeMedia:function
      • Parameters

        • itemId: string

          The item id.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • OptionalinheritFromParent: boolean

          Optional. Determines whether or not parent items should be searched for theme media.

        • OptionalsortBy: ItemSortBy[]

          Optional. Specify one or more sort orders, comma delimited. Options: Album, AlbumArtist, Artist, Budget, CommunityRating, CriticRating, DateCreated, DatePlayed, PlayCount, PremiereDate, ProductionYear, SortName, Random, Revenue, Runtime.

        • OptionalsortOrder: SortOrder[]

          Optional. Sort Order - Ascending, Descending.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<AllThemeMediaResult>)>

        Get theme songs and videos for an item.

    • getThemeSongs:function
      • Parameters

        • itemId: string

          The item id.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • OptionalinheritFromParent: boolean

          Optional. Determines whether or not parent items should be searched for theme media.

        • OptionalsortBy: ItemSortBy[]

          Optional. Specify one or more sort orders, comma delimited. Options: Album, AlbumArtist, Artist, Budget, CommunityRating, CriticRating, DateCreated, DatePlayed, PlayCount, PremiereDate, ProductionYear, SortName, Random, Revenue, Runtime.

        • OptionalsortOrder: SortOrder[]

          Optional. Sort Order - Ascending, Descending.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<ThemeMediaResult>)>

        Get theme songs for an item.

    • getThemeVideos:function
      • Parameters

        • itemId: string

          The item id.

        • OptionaluserId: string

          Optional. Filter by user id, and attach user data.

        • OptionalinheritFromParent: boolean

          Optional. Determines whether or not parent items should be searched for theme media.

        • OptionalsortBy: ItemSortBy[]

          Optional. Specify one or more sort orders, comma delimited. Options: Album, AlbumArtist, Artist, Budget, CommunityRating, CriticRating, DateCreated, DatePlayed, PlayCount, PremiereDate, ProductionYear, SortName, Random, Revenue, Runtime.

        • OptionalsortOrder: SortOrder[]

          Optional. Sort Order - Ascending, Descending.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<ThemeMediaResult>)>

        Get theme videos for an item.

    • postAddedMovies:function
      • Parameters

        • OptionaltmdbId: string

          The tmdbId.

        • OptionalimdbId: string

          The imdbId.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Reports that new movies have been added by an external source.

    • postAddedSeries:function
      • Parameters

        • OptionaltvdbId: string

          The tvdbId.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Reports that new episodes of a series have been added by an external source.

    • postUpdatedMedia:function
      • Parameters

        • mediaUpdateInfoDto: MediaUpdateInfoDto

          The update paths.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Reports that new movies have been added by an external source.

    • postUpdatedMovies:function
      • Parameters

        • OptionaltmdbId: string

          The tmdbId.

        • OptionalimdbId: string

          The imdbId.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Reports that new movies have been added by an external source.

    • postUpdatedSeries:function
      • Parameters

        • OptionaltvdbId: string

          The tvdbId.

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Reports that new episodes of a series have been added by an external source.

    • refreshLibrary:function
      • Parameters

        • Optionaloptions: RawAxiosRequestConfig

          Override http request option.

        Returns Promise<((axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>)>

        Starts a library scan.