-
-
Notifications
You must be signed in to change notification settings - Fork 494
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
I'm not sure where to put this file, but for now I will put it here Signed-off-by: Charles Giann Marcelo <cm122927@gmail.com>
- Loading branch information
1 parent
c95f805
commit fefb055
Showing
1 changed file
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
declare module 'genius-lyrics-api' { | ||
interface SearchOptions { | ||
apiKey: string; | ||
title: string; | ||
artist?: string; | ||
optimizeQuery?: boolean; | ||
} | ||
|
||
interface Song { | ||
id: number; | ||
title: string; | ||
url: string; | ||
} | ||
|
||
interface LyricsOptions { | ||
title: string; | ||
artist: string; | ||
} | ||
|
||
interface AlbumArtOptions { | ||
title: string; | ||
artist: string; | ||
} | ||
|
||
interface SongByIdOptions { | ||
id: number; | ||
apiKey: string; | ||
} | ||
|
||
export function search(options: SearchOptions): Promise<Song[]>; | ||
export function getSong(options: { id: number; apiKey: string }): Promise<Song>; | ||
export function getLyrics(options: LyricsOptions): Promise<string>; | ||
export function getAlbumArt(options: AlbumArtOptions): Promise<string>; | ||
export function getSongById(options: SongByIdOptions): Promise<Song>; | ||
export function searchSong(options: SearchOptions): Promise<Song[]>; | ||
} |