Gathering detailed insights and metrics for spotify-url-info
Gathering detailed insights and metrics for spotify-url-info
Gathering detailed insights and metrics for spotify-url-info
Gathering detailed insights and metrics for spotify-url-info
npm install spotify-url-info
Typescript
Module System
Min. Node Version
Node Version
NPM Version
87.8
Supply Chain
95.9
Quality
80.8
Maintenance
100
Vulnerability
100
License
JavaScript (100%)
Total Downloads
4,988,825
Last Day
598
Last Week
9,528
Last Month
37,400
Last Year
468,290
MIT License
77 Stars
249 Commits
18 Forks
4 Watchers
1 Branches
9 Contributors
Updated on May 31, 2025
Minified
Minified + Gzipped
Latest Version
3.2.18
Package Id
spotify-url-info@3.2.18
Unpacked Size
12.24 kB
Size
4.89 kB
File Count
4
NPM Version
10.9.0
Node Version
22.11.0
Published on
Nov 17, 2024
Cumulative downloads
Total Downloads
Last Day
-31.8%
598
Compared to previous day
Last Week
9.6%
9,528
Compared to previous week
Last Month
-10.3%
37,400
Compared to previous month
Last Year
-16.5%
468,290
Compared to previous year
Get metadata from Spotify URLs.
1npm install spotify-url-info
In order to use the library, you have to provide the fetch agent to use:
1const fetch = require('isomorphic-unfetch') 2const { getData, getPreview, getTracks, getDetails } = 3 require('spotify-url-info')(fetch)
There are four functions:
getData
Provides the full available data, in a shape that is very similar to what the spotify API returns.
getPreview
Always returns the same fields for different types of resources (album, artist, playlist, track). The preview track is the first in the Album, Playlist, etc.
getTracks
Returns array with tracks. This data is passed on straight from spotify, so the shape could change.Only the first 100 tracks will be returned.
getDetails
Returns both the preview and tracks. Should be used if you require information from both of them so that only one request is made.
All the methods receive a Spotify URL (play. or open.) as first argument:
1getPreview('https://open.spotify.com/track/5nTtCOCds6I0PHMNtqelas').then(data =>
2 console.log(data)
3)
Additionally, you can provide fetch agent options as second argument:
1getPreview('https://open.spotify.com/track/5nTtCOCds6I0PHMNtqelas', {
2 headers: {
3 'user-agent': 'googlebot'
4 }
5}).then(data => console.log(data))
It returns back the information related to the Spotify URL:
1{ 2 "title": "Immaterial", 3 "type": "track", 4 "track": "Immaterial", 5 "artist": "SOPHIE", 6 "image": "https://i.scdn.co/image/d6f496a6708d22a2f867e5acb84afb0eb0b07bc1", 7 "audio": "https://p.scdn.co/mp3-preview/6be8eb12ff18ae09b7a6d38ff1e5327fd128a74e?cid=162b7dc01f3a4a2ca32ed3cec83d1e02", 8 "link": "https://open.spotify.com/track/5nTtCOCds6I0PHMNtqelas", 9 "embed": "https://embed.spotify.com/?uri=spotify:track:5nTtCOCds6I0PHMNtqelas", 10 "date": "2018-06-15T00:00:00.000Z", 11 "description": "description of a podcast episode" 12}
When a field can't be retrieved, the value will be undefined
.
There are no guarantees about the shape of this data, because it varies with different media and scraping methods. Handle it carefully.
spotify-url-info © microlink.io, released under the MIT License.
Authored by Karl Sander and maintained by Kiko Beats with help from contributors.
microlink.io · GitHub microlink.io · X @microlinkhq
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
Found 1/21 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
dangerous workflow patterns detected
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-06-09
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More