
Research
NPM targeted by malware campaign mimicking familiar library names
Socket uncovered npm malware campaign mimicking popular Node.js libraries and packages from other ecosystems; packages steal data and execute remote code.
🌿 Retrieve information about a song, including details like the artist, album, release date, genres, and lyrics using Spotify and MusixMatch API
🌿 PyMusix, a tool that lets you retrieve information about a song, including details like the artist, album, release date, genres, lyrics and more. Uses Spotify and Musixmatch APIs to gather this information.
Install the Stable Version of pymusix from PyPi:
# Linux/macOS
python3 -m pip install -U pymusix
# Windows
py -3 -m pip install -U pymusix
OR Install the Working Version of pymusix from Github:
Clone the GitHub repository:
git clone https://github.com/TrueMyst/pymusix.git
cd pymusix
Install the required dependencies:
pip install -r requirements.txt
After installing it anyway, set up the environment variables by creating a .env
file in your root directory. The file should contain the following:
SPOTIFY_CLIENT_ID = "spotify-client-id"
SPOTIFY_CLIENT_SECRET = "spotify-client-secret"
MUSIXMATCH_USERTOKEN = "musixmatch-usertoken"
You can get the Spotify Client ID and Client Secret from the Spotify Developer Dashboard. For Musixmatch User Token, you can follow this guide here.
You are now ready to use PyMusix!
A basic usage is shown below, for more information, please check out the examples given here.
import os
from dotenv import load_dotenv
from pymusix import PyMusix
load_dotenv()
CLIENT_ID = os.getenv("SPOTIFY_CLIENT_ID")
CLIENT_SECRET = os.getenv("SPOTIFY_CLIENT_SECRET")
USER_TOKEN = os.getenv("MUSIXMATCH_USERTOKEN")
song = PyMusix()
song.set_secrets(CLIENT_ID, CLIENT_SECRET, USER_TOKEN)
song.search_track(q_name = "Pluto Projector", q_artist = "Rex Orange County")
print("Track Name:", song.name)
print("Lyrics:", song.lyrics)
print("Primary Genre:", song.primary_genre)
# ... and more
Contributions to pymusix are welcomed. Feel free to submit your suggestions via pull requests. Your contributions are invaluable in enhancing this tool for everyone.
🌿 pymusix is licensed under the MIT license, which you can find in the LICENSE file.
Made with 💜
elysianmyst, 2024
FAQs
🌿 Retrieve information about a song, including details like the artist, album, release date, genres, and lyrics using Spotify and MusixMatch API
We found that pymusix demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovered npm malware campaign mimicking popular Node.js libraries and packages from other ecosystems; packages steal data and execute remote code.
Research
Socket's research uncovers three dangerous Go modules that contain obfuscated disk-wiping malware, threatening complete data loss.
Research
Socket uncovers malicious packages on PyPI using Gmail's SMTP protocol for command and control (C2) to exfiltrate data and execute commands.