Git Product home page Git Product logo

akashi's Introduction

Akashi

Tautulli (formerly PlexPy) script -> Discord webhook

Standard Tautulli Discord webhooks can look like this if semi-properly configured:

But that's pretty much where the configuration ends. Since there is no real way to further configure the output I have written Akashi to help me out with that.
When running Akashi the output will look like this:

The output generated will be a lot more controllable.

For this to properly work it executes a shell script that posts data to Akashi which then gets forwarded to Discord via a webhook.
Currently it only has one endpoint which is /api/plex/recently_added since this is the only use-case I have for it at the moment. It also forces a specific webhook output which could be refactored so that the Discord Embed gets constructed inside of the shell script instead of the API.

Setup

Prerequisites:

  • Node.js
  • Tautulli Server
  • Discord Webhook

First you need to make sure Akashi is running, how that is done is up to the user itself, whether it be tmux, screen, pm2 or Docker.
The configuration for the env, port and Discord webhook is handled via environment variables, namely: NODE_ENV=, PORT=, DISCORD_WEBHOOK=

For a tutorial on how to setup a Discord webhook you can go here: https://support.discordapp.com/hc/en-us/articles/228383668-Intro-to-Webhooks

After that a notification agent needs to be setup in Tautulli:

In the configuration tab, of the newly created script notification agent, the folder containing the script needs to be filled out and then selected:

Afterwards in the Triggers tab a suitable trigger needs to be selected, in our case only Recently Added applies here currently.

And lastly in the Arguments tab the correct script arguments need to be passed down to the shell script:

The order is as follows: url port {show_name} {episode_name} {episode_num} {poster_url} {plex_url}
This ensures a somewhat configurable host and port setup without having to hardcode it inside of the shell script.

After all of this is done you are good to go and have updates to your recently added movies/series in Discord!

Author

Akashi © iCrawl.
Authored and maintained by iCrawl.

GitHub @iCrawl

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.