Method Summary
| Public Methods | ||
| public |
Fetch metadata of the album you create. |
|
| public |
fetchTracks(limit: number, offset: number): Promise Get tracks in an album. |
|
| public |
Get KKBOX web widget uri of the album. |
|
| public |
setAlbumID(albumID: string): AlbumFetcher Set the album fetcher. |
|
Inherited Summary
| From class Fetcher | ||
| public |
fetchNextPage(fulfillment: fulfillment, nextUriPath: String): Promise Fetches next page of various paged APIs. |
|
| public |
hasNextPage(fulfillment: fulfillment, nextUriPath: String): Boolean Is next page available for various paged APIs. |
|
| public |
setTerritory(territory: string): Fetcher Set the fetcher's territory. |
|
Public Methods
public fetchMetadata(): Promise source
Fetch metadata of the album you create.
Example:
api.albumFetcher.setAlbumID('KmRKnW5qmUrTnGRuxF').fetchMetadata();
public fetchTracks(limit: number, offset: number): Promise source
Get tracks in an album. Result will be return with pagination.
Example:
api.albumFetcher.setAlbumID('KmRKnW5qmUrTnGRuxF').fetchTracks();
public getWidgetUri(): string source
Get KKBOX web widget uri of the album.
Example:
https://widget.kkbox.com/v1/?id=4qtXcj31wYJTRZbb23&type=album
public setAlbumID(albumID: string): AlbumFetcher source
Set the album fetcher.
Params:
| Name | Type | Attribute | Description |
| albumID | string | The ID of an album. |
