diff --git a/plexpy/common.py b/plexpy/common.py index 79b76b5c..b0e22147 100644 --- a/plexpy/common.py +++ b/plexpy/common.py @@ -604,7 +604,8 @@ NOTIFICATION_PARAMETERS = [ {'name': 'Subtitle Language Code', 'type': 'str', 'value': 'subtitle_language_code', 'description': 'The subtitle language code of the original media.'}, {'name': 'File', 'type': 'str', 'value': 'file', 'description': 'The file path to the item.'}, {'name': 'Filename', 'type': 'str', 'value': 'filename', 'description': 'The file name of the item.'}, - {'name': 'File Size', 'type': 'int', 'value': 'file_size', 'description': 'The file size of the item.'}, + {'name': 'File Size', 'type': 'str', 'value': 'file_size', 'description': 'The file size of the item in human readable format.', 'example': '1.2 GB'}, + {'name': 'File Size Bytes', 'type': 'int', 'value': 'file_size_bytes', 'description': 'The file size of the item in bytes.'}, {'name': 'Guid', 'type': 'str', 'value': 'guid', 'description': 'The full guid for the item.'}, {'name': 'Section ID', 'type': 'int', 'value': 'section_id', 'description': 'The unique identifier for the library.'}, {'name': 'Rating Key', 'type': 'int', 'value': 'rating_key', 'description': 'The unique identifier for the movie, episode, or track.'}, diff --git a/plexpy/notification_handler.py b/plexpy/notification_handler.py index 4ed08bf6..14e20750 100644 --- a/plexpy/notification_handler.py +++ b/plexpy/notification_handler.py @@ -1215,6 +1215,7 @@ def build_media_notify_params(notify_action=None, session=None, timeline=None, m 'file': notify_params['file'], 'filename': os.path.basename(notify_params['file'].replace('\\', os.sep)), 'file_size': helpers.human_file_size(notify_params['file_size']), + 'file_size_bytes': notify_params['file_size'], 'indexes': notify_params['indexes'], 'guid': notify_params['guid'], 'section_id': notify_params['section_id'],