This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
From a list of TV shows, check if users in a list has watched shows episodes. | |
If all users in list have watched an episode of listed show, then delete episode. | |
""" | |
import requests | |
import sys | |
import os | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
''' | |
fetch function from https://gist.github.com/Hellowlol/ee47b6534410b1880e19 | |
PlexPy > Settings > Notification Agents > Scripts > Bell icon: | |
[X] Notify on pause | |
PlexPy > Settings > Notification Agents > Scripts > Gear icon: | |
Playback Pause: create_wait_kill_all.py | |
PlexPy > Settings > Notifications > Script > Script Arguments: | |
{session_key} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Notify users of recently added episode to show that they have watched at least LIMIT times via email. | |
Also notify users of new movies. | |
Block users with IGNORE_LST. | |
Arguments passed from PlexPy | |
-sn {show_name} -ena {episode_name} -ssn {season_num00} -enu {episode_num00} -srv {server_name} -med {media_type} | |
-pos {poster_url} -tt {title} -sum {summary} -lbn {library_name} -grk {grandparent_rating_key} | |
You can add more arguments if you want more details in the email body |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Kill stream of user if they are accessing Plex from outside network | |
PlexPy > Settings > Notification Agents > Scripts > Bell icon: | |
[X] Notify on playback start | |
PlexPy > Settings > Notification Agents > Scripts > Gear icon: | |
Playback Start: kill_outsider_stream.py | |
PlexPy > Settings > Notifications > Script > Script Arguments |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Find Movies that have been watched by a list of users. | |
If all users have watched movie than delete. | |
Deletion is prompted | |
""" | |
import requests | |
import sys | |
import os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
If user has 2* or more concurrent streams kill all user's streams | |
*PlexPy > Settings > Notification> User Concurrent Stream Threshold | |
The number of concurrent streams by a single user for PlexPy to trigger a notification. Minimum 2. | |
PlexPy > Settings > Notification Agents > Scripts > Bell icon: | |
[X] Notify on user concurrent streams | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
If user has 2* or more concurrent streams and the IP of the 2nd stream differs from 1st kill 2nd. | |
If 2nd stream IP is the same as 1st stream don't kill. | |
*PlexPy > Settings > Notification> User Concurrent Stream Threshold | |
The number of concurrent streams by a single user for PlexPy to trigger a notification. Minimum 2. | |
PlexPy > Settings > Notification Agents > Scripts > Bell icon: | |
[X] Notify on user concurrent streams |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
PlexPy Playback Start | |
""" | |
import requests | |
import platform | |
from uuid import getnode | |
import unicodedata | |
## EDIT THESE SETTINGS ## |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import platform | |
from uuid import getnode | |
## EDIT THESE SETTINGS ## | |
PLEX_HOST = '' | |
PLEX_PORT = 32400 | |
PLEX_SSL = '' # s or '' | |
PLEX_TOKEN = 'xxxxxx' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Create a Plex Playlist with what was aired on this today's month-day, sort by oldest first. | |
If Playlist from yesterday exists delete and create today's. | |
If today's Playlist exists exit. | |
""" | |
import operator, time | |
from plexapi.server import PlexServer | |
import requests |