UNPKG

bandcamp-fetch

Version:
48 lines 1.93 kB
import BaseAPIWithImageSupport, { type BaseAPIWithImageSupportParams } from '../common/BaseAPIWithImageSupport.js'; import type Album from '../types/Album.js'; import type Artist from '../types/Artist.js'; import { type ImageFormat } from '../types/Image.js'; import { type LabelArtist } from '../types/Label.js'; import type Label from '../types/Label.js'; import type Track from '../types/Track.js'; import type Limiter from '../utils/Limiter.js'; export interface BandAPIGetDiscographyParams { bandUrl: string; imageFormat?: string | number | ImageFormat; } export interface BandAPIGetInfoParams { bandUrl: string; imageFormat?: string | number | ImageFormat; labelId?: number; } export interface BandAPIGetLabelArtistsParams { labelUrl: string; imageFormat?: string | number | ImageFormat; } export default class BandAPI extends BaseAPIWithImageSupport { getDiscography(params: BandAPIGetDiscographyParams): Promise<Array<Album | Track>>; getInfo(params: BandAPIGetInfoParams): Promise<Artist | Label>; getLabelArtists(params: BandAPIGetLabelArtistsParams): Promise<LabelArtist[]>; /** * @internal */ protected static getUrl(artistOrLabelUrl: string, path?: string, labelId?: string): string; /** * @internal */ protected static isInfoComplete(data: Artist | Label): true | "" | Label | undefined; /** * @internal */ protected static fillInfo<T extends Artist | Label>(target: T, src: T): T; } export declare class LimiterBandAPI extends BandAPI { #private; constructor(params: BaseAPIWithImageSupportParams & { limiter: Limiter; }); getDiscography(params: BandAPIGetDiscographyParams): Promise<(Album | Track)[]>; getInfo(params: BandAPIGetInfoParams): Promise<Artist | Label>; getLabelArtists(params: BandAPIGetLabelArtistsParams): Promise<LabelArtist[]>; } //# sourceMappingURL=BandAPI.d.ts.map