diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index d998436..8c5e222 100755 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,12 +1,12 @@ lockVersion: 2.0.0 id: 3eeea668-4ef4-464e-a888-bdfa023bedf5 management: - docChecksum: 2554ade61ed4d42b8e095168765d7dc0 + docChecksum: 48a69156b6fa2af10cd43e971790441b docVersion: 0.0.3 - speakeasyVersion: 1.438.3 - generationVersion: 2.457.9 - releaseVersion: 0.19.1 - configChecksum: 6da82312bc6f815c9d30433dc0275c10 + speakeasyVersion: 1.459.2 + generationVersion: 2.483.1 + releaseVersion: 0.20.0 + configChecksum: d2358931157d7fa7e52e620a078dc77f repoURL: https://github.com/LukeHagar/plexpy.git repoSubDirectory: . installationURL: https://github.com/LukeHagar/plexpy.git @@ -14,8 +14,8 @@ management: features: python: additionalDependencies: 1.0.0 - constsAndDefaults: 1.0.4 - core: 5.6.5 + constsAndDefaults: 1.0.5 + core: 5.7.4 defaultEnabledRetries: 0.2.0 deprecations: 3.0.0 downloadStreams: 1.0.1 @@ -27,15 +27,13 @@ features: globalSecurity: 3.0.2 globalSecurityCallbacks: 1.0.0 globalSecurityFlattening: 1.0.0 - globalServerURLs: 3.0.0 - globals: 3.0.0 - methodServerURLs: 3.0.0 + globalServerURLs: 3.1.0 + methodServerURLs: 3.1.0 nameOverrides: 3.0.0 nullables: 1.0.0 responseFormat: 1.0.1 retries: 3.0.2 sdkHooks: 1.0.0 - tests: 1.6.0 generatedFiles: - .gitattributes - .python-version @@ -338,7 +336,6 @@ generatedFiles: - docs/models/errors/uploadplaylisterrors.md - docs/models/errors/uploadplaylistplaylistserrors.md - docs/models/errors/uploadplaylistunauthorized.md - - docs/models/internal/globals.md - docs/models/operations/account.md - docs/models/operations/action.md - docs/models/operations/activedirection.md @@ -527,7 +524,6 @@ generatedFiles: - docs/models/operations/getondeckresponsebody.md - docs/models/operations/getondeckstream.md - docs/models/operations/getpinauthpincontainer.md - - docs/models/operations/getpinglobals.md - docs/models/operations/getpinrequest.md - docs/models/operations/getpinresponse.md - docs/models/operations/getplaylistcontentscountry.md @@ -596,7 +592,6 @@ generatedFiles: - docs/models/operations/getsearchalllibrariesdirector.md - docs/models/operations/getsearchalllibrariesflattenseasons.md - docs/models/operations/getsearchalllibrariesgenre.md - - docs/models/operations/getsearchalllibrariesglobals.md - docs/models/operations/getsearchalllibrarieshasthumbnail.md - docs/models/operations/getsearchalllibrariesimage.md - docs/models/operations/getsearchalllibrarieslibrarytype.md @@ -650,7 +645,6 @@ generatedFiles: - docs/models/operations/getserverpreferencesmediacontainer.md - docs/models/operations/getserverpreferencesresponse.md - docs/models/operations/getserverpreferencesresponsebody.md - - docs/models/operations/getserverresourcesglobals.md - docs/models/operations/getserverresourcesrequest.md - docs/models/operations/getserverresourcesresponse.md - docs/models/operations/getsessionhistorymediacontainer.md @@ -679,7 +673,6 @@ generatedFiles: - docs/models/operations/gettimelineresponse.md - docs/models/operations/gettokenbypinidauthpincontainer.md - docs/models/operations/gettokenbypinidgeodata.md - - docs/models/operations/gettokenbypinidglobals.md - docs/models/operations/gettokenbypinidrequest.md - docs/models/operations/gettokenbypinidresponse.md - docs/models/operations/gettokendetailsauthenticationresponsestatus.md @@ -765,7 +758,6 @@ generatedFiles: - docs/models/operations/postuserssignindataautoselectsubtitle.md - docs/models/operations/postuserssignindatadefaultsubtitleaccessibility.md - docs/models/operations/postuserssignindatadefaultsubtitleforced.md - - docs/models/operations/postuserssignindataglobals.md - docs/models/operations/postuserssignindatamailingliststatus.md - docs/models/operations/postuserssignindatamediareviewsvisibility.md - docs/models/operations/postuserssignindatarequest.md @@ -958,8 +950,6 @@ generatedFiles: - src/plex_api_client/models/errors/updateplaylist.py - src/plex_api_client/models/errors/updateplayprogress.py - src/plex_api_client/models/errors/uploadplaylist.py - - src/plex_api_client/models/internal/__init__.py - - src/plex_api_client/models/internal/globals.py - src/plex_api_client/models/operations/__init__.py - src/plex_api_client/models/operations/addplaylistcontents.py - src/plex_api_client/models/operations/applyupdates.py @@ -1074,7 +1064,8 @@ examples: application/json: {"errors": []} "401": application/json: {"errors": []} - "200": {} + "200": + application/json: {} getServerPreferences: speakeasy-default-get-server-preferences: responses: @@ -1278,7 +1269,8 @@ examples: application/json: {"errors": []} "401": application/json: {"errors": []} - "200": {} + "200": + application/json: {} cancelServerActivities: "": parameters: @@ -1584,7 +1576,7 @@ examples: X-Plex-Container-Size: 50 responses: "200": - application/json: {"MediaContainer": {"Type": [{"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}], "FieldType": [{"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}], "size": 70, "totalSize": 170, "offset": 0, "content": "secondary", "allowSync": true, "nocache": true, "art": "/:/resources/movie-fanart.jpg", "identifier": "com.plexapp.plugins.library", "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionUUID": "322a231a-b7f7-49f5-920f-14c61199cd30", "mediaTagPrefix": "/system/bundle/media/flags/", "mediaTagVersion": 1701731894, "thumb": "/:/resources/movie.png", "title1": "Movies", "title2": "Recently Released", "viewGroup": "movie", "viewMode": 65592, "mixedParents": true, "Metadata": [{"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "dvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [{"tag": "Adventure"}, {"tag": "Adventure"}, {"tag": "Adventure"}], "Country": [{"tag": "United States of America"}, {"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [{"image": "themoviedb://image.rating", "value": 3, "type": "audience"}], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}, {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "dvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [], "Country": [{"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}, {"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}], "Meta": {"Type": [{"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [], "Sort": [], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}, {"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}], "FieldType": [{"type": "tag", "Operator": [{"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}]}}} + application/json: {"MediaContainer": {"Type": [{"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}], "FieldType": [{"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}], "size": 70, "totalSize": 170, "offset": 0, "content": "secondary", "allowSync": true, "nocache": true, "art": "/:/resources/movie-fanart.jpg", "identifier": "com.plexapp.plugins.library", "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionUUID": "322a231a-b7f7-49f5-920f-14c61199cd30", "mediaTagPrefix": "/system/bundle/media/flags/", "mediaTagVersion": 1701731894, "thumb": "/:/resources/movie.png", "title1": "Movies", "title2": "Recently Released", "viewGroup": "movie", "viewMode": 65592, "mixedParents": true, "Metadata": [{"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "tvdbDvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [{"tag": "Adventure"}, {"tag": "Adventure"}, {"tag": "Adventure"}], "Country": [{"tag": "United States of America"}, {"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [{"image": "themoviedb://image.rating", "value": 3, "type": "audience"}], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}, {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "tvdbDvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [], "Country": [{"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}, {"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}], "Meta": {"Type": [{"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [], "Sort": [], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}, {"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}], "FieldType": [{"type": "tag", "Operator": [{"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}, {"type": "tag", "Operator": [{"key": "=", "title": "is"}, {"key": "=", "title": "is"}]}]}}} "400": application/json: {"errors": [{"code": 1000, "message": "X-Plex-Client-Identifier is missing", "status": 400}]} "401": @@ -1705,7 +1697,8 @@ examples: application/json: {"errors": []} "401": application/json: {"errors": []} - "200": {} + "200": + application/json: {} logLine: speakeasy-default-log-line: parameters: @@ -2105,7 +2098,7 @@ examples: X-Plex-Container-Size: 50 responses: "200": - application/json: {"MediaContainer": {"size": 50, "identifier": "com.plexapp.plugins.library", "Meta": {"Type": [{"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}, {"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}, {"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}], "FieldType": [{"type": "tag", "Operator": [{"key": "=", "title": "is"}]}, {"type": "tag", "Operator": []}, {"type": "tag", "Operator": []}]}, "Metadata": [{"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "dvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": []}]}], "Genre": [{"tag": "Adventure"}], "Country": [], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [], "Collection": [], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}]}} + application/json: {"MediaContainer": {"size": 50, "identifier": "com.plexapp.plugins.library", "Meta": {"Type": [{"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}, {"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}, {"key": "/library/sections/2/all?type=2", "type": "show", "title": "TV Shows", "active": false, "Filter": [{"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}, {"filter": "genre", "filterType": "string", "key": "/library/sections/2/genre?type=2", "title": "Genre", "type": "filter"}], "Sort": [{"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}, {"default": "asc", "active": false, "activeDirection": "asc", "defaultDirection": "asc", "descKey": "titleSort:desc", "firstCharacterKey": "/library/sections/2/firstCharacter", "key": "titleSort", "title": "Title"}], "Field": [{"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}, {"key": "show.title", "title": "Show Title", "type": "string", "subType": "rating"}]}], "FieldType": [{"type": "tag", "Operator": [{"key": "=", "title": "is"}]}, {"type": "tag", "Operator": []}, {"type": "tag", "Operator": []}]}, "Metadata": [{"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "tvdbDvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": []}]}], "Genre": [{"tag": "Adventure"}], "Country": [], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [], "Collection": [], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}]}} get-recently-added-library: speakeasy-default-get-recently-added-library: parameters: @@ -2136,8 +2129,9 @@ examples: X-Plex-Client-Identifier: "3381b62b-9ab7-4e37-827b-203e9809eb58" responses: "200": - application/json: {"MediaContainer": {"size": "9266.90", "SearchResult": [{"score": "2698.71", "Metadata": {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "dvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}, {"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [{"tag": "Adventure"}, {"tag": "Adventure"}, {"tag": "Adventure"}], "Country": [{"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}], "Writer": [], "Collection": [{"tag": "Working NL Subs"}, {"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [], "Guid": [{"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}}, {"score": "9681.40", "Metadata": {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "dvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [], "Genre": [], "Country": [], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}, {"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}], "Guid": [], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [{"image": "themoviedb://image.rating", "value": 3, "type": "audience"}], "Image": [], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}}, {"score": "1665.12", "Metadata": {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "dvd", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [{"tag": "Adventure"}, {"tag": "Adventure"}], "Country": [{"tag": "United States of America"}, {"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}, {"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [{"image": "themoviedb://image.rating", "value": 3, "type": "audience"}], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}}]}} + application/json: {"MediaContainer": {"size": "9266.90", "SearchResult": [{"score": "2698.71", "Metadata": {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "tvdbAbsolute", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}, {"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}, {"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [{"tag": "Adventure"}, {"tag": "Adventure"}, {"tag": "Adventure"}], "Country": [{"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}], "Writer": [], "Collection": [{"tag": "Working NL Subs"}, {"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [], "Guid": [{"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}}, {"score": "9681.40", "Metadata": {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "tvdbAbsolute", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [], "Genre": [], "Country": [], "Director": [{"tag": "James Cameron"}, {"tag": "James Cameron"}, {"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}, {"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}], "Guid": [], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [{"image": "themoviedb://image.rating", "value": 3, "type": "audience"}], "Image": [], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}}, {"score": "1665.12", "Metadata": {"ratingKey": "58683", "key": "/library/metadata/58683", "guid": "plex://movie/5d7768ba96b655001fdc0408", "studio": "20th Century Studios", "skipChildren": false, "librarySectionID": 1, "librarySectionTitle": "Movies", "librarySectionKey": "/library/sections/1", "type": "movie", "title": "Avatar: The Way of Water", "slug": "4-for-texas", "contentRating": "PG-13", "summary": "Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.", "rating": 7.6, "audienceRating": 9.2, "year": 2022, "seasonCount": 2022, "tagline": "Return to Pandora.", "flattenSeasons": "1", "showOrdering": "tmdbAiring", "thumb": "/library/metadata/58683/thumb/1703239236", "art": "/library/metadata/58683/art/1703239236", "banner": "/library/metadata/58683/banner/1703239236", "duration": 11558112, "originallyAvailableAt": "2022-12-14T00:00:00Z", "addedAt": 1556281940, "updatedAt": 1556281940, "audienceRatingImage": "rottentomatoes://image.rating.upright", "chapterSource": "media", "primaryExtraKey": "/library/metadata/58684", "ratingImage": "rottentomatoes://image.rating.ripe", "grandparentRatingKey": "66", "grandparentGuid": "plex://show/5d9c081b170e24001f2a7be4", "grandparentKey": "/library/metadata/66", "grandparentTitle": "Caprica", "grandparentThumb": "/library/metadata/66/thumb/1705716261", "parentSlug": "alice-in-borderland-2020", "grandparentSlug": "alice-in-borderland-2020", "grandparentArt": "/library/metadata/66/art/1705716261", "grandparentTheme": "/library/metadata/66/theme/1705716261", "Media": [{"id": 119534, "duration": 11558112, "bitrate": 25025, "width": 3840, "height": 2072, "aspectRatio": 1.85, "audioProfile": "dts", "audioChannels": 6, "audioCodec": "eac3", "videoCodec": "hevc", "videoResolution": "4k", "container": "mkv", "videoFrameRate": "24p", "videoProfile": "main 10", "hasVoiceActivity": false, "optimizedForStreaming": 1, "has64bitOffsets": false, "Part": [{"id": 119542, "key": "/library/parts/119542/1680457526/file.mkv", "duration": 11558112, "file": "/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv", "size": 36158371307, "container": "mkv", "audioProfile": "dts", "has64bitOffsets": false, "optimizedForStreaming": false, "videoProfile": "main 10", "indexes": "sd", "hasThumbnail": "1", "Stream": [{"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}, {"id": 272796, "streamType": 1, "default": true, "selected": true, "codec": "h264", "index": 0, "bitrate": 6273, "colorPrimaries": "bt709", "colorRange": "tv", "colorSpace": "bt709", "colorTrc": "bt709", "bitDepth": 8, "chromaLocation": "left", "streamIdentifier": "2", "chromaSubsampling": "4:2:0", "codedHeight": 1088, "codedWidth": 1920, "frameRate": 29.97, "hasScalingMatrix": false, "hearingImpaired": false, "closedCaptions": false, "embeddedInVideo": "1", "height": 1080, "level": 40, "profile": "main", "refFrames": 4, "scanType": "progressive", "width": 1920, "displayTitle": "1080p (H.264)", "extendedDisplayTitle": "1080p (H.264)", "channels": 2, "language": "English", "languageTag": "en", "languageCode": "eng", "audioChannelLayout": "stereo", "samplingRate": 48000, "title": "English", "canAutoSync": false}]}]}], "Genre": [{"tag": "Adventure"}, {"tag": "Adventure"}], "Country": [{"tag": "United States of America"}, {"tag": "United States of America"}], "Director": [{"tag": "James Cameron"}], "Writer": [{"tag": "James Cameron"}], "Collection": [{"tag": "Working NL Subs"}, {"tag": "Working NL Subs"}], "Role": [{"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}, {"id": 294129, "filter": "actor=294129", "thumb": "https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg", "tag": "Mike Smith", "tagKey": "668e7e7b22bcad9064350c91", "role": "Self"}], "Location": [{"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}, {"path": "/TV Shows/House"}], "Guid": [{"id": "imdb://tt13015952"}, {"id": "imdb://tt13015952"}], "UltraBlurColors": {"topLeft": "11333b", "topRight": "0a232d", "bottomRight": "73958", "bottomLeft": "1f5066"}, "Rating": [{"image": "themoviedb://image.rating", "value": 3, "type": "audience"}], "Image": [{"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}, {"alt": "Episode 1", "type": "background", "url": "/library/metadata/45521/thumb/1644710589"}], "titleSort": "Whale", "viewCount": 1, "lastViewedAt": 1682752242, "originalTitle": "映画 ブラッククローバー 魔法帝の剣", "viewOffset": 5222500, "skipCount": 1, "index": 1, "theme": "/library/metadata/1/theme/1705636920", "leafCount": 14, "viewedLeafCount": 0, "childCount": 1, "hasPremiumExtras": "1", "hasPremiumPrimaryExtra": "1", "parentRatingKey": "66", "parentGuid": "plex://show/5d9c081b170e24001f2a7be4", "parentStudio": "UCP", "parentKey": "/library/metadata/66", "parentTitle": "Caprica", "parentIndex": 1, "parentYear": 2010, "parentThumb": "/library/metadata/66/thumb/1705716261", "parentTheme": "/library/metadata/66/theme/1705716261"}}]}} "400": application/json: {"errors": []} "401": application/json: {"errors": [{"code": 1001, "message": "User could not be authenticated", "status": 401}]} +generatedTests: {} diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index 17f11a1..ce94af8 100644 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -13,7 +13,7 @@ generation: oAuth2ClientCredentialsEnabled: true oAuth2PasswordEnabled: false python: - version: 0.19.1 + version: 0.20.0 additionalDependencies: dev: {} main: {} diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 2dda413..694db77 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,4 +1,4 @@ -speakeasyVersion: 1.438.3 +speakeasyVersion: 1.459.2 sources: my-source: sourceNamespace: my-source @@ -8,19 +8,19 @@ sources: - latest plexapi: sourceNamespace: plexapi - sourceRevisionDigest: sha256:37c6bfb15f4154eb89b112465107f20757411f22bd1cc7d0a04335df7127fcb4 - sourceBlobDigest: sha256:290473ebc909cada80ff428c685b897f4621cf121397e1417355e06d334e7206 + sourceRevisionDigest: sha256:ccba0c42f1644923e2209e28da7a78195a843e48da1aeaaedbf8759f1a8a0fe0 + sourceBlobDigest: sha256:b362c110ef633288220a55ab50627374b996c64f2d9b8e020944e84ea2840332 tags: - latest - - main + - speakeasy-sdk-regen-1734739316 targets: plexpy: source: plexapi sourceNamespace: plexapi - sourceRevisionDigest: sha256:37c6bfb15f4154eb89b112465107f20757411f22bd1cc7d0a04335df7127fcb4 - sourceBlobDigest: sha256:290473ebc909cada80ff428c685b897f4621cf121397e1417355e06d334e7206 + sourceRevisionDigest: sha256:ccba0c42f1644923e2209e28da7a78195a843e48da1aeaaedbf8759f1a8a0fe0 + sourceBlobDigest: sha256:b362c110ef633288220a55ab50627374b996c64f2d9b8e020944e84ea2840332 codeSamplesNamespace: code-samples-python-plexpy - codeSamplesRevisionDigest: sha256:dc4d92eff976b4f84f5b407b04e8a1489653f8e0e8e4bd9743192583a360ca0d + codeSamplesRevisionDigest: sha256:6535e67dae5267bdd609e15a94155f8793e0e60698458cefbd49b01294bd0fca workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/README.md b/README.md index 0d27586..a7e6d08 100644 --- a/README.md +++ b/README.md @@ -40,17 +40,25 @@ The following SDKs are generated from the OpenAPI Specification. They are automa ## Table of Contents + +* [plexpy](#plexpy) +* [Plex Media Server OpenAPI Specification](#plex-media-server-openapi-specification) + * [Documentation](#documentation) + * [SDKs](#sdks) + * [SDK Installation](#sdk-installation) + * [IDE Support](#ide-support) + * [SDK Example Usage](#sdk-example-usage) + * [Available Resources and Operations](#available-resources-and-operations) + * [Retries](#retries) + * [Error Handling](#error-handling) + * [Server Selection](#server-selection) + * [Custom HTTP Client](#custom-http-client) + * [Authentication](#authentication) + * [Debugging](#debugging) +* [Development](#development) + * [Maturity](#maturity) + * [Contributions](#contributions) -* [SDK Installation](#sdk-installation) -* [IDE Support](#ide-support) -* [SDK Example Usage](#sdk-example-usage) -* [Available Resources and Operations](#available-resources-and-operations) -* [Retries](#retries) -* [Error Handling](#error-handling) -* [Server Selection](#server-selection) -* [Custom HTTP Client](#custom-http-client) -* [Authentication](#authentication) -* [Debugging](#debugging) @@ -94,20 +102,16 @@ Generally, the SDK will work well with most IDEs out of the box. However, when u # Synchronous Example from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ```
@@ -119,18 +123,16 @@ import asyncio from plex_api_client import PlexAPI async def main(): - s = PlexAPI( + async with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) - res = await s.server.get_server_capabilities_async() - if res.object is not None: - # handle response - pass + ) as plex_api: + + res = await plex_api.server.get_server_capabilities_async() + + assert res.object is not None + + # Handle response + print(res.object) asyncio.run(main()) ``` @@ -277,47 +279,39 @@ Some of the endpoints in this SDK support retries. If you use the SDK without an To change the default retry strategy for a single API call, simply provide a `RetryConfig` object to the call: ```python -from plex_api.utils import BackoffStrategy, RetryConfig from plex_api_client import PlexAPI +from plex_api_client.utils import BackoffStrategy, RetryConfig -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_capabilities(, - RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False)) + res = plex_api.server.get_server_capabilities(, + RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False)) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` If you'd like to override the default retry strategy for all operations that support retries, you can use the `retry_config` optional parameter when initializing the SDK: ```python -from plex_api.utils import BackoffStrategy, RetryConfig from plex_api_client import PlexAPI +from plex_api_client.utils import BackoffStrategy, RetryConfig -s = PlexAPI( +with PlexAPI( retry_config=RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False), access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -350,32 +344,28 @@ When custom error responses are specified for an operation, the SDK may also rai from plex_api_client import PlexAPI from plex_api_client.models import errors -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: + res = None + try: -res = None -try: - res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() - if res.object is not None: - # handle response - pass + assert res.object is not None -except errors.GetServerCapabilitiesBadRequest as e: - # handle e.data: errors.GetServerCapabilitiesBadRequestData - raise(e) -except errors.GetServerCapabilitiesUnauthorized as e: - # handle e.data: errors.GetServerCapabilitiesUnauthorizedData - raise(e) -except errors.SDKError as e: - # handle exception - raise(e) + # Handle response + print(res.object) + + except errors.GetServerCapabilitiesBadRequest as e: + # handle e.data: errors.GetServerCapabilitiesBadRequestData + raise(e) + except errors.GetServerCapabilitiesUnauthorized as e: + # handle e.data: errors.GetServerCapabilitiesUnauthorizedData + raise(e) + except errors.SDKError as e: + # handle exception + raise(e) ``` @@ -395,21 +385,17 @@ The default server can also be overridden globally by passing a URL to the `serv ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( server_url="https://10.10.10.47:32400", access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -419,20 +405,16 @@ The server URL can also be overridden on a per-operation basis, provided a serve ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.plex.get_companions_data(server_url="https://plex.tv/api/v2") + res = plex_api.plex.get_companions_data(server_url="https://plex.tv/api/v2") -if res.response_bodies is not None: - # handle response - pass + assert res.response_bodies is not None + + # Handle response + print(res.response_bodies) ``` @@ -533,20 +515,16 @@ To authenticate with the API the `access_token` parameter must be set when initi ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` diff --git a/RELEASES.md b/RELEASES.md index 98f79aa..e6efbae 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -868,4 +868,14 @@ Based on: ### Generated - [python v0.19.1] . ### Releases -- [PyPI v0.19.1] https://pypi.org/project/plex-api-client/0.19.1 - . \ No newline at end of file +- [PyPI v0.19.1] https://pypi.org/project/plex-api-client/0.19.1 - . + +## 2024-12-21 00:01:53 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.459.2 (2.483.1) https://github.com/speakeasy-api/speakeasy +### Generated +- [python v0.20.0] . +### Releases +- [PyPI v0.20.0] https://pypi.org/project/plex-api-client/0.20.0 - . \ No newline at end of file diff --git a/USAGE.md b/USAGE.md index 823611e..90718c6 100644 --- a/USAGE.md +++ b/USAGE.md @@ -3,20 +3,16 @@ # Synchronous Example from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ```
@@ -28,18 +24,16 @@ import asyncio from plex_api_client import PlexAPI async def main(): - s = PlexAPI( + async with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) - res = await s.server.get_server_capabilities_async() - if res.object is not None: - # handle response - pass + ) as plex_api: + + res = await plex_api.server.get_server_capabilities_async() + + assert res.object is not None + + # Handle response + print(res.object) asyncio.run(main()) ``` diff --git a/codeSamples.yaml b/codeSamples.yaml index 28c92d5..0ec5a62 100644 --- a/codeSamples.yaml +++ b/codeSamples.yaml @@ -11,20 +11,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/:/prefs"]["get"] update: x-codeSamples: @@ -33,20 +29,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_server_preferences() + res = plex_api.server.get_server_preferences() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/:/progress"]["post"] update: x-codeSamples: @@ -55,20 +47,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.media.update_play_progress(key="", time=90000, state="played") + res = plex_api.media.update_play_progress(key="", time=90000, state="played") - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/:/scrobble"]["get"] update: x-codeSamples: @@ -77,20 +65,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.media.mark_played(key=59398) + res = plex_api.media.mark_played(key=59398) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/:/timeline"]["get"] update: x-codeSamples: @@ -100,31 +84,27 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.video.get_timeline(request={ - "rating_key": 23409, - "key": "/library/metadata/23409", - "state": operations.State.PLAYING, - "has_mde": 1, - "time": 2000, - "duration": 10000, - "context": "home:hub.continueWatching", - "play_queue_item_id": 1, - "play_back_time": 2000, - "row": 1, - }) + res = plex_api.video.get_timeline(request={ + "rating_key": 23409, + "key": "/library/metadata/23409", + "state": operations.State.PLAYING, + "has_mde": 1, + "time": 2000, + "duration": 10000, + "context": "home:hub.continueWatching", + "play_queue_item_id": 1, + "play_back_time": 2000, + "row": 1, + }) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/:/unscrobble"]["get"] update: x-codeSamples: @@ -133,20 +113,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.media.mark_unplayed(key=59398) + res = plex_api.media.mark_unplayed(key=59398) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/activities"]["get"] update: x-codeSamples: @@ -155,20 +131,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.activities.get_server_activities() + res = plex_api.activities.get_server_activities() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/activities/{activityUUID}"]["delete"] update: x-codeSamples: @@ -177,20 +149,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.activities.cancel_server_activities(activity_uuid="25b71ed5-0f9d-461c-baa7-d404e9e10d3e") + res = plex_api.activities.cancel_server_activities(activity_uuid="25b71ed5-0f9d-461c-baa7-d404e9e10d3e") - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/butler"]["delete"] update: x-codeSamples: @@ -199,20 +167,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.butler.stop_all_tasks() + res = plex_api.butler.stop_all_tasks() - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/butler"]["get"] update: x-codeSamples: @@ -221,20 +185,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.butler.get_butler_tasks() + res = plex_api.butler.get_butler_tasks() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/butler"]["post"] update: x-codeSamples: @@ -243,20 +203,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.butler.start_all_tasks() + res = plex_api.butler.start_all_tasks() - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/butler/{taskName}"]["delete"] update: x-codeSamples: @@ -266,20 +222,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.butler.stop_task(task_name=operations.PathParamTaskName.BACKUP_DATABASE) + res = plex_api.butler.stop_task(task_name=operations.PathParamTaskName.BACKUP_DATABASE) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/butler/{taskName}"]["post"] update: x-codeSamples: @@ -289,20 +241,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.butler.start_task(task_name=operations.TaskName.CLEAN_OLD_BUNDLES) + res = plex_api.butler.start_task(task_name=operations.TaskName.CLEAN_OLD_BUNDLES) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/clients"]["get"] update: x-codeSamples: @@ -311,20 +259,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_available_clients() + res = plex_api.server.get_available_clients() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/companions"]["get"] update: x-codeSamples: @@ -333,20 +277,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.plex.get_companions_data() + res = plex_api.plex.get_companions_data() - if res.response_bodies is not None: - # handle response - pass + assert res.response_bodies is not None + + # Handle response + print(res.response_bodies) - target: $["paths"]["/devices"]["get"] update: x-codeSamples: @@ -355,20 +295,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_devices() + res = plex_api.server.get_devices() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/friends"]["get"] update: x-codeSamples: @@ -377,20 +313,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.plex.get_user_friends() + res = plex_api.plex.get_user_friends() - if res.friends is not None: - # handle response - pass + assert res.friends is not None + + # Handle response + print(res.friends) - target: $["paths"]["/geoip"]["get"] update: x-codeSamples: @@ -399,19 +331,14 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + with PlexAPI() as plex_api: - res = s.plex.get_geo_data() + res = plex_api.plex.get_geo_data() - if res.geo_data is not None: - # handle response - pass + assert res.geo_data is not None + + # Handle response + print(res.geo_data) - target: $["paths"]["/home"]["get"] update: x-codeSamples: @@ -420,20 +347,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.plex.get_home_data() + res = plex_api.plex.get_home_data() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/hubs"]["get"] update: x-codeSamples: @@ -442,20 +365,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.hubs.get_global_hubs() + res = plex_api.hubs.get_global_hubs() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/hubs/home/recentlyAdded"]["get"] update: x-codeSamples: @@ -465,27 +384,23 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.hubs.get_recently_added(request={ - "content_directory_id": 470161, - "section_id": 2, - "type": operations.Type.TV_SHOW, - "include_meta": operations.IncludeMeta.ENABLE, - "x_plex_container_start": 0, - "x_plex_container_size": 50, - }) + res = plex_api.hubs.get_recently_added(request={ + "content_directory_id": 470161, + "section_id": 2, + "type": operations.Type.TV_SHOW, + "include_meta": operations.IncludeMeta.ENABLE, + "x_plex_container_start": 0, + "x_plex_container_size": 50, + }) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/hubs/search"]["get"] update: x-codeSamples: @@ -494,20 +409,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.search.perform_search(query="dylan", limit=5) + res = plex_api.search.perform_search(query="dylan", limit=5) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/hubs/search/voice"]["get"] update: x-codeSamples: @@ -516,20 +427,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.search.perform_voice_search(query="dead+poop", limit=5) + res = plex_api.search.perform_voice_search(query="dead+poop", limit=5) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/hubs/sections/{sectionId}"]["get"] update: x-codeSamples: @@ -538,20 +445,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.hubs.get_library_hubs(section_id=6728.76) + res = plex_api.hubs.get_library_hubs(section_id=6728.76) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/identity"]["get"] update: x-codeSamples: @@ -560,19 +463,14 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + with PlexAPI() as plex_api: - res = s.server.get_server_identity() + res = plex_api.server.get_server_identity() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/all/top"]["get"] update: x-codeSamples: @@ -582,20 +480,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_top_watched_content(type_=operations.GetTopWatchedContentQueryParamType.TV_SHOW, include_guids=1) + res = plex_api.library.get_top_watched_content(type_=operations.GetTopWatchedContentQueryParamType.TV_SHOW, include_guids=1) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/hashes"]["get"] update: x-codeSamples: @@ -604,20 +498,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_file_hash(url="file://C:\Image.png&type=13") + res = plex_api.library.get_file_hash(url="file://C:\Image.png&type=13") - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/library/metadata/{ratingKey}"]["get"] update: x-codeSamples: @@ -626,20 +516,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_meta_data_by_rating_key(rating_key=9518) + res = plex_api.library.get_meta_data_by_rating_key(rating_key=9518) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/metadata/{ratingKey}/banner"]["get"] update: x-codeSamples: @@ -648,27 +534,23 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.media.get_banner_image(request={ - "rating_key": 9518, - "width": 396, - "height": 396, - "min_size": 1, - "upscale": 1, - "x_plex_token": "CV5xoxjTpFKUzBTShsaf", - }) + res = plex_api.media.get_banner_image(request={ + "rating_key": 9518, + "width": 396, + "height": 396, + "min_size": 1, + "upscale": 1, + "x_plex_token": "CV5xoxjTpFKUzBTShsaf", + }) - if res.response_stream is not None: - # handle response - pass + assert res.response_stream is not None + + # Handle response + print(res.response_stream) - target: $["paths"]["/library/metadata/{ratingKey}/children"]["get"] update: x-codeSamples: @@ -677,20 +559,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_metadata_children(rating_key=1539.15, include_elements="Stream") + res = plex_api.library.get_metadata_children(rating_key=1539.15, include_elements="Stream") - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/metadata/{ratingKey}/thumb"]["get"] update: x-codeSamples: @@ -699,27 +577,23 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.media.get_thumb_image(request={ - "rating_key": 9518, - "width": 396, - "height": 396, - "min_size": 1, - "upscale": 1, - "x_plex_token": "CV5xoxjTpFKUzBTShsaf", - }) + res = plex_api.media.get_thumb_image(request={ + "rating_key": 9518, + "width": 396, + "height": 396, + "min_size": 1, + "upscale": 1, + "x_plex_token": "CV5xoxjTpFKUzBTShsaf", + }) - if res.response_stream is not None: - # handle response - pass + assert res.response_stream is not None + + # Handle response + print(res.response_stream) - target: $["paths"]["/library/onDeck"]["get"] update: x-codeSamples: @@ -728,20 +602,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_on_deck() + res = plex_api.library.get_on_deck() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/recentlyAdded"]["get"] update: x-codeSamples: @@ -751,41 +621,37 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_recently_added_library(request={ - "content_directory_id": 2, - "pinned_content_directory_id": [ - 3, - 5, - 7, - 13, - 12, - 1, - 6, - 14, - 2, - 10, - 16, - 17, - ], - "section_id": 2, - "type": operations.QueryParamType.TV_SHOW, - "include_meta": operations.QueryParamIncludeMeta.ENABLE, - "x_plex_container_start": 0, - "x_plex_container_size": 50, - }) + res = plex_api.library.get_recently_added_library(request={ + "content_directory_id": 2, + "pinned_content_directory_id": [ + 3, + 5, + 7, + 13, + 12, + 1, + 6, + 14, + 2, + 10, + 16, + 17, + ], + "section_id": 2, + "type": operations.QueryParamType.TV_SHOW, + "include_meta": operations.QueryParamIncludeMeta.ENABLE, + "x_plex_container_start": 0, + "x_plex_container_size": 50, + }) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/search"]["get"] update: x-codeSamples: @@ -795,27 +661,24 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_search_all_libraries(request={ - "query": "", - "search_types": [ - operations.SearchTypes.PEOPLE, - ], - "include_collections": operations.QueryParamIncludeCollections.ENABLE, - "include_external_media": operations.QueryParamIncludeExternalMedia.ENABLE, - }) + res = plex_api.library.get_search_all_libraries(request={ + "query": "", + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "search_types": [ + operations.SearchTypes.PEOPLE, + ], + "include_collections": operations.QueryParamIncludeCollections.ENABLE, + "include_external_media": operations.QueryParamIncludeExternalMedia.ENABLE, + }) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/sections"]["get"] update: x-codeSamples: @@ -824,20 +687,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_all_libraries() + res = plex_api.library.get_all_libraries() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/sections/watchlist/{filter}"]["get"] update: x-codeSamples: @@ -847,25 +706,21 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.watchlist.get_watch_list(request={ - "filter_": operations.Filter.AVAILABLE, - "x_plex_container_start": 0, - "x_plex_container_size": 50, - "x_plex_token": "CV5xoxjTpFKUzBTShsaf", - }) + res = plex_api.watchlist.get_watch_list(request={ + "filter_": operations.Filter.AVAILABLE, + "x_plex_container_start": 0, + "x_plex_container_size": 50, + "x_plex_token": "CV5xoxjTpFKUzBTShsaf", + }) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/sections/{sectionKey}"]["delete"] update: x-codeSamples: @@ -874,20 +729,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.delete_library(section_key=9518) + res = plex_api.library.delete_library(section_key=9518) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/library/sections/{sectionKey}"]["get"] update: x-codeSamples: @@ -896,20 +747,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_library_details(section_key=9518) + res = plex_api.library.get_library_details(section_key=9518) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/sections/{sectionKey}/refresh"]["get"] update: x-codeSamples: @@ -919,20 +766,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_refresh_library_metadata(section_key=9518, force=operations.Force.ONE) + res = plex_api.library.get_refresh_library_metadata(section_key=9518, force=operations.Force.ONE) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/library/sections/{sectionKey}/search"]["get"] update: x-codeSamples: @@ -942,20 +785,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_search_library(section_key=9518, type_=operations.GetSearchLibraryQueryParamType.TV_SHOW) + res = plex_api.library.get_search_library(section_key=9518, type_=operations.GetSearchLibraryQueryParamType.TV_SHOW) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/library/sections/{sectionKey}/{tag}"]["get"] update: x-codeSamples: @@ -965,28 +804,24 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.library.get_library_items(request={ - "tag": operations.Tag.EDITION, - "include_guids": operations.IncludeGuids.ENABLE, - "type": operations.GetLibraryItemsQueryParamType.TV_SHOW, - "section_key": 9518, - "include_meta": operations.GetLibraryItemsQueryParamIncludeMeta.ENABLE, - "x_plex_container_start": 0, - "x_plex_container_size": 50, - }) + res = plex_api.library.get_library_items(request={ + "tag": operations.Tag.EDITION, + "include_guids": operations.IncludeGuids.ENABLE, + "type": operations.GetLibraryItemsQueryParamType.TV_SHOW, + "section_key": 9518, + "include_meta": operations.GetLibraryItemsQueryParamIncludeMeta.ENABLE, + "x_plex_container_start": 0, + "x_plex_container_size": 50, + }) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/log"]["get"] update: x-codeSamples: @@ -996,20 +831,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.log.log_line(level=operations.Level.THREE, message="Test log message", source="Postman") + res = plex_api.log.log_line(level=operations.Level.THREE, message="Test log message", source="Postman") - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/log"]["post"] update: x-codeSamples: @@ -1018,22 +849,18 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.log.log_multi_line(request="level=4&message=Test%20message%201&source=postman\n" + - "level=3&message=Test%20message%202&source=postman\n" + - "level=1&message=Test%20message%203&source=postman") + res = plex_api.log.log_multi_line(request="level=4&message=Test%20message%201&source=postman\n" + + "level=3&message=Test%20message%202&source=postman\n" + + "level=1&message=Test%20message%203&source=postman") - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/log/networked"]["get"] update: x-codeSamples: @@ -1042,20 +869,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.log.enable_paper_trail() + res = plex_api.log.enable_paper_trail() - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/media/providers"]["get"] update: x-codeSamples: @@ -1064,20 +887,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_media_providers(x_plex_token="CV5xoxjTpFKUzBTShsaf") + res = plex_api.server.get_media_providers(x_plex_token="CV5xoxjTpFKUzBTShsaf") - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/myplex/account"]["get"] update: x-codeSamples: @@ -1086,20 +905,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_my_plex_account() + res = plex_api.server.get_my_plex_account() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/photo/:/transcode"]["get"] update: x-codeSamples: @@ -1109,28 +924,24 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_resized_photo(request={ - "width": 110, - "height": 165, - "opacity": 100, - "blur": 0, - "min_size": operations.MinSize.ONE, - "upscale": operations.Upscale.ONE, - "url": "/library/metadata/49564/thumb/1654258204", - }) + res = plex_api.server.get_resized_photo(request={ + "width": 110, + "height": 165, + "opacity": 100, + "blur": 0, + "min_size": operations.MinSize.ONE, + "upscale": operations.Upscale.ONE, + "url": "/library/metadata/49564/thumb/1654258204", + }) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/pins"]["post"] update: x-codeSamples: @@ -1139,19 +950,20 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + with PlexAPI() as plex_api: - res = s.plex.get_pin(request={}) + res = plex_api.plex.get_pin(request={ + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "client_name": "Plex for Roku", + "device_nickname": "Roku 3", + "client_version": "2.4.1", + "platform": "Roku", + }) - if res.auth_pin_container is not None: - # handle response - pass + assert res.auth_pin_container is not None + + # Handle response + print(res.auth_pin_container) - target: $["paths"]["/pins/{pinID}"]["get"] update: x-codeSamples: @@ -1160,21 +972,21 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + with PlexAPI() as plex_api: - res = s.plex.get_token_by_pin_id(request={ - "pin_id": 408895, - }) + res = plex_api.plex.get_token_by_pin_id(request={ + "pin_id": 408895, + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "client_name": "Plex for Roku", + "device_nickname": "Roku 3", + "client_version": "2.4.1", + "platform": "Roku", + }) - if res.auth_pin_container is not None: - # handle response - pass + assert res.auth_pin_container is not None + + # Handle response + print(res.auth_pin_container) - target: $["paths"]["/playlists"]["get"] update: x-codeSamples: @@ -1183,20 +995,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.get_playlists() + res = plex_api.playlists.get_playlists() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/playlists"]["post"] update: x-codeSamples: @@ -1206,25 +1014,21 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.create_playlist(request={ - "title": "", - "type": operations.CreatePlaylistQueryParamType.PHOTO, - "smart": operations.Smart.ONE, - "uri": "https://hoarse-testing.info/", - }) + res = plex_api.playlists.create_playlist(request={ + "title": "", + "type": operations.CreatePlaylistQueryParamType.PHOTO, + "smart": operations.Smart.ONE, + "uri": "https://hoarse-testing.info/", + }) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/playlists/upload"]["post"] update: x-codeSamples: @@ -1234,20 +1038,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.upload_playlist(path="/home/barkley/playlist.m3u", force=operations.QueryParamForce.ZERO, section_id=1) + res = plex_api.playlists.upload_playlist(path="/home/barkley/playlist.m3u", force=operations.QueryParamForce.ZERO, section_id=1) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/playlists/{playlistID}"]["delete"] update: x-codeSamples: @@ -1256,20 +1056,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.delete_playlist(playlist_id=216.22) + res = plex_api.playlists.delete_playlist(playlist_id=216.22) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/playlists/{playlistID}"]["get"] update: x-codeSamples: @@ -1278,20 +1074,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.get_playlist(playlist_id=4109.48) + res = plex_api.playlists.get_playlist(playlist_id=4109.48) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/playlists/{playlistID}"]["put"] update: x-codeSamples: @@ -1300,20 +1092,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.update_playlist(playlist_id=3915.00) + res = plex_api.playlists.update_playlist(playlist_id=3915.00) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/playlists/{playlistID}/items"]["delete"] update: x-codeSamples: @@ -1322,20 +1110,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.clear_playlist_contents(playlist_id=1893.18) + res = plex_api.playlists.clear_playlist_contents(playlist_id=1893.18) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/playlists/{playlistID}/items"]["get"] update: x-codeSamples: @@ -1345,20 +1129,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.get_playlist_contents(playlist_id=5004.46, type_=operations.GetPlaylistContentsQueryParamType.TV_SHOW) + res = plex_api.playlists.get_playlist_contents(playlist_id=5004.46, type_=operations.GetPlaylistContentsQueryParamType.TV_SHOW) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/playlists/{playlistID}/items"]["put"] update: x-codeSamples: @@ -1367,20 +1147,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.playlists.add_playlist_contents(playlist_id=8502.00, uri="server://12345/com.plexapp.plugins.library/library/metadata/1", play_queue_id=123) + res = plex_api.playlists.add_playlist_contents(playlist_id=8502.00, uri="server://12345/com.plexapp.plugins.library/library/metadata/1", play_queue_id=123) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/resources"]["get"] update: x-codeSamples: @@ -1390,20 +1166,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.plex.get_server_resources(include_https=operations.IncludeHTTPS.ENABLE, include_relay=operations.IncludeRelay.ENABLE, include_i_pv6=operations.IncludeIPv6.ENABLE, client_id="3381b62b-9ab7-4e37-827b-203e9809eb58") + res = plex_api.plex.get_server_resources(client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", include_https=operations.IncludeHTTPS.ENABLE, include_relay=operations.IncludeRelay.ENABLE, include_i_pv6=operations.IncludeIPv6.ENABLE) - if res.plex_devices is not None: - # handle response - pass + assert res.plex_devices is not None + + # Handle response + print(res.plex_devices) - target: $["paths"]["/search"]["get"] update: x-codeSamples: @@ -1412,20 +1184,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.search.get_search_results(query="110") + res = plex_api.search.get_search_results(query="110") - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/security/resources"]["get"] update: x-codeSamples: @@ -1434,20 +1202,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.authentication.get_source_connection_information(source="provider://provider-identifier") + res = plex_api.authentication.get_source_connection_information(source="provider://provider-identifier") - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/security/token"]["get"] update: x-codeSamples: @@ -1457,20 +1221,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.authentication.get_transient_token(type_=operations.GetTransientTokenQueryParamType.DELEGATION, scope=operations.Scope.ALL) + res = plex_api.authentication.get_transient_token(type_=operations.GetTransientTokenQueryParamType.DELEGATION, scope=operations.Scope.ALL) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/servers"]["get"] update: x-codeSamples: @@ -1479,20 +1239,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.server.get_server_list() + res = plex_api.server.get_server_list() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/statistics/bandwidth"]["get"] update: x-codeSamples: @@ -1501,20 +1257,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.statistics.get_bandwidth_statistics(timespan=4) + res = plex_api.statistics.get_bandwidth_statistics(timespan=4) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/statistics/media"]["get"] update: x-codeSamples: @@ -1523,20 +1275,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.statistics.get_statistics(timespan=4) + res = plex_api.statistics.get_statistics(timespan=4) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/statistics/resources"]["get"] update: x-codeSamples: @@ -1545,20 +1293,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.statistics.get_resources_statistics(timespan=4) + res = plex_api.statistics.get_resources_statistics(timespan=4) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/status/sessions"]["get"] update: x-codeSamples: @@ -1567,20 +1311,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.sessions.get_sessions() + res = plex_api.sessions.get_sessions() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/status/sessions/history/all"]["get"] update: x-codeSamples: @@ -1589,20 +1329,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.sessions.get_session_history(sort="viewedAt:desc", account_id=1, filter_={}, library_section_id=12) + res = plex_api.sessions.get_session_history(sort="viewedAt:desc", account_id=1, filter_={}, library_section_id=12) - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/transcode/sessions"]["get"] update: x-codeSamples: @@ -1611,20 +1347,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.sessions.get_transcode_sessions() + res = plex_api.sessions.get_transcode_sessions() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/transcode/sessions/{sessionKey}"]["delete"] update: x-codeSamples: @@ -1633,20 +1365,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.sessions.stop_transcode_session(session_key="zz7llzqlx8w9vnrsbnwhbmep") + res = plex_api.sessions.stop_transcode_session(session_key="zz7llzqlx8w9vnrsbnwhbmep") - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/updater/apply"]["put"] update: x-codeSamples: @@ -1656,20 +1384,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.updater.apply_updates(tonight=operations.Tonight.ONE, skip=operations.Skip.ONE) + res = plex_api.updater.apply_updates(tonight=operations.Tonight.ONE, skip=operations.Skip.ONE) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/updater/check"]["put"] update: x-codeSamples: @@ -1679,20 +1403,16 @@ actions: from plex_api_client import PlexAPI from plex_api_client.models import operations - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.updater.check_for_updates(download=operations.Download.ONE) + res = plex_api.updater.check_for_updates(download=operations.Download.ONE) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) - target: $["paths"]["/updater/status"]["get"] update: x-codeSamples: @@ -1701,20 +1421,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.updater.get_update_status() + res = plex_api.updater.get_update_status() - if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) - target: $["paths"]["/user"]["get"] update: x-codeSamples: @@ -1723,20 +1439,16 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.authentication.get_token_details() + res = plex_api.authentication.get_token_details() - if res.user_plex_account is not None: - # handle response - pass + assert res.user_plex_account is not None + + # Handle response + print(res.user_plex_account) - target: $["paths"]["/users/signin"]["post"] update: x-codeSamples: @@ -1745,25 +1457,25 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + with PlexAPI() as plex_api: - res = s.authentication.post_users_sign_in_data(request={ - "request_body": { - "login": "username@email.com", - "password": "password123", - "verification_code": "123456", - }, - }) + res = plex_api.authentication.post_users_sign_in_data(request={ + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "client_name": "Plex for Roku", + "device_nickname": "Roku 3", + "client_version": "2.4.1", + "platform": "Roku", + "request_body": { + "login": "username@email.com", + "password": "password123", + "verification_code": "123456", + }, + }) - if res.user_plex_account is not None: - # handle response - pass + assert res.user_plex_account is not None + + # Handle response + print(res.user_plex_account) - target: $["paths"]["/video/:/transcode/universal/start.mpd"]["get"] update: x-codeSamples: @@ -1772,34 +1484,30 @@ actions: source: |- from plex_api_client import PlexAPI - s = PlexAPI( + with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", - ) + ) as plex_api: - res = s.video.start_universal_transcode(request={ - "has_mde": 1, - "path": "/library/metadata/23409", - "media_index": 0, - "part_index": 0, - "protocol": "hls", - "fast_seek": 0, - "direct_play": 0, - "direct_stream": 0, - "subtitle_size": 100, - "subtites": "burn", - "audio_boost": 100, - "location": "lan", - "media_buffer_size": 102400, - "session": "zvcage8b7rkioqcm8f4uns4c", - "add_debug_overlay": 0, - "auto_adjust_quality": 0, - }) + res = plex_api.video.start_universal_transcode(request={ + "has_mde": 1, + "path": "/library/metadata/23409", + "media_index": 0, + "part_index": 0, + "protocol": "hls", + "fast_seek": 0, + "direct_play": 0, + "direct_stream": 0, + "subtitle_size": 100, + "subtites": "burn", + "audio_boost": 100, + "location": "lan", + "media_buffer_size": 102400, + "session": "zvcage8b7rkioqcm8f4uns4c", + "add_debug_overlay": 0, + "auto_adjust_quality": 0, + }) - if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) diff --git a/docs/models/internal/globals.md b/docs/models/internal/globals.md deleted file mode 100644 index 3e80d9a..0000000 --- a/docs/models/internal/globals.md +++ /dev/null @@ -1,12 +0,0 @@ -# Globals - - -## Fields - -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | -| `client_name` | *Optional[str]* | :heavy_minus_sign: | The name of the client application. (Plex Web, Plex Media Server, etc.) | Plex for Roku | -| `client_version` | *Optional[str]* | :heavy_minus_sign: | The version of the client application. | 2.4.1 | -| `platform` | *Optional[str]* | :heavy_minus_sign: | The platform of the client application. | Roku | -| `device_nickname` | *Optional[str]* | :heavy_minus_sign: | A relatively friendly name for the client device | Roku 3 | \ No newline at end of file diff --git a/docs/models/operations/getlibraryitemsmetadata.md b/docs/models/operations/getlibraryitemsmetadata.md index dbca452..1aaf2f7 100644 --- a/docs/models/operations/getlibraryitemsmetadata.md +++ b/docs/models/operations/getlibraryitemsmetadata.md @@ -25,7 +25,7 @@ | `season_count` | *Optional[int]* | :heavy_minus_sign: | N/A | 2022 | | `tagline` | *Optional[str]* | :heavy_minus_sign: | N/A | Return to Pandora. | | `flatten_seasons` | [Optional[operations.GetLibraryItemsFlattenSeasons]](../../models/operations/getlibraryitemsflattenseasons.md) | :heavy_minus_sign: | N/A | 1 | -| `show_ordering` | [Optional[operations.GetLibraryItemsShowOrdering]](../../models/operations/getlibraryitemsshowordering.md) | :heavy_minus_sign: | Setting that indicates the episode ordering for the show
None = Library default,
tmdbAiring = The Movie Database (Aired),
aired = TheTVDB (Aired),
dvd = TheTVDB (DVD),
absolute = TheTVDB (Absolute)).
| dvd | +| `show_ordering` | [Optional[operations.GetLibraryItemsShowOrdering]](../../models/operations/getlibraryitemsshowordering.md) | :heavy_minus_sign: | Setting that indicates the episode ordering for the show
None = Library default,
tmdbAiring = The Movie Database (Aired),
tvdbAiring = TheTVDB (Aired),
tvdbDvd = TheTVDB (DVD),
tvdbAbsolute = TheTVDB (Absolute)).
| tvdbDvd | | `thumb` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/thumb/1703239236 | | `art` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/art/1703239236 | | `banner` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/banner/1703239236 | diff --git a/docs/models/operations/getlibraryitemsqueryparamtype.md b/docs/models/operations/getlibraryitemsqueryparamtype.md index c44549d..3e72612 100644 --- a/docs/models/operations/getlibraryitemsqueryparamtype.md +++ b/docs/models/operations/getlibraryitemsqueryparamtype.md @@ -17,4 +17,6 @@ E.g. A movie library will not return anything with type 3 as there are no season | `TV_SHOW` | 2 | | `SEASON` | 3 | | `EPISODE` | 4 | -| `AUDIO` | 8 | \ No newline at end of file +| `AUDIO` | 8 | +| `ALBUM` | 9 | +| `TRACK` | 10 | \ No newline at end of file diff --git a/docs/models/operations/getlibraryitemsshowordering.md b/docs/models/operations/getlibraryitemsshowordering.md index f4330eb..2100e1e 100644 --- a/docs/models/operations/getlibraryitemsshowordering.md +++ b/docs/models/operations/getlibraryitemsshowordering.md @@ -1,20 +1,20 @@ # GetLibraryItemsShowOrdering -Setting that indicates the episode ordering for the show -None = Library default, -tmdbAiring = The Movie Database (Aired), -aired = TheTVDB (Aired), -dvd = TheTVDB (DVD), -absolute = TheTVDB (Absolute)). +Setting that indicates the episode ordering for the show +None = Library default, +tmdbAiring = The Movie Database (Aired), +tvdbAiring = TheTVDB (Aired), +tvdbDvd = TheTVDB (DVD), +tvdbAbsolute = TheTVDB (Absolute)). ## Values -| Name | Value | -| ------------- | ------------- | -| `NONE` | None | -| `TMDB_AIRING` | tmdbAiring | -| `AIRED` | aired | -| `DVD` | dvd | -| `ABSOLUTE` | absolute | \ No newline at end of file +| Name | Value | +| --------------- | --------------- | +| `NONE` | None | +| `TMDB_AIRING` | tmdbAiring | +| `TVDB_AIRING` | tvdbAiring | +| `TVDB_DVD` | tvdbDvd | +| `TVDB_ABSOLUTE` | tvdbAbsolute | \ No newline at end of file diff --git a/docs/models/operations/getmetadatabyratingkeymetadata.md b/docs/models/operations/getmetadatabyratingkeymetadata.md index 280537d..0c977e3 100644 --- a/docs/models/operations/getmetadatabyratingkeymetadata.md +++ b/docs/models/operations/getmetadatabyratingkeymetadata.md @@ -14,6 +14,11 @@ | `library_section_title` | *Optional[str]* | :heavy_minus_sign: | N/A | Movies | | `library_section_id` | *Optional[int]* | :heavy_minus_sign: | N/A | 1 | | `library_section_key` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/sections/1 | +| `grandparent_title` | *Optional[str]* | :heavy_minus_sign: | The name of the album artist for the track when audio, and the name of the TV show for the episode when video. | | +| `parent_title` | *Optional[str]* | :heavy_minus_sign: | The name of the album for the track when audio, and the name of the season for the episode when TV show. | | +| `original_title` | *Optional[str]* | :heavy_minus_sign: | The orginal untranslated name of the media item when non-english. | | +| `index` | *Optional[int]* | :heavy_minus_sign: | The index starting from 0 of this media item in the MetaData array. | | +| `parent_index` | *Optional[int]* | :heavy_minus_sign: | The parent index starting from 0 of this media item in the parent MetaData array. | | | `content_rating` | *Optional[str]* | :heavy_minus_sign: | N/A | PG-13 | | `summary` | *Optional[str]* | :heavy_minus_sign: | N/A | Serenity continues the story of the TV series it was based upon ("Firefly"). River Tam had a secret - one in which she's not even aware - so dangerous, no one's safe, as an Alliance operative's sent to capture her, and all others are considered irrelevant to his job. | | `rating` | *Optional[float]* | :heavy_minus_sign: | N/A | 8.2 | diff --git a/docs/models/operations/getpinglobals.md b/docs/models/operations/getpinglobals.md deleted file mode 100644 index 14f9d94..0000000 --- a/docs/models/operations/getpinglobals.md +++ /dev/null @@ -1,12 +0,0 @@ -# GetPinGlobals - - -## Fields - -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | -| `client_name` | *Optional[str]* | :heavy_minus_sign: | The name of the client application. (Plex Web, Plex Media Server, etc.) | Plex for Roku | -| `device_nickname` | *Optional[str]* | :heavy_minus_sign: | A relatively friendly name for the client device | Roku 3 | -| `client_version` | *Optional[str]* | :heavy_minus_sign: | The version of the client application. | 2.4.1 | -| `platform` | *Optional[str]* | :heavy_minus_sign: | The platform of the client application. | Roku | \ No newline at end of file diff --git a/docs/models/operations/getpinrequest.md b/docs/models/operations/getpinrequest.md index 351355a..ad57f85 100644 --- a/docs/models/operations/getpinrequest.md +++ b/docs/models/operations/getpinrequest.md @@ -5,8 +5,8 @@ | Field | Type | Required | Description | Example | | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | +| `client_id` | *str* | :heavy_check_mark: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `strong` | *Optional[bool]* | :heavy_minus_sign: | Determines the kind of code returned by the API call
Strong codes are used for Pin authentication flows
Non-Strong codes are used for `Plex.tv/link`
| | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `client_name` | *Optional[str]* | :heavy_minus_sign: | The name of the client application. (Plex Web, Plex Media Server, etc.) | Plex for Roku | | `device_nickname` | *Optional[str]* | :heavy_minus_sign: | A relatively friendly name for the client device | Roku 3 | | `client_version` | *Optional[str]* | :heavy_minus_sign: | The version of the client application. | 2.4.1 | diff --git a/docs/models/operations/getplaylistcontentsqueryparamtype.md b/docs/models/operations/getplaylistcontentsqueryparamtype.md index 5b1608f..03ff772 100644 --- a/docs/models/operations/getplaylistcontentsqueryparamtype.md +++ b/docs/models/operations/getplaylistcontentsqueryparamtype.md @@ -17,4 +17,6 @@ E.g. A movie library will not return anything with type 3 as there are no season | `TV_SHOW` | 2 | | `SEASON` | 3 | | `EPISODE` | 4 | -| `AUDIO` | 8 | \ No newline at end of file +| `AUDIO` | 8 | +| `ALBUM` | 9 | +| `TRACK` | 10 | \ No newline at end of file diff --git a/docs/models/operations/getrecentlyaddedmetadata.md b/docs/models/operations/getrecentlyaddedmetadata.md index cc07cdb..6149b22 100644 --- a/docs/models/operations/getrecentlyaddedmetadata.md +++ b/docs/models/operations/getrecentlyaddedmetadata.md @@ -25,7 +25,7 @@ | `season_count` | *Optional[int]* | :heavy_minus_sign: | N/A | 2022 | | `tagline` | *Optional[str]* | :heavy_minus_sign: | N/A | Return to Pandora. | | `flatten_seasons` | [Optional[operations.FlattenSeasons]](../../models/operations/flattenseasons.md) | :heavy_minus_sign: | N/A | 1 | -| `show_ordering` | [Optional[operations.ShowOrdering]](../../models/operations/showordering.md) | :heavy_minus_sign: | Setting that indicates the episode ordering for the show
None = Library default,
tmdbAiring = The Movie Database (Aired),
aired = TheTVDB (Aired),
dvd = TheTVDB (DVD),
absolute = TheTVDB (Absolute)).
| dvd | +| `show_ordering` | [Optional[operations.ShowOrdering]](../../models/operations/showordering.md) | :heavy_minus_sign: | Setting that indicates the episode ordering for the show
None = Library default,
tmdbAiring = The Movie Database (Aired),
tvdbAiring = TheTVDB (Aired),
tvdbDvd = TheTVDB (DVD),
tvdbAbsolute = TheTVDB (Absolute)).
| tvdbDvd | | `thumb` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/thumb/1703239236 | | `art` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/art/1703239236 | | `banner` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/banner/1703239236 | diff --git a/docs/models/operations/getsearchalllibrariesglobals.md b/docs/models/operations/getsearchalllibrariesglobals.md deleted file mode 100644 index 3f3089b..0000000 --- a/docs/models/operations/getsearchalllibrariesglobals.md +++ /dev/null @@ -1,8 +0,0 @@ -# GetSearchAllLibrariesGlobals - - -## Fields - -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | \ No newline at end of file diff --git a/docs/models/operations/getsearchalllibrariesmetadata.md b/docs/models/operations/getsearchalllibrariesmetadata.md index 1041b08..405074e 100644 --- a/docs/models/operations/getsearchalllibrariesmetadata.md +++ b/docs/models/operations/getsearchalllibrariesmetadata.md @@ -25,7 +25,7 @@ | `season_count` | *Optional[int]* | :heavy_minus_sign: | N/A | 2022 | | `tagline` | *Optional[str]* | :heavy_minus_sign: | N/A | Return to Pandora. | | `flatten_seasons` | [Optional[operations.GetSearchAllLibrariesFlattenSeasons]](../../models/operations/getsearchalllibrariesflattenseasons.md) | :heavy_minus_sign: | N/A | 1 | -| `show_ordering` | [Optional[operations.GetSearchAllLibrariesShowOrdering]](../../models/operations/getsearchalllibrariesshowordering.md) | :heavy_minus_sign: | Setting that indicates the episode ordering for the show
None = Library default,
tmdbAiring = The Movie Database (Aired),
aired = TheTVDB (Aired),
dvd = TheTVDB (DVD),
absolute = TheTVDB (Absolute)).
| dvd | +| `show_ordering` | [Optional[operations.GetSearchAllLibrariesShowOrdering]](../../models/operations/getsearchalllibrariesshowordering.md) | :heavy_minus_sign: | Setting that indicates the episode ordering for the show
None = Library default,
tmdbAiring = The Movie Database (Aired),
tvdbAiring = TheTVDB (Aired),
tvdbDvd = TheTVDB (DVD),
tvdbAbsolute = TheTVDB (Absolute)).
| tvdbDvd | | `thumb` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/thumb/1703239236 | | `art` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/art/1703239236 | | `banner` | *Optional[str]* | :heavy_minus_sign: | N/A | /library/metadata/58683/banner/1703239236 | diff --git a/docs/models/operations/getsearchalllibrariesrequest.md b/docs/models/operations/getsearchalllibrariesrequest.md index d4da33f..90864fa 100644 --- a/docs/models/operations/getsearchalllibrariesrequest.md +++ b/docs/models/operations/getsearchalllibrariesrequest.md @@ -6,7 +6,7 @@ | Field | Type | Required | Description | Example | | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | | `query` | *str* | :heavy_check_mark: | The search query term. | | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | +| `client_id` | *str* | :heavy_check_mark: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `limit` | *Optional[int]* | :heavy_minus_sign: | Limit the number of results returned. | | | `search_types` | List[[operations.SearchTypes](../../models/operations/searchtypes.md)] | :heavy_minus_sign: | A comma-separated list of search types to include. Valid values are: movies, music, otherVideos, people, tv.
| movies,music,otherVideos,people,tv | | `include_collections` | [Optional[operations.QueryParamIncludeCollections]](../../models/operations/queryparamincludecollections.md) | :heavy_minus_sign: | Whether to include collections in the search results. | 1 | diff --git a/docs/models/operations/getsearchalllibrariesshowordering.md b/docs/models/operations/getsearchalllibrariesshowordering.md index c1581cc..c1092d7 100644 --- a/docs/models/operations/getsearchalllibrariesshowordering.md +++ b/docs/models/operations/getsearchalllibrariesshowordering.md @@ -1,20 +1,20 @@ # GetSearchAllLibrariesShowOrdering -Setting that indicates the episode ordering for the show -None = Library default, -tmdbAiring = The Movie Database (Aired), -aired = TheTVDB (Aired), -dvd = TheTVDB (DVD), -absolute = TheTVDB (Absolute)). +Setting that indicates the episode ordering for the show +None = Library default, +tmdbAiring = The Movie Database (Aired), +tvdbAiring = TheTVDB (Aired), +tvdbDvd = TheTVDB (DVD), +tvdbAbsolute = TheTVDB (Absolute)). ## Values -| Name | Value | -| ------------- | ------------- | -| `NONE` | None | -| `TMDB_AIRING` | tmdbAiring | -| `AIRED` | aired | -| `DVD` | dvd | -| `ABSOLUTE` | absolute | \ No newline at end of file +| Name | Value | +| --------------- | --------------- | +| `NONE` | None | +| `TMDB_AIRING` | tmdbAiring | +| `TVDB_AIRING` | tvdbAiring | +| `TVDB_DVD` | tvdbDvd | +| `TVDB_ABSOLUTE` | tvdbAbsolute | \ No newline at end of file diff --git a/docs/models/operations/getsearchlibraryqueryparamtype.md b/docs/models/operations/getsearchlibraryqueryparamtype.md index 1caace7..9173866 100644 --- a/docs/models/operations/getsearchlibraryqueryparamtype.md +++ b/docs/models/operations/getsearchlibraryqueryparamtype.md @@ -17,4 +17,6 @@ E.g. A movie library will not return anything with type 3 as there are no season | `TV_SHOW` | 2 | | `SEASON` | 3 | | `EPISODE` | 4 | -| `AUDIO` | 8 | \ No newline at end of file +| `AUDIO` | 8 | +| `ALBUM` | 9 | +| `TRACK` | 10 | \ No newline at end of file diff --git a/docs/models/operations/getserverresourcesglobals.md b/docs/models/operations/getserverresourcesglobals.md deleted file mode 100644 index 6628c57..0000000 --- a/docs/models/operations/getserverresourcesglobals.md +++ /dev/null @@ -1,8 +0,0 @@ -# GetServerResourcesGlobals - - -## Fields - -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | \ No newline at end of file diff --git a/docs/models/operations/getserverresourcesrequest.md b/docs/models/operations/getserverresourcesrequest.md index beb093a..f506d4b 100644 --- a/docs/models/operations/getserverresourcesrequest.md +++ b/docs/models/operations/getserverresourcesrequest.md @@ -5,7 +5,7 @@ | Field | Type | Required | Description | Example | | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | +| `client_id` | *str* | :heavy_check_mark: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `include_https` | [Optional[operations.IncludeHTTPS]](../../models/operations/includehttps.md) | :heavy_minus_sign: | Include Https entries in the results | 1 | | `include_relay` | [Optional[operations.IncludeRelay]](../../models/operations/includerelay.md) | :heavy_minus_sign: | Include Relay addresses in the results
E.g: https://10-0-0-25.bbf8e10c7fa20447cacee74cd9914cde.plex.direct:32400
| 1 | -| `include_i_pv6` | [Optional[operations.IncludeIPv6]](../../models/operations/includeipv6.md) | :heavy_minus_sign: | Include IPv6 entries in the results | 1 | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | \ No newline at end of file +| `include_i_pv6` | [Optional[operations.IncludeIPv6]](../../models/operations/includeipv6.md) | :heavy_minus_sign: | Include IPv6 entries in the results | 1 | \ No newline at end of file diff --git a/docs/models/operations/gettokenbypinidglobals.md b/docs/models/operations/gettokenbypinidglobals.md deleted file mode 100644 index 8d23860..0000000 --- a/docs/models/operations/gettokenbypinidglobals.md +++ /dev/null @@ -1,12 +0,0 @@ -# GetTokenByPinIDGlobals - - -## Fields - -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | -| `client_name` | *Optional[str]* | :heavy_minus_sign: | The name of the client application. (Plex Web, Plex Media Server, etc.) | Plex for Roku | -| `device_nickname` | *Optional[str]* | :heavy_minus_sign: | A relatively friendly name for the client device | Roku 3 | -| `client_version` | *Optional[str]* | :heavy_minus_sign: | The version of the client application. | 2.4.1 | -| `platform` | *Optional[str]* | :heavy_minus_sign: | The platform of the client application. | Roku | \ No newline at end of file diff --git a/docs/models/operations/gettokenbypinidrequest.md b/docs/models/operations/gettokenbypinidrequest.md index 9dc272e..07d7661 100644 --- a/docs/models/operations/gettokenbypinidrequest.md +++ b/docs/models/operations/gettokenbypinidrequest.md @@ -6,7 +6,7 @@ | Field | Type | Required | Description | Example | | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | | `pin_id` | *int* | :heavy_check_mark: | The PinID to retrieve an access token for | | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | +| `client_id` | *str* | :heavy_check_mark: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `client_name` | *Optional[str]* | :heavy_minus_sign: | The name of the client application. (Plex Web, Plex Media Server, etc.) | Plex for Roku | | `device_nickname` | *Optional[str]* | :heavy_minus_sign: | A relatively friendly name for the client device | Roku 3 | | `client_version` | *Optional[str]* | :heavy_minus_sign: | The version of the client application. | 2.4.1 | diff --git a/docs/models/operations/gettopwatchedcontentqueryparamtype.md b/docs/models/operations/gettopwatchedcontentqueryparamtype.md index 77642ab..88163df 100644 --- a/docs/models/operations/gettopwatchedcontentqueryparamtype.md +++ b/docs/models/operations/gettopwatchedcontentqueryparamtype.md @@ -17,4 +17,6 @@ E.g. A movie library will not return anything with type 3 as there are no season | `TV_SHOW` | 2 | | `SEASON` | 3 | | `EPISODE` | 4 | -| `AUDIO` | 8 | \ No newline at end of file +| `AUDIO` | 8 | +| `ALBUM` | 9 | +| `TRACK` | 10 | \ No newline at end of file diff --git a/docs/models/operations/postuserssignindataglobals.md b/docs/models/operations/postuserssignindataglobals.md deleted file mode 100644 index e013c80..0000000 --- a/docs/models/operations/postuserssignindataglobals.md +++ /dev/null @@ -1,12 +0,0 @@ -# PostUsersSignInDataGlobals - - -## Fields - -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | -| `client_name` | *Optional[str]* | :heavy_minus_sign: | The name of the client application. (Plex Web, Plex Media Server, etc.) | Plex for Roku | -| `device_nickname` | *Optional[str]* | :heavy_minus_sign: | A relatively friendly name for the client device | Roku 3 | -| `client_version` | *Optional[str]* | :heavy_minus_sign: | The version of the client application. | 2.4.1 | -| `platform` | *Optional[str]* | :heavy_minus_sign: | The platform of the client application. | Roku | \ No newline at end of file diff --git a/docs/models/operations/postuserssignindatarequest.md b/docs/models/operations/postuserssignindatarequest.md index 52c5261..03360d9 100644 --- a/docs/models/operations/postuserssignindatarequest.md +++ b/docs/models/operations/postuserssignindatarequest.md @@ -5,7 +5,7 @@ | Field | Type | Required | Description | Example | | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | +| `client_id` | *str* | :heavy_check_mark: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `client_name` | *Optional[str]* | :heavy_minus_sign: | The name of the client application. (Plex Web, Plex Media Server, etc.) | Plex for Roku | | `device_nickname` | *Optional[str]* | :heavy_minus_sign: | A relatively friendly name for the client device | Roku 3 | | `client_version` | *Optional[str]* | :heavy_minus_sign: | The version of the client application. | 2.4.1 | diff --git a/docs/models/operations/queryparamtype.md b/docs/models/operations/queryparamtype.md index 5821513..8839871 100644 --- a/docs/models/operations/queryparamtype.md +++ b/docs/models/operations/queryparamtype.md @@ -17,4 +17,6 @@ E.g. A movie library will not return anything with type 3 as there are no season | `TV_SHOW` | 2 | | `SEASON` | 3 | | `EPISODE` | 4 | -| `AUDIO` | 8 | \ No newline at end of file +| `AUDIO` | 8 | +| `ALBUM` | 9 | +| `TRACK` | 10 | \ No newline at end of file diff --git a/docs/models/operations/showordering.md b/docs/models/operations/showordering.md index 091f806..345fb66 100644 --- a/docs/models/operations/showordering.md +++ b/docs/models/operations/showordering.md @@ -1,20 +1,20 @@ # ShowOrdering -Setting that indicates the episode ordering for the show -None = Library default, -tmdbAiring = The Movie Database (Aired), -aired = TheTVDB (Aired), -dvd = TheTVDB (DVD), -absolute = TheTVDB (Absolute)). +Setting that indicates the episode ordering for the show +None = Library default, +tmdbAiring = The Movie Database (Aired), +tvdbAiring = TheTVDB (Aired), +tvdbDvd = TheTVDB (DVD), +tvdbAbsolute = TheTVDB (Absolute)). ## Values -| Name | Value | -| ------------- | ------------- | -| `NONE` | None | -| `TMDB_AIRING` | tmdbAiring | -| `AIRED` | aired | -| `DVD` | dvd | -| `ABSOLUTE` | absolute | \ No newline at end of file +| Name | Value | +| --------------- | --------------- | +| `NONE` | None | +| `TMDB_AIRING` | tmdbAiring | +| `TVDB_AIRING` | tvdbAiring | +| `TVDB_DVD` | tvdbDvd | +| `TVDB_ABSOLUTE` | tvdbAbsolute | \ No newline at end of file diff --git a/docs/models/operations/tag.md b/docs/models/operations/tag.md index 19a3a0d..6693065 100644 --- a/docs/models/operations/tag.md +++ b/docs/models/operations/tag.md @@ -25,4 +25,5 @@ A key representing a specific tag within the section. | `RATING` | rating | | `RESOLUTION` | resolution | | `FIRST_CHARACTER` | firstCharacter | -| `FOLDER` | folder | \ No newline at end of file +| `FOLDER` | folder | +| `ALBUMS` | albums | \ No newline at end of file diff --git a/docs/models/operations/type.md b/docs/models/operations/type.md index 2682e54..de77210 100644 --- a/docs/models/operations/type.md +++ b/docs/models/operations/type.md @@ -17,4 +17,6 @@ E.g. A movie library will not return anything with type 3 as there are no season | `TV_SHOW` | 2 | | `SEASON` | 3 | | `EPISODE` | 4 | -| `AUDIO` | 8 | \ No newline at end of file +| `AUDIO` | 8 | +| `ALBUM` | 9 | +| `TRACK` | 10 | \ No newline at end of file diff --git a/docs/sdks/activities/README.md b/docs/sdks/activities/README.md index 241a85c..67c1c30 100644 --- a/docs/sdks/activities/README.md +++ b/docs/sdks/activities/README.md @@ -26,20 +26,16 @@ Get Server Activities ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.activities.get_server_activities() + res = plex_api.activities.get_server_activities() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -70,20 +66,16 @@ Cancel Server Activities ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.activities.cancel_server_activities(activity_uuid="25b71ed5-0f9d-461c-baa7-d404e9e10d3e") + res = plex_api.activities.cancel_server_activities(activity_uuid="25b71ed5-0f9d-461c-baa7-d404e9e10d3e") -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` diff --git a/docs/sdks/authentication/README.md b/docs/sdks/authentication/README.md index 4771ab4..a1d8e59 100644 --- a/docs/sdks/authentication/README.md +++ b/docs/sdks/authentication/README.md @@ -24,20 +24,16 @@ This endpoint provides the caller with a temporary token with the same access le from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.authentication.get_transient_token(type_=operations.GetTransientTokenQueryParamType.DELEGATION, scope=operations.Scope.ALL) + res = plex_api.authentication.get_transient_token(type_=operations.GetTransientTokenQueryParamType.DELEGATION, scope=operations.Scope.ALL) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -72,20 +68,16 @@ Note: requires Plex Media Server >= 1.15.4. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.authentication.get_source_connection_information(source="provider://provider-identifier") + res = plex_api.authentication.get_source_connection_information(source="provider://provider-identifier") -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -117,20 +109,16 @@ Get the User data from the provided X-Plex-Token ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.authentication.get_token_details() + res = plex_api.authentication.get_token_details() -if res.user_plex_account is not None: - # handle response - pass + assert res.user_plex_account is not None + + # Handle response + print(res.user_plex_account) ``` @@ -162,25 +150,25 @@ Sign in user with username and password and return user data with Plex authentic ```python from plex_api_client import PlexAPI -s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +with PlexAPI() as plex_api: -res = s.authentication.post_users_sign_in_data(request={ - "request_body": { - "login": "username@email.com", - "password": "password123", - "verification_code": "123456", - }, -}) + res = plex_api.authentication.post_users_sign_in_data(request={ + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "client_name": "Plex for Roku", + "device_nickname": "Roku 3", + "client_version": "2.4.1", + "platform": "Roku", + "request_body": { + "login": "username@email.com", + "password": "password123", + "verification_code": "123456", + }, + }) -if res.user_plex_account is not None: - # handle response - pass + assert res.user_plex_account is not None + + # Handle response + print(res.user_plex_account) ``` diff --git a/docs/sdks/butler/README.md b/docs/sdks/butler/README.md index 4d75869..6cc7ba8 100644 --- a/docs/sdks/butler/README.md +++ b/docs/sdks/butler/README.md @@ -23,20 +23,16 @@ Returns a list of butler tasks ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.butler.get_butler_tasks() + res = plex_api.butler.get_butler_tasks() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -72,20 +68,16 @@ This endpoint will attempt to start all Butler tasks that are enabled in the set ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.butler.start_all_tasks() + res = plex_api.butler.start_all_tasks() -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -117,20 +109,16 @@ This endpoint will stop all currently running tasks and remove any scheduled tas ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.butler.stop_all_tasks() + res = plex_api.butler.stop_all_tasks() -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -167,20 +155,16 @@ This endpoint will attempt to start a single Butler task that is enabled in the from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.butler.start_task(task_name=operations.TaskName.CLEAN_OLD_BUNDLES) + res = plex_api.butler.start_task(task_name=operations.TaskName.CLEAN_OLD_BUNDLES) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -214,20 +198,16 @@ This endpoint will stop a currently running task by name, or remove it from the from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.butler.stop_task(task_name=operations.PathParamTaskName.BACKUP_DATABASE) + res = plex_api.butler.stop_task(task_name=operations.PathParamTaskName.BACKUP_DATABASE) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` diff --git a/docs/sdks/hubs/README.md b/docs/sdks/hubs/README.md index e7850e8..b9aa34c 100644 --- a/docs/sdks/hubs/README.md +++ b/docs/sdks/hubs/README.md @@ -21,20 +21,16 @@ Get Global Hubs filtered by the parameters provided. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.hubs.get_global_hubs() + res = plex_api.hubs.get_global_hubs() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -69,27 +65,23 @@ This endpoint will return the recently added content. from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.hubs.get_recently_added(request={ - "content_directory_id": 470161, - "type": operations.Type.TV_SHOW, - "section_id": 2, - "include_meta": operations.IncludeMeta.ENABLE, - "x_plex_container_start": 0, - "x_plex_container_size": 50, -}) + res = plex_api.hubs.get_recently_added(request={ + "content_directory_id": 470161, + "type": operations.Type.TV_SHOW, + "section_id": 2, + "include_meta": operations.IncludeMeta.ENABLE, + "x_plex_container_start": 0, + "x_plex_container_size": 50, + }) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -120,20 +112,16 @@ This endpoint will return a list of library specific hubs ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.hubs.get_library_hubs(section_id=6728.76) + res = plex_api.hubs.get_library_hubs(section_id=6728.76) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` diff --git a/docs/sdks/library/README.md b/docs/sdks/library/README.md index f7107fe..dbc79d6 100644 --- a/docs/sdks/library/README.md +++ b/docs/sdks/library/README.md @@ -31,20 +31,16 @@ This resource returns hash values for local files ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_file_hash(url="file://C:\Image.png&type=13") + res = plex_api.library.get_file_hash(url="file://C:\Image.png&type=13") -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -79,41 +75,37 @@ This endpoint will return the recently added content. from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_recently_added_library(request={ - "type": operations.QueryParamType.TV_SHOW, - "content_directory_id": 2, - "pinned_content_directory_id": [ - 3, - 5, - 7, - 13, - 12, - 1, - 6, - 14, - 2, - 10, - 16, - 17, - ], - "section_id": 2, - "include_meta": operations.QueryParamIncludeMeta.ENABLE, - "x_plex_container_start": 0, - "x_plex_container_size": 50, -}) + res = plex_api.library.get_recently_added_library(request={ + "type": operations.QueryParamType.TV_SHOW, + "content_directory_id": 2, + "pinned_content_directory_id": [ + 3, + 5, + 7, + 13, + 12, + 1, + 6, + 14, + 2, + 10, + 16, + 17, + ], + "section_id": 2, + "include_meta": operations.QueryParamIncludeMeta.ENABLE, + "x_plex_container_start": 0, + "x_plex_container_size": 50, + }) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -151,20 +143,16 @@ This allows a client to provide a rich interface around the media (e.g. allow so ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_all_libraries() + res = plex_api.library.get_all_libraries() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -234,20 +222,16 @@ Each type in the library comes with a set of filters and sorts, aiding in buildi ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_library_details(section_key=9518) + res = plex_api.library.get_library_details(section_key=9518) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -280,20 +264,16 @@ Delete a library using a specific section id ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.delete_library(section_key=9518) + res = plex_api.library.delete_library(section_key=9518) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -338,6 +318,7 @@ Fetches details from a specific section of the library identified by a section k - `resolution`: Items categorized by resolution. - `firstCharacter`: Items categorized by the first letter. - `folder`: Items categorized by folder. +- `albums`: Items categorized by album. ### Example Usage @@ -346,28 +327,24 @@ Fetches details from a specific section of the library identified by a section k from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_library_items(request={ - "tag": operations.Tag.EDITION, - "section_key": 9518, - "include_guids": operations.IncludeGuids.ENABLE, - "type": operations.GetLibraryItemsQueryParamType.TV_SHOW, - "include_meta": operations.GetLibraryItemsQueryParamIncludeMeta.ENABLE, - "x_plex_container_start": 0, - "x_plex_container_size": 50, -}) + res = plex_api.library.get_library_items(request={ + "tag": operations.Tag.EDITION, + "section_key": 9518, + "include_guids": operations.IncludeGuids.ENABLE, + "type": operations.GetLibraryItemsQueryParamType.TV_SHOW, + "include_meta": operations.GetLibraryItemsQueryParamIncludeMeta.ENABLE, + "x_plex_container_start": 0, + "x_plex_container_size": 50, + }) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -401,20 +378,16 @@ This endpoint Refreshes all the Metadata of the library. from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_refresh_library_metadata(section_key=9518, force=operations.Force.ONE) + res = plex_api.library.get_refresh_library_metadata(section_key=9518, force=operations.Force.ONE) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -466,20 +439,16 @@ Each type in the library comes with a set of filters and sorts, aiding in buildi from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_search_library(section_key=9518, type_=operations.GetSearchLibraryQueryParamType.TV_SHOW) + res = plex_api.library.get_search_library(section_key=9518, type_=operations.GetSearchLibraryQueryParamType.TV_SHOW) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -514,27 +483,24 @@ Search the provided query across all library sections, or a single section, and from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_search_all_libraries(request={ - "query": "", - "search_types": [ - operations.SearchTypes.PEOPLE, - ], - "include_collections": operations.QueryParamIncludeCollections.ENABLE, - "include_external_media": operations.QueryParamIncludeExternalMedia.ENABLE, -}) + res = plex_api.library.get_search_all_libraries(request={ + "query": "", + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "search_types": [ + operations.SearchTypes.PEOPLE, + ], + "include_collections": operations.QueryParamIncludeCollections.ENABLE, + "include_external_media": operations.QueryParamIncludeExternalMedia.ENABLE, + }) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -567,20 +533,16 @@ This endpoint will return the metadata of a library item specified with the rati ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_meta_data_by_rating_key(rating_key=9518) + res = plex_api.library.get_meta_data_by_rating_key(rating_key=9518) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -613,20 +575,16 @@ This endpoint will return the children of of a library item specified with the r ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_metadata_children(rating_key=1539.14, include_elements="Stream") + res = plex_api.library.get_metadata_children(rating_key=1539.14, include_elements="Stream") -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -661,20 +619,16 @@ This endpoint will return the top watched content from libraries of a certain ty from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_top_watched_content(type_=operations.GetTopWatchedContentQueryParamType.TV_SHOW, include_guids=1) + res = plex_api.library.get_top_watched_content(type_=operations.GetTopWatchedContentQueryParamType.TV_SHOW, include_guids=1) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -708,20 +662,16 @@ This endpoint will return the on deck content. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.library.get_on_deck() + res = plex_api.library.get_on_deck() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` diff --git a/docs/sdks/log/README.md b/docs/sdks/log/README.md index 5c0966a..76530df 100644 --- a/docs/sdks/log/README.md +++ b/docs/sdks/log/README.md @@ -23,20 +23,16 @@ This endpoint will write a single-line log message, including a level and source from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.log.log_line(level=operations.Level.THREE, message="Test log message", source="Postman") + res = plex_api.log.log_line(level=operations.Level.THREE, message="Test log message", source="Postman") -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -91,22 +87,18 @@ Ensure each parameter is properly URL-encoded to avoid interpretation issues. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.log.log_multi_line(request="level=4&message=Test%20message%201&source=postman\n" + -"level=3&message=Test%20message%202&source=postman\n" + -"level=1&message=Test%20message%203&source=postman") + res = plex_api.log.log_multi_line(request="level=4&message=Test%20message%201&source=postman\n" + + "level=3&message=Test%20message%202&source=postman\n" + + "level=1&message=Test%20message%203&source=postman") -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -139,20 +131,16 @@ This endpoint will enable all Plex Media Serverlogs to be sent to the Papertrail ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.log.enable_paper_trail() + res = plex_api.log.enable_paper_trail() -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` diff --git a/docs/sdks/media/README.md b/docs/sdks/media/README.md index 0f52e71..06afcb7 100644 --- a/docs/sdks/media/README.md +++ b/docs/sdks/media/README.md @@ -23,20 +23,16 @@ This will mark the provided media key as Played. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.media.mark_played(key=59398) + res = plex_api.media.mark_played(key=59398) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -68,20 +64,16 @@ This will mark the provided media key as Unplayed. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.media.mark_unplayed(key=59398) + res = plex_api.media.mark_unplayed(key=59398) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -114,20 +106,16 @@ This API command can be used to update the play progress of a media item. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.media.update_play_progress(key="", time=90000, state="played") + res = plex_api.media.update_play_progress(key="", time=90000, state="played") -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -161,27 +149,23 @@ Gets the banner image of the media item ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.media.get_banner_image(request={ - "rating_key": 9518, - "width": 396, - "height": 396, - "min_size": 1, - "upscale": 1, - "x_plex_token": "CV5xoxjTpFKUzBTShsaf", -}) + res = plex_api.media.get_banner_image(request={ + "rating_key": 9518, + "width": 396, + "height": 396, + "min_size": 1, + "upscale": 1, + "x_plex_token": "CV5xoxjTpFKUzBTShsaf", + }) -if res.response_stream is not None: - # handle response - pass + assert res.response_stream is not None + + # Handle response + print(res.response_stream) ``` @@ -213,27 +197,23 @@ Gets the thumbnail image of the media item ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.media.get_thumb_image(request={ - "rating_key": 9518, - "width": 396, - "height": 396, - "min_size": 1, - "upscale": 1, - "x_plex_token": "CV5xoxjTpFKUzBTShsaf", -}) + res = plex_api.media.get_thumb_image(request={ + "rating_key": 9518, + "width": 396, + "height": 396, + "min_size": 1, + "upscale": 1, + "x_plex_token": "CV5xoxjTpFKUzBTShsaf", + }) -if res.response_stream is not None: - # handle response - pass + assert res.response_stream is not None + + # Handle response + print(res.response_stream) ``` diff --git a/docs/sdks/playlists/README.md b/docs/sdks/playlists/README.md index 6d13a9b..7161398 100644 --- a/docs/sdks/playlists/README.md +++ b/docs/sdks/playlists/README.md @@ -34,25 +34,21 @@ Create a new playlist. By default the playlist is blank. To create a playlist al from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.create_playlist(request={ - "title": "", - "type": operations.CreatePlaylistQueryParamType.PHOTO, - "smart": operations.Smart.ONE, - "uri": "https://inborn-brochure.biz", -}) + res = plex_api.playlists.create_playlist(request={ + "title": "", + "type": operations.CreatePlaylistQueryParamType.PHOTO, + "smart": operations.Smart.ONE, + "uri": "https://inborn-brochure.biz", + }) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -84,20 +80,16 @@ Get All Playlists given the specified filters. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.get_playlists() + res = plex_api.playlists.get_playlists() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -132,20 +124,16 @@ Smart playlist details contain the `content` attribute. This is the content URI ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.get_playlist(playlist_id=4109.48) + res = plex_api.playlists.get_playlist(playlist_id=4109.48) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -178,20 +166,16 @@ This endpoint will delete a playlist ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.delete_playlist(playlist_id=216.22) + res = plex_api.playlists.delete_playlist(playlist_id=216.22) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -224,20 +208,16 @@ From PMS version 1.9.1 clients can also edit playlist metadata using this endpoi ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.update_playlist(playlist_id=3915) + res = plex_api.playlists.update_playlist(playlist_id=3915) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -276,20 +256,16 @@ Note that for dumb playlists, items have a `playlistItemID` attribute which is u from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.get_playlist_contents(playlist_id=5004.46, type_=operations.GetPlaylistContentsQueryParamType.TV_SHOW) + res = plex_api.playlists.get_playlist_contents(playlist_id=5004.46, type_=operations.GetPlaylistContentsQueryParamType.TV_SHOW) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -323,20 +299,16 @@ Clears a playlist, only works with dumb playlists. Returns the playlist. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.clear_playlist_contents(playlist_id=1893.18) + res = plex_api.playlists.clear_playlist_contents(playlist_id=1893.18) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -370,20 +342,16 @@ With a smart playlist, passing a new `uri` parameter replaces the rules for the ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.add_playlist_contents(playlist_id=8502.01, uri="server://12345/com.plexapp.plugins.library/library/metadata/1", play_queue_id=123) + res = plex_api.playlists.add_playlist_contents(playlist_id=8502.01, uri="server://12345/com.plexapp.plugins.library/library/metadata/1", play_queue_id=123) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -419,20 +387,16 @@ Imports m3u playlists by passing a path on the server to scan for m3u-formatted from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.playlists.upload_playlist(path="/home/barkley/playlist.m3u", force=operations.QueryParamForce.ZERO, section_id=1) + res = plex_api.playlists.upload_playlist(path="/home/barkley/playlist.m3u", force=operations.QueryParamForce.ZERO, section_id=1) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` diff --git a/docs/sdks/plex/README.md b/docs/sdks/plex/README.md index 0ed6f5a..d8b491a 100644 --- a/docs/sdks/plex/README.md +++ b/docs/sdks/plex/README.md @@ -25,20 +25,16 @@ Get Companions Data ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.plex.get_companions_data() + res = plex_api.plex.get_companions_data() -if res.response_bodies is not None: - # handle response - pass + assert res.response_bodies is not None + + # Handle response + print(res.response_bodies) ``` @@ -70,20 +66,16 @@ Get friends of provided auth token. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.plex.get_user_friends() + res = plex_api.plex.get_user_friends() -if res.friends is not None: - # handle response - pass + assert res.friends is not None + + # Handle response + print(res.friends) ``` @@ -115,19 +107,14 @@ Returns the geolocation and locale data of the caller ```python from plex_api_client import PlexAPI -s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +with PlexAPI() as plex_api: -res = s.plex.get_geo_data() + res = plex_api.plex.get_geo_data() -if res.geo_data is not None: - # handle response - pass + assert res.geo_data is not None + + # Handle response + print(res.geo_data) ``` @@ -159,20 +146,16 @@ Retrieves the home data for the authenticated user, including details like home ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.plex.get_home_data() + res = plex_api.plex.get_home_data() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -204,20 +187,16 @@ Get Plex server access tokens and server connections from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.plex.get_server_resources(include_https=operations.IncludeHTTPS.ENABLE, include_relay=operations.IncludeRelay.ENABLE, include_i_pv6=operations.IncludeIPv6.ENABLE, client_id="3381b62b-9ab7-4e37-827b-203e9809eb58") + res = plex_api.plex.get_server_resources(client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", include_https=operations.IncludeHTTPS.ENABLE, include_relay=operations.IncludeRelay.ENABLE, include_i_pv6=operations.IncludeIPv6.ENABLE) -if res.plex_devices is not None: - # handle response - pass + assert res.plex_devices is not None + + # Handle response + print(res.plex_devices) ``` @@ -225,10 +204,10 @@ if res.plex_devices is not None: | Parameter | Type | Required | Description | Example | | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | +| `client_id` | *str* | :heavy_check_mark: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `include_https` | [Optional[operations.IncludeHTTPS]](../../models/operations/includehttps.md) | :heavy_minus_sign: | Include Https entries in the results | 1 | | `include_relay` | [Optional[operations.IncludeRelay]](../../models/operations/includerelay.md) | :heavy_minus_sign: | Include Relay addresses in the results
E.g: https://10-0-0-25.bbf8e10c7fa20447cacee74cd9914cde.plex.direct:32400
| 1 | | `include_i_pv6` | [Optional[operations.IncludeIPv6]](../../models/operations/includeipv6.md) | :heavy_minus_sign: | Include IPv6 entries in the results | 1 | -| `client_id` | *Optional[str]* | :heavy_minus_sign: | An opaque identifier unique to the client (UUID, serial number, or other unique device ID) | 3381b62b-9ab7-4e37-827b-203e9809eb58 | | `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | | `server_url` | *Optional[str]* | :heavy_minus_sign: | An optional server URL to use. | http://localhost:8080 | @@ -253,19 +232,20 @@ Retrieve a Pin ID from Plex.tv to use for authentication flows ```python from plex_api_client import PlexAPI -s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +with PlexAPI() as plex_api: -res = s.plex.get_pin(request={}) + res = plex_api.plex.get_pin(request={ + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "client_name": "Plex for Roku", + "device_nickname": "Roku 3", + "client_version": "2.4.1", + "platform": "Roku", + }) -if res.auth_pin_container is not None: - # handle response - pass + assert res.auth_pin_container is not None + + # Handle response + print(res.auth_pin_container) ``` @@ -297,21 +277,21 @@ Retrieve an Access Token from Plex.tv after the Pin has been authenticated ```python from plex_api_client import PlexAPI -s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +with PlexAPI() as plex_api: -res = s.plex.get_token_by_pin_id(request={ - "pin_id": 408895, -}) + res = plex_api.plex.get_token_by_pin_id(request={ + "pin_id": 408895, + "client_id": "3381b62b-9ab7-4e37-827b-203e9809eb58", + "client_name": "Plex for Roku", + "device_nickname": "Roku 3", + "client_version": "2.4.1", + "platform": "Roku", + }) -if res.auth_pin_container is not None: - # handle response - pass + assert res.auth_pin_container is not None + + # Handle response + print(res.auth_pin_container) ``` diff --git a/docs/sdks/plexapi/README.md b/docs/sdks/plexapi/README.md index e91fa37..1e395e4 100644 --- a/docs/sdks/plexapi/README.md +++ b/docs/sdks/plexapi/README.md @@ -26,3 +26,6 @@ The following SDKs are generated from the OpenAPI Specification. They are automa | PHP | [GitHub](https://github.com/LukeHagar/plexphp) | [Releases](https://github.com/LukeHagar/plexphp/releases) | - | | Java | [GitHub](https://github.com/LukeHagar/plexjava) | [Releases](https://github.com/LukeHagar/plexjava/releases) | - | | C# | [GitHub](https://github.com/LukeHagar/plexcsharp) | [Releases](https://github.com/LukeHagar/plexcsharp/releases) | - + + +### Available Operations diff --git a/docs/sdks/search/README.md b/docs/sdks/search/README.md index fc7d36c..7273be1 100644 --- a/docs/sdks/search/README.md +++ b/docs/sdks/search/README.md @@ -33,20 +33,16 @@ This request is intended to be very fast, and called as the user types. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.search.perform_search(query="dylan", limit=5) + res = plex_api.search.perform_search(query="dylan", limit=5) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -84,20 +80,16 @@ Results, as well as their containing per-type hubs, contain a `distance` attribu ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.search.perform_voice_search(query="dead+poop", limit=5) + res = plex_api.search.perform_voice_search(query="dead+poop", limit=5) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -131,20 +123,16 @@ This will search the database for the string provided. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.search.get_search_results(query="110") + res = plex_api.search.get_search_results(query="110") -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` diff --git a/docs/sdks/server/README.md b/docs/sdks/server/README.md index 53330fe..2ca000d 100644 --- a/docs/sdks/server/README.md +++ b/docs/sdks/server/README.md @@ -27,20 +27,16 @@ Get Server Capabilities ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_capabilities() + res = plex_api.server.get_server_capabilities() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -71,20 +67,16 @@ Get Server Preferences ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_preferences() + res = plex_api.server.get_server_preferences() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -115,20 +107,16 @@ Get Available Clients ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_available_clients() + res = plex_api.server.get_available_clients() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -159,20 +147,16 @@ Get Devices ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_devices() + res = plex_api.server.get_devices() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -203,19 +187,14 @@ This request is useful to determine if the server is online or offline ```python from plex_api_client import PlexAPI -s = PlexAPI( - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +with PlexAPI() as plex_api: -res = s.server.get_server_identity() + res = plex_api.server.get_server_identity() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -245,20 +224,16 @@ Returns MyPlex Account Information ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_my_plex_account() + res = plex_api.server.get_my_plex_account() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -291,28 +266,24 @@ Plex's Photo transcoder is used throughout the service to serve images at specif from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_resized_photo(request={ - "width": 110, - "height": 165, - "blur": 0, - "min_size": operations.MinSize.ONE, - "upscale": operations.Upscale.ONE, - "url": "/library/metadata/49564/thumb/1654258204", - "opacity": 100, -}) + res = plex_api.server.get_resized_photo(request={ + "width": 110, + "height": 165, + "blur": 0, + "min_size": operations.MinSize.ONE, + "upscale": operations.Upscale.ONE, + "url": "/library/metadata/49564/thumb/1654258204", + "opacity": 100, + }) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -344,20 +315,16 @@ Retrieves media providers and their features from the Plex server. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_media_providers(x_plex_token="CV5xoxjTpFKUzBTShsaf") + res = plex_api.server.get_media_providers(x_plex_token="CV5xoxjTpFKUzBTShsaf") -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -389,20 +356,16 @@ Get Server List ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.server.get_server_list() + res = plex_api.server.get_server_list() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` diff --git a/docs/sdks/sessions/README.md b/docs/sdks/sessions/README.md index 22aba5a..8124592 100644 --- a/docs/sdks/sessions/README.md +++ b/docs/sdks/sessions/README.md @@ -22,20 +22,16 @@ This will retrieve the "Now Playing" Information of the PMS. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.sessions.get_sessions() + res = plex_api.sessions.get_sessions() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -66,20 +62,16 @@ This will Retrieve a listing of all history views. ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.sessions.get_session_history(sort="viewedAt:desc", account_id=1, filter_={}, library_section_id=12) + res = plex_api.sessions.get_session_history(sort="viewedAt:desc", account_id=1, filter_={}, library_section_id=12) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -114,20 +106,16 @@ Get Transcode Sessions ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.sessions.get_transcode_sessions() + res = plex_api.sessions.get_transcode_sessions() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -158,20 +146,16 @@ Stop a Transcode Session ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.sessions.stop_transcode_session(session_key="zz7llzqlx8w9vnrsbnwhbmep") + res = plex_api.sessions.stop_transcode_session(session_key="zz7llzqlx8w9vnrsbnwhbmep") -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` diff --git a/docs/sdks/statistics/README.md b/docs/sdks/statistics/README.md index 3258e4c..cc3866d 100644 --- a/docs/sdks/statistics/README.md +++ b/docs/sdks/statistics/README.md @@ -21,20 +21,16 @@ This will return the media statistics for the server ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.statistics.get_statistics(timespan=4) + res = plex_api.statistics.get_statistics(timespan=4) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -66,20 +62,16 @@ This will return the resources for the server ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.statistics.get_resources_statistics(timespan=4) + res = plex_api.statistics.get_resources_statistics(timespan=4) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -111,20 +103,16 @@ This will return the bandwidth statistics for the server ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.statistics.get_bandwidth_statistics(timespan=4) + res = plex_api.statistics.get_bandwidth_statistics(timespan=4) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` diff --git a/docs/sdks/updater/README.md b/docs/sdks/updater/README.md index 1836d0f..fe58f56 100644 --- a/docs/sdks/updater/README.md +++ b/docs/sdks/updater/README.md @@ -22,20 +22,16 @@ Querying status of updates ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.updater.get_update_status() + res = plex_api.updater.get_update_status() -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` @@ -67,20 +63,16 @@ Checking for updates from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.updater.check_for_updates(download=operations.Download.ONE) + res = plex_api.updater.check_for_updates(download=operations.Download.ONE) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -114,20 +106,16 @@ Note that these two parameters are effectively mutually exclusive. The `tonight` from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.updater.apply_updates(tonight=operations.Tonight.ONE, skip=operations.Skip.ONE) + res = plex_api.updater.apply_updates(tonight=operations.Tonight.ONE, skip=operations.Skip.ONE) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` diff --git a/docs/sdks/video/README.md b/docs/sdks/video/README.md index 50a55fc..6b3cb64 100644 --- a/docs/sdks/video/README.md +++ b/docs/sdks/video/README.md @@ -21,31 +21,27 @@ Get the timeline for a media item from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.video.get_timeline(request={ - "rating_key": 23409, - "key": "/library/metadata/23409", - "state": operations.State.PLAYING, - "has_mde": 1, - "time": 2000, - "duration": 10000, - "context": "home:hub.continueWatching", - "play_queue_item_id": 1, - "play_back_time": 2000, - "row": 1, -}) + res = plex_api.video.get_timeline(request={ + "rating_key": 23409, + "key": "/library/metadata/23409", + "state": operations.State.PLAYING, + "has_mde": 1, + "time": 2000, + "duration": 10000, + "context": "home:hub.continueWatching", + "play_queue_item_id": 1, + "play_back_time": 2000, + "row": 1, + }) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` @@ -77,37 +73,33 @@ Begin a Universal Transcode Session ```python from plex_api_client import PlexAPI -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.video.start_universal_transcode(request={ - "has_mde": 1, - "path": "/library/metadata/23409", - "media_index": 0, - "part_index": 0, - "protocol": "hls", - "fast_seek": 0, - "direct_play": 0, - "direct_stream": 0, - "subtitle_size": 100, - "subtites": "burn", - "audio_boost": 100, - "location": "lan", - "media_buffer_size": 102400, - "session": "zvcage8b7rkioqcm8f4uns4c", - "add_debug_overlay": 0, - "auto_adjust_quality": 0, -}) + res = plex_api.video.start_universal_transcode(request={ + "has_mde": 1, + "path": "/library/metadata/23409", + "media_index": 0, + "part_index": 0, + "protocol": "hls", + "fast_seek": 0, + "direct_play": 0, + "direct_stream": 0, + "subtitle_size": 100, + "subtites": "burn", + "audio_boost": 100, + "location": "lan", + "media_buffer_size": 102400, + "session": "zvcage8b7rkioqcm8f4uns4c", + "add_debug_overlay": 0, + "auto_adjust_quality": 0, + }) -if res is not None: - # handle response - pass + assert res is not None + + # Handle response + print(res) ``` diff --git a/docs/sdks/watchlist/README.md b/docs/sdks/watchlist/README.md index 1cee00d..6b18747 100644 --- a/docs/sdks/watchlist/README.md +++ b/docs/sdks/watchlist/README.md @@ -20,25 +20,21 @@ Get User Watchlist from plex_api_client import PlexAPI from plex_api_client.models import operations -s = PlexAPI( +with PlexAPI( access_token="", - client_id="3381b62b-9ab7-4e37-827b-203e9809eb58", - client_name="Plex for Roku", - client_version="2.4.1", - platform="Roku", - device_nickname="Roku 3", -) +) as plex_api: -res = s.watchlist.get_watch_list(request={ - "filter_": operations.Filter.AVAILABLE, - "x_plex_token": "CV5xoxjTpFKUzBTShsaf", - "x_plex_container_start": 0, - "x_plex_container_size": 50, -}) + res = plex_api.watchlist.get_watch_list(request={ + "filter_": operations.Filter.AVAILABLE, + "x_plex_token": "CV5xoxjTpFKUzBTShsaf", + "x_plex_container_start": 0, + "x_plex_container_size": 50, + }) -if res.object is not None: - # handle response - pass + assert res.object is not None + + # Handle response + print(res.object) ``` diff --git a/poetry.lock b/poetry.lock index 362670e..fe72377 100644 --- a/poetry.lock +++ b/poetry.lock @@ -149,13 +149,13 @@ trio = ["trio (>=0.22.0,<0.26.0)"] [[package]] name = "httpx" -version = "0.27.2" +version = "0.28.1" description = "The next generation HTTP client." optional = false python-versions = ">=3.8" files = [ - {file = "httpx-0.27.2-py3-none-any.whl", hash = "sha256:7bb2708e112d8fdd7829cd4243970f0c223274051cb35ee80c03301ee29a3df0"}, - {file = "httpx-0.27.2.tar.gz", hash = "sha256:f7c2be1d2f3c3c3160d441802406b206c2b76f5947b11115e6df10c6c65e66c2"}, + {file = "httpx-0.28.1-py3-none-any.whl", hash = "sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad"}, + {file = "httpx-0.28.1.tar.gz", hash = "sha256:75e98c5f16b0f35b567856f597f06ff2270a374470a5c2392242528e3e3e42fc"}, ] [package.dependencies] @@ -163,7 +163,6 @@ anyio = "*" certifi = "*" httpcore = "==1.*" idna = "*" -sniffio = "*" [package.extras] brotli = ["brotli", "brotlicffi"] @@ -221,47 +220,53 @@ files = [ [[package]] name = "mypy" -version = "1.10.1" +version = "1.13.0" description = "Optional static typing for Python" optional = false python-versions = ">=3.8" files = [ - {file = "mypy-1.10.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:e36f229acfe250dc660790840916eb49726c928e8ce10fbdf90715090fe4ae02"}, - {file = "mypy-1.10.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:51a46974340baaa4145363b9e051812a2446cf583dfaeba124af966fa44593f7"}, - {file = "mypy-1.10.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:901c89c2d67bba57aaaca91ccdb659aa3a312de67f23b9dfb059727cce2e2e0a"}, - {file = "mypy-1.10.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0cd62192a4a32b77ceb31272d9e74d23cd88c8060c34d1d3622db3267679a5d9"}, - {file = "mypy-1.10.1-cp310-cp310-win_amd64.whl", hash = "sha256:a2cbc68cb9e943ac0814c13e2452d2046c2f2b23ff0278e26599224cf164e78d"}, - {file = "mypy-1.10.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:bd6f629b67bb43dc0d9211ee98b96d8dabc97b1ad38b9b25f5e4c4d7569a0c6a"}, - {file = "mypy-1.10.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:a1bbb3a6f5ff319d2b9d40b4080d46cd639abe3516d5a62c070cf0114a457d84"}, - {file = "mypy-1.10.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b8edd4e9bbbc9d7b79502eb9592cab808585516ae1bcc1446eb9122656c6066f"}, - {file = "mypy-1.10.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:6166a88b15f1759f94a46fa474c7b1b05d134b1b61fca627dd7335454cc9aa6b"}, - {file = "mypy-1.10.1-cp311-cp311-win_amd64.whl", hash = "sha256:5bb9cd11c01c8606a9d0b83ffa91d0b236a0e91bc4126d9ba9ce62906ada868e"}, - {file = "mypy-1.10.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:d8681909f7b44d0b7b86e653ca152d6dff0eb5eb41694e163c6092124f8246d7"}, - {file = "mypy-1.10.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:378c03f53f10bbdd55ca94e46ec3ba255279706a6aacaecac52ad248f98205d3"}, - {file = "mypy-1.10.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6bacf8f3a3d7d849f40ca6caea5c055122efe70e81480c8328ad29c55c69e93e"}, - {file = "mypy-1.10.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:701b5f71413f1e9855566a34d6e9d12624e9e0a8818a5704d74d6b0402e66c04"}, - {file = "mypy-1.10.1-cp312-cp312-win_amd64.whl", hash = "sha256:3c4c2992f6ea46ff7fce0072642cfb62af7a2484efe69017ed8b095f7b39ef31"}, - {file = "mypy-1.10.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:604282c886497645ffb87b8f35a57ec773a4a2721161e709a4422c1636ddde5c"}, - {file = "mypy-1.10.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:37fd87cab83f09842653f08de066ee68f1182b9b5282e4634cdb4b407266bade"}, - {file = "mypy-1.10.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8addf6313777dbb92e9564c5d32ec122bf2c6c39d683ea64de6a1fd98b90fe37"}, - {file = "mypy-1.10.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:5cc3ca0a244eb9a5249c7c583ad9a7e881aa5d7b73c35652296ddcdb33b2b9c7"}, - {file = "mypy-1.10.1-cp38-cp38-win_amd64.whl", hash = "sha256:1b3a2ffce52cc4dbaeee4df762f20a2905aa171ef157b82192f2e2f368eec05d"}, - {file = "mypy-1.10.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:fe85ed6836165d52ae8b88f99527d3d1b2362e0cb90b005409b8bed90e9059b3"}, - {file = "mypy-1.10.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:c2ae450d60d7d020d67ab440c6e3fae375809988119817214440033f26ddf7bf"}, - {file = "mypy-1.10.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6be84c06e6abd72f960ba9a71561c14137a583093ffcf9bbfaf5e613d63fa531"}, - {file = "mypy-1.10.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:2189ff1e39db399f08205e22a797383613ce1cb0cb3b13d8bcf0170e45b96cc3"}, - {file = "mypy-1.10.1-cp39-cp39-win_amd64.whl", hash = "sha256:97a131ee36ac37ce9581f4220311247ab6cba896b4395b9c87af0675a13a755f"}, - {file = "mypy-1.10.1-py3-none-any.whl", hash = "sha256:71d8ac0b906354ebda8ef1673e5fde785936ac1f29ff6987c7483cfbd5a4235a"}, - {file = "mypy-1.10.1.tar.gz", hash = "sha256:1f8f492d7db9e3593ef42d4f115f04e556130f2819ad33ab84551403e97dd4c0"}, + {file = "mypy-1.13.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:6607e0f1dd1fb7f0aca14d936d13fd19eba5e17e1cd2a14f808fa5f8f6d8f60a"}, + {file = "mypy-1.13.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:8a21be69bd26fa81b1f80a61ee7ab05b076c674d9b18fb56239d72e21d9f4c80"}, + {file = "mypy-1.13.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:7b2353a44d2179846a096e25691d54d59904559f4232519d420d64da6828a3a7"}, + {file = "mypy-1.13.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0730d1c6a2739d4511dc4253f8274cdd140c55c32dfb0a4cf8b7a43f40abfa6f"}, + {file = "mypy-1.13.0-cp310-cp310-win_amd64.whl", hash = "sha256:c5fc54dbb712ff5e5a0fca797e6e0aa25726c7e72c6a5850cfd2adbc1eb0a372"}, + {file = "mypy-1.13.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:581665e6f3a8a9078f28d5502f4c334c0c8d802ef55ea0e7276a6e409bc0d82d"}, + {file = "mypy-1.13.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:3ddb5b9bf82e05cc9a627e84707b528e5c7caaa1c55c69e175abb15a761cec2d"}, + {file = "mypy-1.13.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:20c7ee0bc0d5a9595c46f38beb04201f2620065a93755704e141fcac9f59db2b"}, + {file = "mypy-1.13.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:3790ded76f0b34bc9c8ba4def8f919dd6a46db0f5a6610fb994fe8efdd447f73"}, + {file = "mypy-1.13.0-cp311-cp311-win_amd64.whl", hash = "sha256:51f869f4b6b538229c1d1bcc1dd7d119817206e2bc54e8e374b3dfa202defcca"}, + {file = "mypy-1.13.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:5c7051a3461ae84dfb5dd15eff5094640c61c5f22257c8b766794e6dd85e72d5"}, + {file = "mypy-1.13.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:39bb21c69a5d6342f4ce526e4584bc5c197fd20a60d14a8624d8743fffb9472e"}, + {file = "mypy-1.13.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:164f28cb9d6367439031f4c81e84d3ccaa1e19232d9d05d37cb0bd880d3f93c2"}, + {file = "mypy-1.13.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:a4c1bfcdbce96ff5d96fc9b08e3831acb30dc44ab02671eca5953eadad07d6d0"}, + {file = "mypy-1.13.0-cp312-cp312-win_amd64.whl", hash = "sha256:a0affb3a79a256b4183ba09811e3577c5163ed06685e4d4b46429a271ba174d2"}, + {file = "mypy-1.13.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:a7b44178c9760ce1a43f544e595d35ed61ac2c3de306599fa59b38a6048e1aa7"}, + {file = "mypy-1.13.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:5d5092efb8516d08440e36626f0153b5006d4088c1d663d88bf79625af3d1d62"}, + {file = "mypy-1.13.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:de2904956dac40ced10931ac967ae63c5089bd498542194b436eb097a9f77bc8"}, + {file = "mypy-1.13.0-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:7bfd8836970d33c2105562650656b6846149374dc8ed77d98424b40b09340ba7"}, + {file = "mypy-1.13.0-cp313-cp313-win_amd64.whl", hash = "sha256:9f73dba9ec77acb86457a8fc04b5239822df0c14a082564737833d2963677dbc"}, + {file = "mypy-1.13.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:100fac22ce82925f676a734af0db922ecfea991e1d7ec0ceb1e115ebe501301a"}, + {file = "mypy-1.13.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:7bcb0bb7f42a978bb323a7c88f1081d1b5dee77ca86f4100735a6f541299d8fb"}, + {file = "mypy-1.13.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:bde31fc887c213e223bbfc34328070996061b0833b0a4cfec53745ed61f3519b"}, + {file = "mypy-1.13.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:07de989f89786f62b937851295ed62e51774722e5444a27cecca993fc3f9cd74"}, + {file = "mypy-1.13.0-cp38-cp38-win_amd64.whl", hash = "sha256:4bde84334fbe19bad704b3f5b78c4abd35ff1026f8ba72b29de70dda0916beb6"}, + {file = "mypy-1.13.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:0246bcb1b5de7f08f2826451abd947bf656945209b140d16ed317f65a17dc7dc"}, + {file = "mypy-1.13.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:7f5b7deae912cf8b77e990b9280f170381fdfbddf61b4ef80927edd813163732"}, + {file = "mypy-1.13.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:7029881ec6ffb8bc233a4fa364736789582c738217b133f1b55967115288a2bc"}, + {file = "mypy-1.13.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:3e38b980e5681f28f033f3be86b099a247b13c491f14bb8b1e1e134d23bb599d"}, + {file = "mypy-1.13.0-cp39-cp39-win_amd64.whl", hash = "sha256:a6789be98a2017c912ae6ccb77ea553bbaf13d27605d2ca20a76dfbced631b24"}, + {file = "mypy-1.13.0-py3-none-any.whl", hash = "sha256:9c250883f9fd81d212e0952c92dbfcc96fc237f4b7c92f56ac81fd48460b3e5a"}, + {file = "mypy-1.13.0.tar.gz", hash = "sha256:0291a61b6fbf3e6673e3405cfcc0e7650bebc7939659fdca2702958038bd835e"}, ] [package.dependencies] mypy-extensions = ">=1.0.0" tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} -typing-extensions = ">=4.1.0" +typing-extensions = ">=4.6.0" [package.extras] dmypy = ["psutil (>=4.0)"] +faster-cache = ["orjson"] install-types = ["pip"] mypyc = ["setuptools (>=50)"] reports = ["lxml"] @@ -295,22 +300,19 @@ type = ["mypy (>=1.11.2)"] [[package]] name = "pydantic" -version = "2.9.2" +version = "2.10.4" description = "Data validation using Python type hints" optional = false python-versions = ">=3.8" files = [ - {file = "pydantic-2.9.2-py3-none-any.whl", hash = "sha256:f048cec7b26778210e28a0459867920654d48e5e62db0958433636cde4254f12"}, - {file = "pydantic-2.9.2.tar.gz", hash = "sha256:d155cef71265d1e9807ed1c32b4c8deec042a44a50a4188b25ac67ecd81a9c0f"}, + {file = "pydantic-2.10.4-py3-none-any.whl", hash = "sha256:597e135ea68be3a37552fb524bc7d0d66dcf93d395acd93a00682f1efcb8ee3d"}, + {file = "pydantic-2.10.4.tar.gz", hash = "sha256:82f12e9723da6de4fe2ba888b5971157b3be7ad914267dea8f05f82b28254f06"}, ] [package.dependencies] annotated-types = ">=0.6.0" -pydantic-core = "2.23.4" -typing-extensions = [ - {version = ">=4.6.1", markers = "python_version < \"3.13\""}, - {version = ">=4.12.2", markers = "python_version >= \"3.13\""}, -] +pydantic-core = "2.27.2" +typing-extensions = ">=4.12.2" [package.extras] email = ["email-validator (>=2.0.0)"] @@ -318,100 +320,111 @@ timezone = ["tzdata"] [[package]] name = "pydantic-core" -version = "2.23.4" +version = "2.27.2" description = "Core functionality for Pydantic validation and serialization" optional = false python-versions = ">=3.8" files = [ - {file = "pydantic_core-2.23.4-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:b10bd51f823d891193d4717448fab065733958bdb6a6b351967bd349d48d5c9b"}, - {file = "pydantic_core-2.23.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:4fc714bdbfb534f94034efaa6eadd74e5b93c8fa6315565a222f7b6f42ca1166"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:63e46b3169866bd62849936de036f901a9356e36376079b05efa83caeaa02ceb"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ed1a53de42fbe34853ba90513cea21673481cd81ed1be739f7f2efb931b24916"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:cfdd16ab5e59fc31b5e906d1a3f666571abc367598e3e02c83403acabc092e07"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:255a8ef062cbf6674450e668482456abac99a5583bbafb73f9ad469540a3a232"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4a7cd62e831afe623fbb7aabbb4fe583212115b3ef38a9f6b71869ba644624a2"}, - {file = "pydantic_core-2.23.4-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:f09e2ff1f17c2b51f2bc76d1cc33da96298f0a036a137f5440ab3ec5360b624f"}, - {file = "pydantic_core-2.23.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:e38e63e6f3d1cec5a27e0afe90a085af8b6806ee208b33030e65b6516353f1a3"}, - {file = "pydantic_core-2.23.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0dbd8dbed2085ed23b5c04afa29d8fd2771674223135dc9bc937f3c09284d071"}, - {file = "pydantic_core-2.23.4-cp310-none-win32.whl", hash = "sha256:6531b7ca5f951d663c339002e91aaebda765ec7d61b7d1e3991051906ddde119"}, - {file = "pydantic_core-2.23.4-cp310-none-win_amd64.whl", hash = "sha256:7c9129eb40958b3d4500fa2467e6a83356b3b61bfff1b414c7361d9220f9ae8f"}, - {file = "pydantic_core-2.23.4-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:77733e3892bb0a7fa797826361ce8a9184d25c8dffaec60b7ffe928153680ba8"}, - {file = "pydantic_core-2.23.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:1b84d168f6c48fabd1f2027a3d1bdfe62f92cade1fb273a5d68e621da0e44e6d"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:df49e7a0861a8c36d089c1ed57d308623d60416dab2647a4a17fe050ba85de0e"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ff02b6d461a6de369f07ec15e465a88895f3223eb75073ffea56b84d9331f607"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:996a38a83508c54c78a5f41456b0103c30508fed9abcad0a59b876d7398f25fd"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d97683ddee4723ae8c95d1eddac7c192e8c552da0c73a925a89fa8649bf13eea"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:216f9b2d7713eb98cb83c80b9c794de1f6b7e3145eef40400c62e86cee5f4e1e"}, - {file = "pydantic_core-2.23.4-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:6f783e0ec4803c787bcea93e13e9932edab72068f68ecffdf86a99fd5918878b"}, - {file = "pydantic_core-2.23.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:d0776dea117cf5272382634bd2a5c1b6eb16767c223c6a5317cd3e2a757c61a0"}, - {file = "pydantic_core-2.23.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:d5f7a395a8cf1621939692dba2a6b6a830efa6b3cee787d82c7de1ad2930de64"}, - {file = "pydantic_core-2.23.4-cp311-none-win32.whl", hash = "sha256:74b9127ffea03643e998e0c5ad9bd3811d3dac8c676e47db17b0ee7c3c3bf35f"}, - {file = "pydantic_core-2.23.4-cp311-none-win_amd64.whl", hash = "sha256:98d134c954828488b153d88ba1f34e14259284f256180ce659e8d83e9c05eaa3"}, - {file = "pydantic_core-2.23.4-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:f3e0da4ebaef65158d4dfd7d3678aad692f7666877df0002b8a522cdf088f231"}, - {file = "pydantic_core-2.23.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:f69a8e0b033b747bb3e36a44e7732f0c99f7edd5cea723d45bc0d6e95377ffee"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:723314c1d51722ab28bfcd5240d858512ffd3116449c557a1336cbe3919beb87"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:bb2802e667b7051a1bebbfe93684841cc9351004e2badbd6411bf357ab8d5ac8"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d18ca8148bebe1b0a382a27a8ee60350091a6ddaf475fa05ef50dc35b5df6327"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:33e3d65a85a2a4a0dc3b092b938a4062b1a05f3a9abde65ea93b233bca0e03f2"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:128585782e5bfa515c590ccee4b727fb76925dd04a98864182b22e89a4e6ed36"}, - {file = "pydantic_core-2.23.4-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:68665f4c17edcceecc112dfed5dbe6f92261fb9d6054b47d01bf6371a6196126"}, - {file = "pydantic_core-2.23.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:20152074317d9bed6b7a95ade3b7d6054845d70584216160860425f4fbd5ee9e"}, - {file = "pydantic_core-2.23.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:9261d3ce84fa1d38ed649c3638feefeae23d32ba9182963e465d58d62203bd24"}, - {file = "pydantic_core-2.23.4-cp312-none-win32.whl", hash = "sha256:4ba762ed58e8d68657fc1281e9bb72e1c3e79cc5d464be146e260c541ec12d84"}, - {file = "pydantic_core-2.23.4-cp312-none-win_amd64.whl", hash = "sha256:97df63000f4fea395b2824da80e169731088656d1818a11b95f3b173747b6cd9"}, - {file = "pydantic_core-2.23.4-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:7530e201d10d7d14abce4fb54cfe5b94a0aefc87da539d0346a484ead376c3cc"}, - {file = "pydantic_core-2.23.4-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:df933278128ea1cd77772673c73954e53a1c95a4fdf41eef97c2b779271bd0bd"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0cb3da3fd1b6a5d0279a01877713dbda118a2a4fc6f0d821a57da2e464793f05"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:42c6dcb030aefb668a2b7009c85b27f90e51e6a3b4d5c9bc4c57631292015b0d"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:696dd8d674d6ce621ab9d45b205df149399e4bb9aa34102c970b721554828510"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2971bb5ffe72cc0f555c13e19b23c85b654dd2a8f7ab493c262071377bfce9f6"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8394d940e5d400d04cad4f75c0598665cbb81aecefaca82ca85bd28264af7f9b"}, - {file = "pydantic_core-2.23.4-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:0dff76e0602ca7d4cdaacc1ac4c005e0ce0dcfe095d5b5259163a80d3a10d327"}, - {file = "pydantic_core-2.23.4-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:7d32706badfe136888bdea71c0def994644e09fff0bfe47441deaed8e96fdbc6"}, - {file = "pydantic_core-2.23.4-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:ed541d70698978a20eb63d8c5d72f2cc6d7079d9d90f6b50bad07826f1320f5f"}, - {file = "pydantic_core-2.23.4-cp313-none-win32.whl", hash = "sha256:3d5639516376dce1940ea36edf408c554475369f5da2abd45d44621cb616f769"}, - {file = "pydantic_core-2.23.4-cp313-none-win_amd64.whl", hash = "sha256:5a1504ad17ba4210df3a045132a7baeeba5a200e930f57512ee02909fc5c4cb5"}, - {file = "pydantic_core-2.23.4-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:d4488a93b071c04dc20f5cecc3631fc78b9789dd72483ba15d423b5b3689b555"}, - {file = "pydantic_core-2.23.4-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:81965a16b675b35e1d09dd14df53f190f9129c0202356ed44ab2728b1c905658"}, - {file = "pydantic_core-2.23.4-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4ffa2ebd4c8530079140dd2d7f794a9d9a73cbb8e9d59ffe24c63436efa8f271"}, - {file = "pydantic_core-2.23.4-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:61817945f2fe7d166e75fbfb28004034b48e44878177fc54d81688e7b85a3665"}, - {file = "pydantic_core-2.23.4-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:29d2c342c4bc01b88402d60189f3df065fb0dda3654744d5a165a5288a657368"}, - {file = "pydantic_core-2.23.4-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5e11661ce0fd30a6790e8bcdf263b9ec5988e95e63cf901972107efc49218b13"}, - {file = "pydantic_core-2.23.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9d18368b137c6295db49ce7218b1a9ba15c5bc254c96d7c9f9e924a9bc7825ad"}, - {file = "pydantic_core-2.23.4-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:ec4e55f79b1c4ffb2eecd8a0cfba9955a2588497d96851f4c8f99aa4a1d39b12"}, - {file = "pydantic_core-2.23.4-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:374a5e5049eda9e0a44c696c7ade3ff355f06b1fe0bb945ea3cac2bc336478a2"}, - {file = "pydantic_core-2.23.4-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:5c364564d17da23db1106787675fc7af45f2f7b58b4173bfdd105564e132e6fb"}, - {file = "pydantic_core-2.23.4-cp38-none-win32.whl", hash = "sha256:d7a80d21d613eec45e3d41eb22f8f94ddc758a6c4720842dc74c0581f54993d6"}, - {file = "pydantic_core-2.23.4-cp38-none-win_amd64.whl", hash = "sha256:5f5ff8d839f4566a474a969508fe1c5e59c31c80d9e140566f9a37bba7b8d556"}, - {file = "pydantic_core-2.23.4-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:a4fa4fc04dff799089689f4fd502ce7d59de529fc2f40a2c8836886c03e0175a"}, - {file = "pydantic_core-2.23.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:0a7df63886be5e270da67e0966cf4afbae86069501d35c8c1b3b6c168f42cb36"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dcedcd19a557e182628afa1d553c3895a9f825b936415d0dbd3cd0bbcfd29b4b"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:5f54b118ce5de9ac21c363d9b3caa6c800341e8c47a508787e5868c6b79c9323"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:86d2f57d3e1379a9525c5ab067b27dbb8a0642fb5d454e17a9ac434f9ce523e3"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:de6d1d1b9e5101508cb37ab0d972357cac5235f5c6533d1071964c47139257df"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1278e0d324f6908e872730c9102b0112477a7f7cf88b308e4fc36ce1bdb6d58c"}, - {file = "pydantic_core-2.23.4-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:9a6b5099eeec78827553827f4c6b8615978bb4b6a88e5d9b93eddf8bb6790f55"}, - {file = "pydantic_core-2.23.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:e55541f756f9b3ee346b840103f32779c695a19826a4c442b7954550a0972040"}, - {file = "pydantic_core-2.23.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:a5c7ba8ffb6d6f8f2ab08743be203654bb1aaa8c9dcb09f82ddd34eadb695605"}, - {file = "pydantic_core-2.23.4-cp39-none-win32.whl", hash = "sha256:37b0fe330e4a58d3c58b24d91d1eb102aeec675a3db4c292ec3928ecd892a9a6"}, - {file = "pydantic_core-2.23.4-cp39-none-win_amd64.whl", hash = "sha256:1498bec4c05c9c787bde9125cfdcc63a41004ff167f495063191b863399b1a29"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:f455ee30a9d61d3e1a15abd5068827773d6e4dc513e795f380cdd59932c782d5"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:1e90d2e3bd2c3863d48525d297cd143fe541be8bbf6f579504b9712cb6b643ec"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2e203fdf807ac7e12ab59ca2bfcabb38c7cf0b33c41efeb00f8e5da1d86af480"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e08277a400de01bc72436a0ccd02bdf596631411f592ad985dcee21445bd0068"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:f220b0eea5965dec25480b6333c788fb72ce5f9129e8759ef876a1d805d00801"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:d06b0c8da4f16d1d1e352134427cb194a0a6e19ad5db9161bf32b2113409e728"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:ba1a0996f6c2773bd83e63f18914c1de3c9dd26d55f4ac302a7efe93fb8e7433"}, - {file = "pydantic_core-2.23.4-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:9a5bce9d23aac8f0cf0836ecfc033896aa8443b501c58d0602dbfd5bd5b37753"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:78ddaaa81421a29574a682b3179d4cf9e6d405a09b99d93ddcf7e5239c742e21"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:883a91b5dd7d26492ff2f04f40fbb652de40fcc0afe07e8129e8ae779c2110eb"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:88ad334a15b32a791ea935af224b9de1bf99bcd62fabf745d5f3442199d86d59"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:233710f069d251feb12a56da21e14cca67994eab08362207785cf8c598e74577"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:19442362866a753485ba5e4be408964644dd6a09123d9416c54cd49171f50744"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:624e278a7d29b6445e4e813af92af37820fafb6dcc55c012c834f9e26f9aaaef"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:f5ef8f42bec47f21d07668a043f077d507e5bf4e668d5c6dfe6aaba89de1a5b8"}, - {file = "pydantic_core-2.23.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:aea443fffa9fbe3af1a9ba721a87f926fe548d32cab71d188a6ede77d0ff244e"}, - {file = "pydantic_core-2.23.4.tar.gz", hash = "sha256:2584f7cf844ac4d970fba483a717dbe10c1c1c96a969bf65d61ffe94df1b2863"}, + {file = "pydantic_core-2.27.2-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:2d367ca20b2f14095a8f4fa1210f5a7b78b8a20009ecced6b12818f455b1e9fa"}, + {file = "pydantic_core-2.27.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:491a2b73db93fab69731eaee494f320faa4e093dbed776be1a829c2eb222c34c"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7969e133a6f183be60e9f6f56bfae753585680f3b7307a8e555a948d443cc05a"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3de9961f2a346257caf0aa508a4da705467f53778e9ef6fe744c038119737ef5"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e2bb4d3e5873c37bb3dd58714d4cd0b0e6238cebc4177ac8fe878f8b3aa8e74c"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:280d219beebb0752699480fe8f1dc61ab6615c2046d76b7ab7ee38858de0a4e7"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:47956ae78b6422cbd46f772f1746799cbb862de838fd8d1fbd34a82e05b0983a"}, + {file = "pydantic_core-2.27.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:14d4a5c49d2f009d62a2a7140d3064f686d17a5d1a268bc641954ba181880236"}, + {file = "pydantic_core-2.27.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:337b443af21d488716f8d0b6164de833e788aa6bd7e3a39c005febc1284f4962"}, + {file = "pydantic_core-2.27.2-cp310-cp310-musllinux_1_1_armv7l.whl", hash = "sha256:03d0f86ea3184a12f41a2d23f7ccb79cdb5a18e06993f8a45baa8dfec746f0e9"}, + {file = "pydantic_core-2.27.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:7041c36f5680c6e0f08d922aed302e98b3745d97fe1589db0a3eebf6624523af"}, + {file = "pydantic_core-2.27.2-cp310-cp310-win32.whl", hash = "sha256:50a68f3e3819077be2c98110c1f9dcb3817e93f267ba80a2c05bb4f8799e2ff4"}, + {file = "pydantic_core-2.27.2-cp310-cp310-win_amd64.whl", hash = "sha256:e0fd26b16394ead34a424eecf8a31a1f5137094cabe84a1bcb10fa6ba39d3d31"}, + {file = "pydantic_core-2.27.2-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:8e10c99ef58cfdf2a66fc15d66b16c4a04f62bca39db589ae8cba08bc55331bc"}, + {file = "pydantic_core-2.27.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:26f32e0adf166a84d0cb63be85c562ca8a6fa8de28e5f0d92250c6b7e9e2aff7"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8c19d1ea0673cd13cc2f872f6c9ab42acc4e4f492a7ca9d3795ce2b112dd7e15"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:5e68c4446fe0810e959cdff46ab0a41ce2f2c86d227d96dc3847af0ba7def306"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d9640b0059ff4f14d1f37321b94061c6db164fbe49b334b31643e0528d100d99"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:40d02e7d45c9f8af700f3452f329ead92da4c5f4317ca9b896de7ce7199ea459"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1c1fd185014191700554795c99b347d64f2bb637966c4cfc16998a0ca700d048"}, + {file = "pydantic_core-2.27.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:d81d2068e1c1228a565af076598f9e7451712700b673de8f502f0334f281387d"}, + {file = "pydantic_core-2.27.2-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:1a4207639fb02ec2dbb76227d7c751a20b1a6b4bc52850568e52260cae64ca3b"}, + {file = "pydantic_core-2.27.2-cp311-cp311-musllinux_1_1_armv7l.whl", hash = "sha256:3de3ce3c9ddc8bbd88f6e0e304dea0e66d843ec9de1b0042b0911c1663ffd474"}, + {file = "pydantic_core-2.27.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:30c5f68ded0c36466acede341551106821043e9afaad516adfb6e8fa80a4e6a6"}, + {file = "pydantic_core-2.27.2-cp311-cp311-win32.whl", hash = "sha256:c70c26d2c99f78b125a3459f8afe1aed4d9687c24fd677c6a4436bc042e50d6c"}, + {file = "pydantic_core-2.27.2-cp311-cp311-win_amd64.whl", hash = "sha256:08e125dbdc505fa69ca7d9c499639ab6407cfa909214d500897d02afb816e7cc"}, + {file = "pydantic_core-2.27.2-cp311-cp311-win_arm64.whl", hash = "sha256:26f0d68d4b235a2bae0c3fc585c585b4ecc51382db0e3ba402a22cbc440915e4"}, + {file = "pydantic_core-2.27.2-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:9e0c8cfefa0ef83b4da9588448b6d8d2a2bf1a53c3f1ae5fca39eb3061e2f0b0"}, + {file = "pydantic_core-2.27.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:83097677b8e3bd7eaa6775720ec8e0405f1575015a463285a92bfdfe254529ef"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:172fce187655fece0c90d90a678424b013f8fbb0ca8b036ac266749c09438cb7"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:519f29f5213271eeeeb3093f662ba2fd512b91c5f188f3bb7b27bc5973816934"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:05e3a55d124407fffba0dd6b0c0cd056d10e983ceb4e5dbd10dda135c31071d6"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9c3ed807c7b91de05e63930188f19e921d1fe90de6b4f5cd43ee7fcc3525cb8c"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6fb4aadc0b9a0c063206846d603b92030eb6f03069151a625667f982887153e2"}, + {file = "pydantic_core-2.27.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:28ccb213807e037460326424ceb8b5245acb88f32f3d2777427476e1b32c48c4"}, + {file = "pydantic_core-2.27.2-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:de3cd1899e2c279b140adde9357c4495ed9d47131b4a4eaff9052f23398076b3"}, + {file = "pydantic_core-2.27.2-cp312-cp312-musllinux_1_1_armv7l.whl", hash = "sha256:220f892729375e2d736b97d0e51466252ad84c51857d4d15f5e9692f9ef12be4"}, + {file = "pydantic_core-2.27.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:a0fcd29cd6b4e74fe8ddd2c90330fd8edf2e30cb52acda47f06dd615ae72da57"}, + {file = "pydantic_core-2.27.2-cp312-cp312-win32.whl", hash = "sha256:1e2cb691ed9834cd6a8be61228471d0a503731abfb42f82458ff27be7b2186fc"}, + {file = "pydantic_core-2.27.2-cp312-cp312-win_amd64.whl", hash = "sha256:cc3f1a99a4f4f9dd1de4fe0312c114e740b5ddead65bb4102884b384c15d8bc9"}, + {file = "pydantic_core-2.27.2-cp312-cp312-win_arm64.whl", hash = "sha256:3911ac9284cd8a1792d3cb26a2da18f3ca26c6908cc434a18f730dc0db7bfa3b"}, + {file = "pydantic_core-2.27.2-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:7d14bd329640e63852364c306f4d23eb744e0f8193148d4044dd3dacdaacbd8b"}, + {file = "pydantic_core-2.27.2-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:82f91663004eb8ed30ff478d77c4d1179b3563df6cdb15c0817cd1cdaf34d154"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:71b24c7d61131bb83df10cc7e687433609963a944ccf45190cfc21e0887b08c9"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:fa8e459d4954f608fa26116118bb67f56b93b209c39b008277ace29937453dc9"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ce8918cbebc8da707ba805b7fd0b382816858728ae7fe19a942080c24e5b7cd1"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:eda3f5c2a021bbc5d976107bb302e0131351c2ba54343f8a496dc8783d3d3a6a"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bd8086fa684c4775c27f03f062cbb9eaa6e17f064307e86b21b9e0abc9c0f02e"}, + {file = "pydantic_core-2.27.2-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:8d9b3388db186ba0c099a6d20f0604a44eabdeef1777ddd94786cdae158729e4"}, + {file = "pydantic_core-2.27.2-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:7a66efda2387de898c8f38c0cf7f14fca0b51a8ef0b24bfea5849f1b3c95af27"}, + {file = "pydantic_core-2.27.2-cp313-cp313-musllinux_1_1_armv7l.whl", hash = "sha256:18a101c168e4e092ab40dbc2503bdc0f62010e95d292b27827871dc85450d7ee"}, + {file = "pydantic_core-2.27.2-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:ba5dd002f88b78a4215ed2f8ddbdf85e8513382820ba15ad5ad8955ce0ca19a1"}, + {file = "pydantic_core-2.27.2-cp313-cp313-win32.whl", hash = "sha256:1ebaf1d0481914d004a573394f4be3a7616334be70261007e47c2a6fe7e50130"}, + {file = "pydantic_core-2.27.2-cp313-cp313-win_amd64.whl", hash = "sha256:953101387ecf2f5652883208769a79e48db18c6df442568a0b5ccd8c2723abee"}, + {file = "pydantic_core-2.27.2-cp313-cp313-win_arm64.whl", hash = "sha256:ac4dbfd1691affb8f48c2c13241a2e3b60ff23247cbcf981759c768b6633cf8b"}, + {file = "pydantic_core-2.27.2-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:d3e8d504bdd3f10835468f29008d72fc8359d95c9c415ce6e767203db6127506"}, + {file = "pydantic_core-2.27.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:521eb9b7f036c9b6187f0b47318ab0d7ca14bd87f776240b90b21c1f4f149320"}, + {file = "pydantic_core-2.27.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:85210c4d99a0114f5a9481b44560d7d1e35e32cc5634c656bc48e590b669b145"}, + {file = "pydantic_core-2.27.2-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:d716e2e30c6f140d7560ef1538953a5cd1a87264c737643d481f2779fc247fe1"}, + {file = "pydantic_core-2.27.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f66d89ba397d92f840f8654756196d93804278457b5fbede59598a1f9f90b228"}, + {file = "pydantic_core-2.27.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:669e193c1c576a58f132e3158f9dfa9662969edb1a250c54d8fa52590045f046"}, + {file = "pydantic_core-2.27.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9fdbe7629b996647b99c01b37f11170a57ae675375b14b8c13b8518b8320ced5"}, + {file = "pydantic_core-2.27.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:d262606bf386a5ba0b0af3b97f37c83d7011439e3dc1a9298f21efb292e42f1a"}, + {file = "pydantic_core-2.27.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:cabb9bcb7e0d97f74df8646f34fc76fbf793b7f6dc2438517d7a9e50eee4f14d"}, + {file = "pydantic_core-2.27.2-cp38-cp38-musllinux_1_1_armv7l.whl", hash = "sha256:d2d63f1215638d28221f664596b1ccb3944f6e25dd18cd3b86b0a4c408d5ebb9"}, + {file = "pydantic_core-2.27.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:bca101c00bff0adb45a833f8451b9105d9df18accb8743b08107d7ada14bd7da"}, + {file = "pydantic_core-2.27.2-cp38-cp38-win32.whl", hash = "sha256:f6f8e111843bbb0dee4cb6594cdc73e79b3329b526037ec242a3e49012495b3b"}, + {file = "pydantic_core-2.27.2-cp38-cp38-win_amd64.whl", hash = "sha256:fd1aea04935a508f62e0d0ef1f5ae968774a32afc306fb8545e06f5ff5cdf3ad"}, + {file = "pydantic_core-2.27.2-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:c10eb4f1659290b523af58fa7cffb452a61ad6ae5613404519aee4bfbf1df993"}, + {file = "pydantic_core-2.27.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ef592d4bad47296fb11f96cd7dc898b92e795032b4894dfb4076cfccd43a9308"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c61709a844acc6bf0b7dce7daae75195a10aac96a596ea1b776996414791ede4"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:42c5f762659e47fdb7b16956c71598292f60a03aa92f8b6351504359dbdba6cf"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:4c9775e339e42e79ec99c441d9730fccf07414af63eac2f0e48e08fd38a64d76"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:57762139821c31847cfb2df63c12f725788bd9f04bc2fb392790959b8f70f118"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0d1e85068e818c73e048fe28cfc769040bb1f475524f4745a5dc621f75ac7630"}, + {file = "pydantic_core-2.27.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:097830ed52fd9e427942ff3b9bc17fab52913b2f50f2880dc4a5611446606a54"}, + {file = "pydantic_core-2.27.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:044a50963a614ecfae59bb1eaf7ea7efc4bc62f49ed594e18fa1e5d953c40e9f"}, + {file = "pydantic_core-2.27.2-cp39-cp39-musllinux_1_1_armv7l.whl", hash = "sha256:4e0b4220ba5b40d727c7f879eac379b822eee5d8fff418e9d3381ee45b3b0362"}, + {file = "pydantic_core-2.27.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5e4f4bb20d75e9325cc9696c6802657b58bc1dbbe3022f32cc2b2b632c3fbb96"}, + {file = "pydantic_core-2.27.2-cp39-cp39-win32.whl", hash = "sha256:cca63613e90d001b9f2f9a9ceb276c308bfa2a43fafb75c8031c4f66039e8c6e"}, + {file = "pydantic_core-2.27.2-cp39-cp39-win_amd64.whl", hash = "sha256:77d1bca19b0f7021b3a982e6f903dcd5b2b06076def36a652e3907f596e29f67"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:2bf14caea37e91198329b828eae1618c068dfb8ef17bb33287a7ad4b61ac314e"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:b0cb791f5b45307caae8810c2023a184c74605ec3bcbb67d13846c28ff731ff8"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:688d3fd9fcb71f41c4c015c023d12a79d1c4c0732ec9eb35d96e3388a120dcf3"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3d591580c34f4d731592f0e9fe40f9cc1b430d297eecc70b962e93c5c668f15f"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:82f986faf4e644ffc189a7f1aafc86e46ef70372bb153e7001e8afccc6e54133"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:bec317a27290e2537f922639cafd54990551725fc844249e64c523301d0822fc"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:0296abcb83a797db256b773f45773da397da75a08f5fcaef41f2044adec05f50"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:0d75070718e369e452075a6017fbf187f788e17ed67a3abd47fa934d001863d9"}, + {file = "pydantic_core-2.27.2-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:7e17b560be3c98a8e3aa66ce828bdebb9e9ac6ad5466fba92eb74c4c95cb1151"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:c33939a82924da9ed65dab5a65d427205a73181d8098e79b6b426bdf8ad4e656"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:00bad2484fa6bda1e216e7345a798bd37c68fb2d97558edd584942aa41b7d278"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c817e2b40aba42bac6f457498dacabc568c3b7a986fc9ba7c8d9d260b71485fb"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:251136cdad0cb722e93732cb45ca5299fb56e1344a833640bf93b2803f8d1bfd"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:d2088237af596f0a524d3afc39ab3b036e8adb054ee57cbb1dcf8e09da5b29cc"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:d4041c0b966a84b4ae7a09832eb691a35aec90910cd2dbe7a208de59be77965b"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:8083d4e875ebe0b864ffef72a4304827015cff328a1be6e22cc850753bfb122b"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:f141ee28a0ad2123b6611b6ceff018039df17f32ada8b534e6aa039545a3efb2"}, + {file = "pydantic_core-2.27.2-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:7d0c8399fcc1848491f00e0314bd59fb34a9c008761bcb422a057670c3f65e35"}, + {file = "pydantic_core-2.27.2.tar.gz", hash = "sha256:eb026e5a4c1fee05726072337ff51d1efb6f59090b7da90d30ea58625b1ffb39"}, ] [package.dependencies] @@ -545,4 +558,4 @@ typing-extensions = ">=3.7.4" [metadata] lock-version = "2.0" python-versions = "^3.8" -content-hash = "9e57d395164aeb8637702f9d37b29cff9bdc5ebcbd44305b91808c122428bacb" +content-hash = "231d09484040ca8e2e4ea801ceedb0b672113dd483caa7cb13d217c3e92d7655" diff --git a/pyproject.toml b/pyproject.toml index d902e2a..4897ba2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "plex-api-client" -version = "0.19.1" +version = "0.20.0" description = "Python Client SDK Generated by Speakeasy" authors = ["Speakeasy",] readme = "README-PYPI.md" @@ -19,14 +19,14 @@ in-project = true [tool.poetry.dependencies] python = "^3.8" eval-type-backport = "^0.2.0" -httpx = "^0.27.0" +httpx = "^0.28.1" jsonpath-python = "^1.0.6" -pydantic = "~2.9.2" -python-dateutil = "2.8.2" +pydantic = "~2.10.3" +python-dateutil = "^2.8.2" typing-inspect = "^0.9.0" [tool.poetry.group.dev.dependencies] -mypy = "==1.10.1" +mypy = "==1.13.0" pylint = "==3.2.3" types-python-dateutil = "^2.9.0.20240316" diff --git a/src/plex_api_client/_version.py b/src/plex_api_client/_version.py index c8e18eb..1ffd48c 100644 --- a/src/plex_api_client/_version.py +++ b/src/plex_api_client/_version.py @@ -3,7 +3,7 @@ import importlib.metadata __title__: str = "plex-api-client" -__version__: str = "0.19.1" +__version__: str = "0.20.0" try: if __package__ is not None: diff --git a/src/plex_api_client/activities.py b/src/plex_api_client/activities.py index 06d40e9..4dc6d68 100644 --- a/src/plex_api_client/activities.py +++ b/src/plex_api_client/activities.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import OptionalNullable, UNSET -from typing import Any, Optional +from typing import Any, Mapping, Optional class Activities(BaseSDK): @@ -25,6 +25,7 @@ class Activities(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerActivitiesResponse: r"""Get Server Activities @@ -33,6 +34,7 @@ class Activities(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -52,6 +54,7 @@ class Activities(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -118,6 +121,7 @@ class Activities(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerActivitiesResponse: r"""Get Server Activities @@ -126,6 +130,7 @@ class Activities(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -145,6 +150,7 @@ class Activities(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -212,6 +218,7 @@ class Activities(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.CancelServerActivitiesResponse: r"""Cancel Server Activities @@ -221,6 +228,7 @@ class Activities(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -245,6 +253,7 @@ class Activities(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -309,6 +318,7 @@ class Activities(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.CancelServerActivitiesResponse: r"""Cancel Server Activities @@ -318,6 +328,7 @@ class Activities(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -342,6 +353,7 @@ class Activities(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/authentication.py b/src/plex_api_client/authentication.py index d25ad72..96c5bfc 100644 --- a/src/plex_api_client/authentication.py +++ b/src/plex_api_client/authentication.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Authentication(BaseSDK): @@ -19,6 +19,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTransientTokenResponse: r"""Get a Transient Token @@ -30,6 +31,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -55,6 +57,7 @@ class Authentication(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -120,6 +123,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTransientTokenResponse: r"""Get a Transient Token @@ -131,6 +135,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -156,6 +161,7 @@ class Authentication(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -220,6 +226,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSourceConnectionInformationResponse: r"""Get Source Connection Information @@ -231,6 +238,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -255,6 +263,7 @@ class Authentication(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -319,6 +328,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSourceConnectionInformationResponse: r"""Get Source Connection Information @@ -330,6 +340,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -354,6 +365,7 @@ class Authentication(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -417,6 +429,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTokenDetailsResponse: r"""Get Token Details @@ -425,6 +438,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -446,6 +460,7 @@ class Authentication(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -512,6 +527,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTokenDetailsResponse: r"""Get Token Details @@ -520,6 +536,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -541,6 +558,7 @@ class Authentication(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -611,6 +629,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.PostUsersSignInDataResponse: r"""Get User Sign In Data @@ -620,6 +639,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -646,13 +666,7 @@ class Authentication(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.PostUsersSignInDataGlobals( - client_id=self.sdk_configuration.globals.client_id, - client_name=self.sdk_configuration.globals.client_name, - device_nickname=self.sdk_configuration.globals.device_nickname, - client_version=self.sdk_configuration.globals.client_version, - platform=self.sdk_configuration.globals.platform, - ), + http_headers=http_headers, get_serialized_body=lambda: utils.serialize_request_body( request.request_body, False, @@ -730,6 +744,7 @@ class Authentication(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.PostUsersSignInDataResponse: r"""Get User Sign In Data @@ -739,6 +754,7 @@ class Authentication(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -765,13 +781,7 @@ class Authentication(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.PostUsersSignInDataGlobals( - client_id=self.sdk_configuration.globals.client_id, - client_name=self.sdk_configuration.globals.client_name, - device_nickname=self.sdk_configuration.globals.device_nickname, - client_version=self.sdk_configuration.globals.client_version, - platform=self.sdk_configuration.globals.platform, - ), + http_headers=http_headers, get_serialized_body=lambda: utils.serialize_request_body( request.request_body, False, diff --git a/src/plex_api_client/basesdk.py b/src/plex_api_client/basesdk.py index b6c42a1..97f1bc7 100644 --- a/src/plex_api_client/basesdk.py +++ b/src/plex_api_client/basesdk.py @@ -10,7 +10,8 @@ from plex_api_client._hooks import ( ) from plex_api_client.models import errors from plex_api_client.utils import RetryConfig, SerializedRequestBody, get_body_content -from typing import Callable, List, Optional, Tuple +from typing import Callable, List, Mapping, Optional, Tuple +from urllib.parse import parse_qs, urlparse class BaseSDK: @@ -49,6 +50,7 @@ class BaseSDK: Callable[[], Optional[SerializedRequestBody]] ] = None, url_override: Optional[str] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> httpx.Request: client = self.sdk_configuration.async_client return self.build_request_with_client( @@ -68,6 +70,7 @@ class BaseSDK: timeout_ms, get_serialized_body, url_override, + http_headers, ) def build_request( @@ -89,6 +92,7 @@ class BaseSDK: Callable[[], Optional[SerializedRequestBody]] ] = None, url_override: Optional[str] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> httpx.Request: client = self.sdk_configuration.client return self.build_request_with_client( @@ -108,6 +112,7 @@ class BaseSDK: timeout_ms, get_serialized_body, url_override, + http_headers, ) def build_request_with_client( @@ -130,6 +135,7 @@ class BaseSDK: Callable[[], Optional[SerializedRequestBody]] ] = None, url_override: Optional[str] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> httpx.Request: query_params = {} @@ -146,6 +152,12 @@ class BaseSDK: request if request_has_query_params else None, _globals if request_has_query_params else None, ) + else: + # Pick up the query parameter from the override so they can be + # preserved when building the request later on (necessary as of + # httpx 0.28). + parsed_override = urlparse(str(url_override)) + query_params = parse_qs(parsed_override.query, keep_blank_values=True) headers = utils.get_headers(request, _globals) headers["Accept"] = accept_header_value @@ -160,7 +172,7 @@ class BaseSDK: headers = {**headers, **security_headers} query_params = {**query_params, **security_query_params} - serialized_request_body = SerializedRequestBody("application/octet-stream") + serialized_request_body = SerializedRequestBody() if get_serialized_body is not None: rb = get_serialized_body() if request_body_required and rb is None: @@ -179,6 +191,10 @@ class BaseSDK: ): headers["content-type"] = serialized_request_body.media_type + if http_headers is not None: + for header, value in http_headers.items(): + headers[header] = value + timeout = timeout_ms / 1000 if timeout_ms is not None else None return client.build_request( diff --git a/src/plex_api_client/butler.py b/src/plex_api_client/butler.py index 3ba4ffc..79c1cb3 100644 --- a/src/plex_api_client/butler.py +++ b/src/plex_api_client/butler.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import OptionalNullable, UNSET -from typing import Any, Optional +from typing import Any, Mapping, Optional class Butler(BaseSDK): @@ -17,6 +17,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetButlerTasksResponse: r"""Get Butler tasks @@ -25,6 +26,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -44,6 +46,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -110,6 +113,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetButlerTasksResponse: r"""Get Butler tasks @@ -118,6 +122,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -137,6 +142,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -203,6 +209,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StartAllTasksResponse: r"""Start all Butler tasks @@ -216,6 +223,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -235,6 +243,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -298,6 +307,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StartAllTasksResponse: r"""Start all Butler tasks @@ -311,6 +321,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -330,6 +341,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -393,6 +405,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StopAllTasksResponse: r"""Stop all Butler tasks @@ -402,6 +415,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -421,6 +435,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -484,6 +499,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StopAllTasksResponse: r"""Stop all Butler tasks @@ -493,6 +509,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -512,6 +529,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -576,6 +594,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StartTaskResponse: r"""Start a single Butler task @@ -590,6 +609,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -614,6 +634,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -674,6 +695,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StartTaskResponse: r"""Start a single Butler task @@ -688,6 +710,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -712,6 +735,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -772,6 +796,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StopTaskResponse: r"""Stop a single Butler task @@ -782,6 +807,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -806,6 +832,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -866,6 +893,7 @@ class Butler(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StopTaskResponse: r"""Stop a single Butler task @@ -876,6 +904,7 @@ class Butler(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -900,6 +929,7 @@ class Butler(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/httpclient.py b/src/plex_api_client/httpclient.py index 36b642a..167cea4 100644 --- a/src/plex_api_client/httpclient.py +++ b/src/plex_api_client/httpclient.py @@ -41,6 +41,9 @@ class HttpClient(Protocol): ) -> httpx.Request: pass + def close(self) -> None: + pass + @runtime_checkable class AsyncHttpClient(Protocol): @@ -76,3 +79,6 @@ class AsyncHttpClient(Protocol): extensions: Optional[httpx._types.RequestExtensions] = None, ) -> httpx.Request: pass + + async def aclose(self) -> None: + pass diff --git a/src/plex_api_client/hubs.py b/src/plex_api_client/hubs.py index c1d8675..e37d2a5 100644 --- a/src/plex_api_client/hubs.py +++ b/src/plex_api_client/hubs.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Hubs(BaseSDK): @@ -19,6 +19,7 @@ class Hubs(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetGlobalHubsResponse: r"""Get Global Hubs @@ -29,6 +30,7 @@ class Hubs(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -54,6 +56,7 @@ class Hubs(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -122,6 +125,7 @@ class Hubs(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetGlobalHubsResponse: r"""Get Global Hubs @@ -132,6 +136,7 @@ class Hubs(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -157,6 +162,7 @@ class Hubs(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -227,6 +233,7 @@ class Hubs(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetRecentlyAddedResponse: r"""Get Recently Added @@ -237,6 +244,7 @@ class Hubs(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -261,6 +269,7 @@ class Hubs(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -318,6 +327,7 @@ class Hubs(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetRecentlyAddedResponse: r"""Get Recently Added @@ -328,6 +338,7 @@ class Hubs(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -352,6 +363,7 @@ class Hubs(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -408,6 +420,7 @@ class Hubs(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetLibraryHubsResponse: r"""Get library specific hubs @@ -420,6 +433,7 @@ class Hubs(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -446,6 +460,7 @@ class Hubs(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -515,6 +530,7 @@ class Hubs(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetLibraryHubsResponse: r"""Get library specific hubs @@ -527,6 +543,7 @@ class Hubs(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -553,6 +570,7 @@ class Hubs(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/library.py b/src/plex_api_client/library.py index 677271b..116d019 100644 --- a/src/plex_api_client/library.py +++ b/src/plex_api_client/library.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Library(BaseSDK): @@ -19,6 +19,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetFileHashResponse: r"""Get Hash Value @@ -29,6 +30,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -54,6 +56,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -117,6 +120,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetFileHashResponse: r"""Get Hash Value @@ -127,6 +131,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -152,6 +157,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -217,6 +223,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetRecentlyAddedLibraryResponse: r"""Get Recently Added @@ -227,6 +234,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -253,6 +261,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -324,6 +333,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetRecentlyAddedLibraryResponse: r"""Get Recently Added @@ -334,6 +344,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -360,6 +371,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -427,6 +439,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetAllLibrariesResponse: r"""Get All Libraries @@ -441,6 +454,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -460,6 +474,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -526,6 +541,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetAllLibrariesResponse: r"""Get All Libraries @@ -540,6 +556,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -559,6 +576,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -629,6 +647,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetLibraryDetailsResponse: r"""Get Library Details @@ -678,6 +697,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -703,6 +723,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -773,6 +794,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetLibraryDetailsResponse: r"""Get Library Details @@ -822,6 +844,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -847,6 +870,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -914,6 +938,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.DeleteLibraryResponse: r"""Delete Library Section @@ -923,6 +948,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -947,6 +973,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1011,6 +1038,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.DeleteLibraryResponse: r"""Delete Library Section @@ -1020,6 +1048,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1044,6 +1073,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1111,6 +1141,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetLibraryItemsResponse: r"""Get Library Items @@ -1134,12 +1165,14 @@ class Library(BaseSDK): - `resolution`: Items categorized by resolution. - `firstCharacter`: Items categorized by the first letter. - `folder`: Items categorized by folder. + - `albums`: Items categorized by album. :param request: The request object to send. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1164,6 +1197,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1234,6 +1268,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetLibraryItemsResponse: r"""Get Library Items @@ -1257,12 +1292,14 @@ class Library(BaseSDK): - `resolution`: Items categorized by resolution. - `firstCharacter`: Items categorized by the first letter. - `folder`: Items categorized by folder. + - `albums`: Items categorized by album. :param request: The request object to send. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1287,6 +1324,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1355,6 +1393,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetRefreshLibraryMetadataResponse: r"""Refresh Metadata Of The Library @@ -1366,6 +1405,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1391,6 +1431,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1456,6 +1497,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetRefreshLibraryMetadataResponse: r"""Refresh Metadata Of The Library @@ -1467,6 +1509,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1492,6 +1535,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1557,6 +1601,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSearchLibraryResponse: r"""Search Library @@ -1585,6 +1630,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1610,6 +1656,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1678,6 +1725,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSearchLibraryResponse: r"""Search Library @@ -1706,6 +1754,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1731,6 +1780,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1801,6 +1851,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSearchAllLibrariesResponse: r"""Search All Libraries @@ -1811,6 +1862,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1835,9 +1887,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetSearchAllLibrariesGlobals( - client_id=self.sdk_configuration.globals.client_id, - ), + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1909,6 +1959,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSearchAllLibrariesResponse: r"""Search All Libraries @@ -1919,6 +1970,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1943,9 +1995,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetSearchAllLibrariesGlobals( - client_id=self.sdk_configuration.globals.client_id, - ), + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2014,6 +2064,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMetaDataByRatingKeyResponse: r"""Get Metadata by RatingKey @@ -2024,6 +2075,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2048,6 +2100,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2116,6 +2169,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMetaDataByRatingKeyResponse: r"""Get Metadata by RatingKey @@ -2126,6 +2180,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2150,6 +2205,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2219,6 +2275,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMetadataChildrenResponse: r"""Get Items Children @@ -2230,6 +2287,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2255,6 +2313,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2323,6 +2382,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMetadataChildrenResponse: r"""Get Items Children @@ -2334,6 +2394,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2359,6 +2420,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2427,6 +2489,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTopWatchedContentResponse: r"""Get Top Watched Content @@ -2438,6 +2501,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2463,6 +2527,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2531,6 +2596,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTopWatchedContentResponse: r"""Get Top Watched Content @@ -2542,6 +2608,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2567,6 +2634,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2633,6 +2701,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetOnDeckResponse: r"""Get On Deck @@ -2642,6 +2711,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2661,6 +2731,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -2723,6 +2794,7 @@ class Library(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetOnDeckResponse: r"""Get On Deck @@ -2732,6 +2804,7 @@ class Library(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -2751,6 +2824,7 @@ class Library(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/log.py b/src/plex_api_client/log.py index bcb2051..b3775af 100644 --- a/src/plex_api_client/log.py +++ b/src/plex_api_client/log.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import OptionalNullable, UNSET -from typing import Any, Optional +from typing import Any, Mapping, Optional class Log(BaseSDK): @@ -20,6 +20,7 @@ class Log(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.LogLineResponse: r"""Logging a single line message. @@ -32,6 +33,7 @@ class Log(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -58,6 +60,7 @@ class Log(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -120,6 +123,7 @@ class Log(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.LogLineResponse: r"""Logging a single line message. @@ -132,6 +136,7 @@ class Log(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -158,6 +163,7 @@ class Log(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -218,6 +224,7 @@ class Log(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.LogMultiLineResponse: r"""Logging a multi-line message @@ -248,6 +255,7 @@ class Log(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -268,6 +276,7 @@ class Log(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, get_serialized_body=lambda: utils.serialize_request_body( request, False, False, "string", str @@ -335,6 +344,7 @@ class Log(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.LogMultiLineResponse: r"""Logging a multi-line message @@ -365,6 +375,7 @@ class Log(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -385,6 +396,7 @@ class Log(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, get_serialized_body=lambda: utils.serialize_request_body( request, False, False, "string", str @@ -451,6 +463,7 @@ class Log(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.EnablePaperTrailResponse: r"""Enabling Papertrail @@ -460,6 +473,7 @@ class Log(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -479,6 +493,7 @@ class Log(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -542,6 +557,7 @@ class Log(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.EnablePaperTrailResponse: r"""Enabling Papertrail @@ -551,6 +567,7 @@ class Log(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -570,6 +587,7 @@ class Log(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/media.py b/src/plex_api_client/media.py index a3f6e6d..5a97e25 100644 --- a/src/plex_api_client/media.py +++ b/src/plex_api_client/media.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Media(BaseSDK): @@ -18,6 +18,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.MarkPlayedResponse: r"""Mark Media Played @@ -27,6 +28,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -51,6 +53,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -113,6 +116,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.MarkPlayedResponse: r"""Mark Media Played @@ -122,6 +126,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -146,6 +151,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -208,6 +214,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.MarkUnplayedResponse: r"""Mark Media Unplayed @@ -217,6 +224,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -241,6 +249,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -305,6 +314,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.MarkUnplayedResponse: r"""Mark Media Unplayed @@ -314,6 +324,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -338,6 +349,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -404,6 +416,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.UpdatePlayProgressResponse: r"""Update Media Play Progress @@ -416,6 +429,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -442,6 +456,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -508,6 +523,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.UpdatePlayProgressResponse: r"""Update Media Play Progress @@ -520,6 +536,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -546,6 +563,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -612,6 +630,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetBannerImageResponse: r"""Get Banner Image @@ -621,6 +640,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -645,6 +665,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="image/jpeg", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -716,6 +737,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetBannerImageResponse: r"""Get Banner Image @@ -725,6 +747,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -749,6 +772,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="image/jpeg", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -820,6 +844,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetThumbImageResponse: r"""Get Thumb Image @@ -829,6 +854,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -853,6 +879,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="image/jpeg", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -924,6 +951,7 @@ class Media(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetThumbImageResponse: r"""Get Thumb Image @@ -933,6 +961,7 @@ class Media(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -957,6 +986,7 @@ class Media(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="image/jpeg", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/models/internal/__init__.py b/src/plex_api_client/models/internal/__init__.py deleted file mode 100644 index 9e3dfb7..0000000 --- a/src/plex_api_client/models/internal/__init__.py +++ /dev/null @@ -1,5 +0,0 @@ -"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" - -from .globals import Globals, GlobalsTypedDict - -__all__ = ["Globals", "GlobalsTypedDict"] diff --git a/src/plex_api_client/models/internal/globals.py b/src/plex_api_client/models/internal/globals.py deleted file mode 100644 index 4f23e1f..0000000 --- a/src/plex_api_client/models/internal/globals.py +++ /dev/null @@ -1,58 +0,0 @@ -"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" - -from __future__ import annotations -from plex_api_client.types import BaseModel -from plex_api_client.utils import FieldMetadata, HeaderMetadata -import pydantic -from typing import Optional -from typing_extensions import Annotated, NotRequired, TypedDict - - -class GlobalsTypedDict(TypedDict): - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - client_name: NotRequired[str] - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - client_version: NotRequired[str] - r"""The version of the client application.""" - platform: NotRequired[str] - r"""The platform of the client application.""" - device_nickname: NotRequired[str] - r"""A relatively friendly name for the client device""" - - -class Globals(BaseModel): - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - client_name: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Product"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - - client_version: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Version"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The version of the client application.""" - - platform: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Platform"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The platform of the client application.""" - - device_nickname: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Device"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""A relatively friendly name for the client device""" diff --git a/src/plex_api_client/models/operations/__init__.py b/src/plex_api_client/models/operations/__init__.py index 0514a28..3b8d605 100644 --- a/src/plex_api_client/models/operations/__init__.py +++ b/src/plex_api_client/models/operations/__init__.py @@ -369,8 +369,6 @@ from .get_search_all_libraries import ( GetSearchAllLibrariesFlattenSeasons, GetSearchAllLibrariesGenre, GetSearchAllLibrariesGenreTypedDict, - GetSearchAllLibrariesGlobals, - GetSearchAllLibrariesGlobalsTypedDict, GetSearchAllLibrariesHasThumbnail, GetSearchAllLibrariesImage, GetSearchAllLibrariesImageTypedDict, @@ -437,8 +435,6 @@ from .get_server_resources import ( Connections, ConnectionsTypedDict, GET_SERVER_RESOURCES_SERVERS, - GetServerResourcesGlobals, - GetServerResourcesGlobalsTypedDict, GetServerResourcesRequest, GetServerResourcesRequestTypedDict, GetServerResourcesResponse, @@ -635,8 +631,6 @@ from .getpin import ( GeoDataTypedDict, GetPinAuthPinContainer, GetPinAuthPinContainerTypedDict, - GetPinGlobals, - GetPinGlobalsTypedDict, GetPinRequest, GetPinRequestTypedDict, GetPinResponse, @@ -856,8 +850,6 @@ from .gettokenbypinid import ( GetTokenByPinIDAuthPinContainerTypedDict, GetTokenByPinIDGeoData, GetTokenByPinIDGeoDataTypedDict, - GetTokenByPinIDGlobals, - GetTokenByPinIDGlobalsTypedDict, GetTokenByPinIDRequest, GetTokenByPinIDRequestTypedDict, GetTokenByPinIDResponse, @@ -997,8 +989,6 @@ from .post_users_sign_in_data import ( PostUsersSignInDataAutoSelectSubtitle, PostUsersSignInDataDefaultSubtitleAccessibility, PostUsersSignInDataDefaultSubtitleForced, - PostUsersSignInDataGlobals, - PostUsersSignInDataGlobalsTypedDict, PostUsersSignInDataMailingListStatus, PostUsersSignInDataMediaReviewsVisibility, PostUsersSignInDataRequest, @@ -1432,8 +1422,6 @@ __all__ = [ "GetOnDeckStreamTypedDict", "GetPinAuthPinContainer", "GetPinAuthPinContainerTypedDict", - "GetPinGlobals", - "GetPinGlobalsTypedDict", "GetPinRequest", "GetPinRequestTypedDict", "GetPinResponse", @@ -1564,8 +1552,6 @@ __all__ = [ "GetSearchAllLibrariesFlattenSeasons", "GetSearchAllLibrariesGenre", "GetSearchAllLibrariesGenreTypedDict", - "GetSearchAllLibrariesGlobals", - "GetSearchAllLibrariesGlobalsTypedDict", "GetSearchAllLibrariesHasThumbnail", "GetSearchAllLibrariesImage", "GetSearchAllLibrariesImageTypedDict", @@ -1666,8 +1652,6 @@ __all__ = [ "GetServerPreferencesResponseBody", "GetServerPreferencesResponseBodyTypedDict", "GetServerPreferencesResponseTypedDict", - "GetServerResourcesGlobals", - "GetServerResourcesGlobalsTypedDict", "GetServerResourcesRequest", "GetServerResourcesRequestTypedDict", "GetServerResourcesResponse", @@ -1724,8 +1708,6 @@ __all__ = [ "GetTokenByPinIDAuthPinContainerTypedDict", "GetTokenByPinIDGeoData", "GetTokenByPinIDGeoDataTypedDict", - "GetTokenByPinIDGlobals", - "GetTokenByPinIDGlobalsTypedDict", "GetTokenByPinIDRequest", "GetTokenByPinIDRequestTypedDict", "GetTokenByPinIDResponse", @@ -1869,8 +1851,6 @@ __all__ = [ "PostUsersSignInDataAutoSelectSubtitle", "PostUsersSignInDataDefaultSubtitleAccessibility", "PostUsersSignInDataDefaultSubtitleForced", - "PostUsersSignInDataGlobals", - "PostUsersSignInDataGlobalsTypedDict", "PostUsersSignInDataMailingListStatus", "PostUsersSignInDataMediaReviewsVisibility", "PostUsersSignInDataRequest", diff --git a/src/plex_api_client/models/operations/get_library_items.py b/src/plex_api_client/models/operations/get_library_items.py index d384e41..83af7cb 100644 --- a/src/plex_api_client/models/operations/get_library_items.py +++ b/src/plex_api_client/models/operations/get_library_items.py @@ -33,6 +33,7 @@ class Tag(str, Enum): RESOLUTION = "resolution" FIRST_CHARACTER = "firstCharacter" FOLDER = "folder" + ALBUMS = "albums" class IncludeGuids(int, Enum): @@ -57,6 +58,8 @@ class GetLibraryItemsQueryParamType(int, Enum): SEASON = 3 EPISODE = 4 AUDIO = 8 + ALBUM = 9 + TRACK = 10 class GetLibraryItemsQueryParamIncludeMeta(int, Enum): @@ -347,17 +350,17 @@ class GetLibraryItemsShowOrdering(str, Enum): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ NONE = "None" TMDB_AIRING = "tmdbAiring" - AIRED = "aired" - DVD = "dvd" - ABSOLUTE = "absolute" + TVDB_AIRING = "tvdbAiring" + TVDB_DVD = "tvdbDvd" + TVDB_ABSOLUTE = "tvdbAbsolute" class GetLibraryItemsOptimizedForStreaming(int, Enum): @@ -897,9 +900,9 @@ class GetLibraryItemsMetadataTypedDict(TypedDict): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ thumb: NotRequired[str] @@ -1036,9 +1039,9 @@ class GetLibraryItemsMetadata(BaseModel): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ diff --git a/src/plex_api_client/models/operations/get_meta_data_by_rating_key.py b/src/plex_api_client/models/operations/get_meta_data_by_rating_key.py index bc3af30..af4af57 100644 --- a/src/plex_api_client/models/operations/get_meta_data_by_rating_key.py +++ b/src/plex_api_client/models/operations/get_meta_data_by_rating_key.py @@ -392,6 +392,16 @@ class GetMetaDataByRatingKeyMetadataTypedDict(TypedDict): library_section_title: NotRequired[str] library_section_id: NotRequired[int] library_section_key: NotRequired[str] + grandparent_title: NotRequired[str] + r"""The name of the album artist for the track when audio, and the name of the TV show for the episode when video.""" + parent_title: NotRequired[str] + r"""The name of the album for the track when audio, and the name of the season for the episode when TV show.""" + original_title: NotRequired[str] + r"""The orginal untranslated name of the media item when non-english.""" + index: NotRequired[int] + r"""The index starting from 0 of this media item in the MetaData array.""" + parent_index: NotRequired[int] + r"""The parent index starting from 0 of this media item in the parent MetaData array.""" content_rating: NotRequired[str] summary: NotRequired[str] rating: NotRequired[float] @@ -443,6 +453,25 @@ class GetMetaDataByRatingKeyMetadata(BaseModel): Optional[str], pydantic.Field(alias="librarySectionKey") ] = None + grandparent_title: Annotated[ + Optional[str], pydantic.Field(alias="grandparentTitle") + ] = None + r"""The name of the album artist for the track when audio, and the name of the TV show for the episode when video.""" + + parent_title: Annotated[Optional[str], pydantic.Field(alias="parentTitle")] = None + r"""The name of the album for the track when audio, and the name of the season for the episode when TV show.""" + + original_title: Annotated[Optional[str], pydantic.Field(alias="originalTitle")] = ( + None + ) + r"""The orginal untranslated name of the media item when non-english.""" + + index: Optional[int] = None + r"""The index starting from 0 of this media item in the MetaData array.""" + + parent_index: Annotated[Optional[int], pydantic.Field(alias="parentIndex")] = None + r"""The parent index starting from 0 of this media item in the parent MetaData array.""" + content_rating: Annotated[Optional[str], pydantic.Field(alias="contentRating")] = ( None ) diff --git a/src/plex_api_client/models/operations/get_recently_added.py b/src/plex_api_client/models/operations/get_recently_added.py index 25c153f..ca79bd7 100644 --- a/src/plex_api_client/models/operations/get_recently_added.py +++ b/src/plex_api_client/models/operations/get_recently_added.py @@ -26,6 +26,8 @@ class Type(int, Enum): SEASON = 3 EPISODE = 4 AUDIO = 8 + ALBUM = 9 + TRACK = 10 class IncludeMeta(int, Enum): @@ -328,17 +330,17 @@ class ShowOrdering(str, Enum): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ NONE = "None" TMDB_AIRING = "tmdbAiring" - AIRED = "aired" - DVD = "dvd" - ABSOLUTE = "absolute" + TVDB_AIRING = "tvdbAiring" + TVDB_DVD = "tvdbDvd" + TVDB_ABSOLUTE = "tvdbAbsolute" class OptimizedForStreaming(int, Enum): @@ -875,9 +877,9 @@ class GetRecentlyAddedMetadataTypedDict(TypedDict): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ thumb: NotRequired[str] @@ -1014,9 +1016,9 @@ class GetRecentlyAddedMetadata(BaseModel): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ diff --git a/src/plex_api_client/models/operations/get_recently_added_library.py b/src/plex_api_client/models/operations/get_recently_added_library.py index 2b30a17..bd15002 100644 --- a/src/plex_api_client/models/operations/get_recently_added_library.py +++ b/src/plex_api_client/models/operations/get_recently_added_library.py @@ -26,6 +26,8 @@ class QueryParamType(int, Enum): SEASON = 3 EPISODE = 4 AUDIO = 8 + ALBUM = 9 + TRACK = 10 class QueryParamIncludeMeta(int, Enum): diff --git a/src/plex_api_client/models/operations/get_search_all_libraries.py b/src/plex_api_client/models/operations/get_search_all_libraries.py index a8896fc..78d4987 100644 --- a/src/plex_api_client/models/operations/get_search_all_libraries.py +++ b/src/plex_api_client/models/operations/get_search_all_libraries.py @@ -11,20 +11,6 @@ from typing import List, Optional from typing_extensions import Annotated, NotRequired, TypedDict -class GetSearchAllLibrariesGlobalsTypedDict(TypedDict): - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - -class GetSearchAllLibrariesGlobals(BaseModel): - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - class SearchTypes(str, Enum): MOVIES = "movies" MUSIC = "music" @@ -50,7 +36,7 @@ class QueryParamIncludeExternalMedia(int, Enum): class GetSearchAllLibrariesRequestTypedDict(TypedDict): query: str r"""The search query term.""" - client_id: NotRequired[str] + client_id: str r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" limit: NotRequired[int] r"""Limit the number of results returned.""" @@ -71,10 +57,10 @@ class GetSearchAllLibrariesRequest(BaseModel): r"""The search query term.""" client_id: Annotated[ - Optional[str], + str, pydantic.Field(alias="X-Plex-Client-Identifier"), FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None + ] r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" limit: Annotated[ @@ -125,17 +111,17 @@ class GetSearchAllLibrariesShowOrdering(str, Enum): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ NONE = "None" TMDB_AIRING = "tmdbAiring" - AIRED = "aired" - DVD = "dvd" - ABSOLUTE = "absolute" + TVDB_AIRING = "tvdbAiring" + TVDB_DVD = "tvdbDvd" + TVDB_ABSOLUTE = "tvdbAbsolute" class GetSearchAllLibrariesOptimizedForStreaming(int, Enum): @@ -676,9 +662,9 @@ class GetSearchAllLibrariesMetadataTypedDict(TypedDict): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ thumb: NotRequired[str] @@ -817,9 +803,9 @@ class GetSearchAllLibrariesMetadata(BaseModel): r"""Setting that indicates the episode ordering for the show None = Library default, tmdbAiring = The Movie Database (Aired), - aired = TheTVDB (Aired), - dvd = TheTVDB (DVD), - absolute = TheTVDB (Absolute)). + tvdbAiring = TheTVDB (Aired), + tvdbDvd = TheTVDB (DVD), + tvdbAbsolute = TheTVDB (Absolute)). """ diff --git a/src/plex_api_client/models/operations/get_search_library.py b/src/plex_api_client/models/operations/get_search_library.py index a44f645..cb4e147 100644 --- a/src/plex_api_client/models/operations/get_search_library.py +++ b/src/plex_api_client/models/operations/get_search_library.py @@ -25,6 +25,8 @@ class GetSearchLibraryQueryParamType(int, Enum): SEASON = 3 EPISODE = 4 AUDIO = 8 + ALBUM = 9 + TRACK = 10 class GetSearchLibraryRequestTypedDict(TypedDict): diff --git a/src/plex_api_client/models/operations/get_server_resources.py b/src/plex_api_client/models/operations/get_server_resources.py index 935749d..5eddfb1 100644 --- a/src/plex_api_client/models/operations/get_server_resources.py +++ b/src/plex_api_client/models/operations/get_server_resources.py @@ -16,20 +16,6 @@ GET_SERVER_RESOURCES_SERVERS = [ ] -class GetServerResourcesGlobalsTypedDict(TypedDict): - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - -class GetServerResourcesGlobals(BaseModel): - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - class IncludeHTTPS(int, Enum): r"""Include Https entries in the results""" @@ -55,6 +41,8 @@ class IncludeIPv6(int, Enum): class GetServerResourcesRequestTypedDict(TypedDict): + client_id: str + r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" include_https: NotRequired[IncludeHTTPS] r"""Include Https entries in the results""" include_relay: NotRequired[IncludeRelay] @@ -64,11 +52,16 @@ class GetServerResourcesRequestTypedDict(TypedDict): """ include_i_pv6: NotRequired[IncludeIPv6] r"""Include IPv6 entries in the results""" - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" class GetServerResourcesRequest(BaseModel): + client_id: Annotated[ + str, + pydantic.Field(alias="X-Plex-Client-Identifier"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] + r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" + include_https: Annotated[ Optional[IncludeHTTPS], pydantic.Field(alias="includeHttps"), @@ -93,13 +86,6 @@ class GetServerResourcesRequest(BaseModel): ] = IncludeIPv6.DISABLE r"""Include IPv6 entries in the results""" - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - class Protocol(str, Enum): r"""The protocol used for the connection (http, https, etc)""" diff --git a/src/plex_api_client/models/operations/get_watch_list.py b/src/plex_api_client/models/operations/get_watch_list.py index b4d9562..4cb634d 100644 --- a/src/plex_api_client/models/operations/get_watch_list.py +++ b/src/plex_api_client/models/operations/get_watch_list.py @@ -16,8 +16,8 @@ from typing import List, Optional from typing_extensions import Annotated, NotRequired, TypedDict GET_WATCH_LIST_SERVERS = [ + # The plex metadata provider server "https://metadata.provider.plex.tv", - r"""The plex metadata provider server""", ] diff --git a/src/plex_api_client/models/operations/getpin.py b/src/plex_api_client/models/operations/getpin.py index efdeb13..fa6337b 100644 --- a/src/plex_api_client/models/operations/getpin.py +++ b/src/plex_api_client/models/operations/getpin.py @@ -21,65 +21,15 @@ GET_PIN_SERVERS = [ ] -class GetPinGlobalsTypedDict(TypedDict): - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - client_name: NotRequired[str] - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - device_nickname: NotRequired[str] - r"""A relatively friendly name for the client device""" - client_version: NotRequired[str] - r"""The version of the client application.""" - platform: NotRequired[str] - r"""The platform of the client application.""" - - -class GetPinGlobals(BaseModel): - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - client_name: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Product"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - - device_nickname: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Device"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""A relatively friendly name for the client device""" - - client_version: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Version"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The version of the client application.""" - - platform: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Platform"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The platform of the client application.""" - - class GetPinRequestTypedDict(TypedDict): + client_id: str + r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" strong: NotRequired[bool] r"""Determines the kind of code returned by the API call Strong codes are used for Pin authentication flows Non-Strong codes are used for `Plex.tv/link` """ - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" client_name: NotRequired[str] r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" device_nickname: NotRequired[str] @@ -91,6 +41,13 @@ class GetPinRequestTypedDict(TypedDict): class GetPinRequest(BaseModel): + client_id: Annotated[ + str, + pydantic.Field(alias="X-Plex-Client-Identifier"), + FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), + ] + r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" + strong: Annotated[ Optional[bool], FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), @@ -101,13 +58,6 @@ class GetPinRequest(BaseModel): """ - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - client_name: Annotated[ Optional[str], pydantic.Field(alias="X-Plex-Product"), diff --git a/src/plex_api_client/models/operations/getplaylistcontents.py b/src/plex_api_client/models/operations/getplaylistcontents.py index 38320cd..d284b81 100644 --- a/src/plex_api_client/models/operations/getplaylistcontents.py +++ b/src/plex_api_client/models/operations/getplaylistcontents.py @@ -26,6 +26,8 @@ class GetPlaylistContentsQueryParamType(int, Enum): SEASON = 3 EPISODE = 4 AUDIO = 8 + ALBUM = 9 + TRACK = 10 class GetPlaylistContentsRequestTypedDict(TypedDict): diff --git a/src/plex_api_client/models/operations/gettokenbypinid.py b/src/plex_api_client/models/operations/gettokenbypinid.py index dd01d02..549d2f1 100644 --- a/src/plex_api_client/models/operations/gettokenbypinid.py +++ b/src/plex_api_client/models/operations/gettokenbypinid.py @@ -21,60 +21,10 @@ GET_TOKEN_BY_PIN_ID_SERVERS = [ ] -class GetTokenByPinIDGlobalsTypedDict(TypedDict): - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - client_name: NotRequired[str] - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - device_nickname: NotRequired[str] - r"""A relatively friendly name for the client device""" - client_version: NotRequired[str] - r"""The version of the client application.""" - platform: NotRequired[str] - r"""The platform of the client application.""" - - -class GetTokenByPinIDGlobals(BaseModel): - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - client_name: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Product"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - - device_nickname: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Device"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""A relatively friendly name for the client device""" - - client_version: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Version"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The version of the client application.""" - - platform: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Platform"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The platform of the client application.""" - - class GetTokenByPinIDRequestTypedDict(TypedDict): pin_id: int r"""The PinID to retrieve an access token for""" - client_id: NotRequired[str] + client_id: str r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" client_name: NotRequired[str] r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" @@ -95,10 +45,10 @@ class GetTokenByPinIDRequest(BaseModel): r"""The PinID to retrieve an access token for""" client_id: Annotated[ - Optional[str], + str, pydantic.Field(alias="X-Plex-Client-Identifier"), FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None + ] r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" client_name: Annotated[ diff --git a/src/plex_api_client/models/operations/gettopwatchedcontent.py b/src/plex_api_client/models/operations/gettopwatchedcontent.py index bd83aae..0832068 100644 --- a/src/plex_api_client/models/operations/gettopwatchedcontent.py +++ b/src/plex_api_client/models/operations/gettopwatchedcontent.py @@ -26,6 +26,8 @@ class GetTopWatchedContentQueryParamType(int, Enum): SEASON = 3 EPISODE = 4 AUDIO = 8 + ALBUM = 9 + TRACK = 10 class GetTopWatchedContentRequestTypedDict(TypedDict): diff --git a/src/plex_api_client/models/operations/post_users_sign_in_data.py b/src/plex_api_client/models/operations/post_users_sign_in_data.py index 4ae3527..774cec2 100644 --- a/src/plex_api_client/models/operations/post_users_sign_in_data.py +++ b/src/plex_api_client/models/operations/post_users_sign_in_data.py @@ -21,56 +21,6 @@ POST_USERS_SIGN_IN_DATA_SERVERS = [ ] -class PostUsersSignInDataGlobalsTypedDict(TypedDict): - client_id: NotRequired[str] - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - client_name: NotRequired[str] - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - device_nickname: NotRequired[str] - r"""A relatively friendly name for the client device""" - client_version: NotRequired[str] - r"""The version of the client application.""" - platform: NotRequired[str] - r"""The platform of the client application.""" - - -class PostUsersSignInDataGlobals(BaseModel): - client_id: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Client-Identifier"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" - - client_name: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Product"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" - - device_nickname: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Device"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""A relatively friendly name for the client device""" - - client_version: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Version"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The version of the client application.""" - - platform: Annotated[ - Optional[str], - pydantic.Field(alias="X-Plex-Platform"), - FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None - r"""The platform of the client application.""" - - class PostUsersSignInDataRequestBodyTypedDict(TypedDict): r"""Login credentials""" @@ -99,7 +49,7 @@ class PostUsersSignInDataRequestBody(BaseModel): class PostUsersSignInDataRequestTypedDict(TypedDict): - client_id: NotRequired[str] + client_id: str r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" client_name: NotRequired[str] r"""The name of the client application. (Plex Web, Plex Media Server, etc.)""" @@ -115,10 +65,10 @@ class PostUsersSignInDataRequestTypedDict(TypedDict): class PostUsersSignInDataRequest(BaseModel): client_id: Annotated[ - Optional[str], + str, pydantic.Field(alias="X-Plex-Client-Identifier"), FieldMetadata(header=HeaderMetadata(style="simple", explode=False)), - ] = None + ] r"""An opaque identifier unique to the client (UUID, serial number, or other unique device ID)""" client_name: Annotated[ diff --git a/src/plex_api_client/playlists.py b/src/plex_api_client/playlists.py index 894218b..a56349d 100644 --- a/src/plex_api_client/playlists.py +++ b/src/plex_api_client/playlists.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Playlists(BaseSDK): @@ -25,6 +25,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.CreatePlaylistResponse: r"""Create a Playlist @@ -37,6 +38,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -61,6 +63,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -130,6 +133,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.CreatePlaylistResponse: r"""Create a Playlist @@ -142,6 +146,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -166,6 +171,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -234,6 +240,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPlaylistsResponse: r"""Get All Playlists @@ -244,6 +251,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -269,6 +277,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -337,6 +346,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPlaylistsResponse: r"""Get All Playlists @@ -347,6 +357,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -372,6 +383,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -439,6 +451,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPlaylistResponse: r"""Retrieve Playlist @@ -450,6 +463,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -474,6 +488,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -539,6 +554,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPlaylistResponse: r"""Retrieve Playlist @@ -550,6 +566,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -574,6 +591,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -639,6 +657,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.DeletePlaylistResponse: r"""Deletes a Playlist @@ -649,6 +668,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -673,6 +693,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -737,6 +758,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.DeletePlaylistResponse: r"""Deletes a Playlist @@ -747,6 +769,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -771,6 +794,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -837,6 +861,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.UpdatePlaylistResponse: r"""Update a Playlist @@ -849,6 +874,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -875,6 +901,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -941,6 +968,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.UpdatePlaylistResponse: r"""Update a Playlist @@ -953,6 +981,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -979,6 +1008,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1044,6 +1074,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPlaylistContentsResponse: r"""Retrieve Playlist Contents @@ -1058,6 +1089,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1083,6 +1115,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1151,6 +1184,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPlaylistContentsResponse: r"""Retrieve Playlist Contents @@ -1165,6 +1199,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1190,6 +1225,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1257,6 +1293,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.ClearPlaylistContentsResponse: r"""Delete Playlist Contents @@ -1267,6 +1304,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1291,6 +1329,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1355,6 +1394,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.ClearPlaylistContentsResponse: r"""Delete Playlist Contents @@ -1365,6 +1405,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1389,6 +1430,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1455,6 +1497,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.AddPlaylistContentsResponse: r"""Adding to a Playlist @@ -1468,6 +1511,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1494,6 +1538,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1563,6 +1608,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.AddPlaylistContentsResponse: r"""Adding to a Playlist @@ -1576,6 +1622,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1602,6 +1649,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1671,6 +1719,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.UploadPlaylistResponse: r"""Upload Playlist @@ -1683,6 +1732,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1709,6 +1759,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1775,6 +1826,7 @@ class Playlists(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.UploadPlaylistResponse: r"""Upload Playlist @@ -1787,6 +1839,7 @@ class Playlists(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1813,6 +1866,7 @@ class Playlists(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/plex.py b/src/plex_api_client/plex.py index 2460807..e659ede 100644 --- a/src/plex_api_client/plex.py +++ b/src/plex_api_client/plex.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, List, Optional, Union, cast +from typing import Any, List, Mapping, Optional, Union, cast class Plex(BaseSDK): @@ -17,6 +17,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetCompanionsDataResponse: r"""Get Companions Data @@ -25,6 +26,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -46,6 +48,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -112,6 +115,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetCompanionsDataResponse: r"""Get Companions Data @@ -120,6 +124,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -141,6 +146,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -207,6 +213,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetUserFriendsResponse: r"""Get list of friends of the user logged in @@ -215,6 +222,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -236,6 +244,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -302,6 +311,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetUserFriendsResponse: r"""Get list of friends of the user logged in @@ -310,6 +320,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -331,6 +342,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -397,6 +409,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetGeoDataResponse: r"""Get Geo Data @@ -405,6 +418,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -426,6 +440,7 @@ class Plex(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, timeout_ms=timeout_ms, ) @@ -487,6 +502,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetGeoDataResponse: r"""Get Geo Data @@ -495,6 +511,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -516,6 +533,7 @@ class Plex(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, timeout_ms=timeout_ms, ) @@ -577,6 +595,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetHomeDataResponse: r"""Get Plex Home Data @@ -585,6 +604,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -604,6 +624,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -668,6 +689,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetHomeDataResponse: r"""Get Plex Home Data @@ -676,6 +698,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -695,6 +718,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -756,6 +780,7 @@ class Plex(BaseSDK): def get_server_resources( self, *, + client_id: str, include_https: Optional[ operations.IncludeHTTPS ] = operations.IncludeHTTPS.DISABLE, @@ -765,22 +790,23 @@ class Plex(BaseSDK): include_i_pv6: Optional[ operations.IncludeIPv6 ] = operations.IncludeIPv6.DISABLE, - client_id: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerResourcesResponse: r"""Get Server Resources Get Plex server access tokens and server connections + :param client_id: An opaque identifier unique to the client (UUID, serial number, or other unique device ID) :param include_https: Include Https entries in the results :param include_relay: Include Relay addresses in the results E.g: https://10-0-0-25.bbf8e10c7fa20447cacee74cd9914cde.plex.direct:32400 :param include_i_pv6: Include IPv6 entries in the results - :param client_id: An opaque identifier unique to the client (UUID, serial number, or other unique device ID) :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -810,9 +836,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetServerResourcesGlobals( - client_id=self.sdk_configuration.globals.client_id, - ), + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -876,6 +900,7 @@ class Plex(BaseSDK): async def get_server_resources_async( self, *, + client_id: str, include_https: Optional[ operations.IncludeHTTPS ] = operations.IncludeHTTPS.DISABLE, @@ -885,22 +910,23 @@ class Plex(BaseSDK): include_i_pv6: Optional[ operations.IncludeIPv6 ] = operations.IncludeIPv6.DISABLE, - client_id: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerResourcesResponse: r"""Get Server Resources Get Plex server access tokens and server connections + :param client_id: An opaque identifier unique to the client (UUID, serial number, or other unique device ID) :param include_https: Include Https entries in the results :param include_relay: Include Relay addresses in the results E.g: https://10-0-0-25.bbf8e10c7fa20447cacee74cd9914cde.plex.direct:32400 :param include_i_pv6: Include IPv6 entries in the results - :param client_id: An opaque identifier unique to the client (UUID, serial number, or other unique device ID) :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -930,9 +956,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetServerResourcesGlobals( - client_id=self.sdk_configuration.globals.client_id, - ), + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1000,6 +1024,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPinResponse: r"""Get a Pin @@ -1009,6 +1034,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1035,13 +1061,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetPinGlobals( - client_id=self.sdk_configuration.globals.client_id, - client_name=self.sdk_configuration.globals.client_name, - device_nickname=self.sdk_configuration.globals.device_nickname, - client_version=self.sdk_configuration.globals.client_version, - platform=self.sdk_configuration.globals.platform, - ), + http_headers=http_headers, timeout_ms=timeout_ms, ) @@ -1098,6 +1118,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetPinResponse: r"""Get a Pin @@ -1107,6 +1128,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1133,13 +1155,7 @@ class Plex(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetPinGlobals( - client_id=self.sdk_configuration.globals.client_id, - client_name=self.sdk_configuration.globals.client_name, - device_nickname=self.sdk_configuration.globals.device_nickname, - client_version=self.sdk_configuration.globals.client_version, - platform=self.sdk_configuration.globals.platform, - ), + http_headers=http_headers, timeout_ms=timeout_ms, ) @@ -1199,6 +1215,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTokenByPinIDResponse: r"""Get Access Token by PinId @@ -1208,6 +1225,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1234,13 +1252,7 @@ class Plex(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetTokenByPinIDGlobals( - client_id=self.sdk_configuration.globals.client_id, - client_name=self.sdk_configuration.globals.client_name, - device_nickname=self.sdk_configuration.globals.device_nickname, - client_version=self.sdk_configuration.globals.client_version, - platform=self.sdk_configuration.globals.platform, - ), + http_headers=http_headers, timeout_ms=timeout_ms, ) @@ -1308,6 +1320,7 @@ class Plex(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTokenByPinIDResponse: r"""Get Access Token by PinId @@ -1317,6 +1330,7 @@ class Plex(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1343,13 +1357,7 @@ class Plex(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", - _globals=operations.GetTokenByPinIDGlobals( - client_id=self.sdk_configuration.globals.client_id, - client_name=self.sdk_configuration.globals.client_name, - device_nickname=self.sdk_configuration.globals.device_nickname, - client_version=self.sdk_configuration.globals.client_version, - platform=self.sdk_configuration.globals.platform, - ), + http_headers=http_headers, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/sdk.py b/src/plex_api_client/sdk.py index 52e69e1..169b511 100644 --- a/src/plex_api_client/sdk.py +++ b/src/plex_api_client/sdk.py @@ -15,7 +15,7 @@ from plex_api_client.hubs import Hubs from plex_api_client.library import Library from plex_api_client.log import Log from plex_api_client.media import Media -from plex_api_client.models import components, internal +from plex_api_client.models import components from plex_api_client.playlists import Playlists from plex_api_client.plex import Plex from plex_api_client.search import Search @@ -139,11 +139,6 @@ class PlexAPI(BaseSDK): access_token: Optional[ Union[Optional[str], Callable[[], Optional[str]]] ] = None, - client_id: Optional[str] = None, - client_name: Optional[str] = None, - client_version: Optional[str] = None, - platform: Optional[str] = None, - device_nickname: Optional[str] = None, protocol: Optional[ServerProtocol] = None, ip: Optional[str] = None, port: Optional[str] = None, @@ -159,11 +154,6 @@ class PlexAPI(BaseSDK): r"""Instantiates the SDK configuring it with the provided parameters. :param access_token: The access_token required for authentication - :param client_id: Configures the client_id parameter for all supported operations - :param client_name: Configures the client_name parameter for all supported operations - :param client_version: Configures the client_version parameter for all supported operations - :param platform: Configures the platform parameter for all supported operations - :param device_nickname: Configures the device_nickname parameter for all supported operations :param protocol: Allows setting the protocol variable for url substitution :param ip: Allows setting the ip variable for url substitution :param port: Allows setting the port variable for url substitution @@ -209,24 +199,11 @@ class PlexAPI(BaseSDK): }, ] - _globals = internal.Globals( - client_id=utils.get_global_from_env(client_id, "CLIENT_ID", str), - client_name=utils.get_global_from_env(client_name, "CLIENT_NAME", str), - client_version=utils.get_global_from_env( - client_version, "CLIENT_VERSION", str - ), - platform=utils.get_global_from_env(platform, "PLATFORM", str), - device_nickname=utils.get_global_from_env( - device_nickname, "DEVICE_NICKNAME", str - ), - ) - BaseSDK.__init__( self, SDKConfiguration( client=client, async_client=async_client, - globals=_globals, security=security, server_url=server_url, server_idx=server_idx, @@ -268,3 +245,17 @@ class PlexAPI(BaseSDK): self.statistics = Statistics(self.sdk_configuration) self.sessions = Sessions(self.sdk_configuration) self.updater = Updater(self.sdk_configuration) + + def __enter__(self): + return self + + async def __aenter__(self): + return self + + def __exit__(self, exc_type, exc_val, exc_tb): + if self.sdk_configuration.client is not None: + self.sdk_configuration.client.close() + + async def __aexit__(self, exc_type, exc_val, exc_tb): + if self.sdk_configuration.async_client is not None: + await self.sdk_configuration.async_client.aclose() diff --git a/src/plex_api_client/sdkconfiguration.py b/src/plex_api_client/sdkconfiguration.py index cac6ddb..8096e83 100644 --- a/src/plex_api_client/sdkconfiguration.py +++ b/src/plex_api_client/sdkconfiguration.py @@ -5,7 +5,7 @@ from .httpclient import AsyncHttpClient, HttpClient from .utils import Logger, RetryConfig, remove_suffix from dataclasses import dataclass, field from enum import Enum -from plex_api_client.models import components, internal +from plex_api_client.models import components from plex_api_client.types import OptionalNullable, UNSET from pydantic import Field from typing import Callable, Dict, List, Optional, Tuple, Union @@ -30,7 +30,6 @@ class SDKConfiguration: client: HttpClient async_client: AsyncHttpClient debug_logger: Logger - globals: internal.Globals security: Optional[ Union[components.Security, Callable[[], components.Security]] ] = None @@ -39,9 +38,9 @@ class SDKConfiguration: server_defaults: List[Dict[str, str]] = field(default_factory=List) language: str = "python" openapi_doc_version: str = "0.0.3" - sdk_version: str = "0.19.1" - gen_version: str = "2.457.9" - user_agent: str = "speakeasy-sdk/python 0.19.1 2.457.9 0.0.3 plex-api-client" + sdk_version: str = "0.20.0" + gen_version: str = "2.483.1" + user_agent: str = "speakeasy-sdk/python 0.20.0 2.483.1 0.0.3 plex-api-client" retry_config: OptionalNullable[RetryConfig] = Field(default_factory=lambda: UNSET) timeout_ms: Optional[int] = None diff --git a/src/plex_api_client/search.py b/src/plex_api_client/search.py index 8d411d2..0c859c8 100644 --- a/src/plex_api_client/search.py +++ b/src/plex_api_client/search.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import OptionalNullable, UNSET -from typing import Any, Optional +from typing import Any, Mapping, Optional class Search(BaseSDK): @@ -20,6 +20,7 @@ class Search(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.PerformSearchResponse: r"""Perform a search @@ -43,6 +44,7 @@ class Search(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -69,6 +71,7 @@ class Search(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -135,6 +138,7 @@ class Search(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.PerformSearchResponse: r"""Perform a search @@ -158,6 +162,7 @@ class Search(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -184,6 +189,7 @@ class Search(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -250,6 +256,7 @@ class Search(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.PerformVoiceSearchResponse: r"""Perform a voice search @@ -265,6 +272,7 @@ class Search(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -291,6 +299,7 @@ class Search(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -357,6 +366,7 @@ class Search(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.PerformVoiceSearchResponse: r"""Perform a voice search @@ -372,6 +382,7 @@ class Search(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -398,6 +409,7 @@ class Search(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -462,6 +474,7 @@ class Search(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSearchResultsResponse: r"""Get Search Results @@ -471,6 +484,7 @@ class Search(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -495,6 +509,7 @@ class Search(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -562,6 +577,7 @@ class Search(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSearchResultsResponse: r"""Get Search Results @@ -571,6 +587,7 @@ class Search(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -595,6 +612,7 @@ class Search(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/server.py b/src/plex_api_client/server.py index 0d6813a..4f5a7da 100644 --- a/src/plex_api_client/server.py +++ b/src/plex_api_client/server.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Server(BaseSDK): @@ -17,6 +17,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerCapabilitiesResponse: r"""Get Server Capabilities @@ -25,6 +26,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -44,6 +46,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -111,6 +114,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerCapabilitiesResponse: r"""Get Server Capabilities @@ -119,6 +123,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -138,6 +143,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -205,6 +211,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerPreferencesResponse: r"""Get Server Preferences @@ -213,6 +220,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -232,6 +240,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -298,6 +307,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerPreferencesResponse: r"""Get Server Preferences @@ -306,6 +316,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -325,6 +336,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -391,6 +403,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetAvailableClientsResponse: r"""Get Available Clients @@ -399,6 +412,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -418,6 +432,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -484,6 +499,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetAvailableClientsResponse: r"""Get Available Clients @@ -492,6 +508,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -511,6 +528,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -577,6 +595,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetDevicesResponse: r"""Get Devices @@ -585,6 +604,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -604,6 +624,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -668,6 +689,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetDevicesResponse: r"""Get Devices @@ -676,6 +698,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -695,6 +718,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -759,6 +783,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerIdentityResponse: r"""Get Server Identity @@ -767,6 +792,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -786,6 +812,7 @@ class Server(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, timeout_ms=timeout_ms, ) @@ -845,6 +872,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerIdentityResponse: r"""Get Server Identity @@ -853,6 +881,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -872,6 +901,7 @@ class Server(BaseSDK): request_has_query_params=False, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, timeout_ms=timeout_ms, ) @@ -931,6 +961,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMyPlexAccountResponse: r"""Get MyPlex Account @@ -939,6 +970,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -958,6 +990,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1024,6 +1057,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMyPlexAccountResponse: r"""Get MyPlex Account @@ -1032,6 +1066,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1051,6 +1086,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1121,6 +1157,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetResizedPhotoResponse: r"""Get a Resized Photo @@ -1131,6 +1168,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1155,6 +1193,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1222,6 +1261,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetResizedPhotoResponse: r"""Get a Resized Photo @@ -1232,6 +1272,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1256,6 +1297,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1320,6 +1362,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMediaProvidersResponse: r"""Get Media Providers @@ -1329,6 +1372,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1353,6 +1397,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1420,6 +1465,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetMediaProvidersResponse: r"""Get Media Providers @@ -1429,6 +1475,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1453,6 +1500,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1519,6 +1567,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerListResponse: r"""Get Server List @@ -1527,6 +1576,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1546,6 +1596,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -1612,6 +1663,7 @@ class Server(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetServerListResponse: r"""Get Server List @@ -1620,6 +1672,7 @@ class Server(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -1639,6 +1692,7 @@ class Server(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/sessions.py b/src/plex_api_client/sessions.py index 2d57c30..a846617 100644 --- a/src/plex_api_client/sessions.py +++ b/src/plex_api_client/sessions.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import OptionalNullable, UNSET -from typing import Any, Optional, Union +from typing import Any, Mapping, Optional, Union class Sessions(BaseSDK): @@ -17,6 +17,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSessionsResponse: r"""Get Active Sessions @@ -25,6 +26,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -44,6 +46,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -108,6 +111,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSessionsResponse: r"""Get Active Sessions @@ -116,6 +120,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -135,6 +140,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -205,6 +211,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSessionHistoryResponse: r"""Get Session History @@ -217,6 +224,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -246,6 +254,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -318,6 +327,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetSessionHistoryResponse: r"""Get Session History @@ -330,6 +340,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -359,6 +370,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -425,6 +437,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTranscodeSessionsResponse: r"""Get Transcode Sessions @@ -433,6 +446,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -452,6 +466,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -518,6 +533,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTranscodeSessionsResponse: r"""Get Transcode Sessions @@ -526,6 +542,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -545,6 +562,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -612,6 +630,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StopTranscodeSessionResponse: r"""Stop a Transcode Session @@ -621,6 +640,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -645,6 +665,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -709,6 +730,7 @@ class Sessions(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StopTranscodeSessionResponse: r"""Stop a Transcode Session @@ -718,6 +740,7 @@ class Sessions(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -742,6 +765,7 @@ class Sessions(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/statistics.py b/src/plex_api_client/statistics.py index 70f1f40..2276f0c 100644 --- a/src/plex_api_client/statistics.py +++ b/src/plex_api_client/statistics.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import OptionalNullable, UNSET -from typing import Any, Optional +from typing import Any, Mapping, Optional class Statistics(BaseSDK): @@ -18,6 +18,7 @@ class Statistics(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetStatisticsResponse: r"""Get Media Statistics @@ -27,6 +28,7 @@ class Statistics(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -51,6 +53,7 @@ class Statistics(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -118,6 +121,7 @@ class Statistics(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetStatisticsResponse: r"""Get Media Statistics @@ -127,6 +131,7 @@ class Statistics(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -151,6 +156,7 @@ class Statistics(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -218,6 +224,7 @@ class Statistics(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetResourcesStatisticsResponse: r"""Get Resources Statistics @@ -227,6 +234,7 @@ class Statistics(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -251,6 +259,7 @@ class Statistics(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -319,6 +328,7 @@ class Statistics(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetResourcesStatisticsResponse: r"""Get Resources Statistics @@ -328,6 +338,7 @@ class Statistics(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -352,6 +363,7 @@ class Statistics(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -420,6 +432,7 @@ class Statistics(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetBandwidthStatisticsResponse: r"""Get Bandwidth Statistics @@ -429,6 +442,7 @@ class Statistics(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -453,6 +467,7 @@ class Statistics(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -521,6 +536,7 @@ class Statistics(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetBandwidthStatisticsResponse: r"""Get Bandwidth Statistics @@ -530,6 +546,7 @@ class Statistics(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -554,6 +571,7 @@ class Statistics(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/updater.py b/src/plex_api_client/updater.py index 0349a97..1280653 100644 --- a/src/plex_api_client/updater.py +++ b/src/plex_api_client/updater.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import OptionalNullable, UNSET -from typing import Any, Optional +from typing import Any, Mapping, Optional class Updater(BaseSDK): @@ -20,6 +20,7 @@ class Updater(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetUpdateStatusResponse: r"""Querying status of updates @@ -28,6 +29,7 @@ class Updater(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -47,6 +49,7 @@ class Updater(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -113,6 +116,7 @@ class Updater(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetUpdateStatusResponse: r"""Querying status of updates @@ -121,6 +125,7 @@ class Updater(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -140,6 +145,7 @@ class Updater(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -207,6 +213,7 @@ class Updater(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.CheckForUpdatesResponse: r"""Checking for updates @@ -216,6 +223,7 @@ class Updater(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -240,6 +248,7 @@ class Updater(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -304,6 +313,7 @@ class Updater(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.CheckForUpdatesResponse: r"""Checking for updates @@ -313,6 +323,7 @@ class Updater(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -337,6 +348,7 @@ class Updater(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -402,6 +414,7 @@ class Updater(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.ApplyUpdatesResponse: r"""Apply Updates @@ -413,6 +426,7 @@ class Updater(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -438,6 +452,7 @@ class Updater(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -503,6 +518,7 @@ class Updater(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.ApplyUpdatesResponse: r"""Apply Updates @@ -514,6 +530,7 @@ class Updater(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -539,6 +556,7 @@ class Updater(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/utils/annotations.py b/src/plex_api_client/utils/annotations.py index 5b3bbb0..387874e 100644 --- a/src/plex_api_client/utils/annotations.py +++ b/src/plex_api_client/utils/annotations.py @@ -1,30 +1,55 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from enum import Enum -from typing import Any +from typing import Any, Optional def get_discriminator(model: Any, fieldname: str, key: str) -> str: - if isinstance(model, dict): - try: - return f'{model.get(key)}' - except AttributeError as e: - raise ValueError(f'Could not find discriminator key {key} in {model}') from e + """ + Recursively search for the discriminator attribute in a model. - if hasattr(model, fieldname): - attr = getattr(model, fieldname) + Args: + model (Any): The model to search within. + fieldname (str): The name of the field to search for. + key (str): The key to search for in dictionaries. - if isinstance(attr, Enum): - return f'{attr.value}' + Returns: + str: The name of the discriminator attribute. - return f'{attr}' + Raises: + ValueError: If the discriminator attribute is not found. + """ + upper_fieldname = fieldname.upper() - fieldname = fieldname.upper() - if hasattr(model, fieldname): - attr = getattr(model, fieldname) + def get_field_discriminator(field: Any) -> Optional[str]: + """Search for the discriminator attribute in a given field.""" - if isinstance(attr, Enum): - return f'{attr.value}' + if isinstance(field, dict): + if key in field: + return f'{field[key]}' - return f'{attr}' + if hasattr(field, fieldname): + attr = getattr(field, fieldname) + if isinstance(attr, Enum): + return f'{attr.value}' + return f'{attr}' + + if hasattr(field, upper_fieldname): + attr = getattr(field, upper_fieldname) + if isinstance(attr, Enum): + return f'{attr.value}' + return f'{attr}' + + return None + + + if isinstance(model, list): + for field in model: + discriminator = get_field_discriminator(field) + if discriminator is not None: + return discriminator + + discriminator = get_field_discriminator(model) + if discriminator is not None: + return discriminator raise ValueError(f'Could not find discriminator field {fieldname} in {model}') diff --git a/src/plex_api_client/utils/eventstreaming.py b/src/plex_api_client/utils/eventstreaming.py index 553b386..74a63f7 100644 --- a/src/plex_api_client/utils/eventstreaming.py +++ b/src/plex_api_client/utils/eventstreaming.py @@ -2,12 +2,72 @@ import re import json -from typing import Callable, TypeVar, Optional, Generator, AsyncGenerator, Tuple +from typing import ( + Callable, + Generic, + TypeVar, + Optional, + Generator, + AsyncGenerator, + Tuple, +) import httpx T = TypeVar("T") +class EventStream(Generic[T]): + response: httpx.Response + generator: Generator[T, None, None] + + def __init__( + self, + response: httpx.Response, + decoder: Callable[[str], T], + sentinel: Optional[str] = None, + ): + self.response = response + self.generator = stream_events(response, decoder, sentinel) + + def __iter__(self): + return self + + def __next__(self): + return next(self.generator) + + def __enter__(self): + return self + + def __exit__(self, exc_type, exc_val, exc_tb): + self.response.close() + + +class EventStreamAsync(Generic[T]): + response: httpx.Response + generator: AsyncGenerator[T, None] + + def __init__( + self, + response: httpx.Response, + decoder: Callable[[str], T], + sentinel: Optional[str] = None, + ): + self.response = response + self.generator = stream_events_async(response, decoder, sentinel) + + def __aiter__(self): + return self + + async def __anext__(self): + return await self.generator.__anext__() + + async def __aenter__(self): + return self + + async def __aexit__(self, exc_type, exc_val, exc_tb): + await self.response.aclose() + + class ServerEvent: id: Optional[str] = None event: Optional[str] = None diff --git a/src/plex_api_client/utils/forms.py b/src/plex_api_client/utils/forms.py index 9f5a731..0472aba 100644 --- a/src/plex_api_client/utils/forms.py +++ b/src/plex_api_client/utils/forms.py @@ -109,13 +109,12 @@ def serialize_multipart_form( if not field_metadata: continue - f_name = field.alias if field.alias is not None else name + f_name = field.alias if field.alias else name if field_metadata.file: file_fields: Dict[str, FieldInfo] = val.__class__.model_fields file_name = "" - field_name = "" content = None content_type = None @@ -131,20 +130,15 @@ def serialize_multipart_form( elif file_field_name == "content_type": content_type = getattr(val, file_field_name, None) else: - field_name = ( - file_field.alias - if file_field.alias is not None - else file_field_name - ) file_name = getattr(val, file_field_name) - if field_name == "" or file_name == "" or content is None: + if file_name == "" or content is None: raise ValueError("invalid multipart/form-data file") if content_type is not None: - files[field_name] = (file_name, content, content_type) + files[f_name] = (file_name, content, content_type) else: - files[field_name] = (file_name, content) + files[f_name] = (file_name, content) elif field_metadata.json: files[f_name] = ( None, diff --git a/src/plex_api_client/utils/requestbodies.py b/src/plex_api_client/utils/requestbodies.py index 4f586ae..d5240dd 100644 --- a/src/plex_api_client/utils/requestbodies.py +++ b/src/plex_api_client/utils/requestbodies.py @@ -23,7 +23,7 @@ SERIALIZATION_METHOD_TO_CONTENT_TYPE = { @dataclass class SerializedRequestBody: - media_type: str + media_type: Optional[str] = None content: Optional[Any] = None data: Optional[Any] = None files: Optional[Any] = None diff --git a/src/plex_api_client/video.py b/src/plex_api_client/video.py index 95b3ddb..3ce4401 100644 --- a/src/plex_api_client/video.py +++ b/src/plex_api_client/video.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Video(BaseSDK): @@ -20,6 +20,7 @@ class Video(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTimelineResponse: r"""Get the timeline for a media item @@ -29,6 +30,7 @@ class Video(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -53,6 +55,7 @@ class Video(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -117,6 +120,7 @@ class Video(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetTimelineResponse: r"""Get the timeline for a media item @@ -126,6 +130,7 @@ class Video(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -150,6 +155,7 @@ class Video(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -215,6 +221,7 @@ class Video(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StartUniversalTranscodeResponse: r"""Start Universal Transcode @@ -224,6 +231,7 @@ class Video(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -250,6 +258,7 @@ class Video(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -317,6 +326,7 @@ class Video(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.StartUniversalTranscodeResponse: r"""Start Universal Transcode @@ -326,6 +336,7 @@ class Video(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -352,6 +363,7 @@ class Video(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) diff --git a/src/plex_api_client/watchlist.py b/src/plex_api_client/watchlist.py index 5799454..e63aa79 100644 --- a/src/plex_api_client/watchlist.py +++ b/src/plex_api_client/watchlist.py @@ -5,7 +5,7 @@ from plex_api_client import utils from plex_api_client._hooks import HookContext from plex_api_client.models import errors, operations from plex_api_client.types import BaseModel, OptionalNullable, UNSET -from typing import Any, Optional, Union, cast +from typing import Any, Mapping, Optional, Union, cast class Watchlist(BaseSDK): @@ -20,6 +20,7 @@ class Watchlist(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetWatchListResponse: r"""Get User Watchlist @@ -29,6 +30,7 @@ class Watchlist(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -55,6 +57,7 @@ class Watchlist(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, ) @@ -124,6 +127,7 @@ class Watchlist(BaseSDK): retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, ) -> operations.GetWatchListResponse: r"""Get User Watchlist @@ -133,6 +137,7 @@ class Watchlist(BaseSDK): :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. """ base_url = None url_variables = None @@ -159,6 +164,7 @@ class Watchlist(BaseSDK): request_has_query_params=True, user_agent_header="user-agent", accept_header_value="application/json", + http_headers=http_headers, security=self.sdk_configuration.security, timeout_ms=timeout_ms, )