You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+18-17Lines changed: 18 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -4,8 +4,6 @@
4
4
5
5
YouTube Music API (Unofficial) is a YouTube Music data scraper. It comes with TypeScript support API for return types. The NPM package can be found [here](https://npmjs.com/package/ytmusic-api)
6
6
7
-
**Full documentation is available [here](http://ytmusic-api.zectan.com).**
8
-
9
7
## Motivation
10
8
11
9
I used to use [youtube-music-api](https://npmjs.com/package/youtube-music-api) as my youtube music api data scraper. I liked looking into the source code of how it works but it never made sense to me. I also didn't like that there were no TypeScript annotations for the return types of methods.
@@ -22,45 +20,48 @@ Because of this, I decided to build my own version of a youtube music api with T
22
20
- Artists
23
21
- Albums
24
22
- Playlists
23
+
- Lyrics
24
+
25
+
## Usage
26
+
27
+
```js
28
+
importYTMusicfrom"ytmusic-api"
29
+
30
+
constytmusic=newYTMusic()
31
+
awaitytmusic.initialize(/* Optional: Custom cookies */)
32
+
33
+
ytmusic.search("Never gonna give you up").then(songs=> {
34
+
console.log(songs)
35
+
})
36
+
```
25
37
26
38
## Credits
27
39
28
40
A lot of the credit should go to [youtube-music-api](https://npmjs.com/package/youtube-music-api). I build this package as a refactored and tested version of youtube-music-api with TypeScript annotations
29
41
30
42
## Testing
31
43
32
-
YTMusic API's data return types are tested with Mocha. To run the tests, run the command
44
+
YTMusic API's data return types are tested with Bun Test. To run the tests, run the command
0 commit comments