npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

kodicord

v2.0.7

Published

Kodi music rich presence for Discord

Downloads

39

Readme

Contents


Notice

this is completely safe if you keep the API_ABUSE setting disabled!

This is an experimental integration and incorrect usage may be considered as Discord API abuse. If you are not comfortable entering your Discord account token into this integration then it's not for you.

By enabling the API_ABUSE setting in .env, you will be considered as abusing the Discord API and if reported you are at risk of deletion. I've asked a Discord developer regarding changing the application name programmatically every time the song name is changed and they confirmed it is indeed API abuse.

Album covers may take up to 15 seconds to update due to Discord caching. This usually is not the case.

How to use

In order for this to work, you must have remote connections via HTTP enabled on your XMBC/Kodi device.

screenshot

Step One: Creating a Discord application

Go to the Discord Developer Portal and create an Application. Name it something nice, for example: "Music"

(if the API_ABUSE setting is enabled then the application name will be overridden by the current song name)
Step Two: Uploading a default album cover

You'll need to upload a default album cover for when the application cannot fetch the artwork of the album you're listening to.

Upload any image and name the asset specifically defaultcover.

screenshot

Step Three: Editing the configuration

Once you've uploaded your default cover, you'll need to edit .env.default with the necessary values and rename it to .env.

  • URL : The link to your Kodi/XMBC HTTP dashboard. (see screenshot above)

  • CLIENT_ID: Your application's client ID.

  • USER_TOKEN: The token of YOUR Discord account.

  • LASTFM_KEY: Your Last.FM API key. Get one at their API portal for free with no limits.

  • API_ABUSE: read the Notice section

Step Four: Starting the integration

As of now there is no UI for this integration and it is command-line based. Good news is you only have to run the command once and it'll remain in the background.

Run npm install then npm start in your choice of terminal. (ex: command prompt)

Step Five: Get Banned (kidding)

No, I'm kidding. You won't be banned for simply using this integration... unless you're being edgy and using the API_ABUSE feature.

If all goes well you'll end up with a presence like this: (left = API abuse, right = no API abuse)

screenshot screenshot

License

This repository has been released under the MIT license.


Contact me on Discord: wright#0666