Compare commits

...

4 Commits

Author SHA1 Message Date
speakeasybot
4d8ee6c199 ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.390.7 2024-09-06 00:03:49 +00:00
Luke Hagar
4fe1356250 Update speakeasy_sdk_generation.yml 2024-08-30 20:10:43 -05:00
speakeasybot
454b20d045 ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.377.1 2024-08-22 05:18:31 +00:00
speakeasybot
8c39ddc475 ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.323.0 2024-07-01 16:25:36 +00:00
810 changed files with 61900 additions and 23833 deletions

View File

@@ -23,7 +23,7 @@ jobs:
with: with:
force: ${{ github.event.inputs.force }} force: ${{ github.event.inputs.force }}
mode: direct mode: direct
push_code_samples_only: ${{ fromJSON(github.event.inputs.push_code_samples_only) }} push_code_samples_only: ${{ fromJSON(github.event.inputs.push_code_samples_only != '' && github.event.inputs.push_code_samples_only || 'false') }}
speakeasy_version: latest speakeasy_version: latest
secrets: secrets:
github_access_token: ${{ secrets.GITHUB_TOKEN }} github_access_token: ${{ secrets.GITHUB_TOKEN }}

6
.gitignore vendored
View File

@@ -1,3 +1,9 @@
/funcs
/core.*
/esm
/dist
/.tshy
/.tshy-*
/hooks /hooks
/models /models
/models/errors /models/errors

View File

@@ -5,3 +5,5 @@
/.eslintrc.js /.eslintrc.js
/cjs /cjs
/.tshy
/.tshy-*

View File

@@ -1,12 +1,12 @@
lockVersion: 2.0.0 lockVersion: 2.0.0
id: 16f22cbf-f23f-4419-8924-3a4b06381947 id: 16f22cbf-f23f-4419-8924-3a4b06381947
management: management:
docChecksum: e73920abd3a55e8d249592f2e3090574 docChecksum: f627107f2ac6c53325be4f291ae2dea7
docVersion: 0.0.3 docVersion: 0.0.3
speakeasyVersion: 1.323.0 speakeasyVersion: 1.390.7
generationVersion: 2.356.0 generationVersion: 2.409.8
releaseVersion: 0.18.1 releaseVersion: 0.20.0
configChecksum: 85719ed12dded10484b522822b0eff1a configChecksum: 1eb0f35569735ddf4ea84adabb3887ba
repoURL: https://github.com/LukeHagar/plexjs.git repoURL: https://github.com/LukeHagar/plexjs.git
repoSubDirectory: . repoSubDirectory: .
installationURL: https://github.com/LukeHagar/plexjs installationURL: https://github.com/LukeHagar/plexjs
@@ -14,10 +14,14 @@ management:
features: features:
typescript: typescript:
additionalDependencies: 0.1.0 additionalDependencies: 0.1.0
constsAndDefaults: 0.1.5 constsAndDefaults: 0.1.11
core: 3.10.2 core: 3.16.1
defaultEnabledRetries: 0.1.0
deprecations: 2.81.1
downloadStreams: 0.1.1
envVarSecurityUsage: 0.1.1
flattening: 2.81.1 flattening: 2.81.1
globalSecurity: 2.82.9 globalSecurity: 2.82.11
globalSecurityCallbacks: 0.1.0 globalSecurityCallbacks: 0.1.0
globalSecurityFlattening: 0.1.0 globalSecurityFlattening: 0.1.0
globalServerURLs: 2.82.4 globalServerURLs: 2.82.4
@@ -26,10 +30,84 @@ features:
nameOverrides: 2.81.2 nameOverrides: 2.81.2
nullables: 0.1.0 nullables: 0.1.0
responseFormat: 0.2.3 responseFormat: 0.2.3
retries: 2.83.0
sdkHooks: 0.1.0 sdkHooks: 0.1.0
typeOverrides: 2.81.1 unions: 2.85.7
unions: 2.85.5
generatedFiles: generatedFiles:
- src/funcs/serverGetServerCapabilities.ts
- src/funcs/serverGetServerPreferences.ts
- src/funcs/serverGetAvailableClients.ts
- src/funcs/serverGetDevices.ts
- src/funcs/serverGetServerIdentity.ts
- src/funcs/serverGetMyPlexAccount.ts
- src/funcs/serverGetResizedPhoto.ts
- src/funcs/serverGetMediaProviders.ts
- src/funcs/serverGetServerList.ts
- src/funcs/mediaMarkPlayed.ts
- src/funcs/mediaMarkUnplayed.ts
- src/funcs/mediaUpdatePlayProgress.ts
- src/funcs/mediaGetBannerImage.ts
- src/funcs/mediaGetThumbImage.ts
- src/funcs/videoGetTimeline.ts
- src/funcs/videoStartUniversalTranscode.ts
- src/funcs/activitiesGetServerActivities.ts
- src/funcs/activitiesCancelServerActivities.ts
- src/funcs/butlerGetButlerTasks.ts
- src/funcs/butlerStartAllTasks.ts
- src/funcs/butlerStopAllTasks.ts
- src/funcs/butlerStartTask.ts
- src/funcs/butlerStopTask.ts
- src/funcs/plexGetCompanionsData.ts
- src/funcs/plexGetUserFriends.ts
- src/funcs/plexGetGeoData.ts
- src/funcs/plexGetHomeData.ts
- src/funcs/plexGetServerResources.ts
- src/funcs/plexGetPin.ts
- src/funcs/plexGetTokenByPinId.ts
- src/funcs/hubsGetGlobalHubs.ts
- src/funcs/hubsGetLibraryHubs.ts
- src/funcs/searchPerformSearch.ts
- src/funcs/searchPerformVoiceSearch.ts
- src/funcs/searchGetSearchResults.ts
- src/funcs/libraryGetFileHash.ts
- src/funcs/libraryGetRecentlyAdded.ts
- src/funcs/libraryGetAllLibraries.ts
- src/funcs/libraryGetLibraryDetails.ts
- src/funcs/libraryDeleteLibrary.ts
- src/funcs/libraryGetLibraryItems.ts
- src/funcs/libraryGetRefreshLibraryMetadata.ts
- src/funcs/libraryGetSearchLibrary.ts
- src/funcs/libraryGetMetaDataByRatingKey.ts
- src/funcs/libraryGetMetadataChildren.ts
- src/funcs/libraryGetTopWatchedContent.ts
- src/funcs/libraryGetOnDeck.ts
- src/funcs/watchlistGetWatchList.ts
- src/funcs/logLogLine.ts
- src/funcs/logLogMultiLine.ts
- src/funcs/logEnablePaperTrail.ts
- src/funcs/playlistsCreatePlaylist.ts
- src/funcs/playlistsGetPlaylists.ts
- src/funcs/playlistsGetPlaylist.ts
- src/funcs/playlistsDeletePlaylist.ts
- src/funcs/playlistsUpdatePlaylist.ts
- src/funcs/playlistsGetPlaylistContents.ts
- src/funcs/playlistsClearPlaylistContents.ts
- src/funcs/playlistsAddPlaylistContents.ts
- src/funcs/playlistsUploadPlaylist.ts
- src/funcs/authenticationGetTransientToken.ts
- src/funcs/authenticationGetSourceConnectionInformation.ts
- src/funcs/authenticationGetUserDetails.ts
- src/funcs/authenticationPostUsersSignInData.ts
- src/funcs/statisticsGetStatistics.ts
- src/funcs/statisticsGetResourcesStatistics.ts
- src/funcs/statisticsGetBandwidthStatistics.ts
- src/funcs/sessionsGetSessions.ts
- src/funcs/sessionsGetSessionHistory.ts
- src/funcs/sessionsGetTranscodeSessions.ts
- src/funcs/sessionsStopTranscodeSession.ts
- src/funcs/updaterGetUpdateStatus.ts
- src/funcs/updaterCheckForUpdates.ts
- src/funcs/updaterApplyUpdates.ts
- src/sdk/server.ts - src/sdk/server.ts
- src/sdk/media.ts - src/sdk/media.ts
- src/sdk/video.ts - src/sdk/video.ts
@@ -39,25 +117,31 @@ generatedFiles:
- src/sdk/hubs.ts - src/sdk/hubs.ts
- src/sdk/search.ts - src/sdk/search.ts
- src/sdk/library.ts - src/sdk/library.ts
- src/sdk/watchlist.ts
- src/sdk/log.ts - src/sdk/log.ts
- src/sdk/playlists.ts - src/sdk/playlists.ts
- src/sdk/authentication.ts - src/sdk/authentication.ts
- src/sdk/statistics.ts - src/sdk/statistics.ts
- src/sdk/sessions.ts - src/sdk/sessions.ts
- src/sdk/updater.ts - src/sdk/updater.ts
- src/sdk/watchlist.ts
- src/sdk/sdk.ts - src/sdk/sdk.ts
- .eslintrc.cjs - .eslintrc.cjs
- .npmignore - .npmignore
- FUNCTIONS.md
- RUNTIMES.md - RUNTIMES.md
- jsr.json - jsr.json
- package.json - package.json
- src/core.ts
- src/index.ts - src/index.ts
- src/lib/base64.ts - src/lib/base64.ts
- src/lib/config.ts - src/lib/config.ts
- src/lib/dlv.ts
- src/lib/encodings.ts - src/lib/encodings.ts
- src/lib/files.ts
- src/lib/http.ts - src/lib/http.ts
- src/lib/is-plain-object.ts - src/lib/is-plain-object.ts
- src/lib/logger.ts
- src/lib/matchers.ts
- src/lib/primitives.ts - src/lib/primitives.ts
- src/lib/retries.ts - src/lib/retries.ts
- src/lib/schemas.ts - src/lib/schemas.ts
@@ -65,13 +149,17 @@ generatedFiles:
- src/lib/security.ts - src/lib/security.ts
- src/lib/url.ts - src/lib/url.ts
- src/sdk/index.ts - src/sdk/index.ts
- src/models/httpclienterrors.ts
- src/models/sdkerror.ts - src/models/sdkerror.ts
- src/models/sdkvalidationerror.ts - src/models/sdkvalidationerror.ts
- src/types/blobs.ts - src/types/blobs.ts
- src/types/constdatetime.ts
- src/types/enums.ts - src/types/enums.ts
- src/types/fp.ts
- src/types/index.ts - src/types/index.ts
- src/types/operations.ts - src/types/operations.ts
- src/types/rfcdate.ts - src/types/rfcdate.ts
- src/types/streams.ts
- tsconfig.json - tsconfig.json
- src/models/getservercapabilitiesop.ts - src/models/getservercapabilitiesop.ts
- src/models/getserverpreferencesop.ts - src/models/getserverpreferencesop.ts
@@ -80,10 +168,13 @@ generatedFiles:
- src/models/getserveridentityop.ts - src/models/getserveridentityop.ts
- src/models/getmyplexaccountop.ts - src/models/getmyplexaccountop.ts
- src/models/getresizedphotoop.ts - src/models/getresizedphotoop.ts
- src/models/getmediaprovidersop.ts
- src/models/getserverlistop.ts - src/models/getserverlistop.ts
- src/models/markplayedop.ts - src/models/markplayedop.ts
- src/models/markunplayedop.ts - src/models/markunplayedop.ts
- src/models/updateplayprogressop.ts - src/models/updateplayprogressop.ts
- src/models/getbannerimageop.ts
- src/models/getthumbimageop.ts
- src/models/gettimelineop.ts - src/models/gettimelineop.ts
- src/models/startuniversaltranscodeop.ts - src/models/startuniversaltranscodeop.ts
- src/models/getserveractivitiesop.ts - src/models/getserveractivitiesop.ts
@@ -93,9 +184,13 @@ generatedFiles:
- src/models/stopalltasksop.ts - src/models/stopalltasksop.ts
- src/models/starttaskop.ts - src/models/starttaskop.ts
- src/models/stoptaskop.ts - src/models/stoptaskop.ts
- src/models/getcompanionsdataop.ts
- src/models/getuserfriendsop.ts
- src/models/getgeodataop.ts
- src/models/gethomedataop.ts - src/models/gethomedataop.ts
- src/models/getserverresourcesop.ts
- src/models/getpinop.ts - src/models/getpinop.ts
- src/models/gettokenop.ts - src/models/gettokenbypinidop.ts
- src/models/getglobalhubsop.ts - src/models/getglobalhubsop.ts
- src/models/getlibraryhubsop.ts - src/models/getlibraryhubsop.ts
- src/models/performsearchop.ts - src/models/performsearchop.ts
@@ -103,16 +198,17 @@ generatedFiles:
- src/models/getsearchresultsop.ts - src/models/getsearchresultsop.ts
- src/models/getfilehashop.ts - src/models/getfilehashop.ts
- src/models/getrecentlyaddedop.ts - src/models/getrecentlyaddedop.ts
- src/models/getlibrariesop.ts - src/models/getalllibrariesop.ts
- src/models/getlibraryop.ts - src/models/getlibrarydetailsop.ts
- src/models/deletelibraryop.ts - src/models/deletelibraryop.ts
- src/models/getlibraryitemsop.ts - src/models/getlibraryitemsop.ts
- src/models/refreshlibraryop.ts - src/models/getrefreshlibrarymetadataop.ts
- src/models/searchlibraryop.ts - src/models/getsearchlibraryop.ts
- src/models/getmetadataop.ts - src/models/getmetadatabyratingkeyop.ts
- src/models/getmetadatachildrenop.ts - src/models/getmetadatachildrenop.ts
- src/models/gettopwatchedcontentop.ts - src/models/gettopwatchedcontentop.ts
- src/models/getondeckop.ts - src/models/getondeckop.ts
- src/models/getwatchlistop.ts
- src/models/loglineop.ts - src/models/loglineop.ts
- src/models/logmultilineop.ts - src/models/logmultilineop.ts
- src/models/enablepapertrailop.ts - src/models/enablepapertrailop.ts
@@ -127,6 +223,8 @@ generatedFiles:
- src/models/uploadplaylistop.ts - src/models/uploadplaylistop.ts
- src/models/gettransienttokenop.ts - src/models/gettransienttokenop.ts
- src/models/getsourceconnectioninformationop.ts - src/models/getsourceconnectioninformationop.ts
- src/models/getuserdetailsop.ts
- src/models/postuserssignindataop.ts
- src/models/getstatisticsop.ts - src/models/getstatisticsop.ts
- src/models/getresourcesstatisticsop.ts - src/models/getresourcesstatisticsop.ts
- src/models/getbandwidthstatisticsop.ts - src/models/getbandwidthstatisticsop.ts
@@ -137,7 +235,6 @@ generatedFiles:
- src/models/getupdatestatusop.ts - src/models/getupdatestatusop.ts
- src/models/checkforupdatesop.ts - src/models/checkforupdatesop.ts
- src/models/applyupdatesop.ts - src/models/applyupdatesop.ts
- src/models/getwatchlistop.ts
- src/models/security.ts - src/models/security.ts
- src/models/index.ts - src/models/index.ts
- docs/models/errors.md - docs/models/errors.md
@@ -164,7 +261,6 @@ generatedFiles:
- docs/models/getdevicesmediacontainer.md - docs/models/getdevicesmediacontainer.md
- docs/models/getdevicesresponsebody.md - docs/models/getdevicesresponsebody.md
- docs/models/getdevicesresponse.md - docs/models/getdevicesresponse.md
- docs/models/getserveridentityerrors.md
- docs/models/getserveridentityserverresponsebody.md - docs/models/getserveridentityserverresponsebody.md
- docs/models/getserveridentitymediacontainer.md - docs/models/getserveridentitymediacontainer.md
- docs/models/getserveridentityresponsebody.md - docs/models/getserveridentityresponsebody.md
@@ -180,6 +276,16 @@ generatedFiles:
- docs/models/getresizedphotoerrors.md - docs/models/getresizedphotoerrors.md
- docs/models/getresizedphotoresponsebody.md - docs/models/getresizedphotoresponsebody.md
- docs/models/getresizedphotoresponse.md - docs/models/getresizedphotoresponse.md
- docs/models/getmediaprovidersrequest.md
- docs/models/getmediaproviderserrors.md
- docs/models/getmediaprovidersserverresponsebody.md
- docs/models/pivot.md
- docs/models/getmediaprovidersdirectory.md
- docs/models/feature.md
- docs/models/mediaprovider.md
- docs/models/getmediaprovidersmediacontainer.md
- docs/models/getmediaprovidersresponsebody.md
- docs/models/getmediaprovidersresponse.md
- docs/models/getserverlisterrors.md - docs/models/getserverlisterrors.md
- docs/models/getserverlistserverresponsebody.md - docs/models/getserverlistserverresponsebody.md
- docs/models/getserverlistserver.md - docs/models/getserverlistserver.md
@@ -198,6 +304,14 @@ generatedFiles:
- docs/models/updateplayprogresserrors.md - docs/models/updateplayprogresserrors.md
- docs/models/updateplayprogressresponsebody.md - docs/models/updateplayprogressresponsebody.md
- docs/models/updateplayprogressresponse.md - docs/models/updateplayprogressresponse.md
- docs/models/getbannerimagerequest.md
- docs/models/getbannerimageerrors.md
- docs/models/getbannerimageresponsebody.md
- docs/models/getbannerimageresponse.md
- docs/models/getthumbimagerequest.md
- docs/models/getthumbimageerrors.md
- docs/models/getthumbimageresponsebody.md
- docs/models/getthumbimageresponse.md
- docs/models/state.md - docs/models/state.md
- docs/models/gettimelinerequest.md - docs/models/gettimelinerequest.md
- docs/models/gettimelineerrors.md - docs/models/gettimelineerrors.md
@@ -240,24 +354,51 @@ generatedFiles:
- docs/models/stoptaskerrors.md - docs/models/stoptaskerrors.md
- docs/models/stoptaskresponsebody.md - docs/models/stoptaskresponsebody.md
- docs/models/stoptaskresponse.md - docs/models/stoptaskresponse.md
- docs/models/getcompanionsdataerrors.md
- docs/models/getcompanionsdataresponsebody.md
- docs/models/responsebody.md
- docs/models/getcompanionsdataresponse.md
- docs/models/getuserfriendserrors.md
- docs/models/getuserfriendsresponsebody.md
- docs/models/sharedservers.md
- docs/models/sharedsources.md
- docs/models/status.md
- docs/models/friend.md
- docs/models/getuserfriendsresponse.md
- docs/models/getgeodataerrors.md
- docs/models/getgeodataresponsebody.md
- docs/models/getgeodatageodata.md
- docs/models/getgeodataresponse.md
- docs/models/gethomedataerrors.md - docs/models/gethomedataerrors.md
- docs/models/gethomedataplexresponsebody.md - docs/models/gethomedataplexresponsebody.md
- docs/models/gethomedataresponsebody.md - docs/models/gethomedataresponsebody.md
- docs/models/gethomedataresponse.md - docs/models/gethomedataresponse.md
- docs/models/getserverresourcesglobals.md
- docs/models/includehttps.md
- docs/models/includerelay.md
- docs/models/includeipv6.md
- docs/models/getserverresourcesrequest.md
- docs/models/getserverresourceserrors.md
- docs/models/getserverresourcesresponsebody.md
- docs/models/connections.md
- docs/models/plexdevice.md
- docs/models/getserverresourcesresponse.md
- docs/models/getpinglobals.md - docs/models/getpinglobals.md
- docs/models/getpinrequest.md - docs/models/getpinrequest.md
- docs/models/getpinerrors.md - docs/models/getpinerrors.md
- docs/models/getpinplexresponsebody.md
- docs/models/location.md
- docs/models/getpinresponsebody.md - docs/models/getpinresponsebody.md
- docs/models/geodata.md
- docs/models/getpinauthpincontainer.md
- docs/models/getpinresponse.md - docs/models/getpinresponse.md
- docs/models/gettokenglobals.md - docs/models/gettokenbypinidglobals.md
- docs/models/gettokenrequest.md - docs/models/gettokenbypinidrequest.md
- docs/models/gettokenerrors.md - docs/models/gettokenbypinidplexerrors.md
- docs/models/gettokenplexresponsebody.md - docs/models/gettokenbypinidplexresponsebody.md
- docs/models/gettokenlocation.md - docs/models/gettokenbypiniderrors.md
- docs/models/gettokenresponsebody.md - docs/models/gettokenbypinidresponsebody.md
- docs/models/gettokenresponse.md - docs/models/gettokenbypinidgeodata.md
- docs/models/gettokenbypinidauthpincontainer.md
- docs/models/gettokenbypinidresponse.md
- docs/models/onlytransient.md - docs/models/onlytransient.md
- docs/models/getglobalhubsrequest.md - docs/models/getglobalhubsrequest.md
- docs/models/getglobalhubserrors.md - docs/models/getglobalhubserrors.md
@@ -311,6 +452,7 @@ generatedFiles:
- docs/models/getfilehasherrors.md - docs/models/getfilehasherrors.md
- docs/models/getfilehashresponsebody.md - docs/models/getfilehashresponsebody.md
- docs/models/getfilehashresponse.md - docs/models/getfilehashresponse.md
- docs/models/getrecentlyaddedrequest.md
- docs/models/getrecentlyaddederrors.md - docs/models/getrecentlyaddederrors.md
- docs/models/getrecentlyaddedlibraryresponsebody.md - docs/models/getrecentlyaddedlibraryresponsebody.md
- docs/models/part.md - docs/models/part.md
@@ -324,32 +466,35 @@ generatedFiles:
- docs/models/getrecentlyaddedmediacontainer.md - docs/models/getrecentlyaddedmediacontainer.md
- docs/models/getrecentlyaddedresponsebody.md - docs/models/getrecentlyaddedresponsebody.md
- docs/models/getrecentlyaddedresponse.md - docs/models/getrecentlyaddedresponse.md
- docs/models/getlibrarieserrors.md - docs/models/getalllibrarieserrors.md
- docs/models/getlibrarieslibraryresponsebody.md - docs/models/getalllibrarieslibraryresponsebody.md
- docs/models/getlibrarieslocation.md - docs/models/location.md
- docs/models/getlibrariesdirectory.md - docs/models/getalllibrariesdirectory.md
- docs/models/getlibrariesmediacontainer.md - docs/models/getalllibrariesmediacontainer.md
- docs/models/getlibrariesresponsebody.md - docs/models/getalllibrariesresponsebody.md
- docs/models/getlibrariesresponse.md - docs/models/getalllibrariesresponse.md
- docs/models/includedetails.md - docs/models/includedetails.md
- docs/models/getlibraryrequest.md - docs/models/getlibrarydetailsrequest.md
- docs/models/getlibraryerrors.md - docs/models/getlibrarydetailserrors.md
- docs/models/getlibrarylibraryresponsebody.md - docs/models/getlibrarydetailslibraryresponsebody.md
- docs/models/getlibrarydirectory.md - docs/models/getlibrarydetailsdirectory.md
- docs/models/getlibraryfilter.md - docs/models/getlibrarydetailsfilter.md
- docs/models/sort.md - docs/models/sort.md
- docs/models/field.md - docs/models/field.md
- docs/models/getlibrarytype.md - docs/models/getlibrarydetailstype.md
- docs/models/operator.md - docs/models/operator.md
- docs/models/fieldtype.md - docs/models/fieldtype.md
- docs/models/getlibrarymediacontainer.md - docs/models/getlibrarydetailsmediacontainer.md
- docs/models/getlibraryresponsebody.md - docs/models/getlibrarydetailsresponsebody.md
- docs/models/getlibraryresponse.md - docs/models/getlibrarydetailsresponse.md
- docs/models/deletelibraryrequest.md - docs/models/deletelibraryrequest.md
- docs/models/deletelibraryerrors.md - docs/models/deletelibraryerrors.md
- docs/models/deletelibraryresponsebody.md - docs/models/deletelibraryresponsebody.md
- docs/models/deletelibraryresponse.md - docs/models/deletelibraryresponse.md
- docs/models/tag.md - docs/models/tag.md
- docs/models/includeguids.md
- docs/models/includemeta.md
- docs/models/type.md
- docs/models/getlibraryitemsrequest.md - docs/models/getlibraryitemsrequest.md
- docs/models/getlibraryitemserrors.md - docs/models/getlibraryitemserrors.md
- docs/models/getlibraryitemslibraryresponsebody.md - docs/models/getlibraryitemslibraryresponsebody.md
@@ -365,36 +510,37 @@ generatedFiles:
- docs/models/getlibraryitemsmediacontainer.md - docs/models/getlibraryitemsmediacontainer.md
- docs/models/getlibraryitemsresponsebody.md - docs/models/getlibraryitemsresponsebody.md
- docs/models/getlibraryitemsresponse.md - docs/models/getlibraryitemsresponse.md
- docs/models/refreshlibraryrequest.md - docs/models/force.md
- docs/models/refreshlibraryerrors.md - docs/models/getrefreshlibrarymetadatarequest.md
- docs/models/refreshlibraryresponsebody.md - docs/models/getrefreshlibrarymetadataerrors.md
- docs/models/refreshlibraryresponse.md - docs/models/getrefreshlibrarymetadataresponsebody.md
- docs/models/type.md - docs/models/getrefreshlibrarymetadataresponse.md
- docs/models/searchlibraryrequest.md - docs/models/queryparamtype.md
- docs/models/searchlibraryerrors.md - docs/models/getsearchlibraryrequest.md
- docs/models/searchlibrarylibraryresponsebody.md - docs/models/getsearchlibraryerrors.md
- docs/models/searchlibrarymetadata.md - docs/models/getsearchlibrarylibraryresponsebody.md
- docs/models/searchlibrarymediacontainer.md - docs/models/getsearchlibrarymetadata.md
- docs/models/searchlibraryresponsebody.md - docs/models/getsearchlibrarymediacontainer.md
- docs/models/searchlibraryresponse.md - docs/models/getsearchlibraryresponsebody.md
- docs/models/getmetadatarequest.md - docs/models/getsearchlibraryresponse.md
- docs/models/getmetadataerrors.md - docs/models/getmetadatabyratingkeyrequest.md
- docs/models/getmetadatalibraryresponsebody.md - docs/models/getmetadatabyratingkeyerrors.md
- docs/models/getmetadatabyratingkeylibraryresponsebody.md
- docs/models/stream.md - docs/models/stream.md
- docs/models/getmetadatapart.md - docs/models/getmetadatabyratingkeypart.md
- docs/models/getmetadatamedia.md - docs/models/getmetadatabyratingkeymedia.md
- docs/models/getmetadatagenre.md - docs/models/getmetadatabyratingkeygenre.md
- docs/models/getmetadatacountry.md - docs/models/getmetadatabyratingkeycountry.md
- docs/models/guids.md - docs/models/guids.md
- docs/models/ratings.md - docs/models/ratings.md
- docs/models/getmetadatadirector.md - docs/models/getmetadatabyratingkeydirector.md
- docs/models/getmetadatawriter.md - docs/models/getmetadatabyratingkeywriter.md
- docs/models/getmetadatarole.md - docs/models/getmetadatabyratingkeyrole.md
- docs/models/producer.md - docs/models/producer.md
- docs/models/getmetadatametadata.md - docs/models/getmetadatabyratingkeymetadata.md
- docs/models/getmetadatamediacontainer.md - docs/models/getmetadatabyratingkeymediacontainer.md
- docs/models/getmetadataresponsebody.md - docs/models/getmetadatabyratingkeyresponsebody.md
- docs/models/getmetadataresponse.md - docs/models/getmetadatabyratingkeyresponse.md
- docs/models/getmetadatachildrenrequest.md - docs/models/getmetadatachildrenrequest.md
- docs/models/getmetadatachildrenerrors.md - docs/models/getmetadatachildrenerrors.md
- docs/models/getmetadatachildrenlibraryresponsebody.md - docs/models/getmetadatachildrenlibraryresponsebody.md
@@ -403,7 +549,10 @@ generatedFiles:
- docs/models/getmetadatachildrenmediacontainer.md - docs/models/getmetadatachildrenmediacontainer.md
- docs/models/getmetadatachildrenresponsebody.md - docs/models/getmetadatachildrenresponsebody.md
- docs/models/getmetadatachildrenresponse.md - docs/models/getmetadatachildrenresponse.md
- docs/models/gettopwatchedcontentqueryparamtype.md
- docs/models/gettopwatchedcontentrequest.md - docs/models/gettopwatchedcontentrequest.md
- docs/models/gettopwatchedcontenterrors.md
- docs/models/gettopwatchedcontentlibraryresponsebody.md
- docs/models/gettopwatchedcontentgenre.md - docs/models/gettopwatchedcontentgenre.md
- docs/models/gettopwatchedcontentcountry.md - docs/models/gettopwatchedcontentcountry.md
- docs/models/gettopwatchedcontentguids.md - docs/models/gettopwatchedcontentguids.md
@@ -423,6 +572,17 @@ generatedFiles:
- docs/models/getondeckmediacontainer.md - docs/models/getondeckmediacontainer.md
- docs/models/getondeckresponsebody.md - docs/models/getondeckresponsebody.md
- docs/models/getondeckresponse.md - docs/models/getondeckresponse.md
- docs/models/filter.md
- docs/models/libtype.md
- docs/models/includecollections.md
- docs/models/includeexternalmedia.md
- docs/models/getwatchlistrequest.md
- docs/models/getwatchlisterrors.md
- docs/models/getwatchlistwatchlistresponsebody.md
- docs/models/image.md
- docs/models/metadata.md
- docs/models/getwatchlistresponsebody.md
- docs/models/getwatchlistresponse.md
- docs/models/level.md - docs/models/level.md
- docs/models/loglinerequest.md - docs/models/loglinerequest.md
- docs/models/loglineerrors.md - docs/models/loglineerrors.md
@@ -434,7 +594,7 @@ generatedFiles:
- docs/models/enablepapertrailerrors.md - docs/models/enablepapertrailerrors.md
- docs/models/enablepapertrailresponsebody.md - docs/models/enablepapertrailresponsebody.md
- docs/models/enablepapertrailresponse.md - docs/models/enablepapertrailresponse.md
- docs/models/queryparamtype.md - docs/models/createplaylistqueryparamtype.md
- docs/models/smart.md - docs/models/smart.md
- docs/models/createplaylistrequest.md - docs/models/createplaylistrequest.md
- docs/models/createplaylisterrors.md - docs/models/createplaylisterrors.md
@@ -467,6 +627,7 @@ generatedFiles:
- docs/models/updateplaylisterrors.md - docs/models/updateplaylisterrors.md
- docs/models/updateplaylistresponsebody.md - docs/models/updateplaylistresponsebody.md
- docs/models/updateplaylistresponse.md - docs/models/updateplaylistresponse.md
- docs/models/getplaylistcontentsqueryparamtype.md
- docs/models/getplaylistcontentsrequest.md - docs/models/getplaylistcontentsrequest.md
- docs/models/getplaylistcontentserrors.md - docs/models/getplaylistcontentserrors.md
- docs/models/getplaylistcontentsplaylistsresponsebody.md - docs/models/getplaylistcontentsplaylistsresponsebody.md
@@ -492,7 +653,7 @@ generatedFiles:
- docs/models/addplaylistcontentsmediacontainer.md - docs/models/addplaylistcontentsmediacontainer.md
- docs/models/addplaylistcontentsresponsebody.md - docs/models/addplaylistcontentsresponsebody.md
- docs/models/addplaylistcontentsresponse.md - docs/models/addplaylistcontentsresponse.md
- docs/models/force.md - docs/models/queryparamforce.md
- docs/models/uploadplaylistrequest.md - docs/models/uploadplaylistrequest.md
- docs/models/uploadplaylisterrors.md - docs/models/uploadplaylisterrors.md
- docs/models/uploadplaylistresponsebody.md - docs/models/uploadplaylistresponsebody.md
@@ -507,6 +668,53 @@ generatedFiles:
- docs/models/getsourceconnectioninformationerrors.md - docs/models/getsourceconnectioninformationerrors.md
- docs/models/getsourceconnectioninformationresponsebody.md - docs/models/getsourceconnectioninformationresponsebody.md
- docs/models/getsourceconnectioninformationresponse.md - docs/models/getsourceconnectioninformationresponse.md
- docs/models/getuserdetailsrequest.md
- docs/models/getuserdetailserrors.md
- docs/models/getuserdetailsresponsebody.md
- docs/models/mailingliststatus.md
- docs/models/autoselectsubtitle.md
- docs/models/defaultsubtitleaccessibility.md
- docs/models/defaultsubtitleforced.md
- docs/models/watchedindicator.md
- docs/models/mediareviewsvisibility.md
- docs/models/userprofile.md
- docs/models/getuserdetailsstatus.md
- docs/models/services.md
- docs/models/features.md
- docs/models/getuserdetailsauthenticationstatus.md
- docs/models/subscription.md
- docs/models/getuserdetailsfeatures.md
- docs/models/getuserdetailsauthenticationresponsestatus.md
- docs/models/getuserdetailssubscription.md
- docs/models/getuserdetailsuserplexaccount.md
- docs/models/getuserdetailsresponse.md
- docs/models/postuserssignindataglobals.md
- docs/models/postuserssignindatarequestbody.md
- docs/models/postuserssignindatarequest.md
- docs/models/postuserssignindataerrors.md
- docs/models/postuserssignindataresponsebody.md
- docs/models/postuserssignindatamailingliststatus.md
- docs/models/postuserssignindataautoselectsubtitle.md
- docs/models/postuserssignindatadefaultsubtitleaccessibility.md
- docs/models/postuserssignindatadefaultsubtitleforced.md
- docs/models/postuserssignindatawatchedindicator.md
- docs/models/postuserssignindatamediareviewsvisibility.md
- docs/models/postuserssignindatauserprofile.md
- docs/models/postuserssignindatastatus.md
- docs/models/postuserssignindataservices.md
- docs/models/postuserssignindatafeatures.md
- docs/models/postuserssignindataauthenticationstatus.md
- docs/models/postuserssignindatasubscription.md
- docs/models/postuserssignindataauthenticationfeatures.md
- docs/models/postuserssignindataauthenticationresponsestatus.md
- docs/models/postuserssignindataauthenticationsubscription.md
- docs/models/postuserssignindatastate.md
- docs/models/internalpaymentmethod.md
- docs/models/billing.md
- docs/models/pastsubscription.md
- docs/models/trials.md
- docs/models/postuserssignindatauserplexaccount.md
- docs/models/postuserssignindataresponse.md
- docs/models/getstatisticsrequest.md - docs/models/getstatisticsrequest.md
- docs/models/getstatisticserrors.md - docs/models/getstatisticserrors.md
- docs/models/getstatisticsstatisticsresponsebody.md - docs/models/getstatisticsstatisticsresponsebody.md
@@ -544,7 +752,7 @@ generatedFiles:
- docs/models/getsessionsmediacontainer.md - docs/models/getsessionsmediacontainer.md
- docs/models/getsessionsresponsebody.md - docs/models/getsessionsresponsebody.md
- docs/models/getsessionsresponse.md - docs/models/getsessionsresponse.md
- docs/models/filter.md - docs/models/queryparamfilter.md
- docs/models/getsessionhistoryrequest.md - docs/models/getsessionhistoryrequest.md
- docs/models/getsessionhistoryerrors.md - docs/models/getsessionhistoryerrors.md
- docs/models/getsessionhistorysessionsresponsebody.md - docs/models/getsessionhistorysessionsresponsebody.md
@@ -579,19 +787,9 @@ generatedFiles:
- docs/models/applyupdateserrors.md - docs/models/applyupdateserrors.md
- docs/models/applyupdatesresponsebody.md - docs/models/applyupdatesresponsebody.md
- docs/models/applyupdatesresponse.md - docs/models/applyupdatesresponse.md
- docs/models/pathparamfilter.md
- docs/models/libtype.md
- docs/models/includecollections.md
- docs/models/includeexternalmedia.md
- docs/models/getwatchlistrequest.md
- docs/models/getwatchlisterrors.md
- docs/models/getwatchlistwatchlistresponsebody.md
- docs/models/image.md
- docs/models/metadata.md
- docs/models/getwatchlistresponsebody.md
- docs/models/getwatchlistresponse.md
- docs/models/security.md - docs/models/security.md
- docs/sdks/plexapi/README.md - docs/sdks/plexapi/README.md
- docs/lib/utils/retryconfig.md
- docs/sdks/server/README.md - docs/sdks/server/README.md
- docs/sdks/media/README.md - docs/sdks/media/README.md
- docs/sdks/video/README.md - docs/sdks/video/README.md
@@ -601,15 +799,16 @@ generatedFiles:
- docs/sdks/hubs/README.md - docs/sdks/hubs/README.md
- docs/sdks/search/README.md - docs/sdks/search/README.md
- docs/sdks/library/README.md - docs/sdks/library/README.md
- docs/sdks/watchlist/README.md
- docs/sdks/log/README.md - docs/sdks/log/README.md
- docs/sdks/playlists/README.md - docs/sdks/playlists/README.md
- docs/sdks/authentication/README.md - docs/sdks/authentication/README.md
- docs/sdks/statistics/README.md - docs/sdks/statistics/README.md
- docs/sdks/sessions/README.md - docs/sdks/sessions/README.md
- docs/sdks/updater/README.md - docs/sdks/updater/README.md
- docs/sdks/watchlist/README.md
- USAGE.md - USAGE.md
- .gitattributes - .gitattributes
- src/hooks/hooks.ts - src/hooks/hooks.ts
- src/hooks/types.ts - src/hooks/types.ts
- src/hooks/index.ts - src/hooks/index.ts
- CONTRIBUTING.md

View File

@@ -12,7 +12,7 @@ generation:
auth: auth:
oAuth2ClientCredentialsEnabled: true oAuth2ClientCredentialsEnabled: true
typescript: typescript:
version: 0.18.1 version: 0.20.0
additionalDependencies: additionalDependencies:
dependencies: {} dependencies: {}
devDependencies: {} devDependencies: {}
@@ -33,6 +33,7 @@ typescript:
inputModelSuffix: input inputModelSuffix: input
maxMethodParams: 4 maxMethodParams: 4
methodArguments: require-security-and-request methodArguments: require-security-and-request
moduleFormat: commonjs
outputModelSuffix: output outputModelSuffix: output
packageName: '@lukehagar/plexjs' packageName: '@lukehagar/plexjs'
responseFormat: envelope responseFormat: envelope

View File

@@ -1,9 +1,9 @@
speakeasyVersion: 1.323.0 speakeasyVersion: 1.390.7
sources: sources:
my-source: my-source:
sourceNamespace: my-source sourceNamespace: my-source
sourceRevisionDigest: sha256:0e26af4bb9b5be12ffae3b400ee850d3b01e316f5b63346bc24f5173f8f17609 sourceRevisionDigest: sha256:fff67c8d70fdb1711caf3e9c61cdc91a4c88ac98b3419c1d287db6ca95c7278b
sourceBlobDigest: sha256:879ee990da6c37e0b2972ef14220e0ce5db709dc39390ef8c2c24d3f4bba8b13 sourceBlobDigest: sha256:235067aeeeba40f6a4b062d9b9e6816a6e1282023f9664b46cbc1af6495b4c53
tags: tags:
- latest - latest
- main - main
@@ -11,10 +11,10 @@ targets:
plexjs: plexjs:
source: my-source source: my-source
sourceNamespace: my-source sourceNamespace: my-source
sourceRevisionDigest: sha256:0e26af4bb9b5be12ffae3b400ee850d3b01e316f5b63346bc24f5173f8f17609 sourceRevisionDigest: sha256:fff67c8d70fdb1711caf3e9c61cdc91a4c88ac98b3419c1d287db6ca95c7278b
sourceBlobDigest: sha256:879ee990da6c37e0b2972ef14220e0ce5db709dc39390ef8c2c24d3f4bba8b13 sourceBlobDigest: sha256:235067aeeeba40f6a4b062d9b9e6816a6e1282023f9664b46cbc1af6495b4c53
codeSamplesNamespace: code-samples-typescript-plexjs codeSamplesNamespace: code-samples-typescript-plexjs
codeSamplesRevisionDigest: sha256:a9631d3ae79a06641a20d5334a699ffa86a70ae2e64f326d280e285e21258893 codeSamplesRevisionDigest: sha256:18919b4d52e4482e8771f2e3657d74cae7f332e481471d177e5b248a9ffc99bd
outLocation: /github/workspace/repo outLocation: /github/workspace/repo
workflow: workflow:
workflowVersion: 1.0.0 workflowVersion: 1.0.0

26
CONTRIBUTING.md Normal file
View File

@@ -0,0 +1,26 @@
# Contributing to This Repository
Thank you for your interest in contributing to this repository. Please note that this repository contains generated code. As such, we do not accept direct changes or pull requests. Instead, we encourage you to follow the guidelines below to report issues and suggest improvements.
## How to Report Issues
If you encounter any bugs or have suggestions for improvements, please open an issue on GitHub. When reporting an issue, please provide as much detail as possible to help us reproduce the problem. This includes:
- A clear and descriptive title
- Steps to reproduce the issue
- Expected and actual behavior
- Any relevant logs, screenshots, or error messages
- Information about your environment (e.g., operating system, software versions)
- For example can be collected using the `npx envinfo` command from your terminal if you have Node.js installed
## Issue Triage and Upstream Fixes
We will review and triage issues as quickly as possible. Our goal is to address bugs and incorporate improvements in the upstream source code. Fixes will be included in the next generation of the generated code.
## Contact
If you have any questions or need further assistance, please feel free to reach out by opening an issue.
Thank you for your understanding and cooperation!
The Maintainers

105
FUNCTIONS.md Normal file
View File

@@ -0,0 +1,105 @@
# Standalone Functions
> [!NOTE]
> This section is useful if you are using a bundler and targetting browsers and
> runtimes where the size of an application affects performance and load times.
Every method in this SDK is also available as a standalone function. This
alternative API is suitable when targetting the browser or serverless runtimes
and using a bundler to build your application since all unused functionality
will be tree-shaken away. This includes code for unused methods, Zod schemas,
encoding helpers and response handlers. The result is dramatically smaller
impact on the application's final bundle size which grows very slowly as you use
more and more functionality from this SDK.
Calling methods through the main SDK class remains a valid and generally more
more ergonomic option. Standalone functions represent an optimisation for a
specific category of applications.
## Example
```typescript
import { PlexAPICore } from "@lukehagar/plexjs/core.js";
import { serverGetServerCapabilities } from "@lukehagar/plexjs/funcs/serverGetServerCapabilities.js";
import { SDKValidationError } from "@lukehagar/plexjs/models/sdkvalidationerror.js";
// Use `PlexAPICore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const plexAPI = new PlexAPICore({
accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
});
async function run() {
const res = await serverGetServerCapabilities(plexAPI);
switch (true) {
case res.ok:
// The success case will be handled outside of the switch block
break;
case res.error instanceof SDKValidationError:
// Pretty-print validation errors.
return console.log(res.error.pretty());
case res.error instanceof Error:
return console.log(res.error);
default:
// TypeScript's type checking will fail on the following line if the above
// cases were not exhaustive.
res.error satisfies never;
throw new Error("Assertion failed: expected error checks to be exhaustive: " + res.error);
}
const { value: result } = res;
// Handle the result
console.log(result)
}
run();
```
## Result types
Standalone functions differ from SDK methods in that they return a
`Result<Value, Error>` type to capture _known errors_ and document them using
the type system. By avoiding throwing errors, application code maintains clear
control flow and error-handling become part of the regular flow of application
code.
> We use the term "known errors" because standalone functions, and JavaScript
> code in general, can still throw unexpected errors such as `TypeError`s,
> `RangeError`s and `DOMException`s. Exhaustively catching all errors may be
> something this SDK addresses in the future. Nevertheless, there is still a lot
> of benefit from capturing most errors and turning them into values.
The second reason for this style of programming is because these functions will
typically be used in front-end applications where exception throwing is
sometimes discouraged or considered unidiomatic. React and similar ecosystems
and libraries tend to promote this style of programming so that components
render useful content under all states (loading, success, error and so on).
The general pattern when calling standalone functions looks like this:
```typescript
import { Core } from "<sdk-package-name>";
import { fetchSomething } from "<sdk-package-name>/funcs/fetchSomething.js";
const client = new Core();
async function run() {
const result = await fetchSomething(client, { id: "123" });
if (!result.ok) {
// You can throw the error or handle it. It's your choice now.
throw result.error;
}
console.log(result.value);
}
run();
```
Notably, `result.error` above will have an explicit type compared to a try-catch
variation where the error in the catch block can only be of type `unknown` (or
`any` depending on your TypeScript settings).

276
README.md
View File

@@ -7,9 +7,34 @@
</a> </a>
</div> </div>
<!-- Start Summary [summary] -->
## Summary
Plex-API: An Open API Spec for interacting with Plex.tv and Plex Media Server
<!-- End Summary [summary] -->
<!-- Start Table of Contents [toc] -->
## Table of Contents
* [SDK Installation](#sdk-installation)
* [Requirements](#requirements)
* [SDK Example Usage](#sdk-example-usage)
* [Available Resources and Operations](#available-resources-and-operations)
* [Standalone functions](#standalone-functions)
* [Global Parameters](#global-parameters)
* [Retries](#retries)
* [Error Handling](#error-handling)
* [Server Selection](#server-selection)
* [Custom HTTP Client](#custom-http-client)
* [Authentication](#authentication)
* [Debugging](#debugging)
<!-- End Table of Contents [toc] -->
<!-- Start SDK Installation [installation] --> <!-- Start SDK Installation [installation] -->
## SDK Installation ## SDK Installation
The SDK can be installed with either [npm](https://www.npmjs.com/), [pnpm](https://pnpm.io/), [bun](https://bun.sh/) or [yarn](https://classic.yarnpkg.com/en/) package managers.
### NPM ### NPM
```bash ```bash
@@ -48,7 +73,7 @@ import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "Postman", xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {
@@ -75,6 +100,7 @@ run();
* [getServerIdentity](docs/sdks/server/README.md#getserveridentity) - Get Server Identity * [getServerIdentity](docs/sdks/server/README.md#getserveridentity) - Get Server Identity
* [getMyPlexAccount](docs/sdks/server/README.md#getmyplexaccount) - Get MyPlex Account * [getMyPlexAccount](docs/sdks/server/README.md#getmyplexaccount) - Get MyPlex Account
* [getResizedPhoto](docs/sdks/server/README.md#getresizedphoto) - Get a Resized Photo * [getResizedPhoto](docs/sdks/server/README.md#getresizedphoto) - Get a Resized Photo
* [getMediaProviders](docs/sdks/server/README.md#getmediaproviders) - Get Media Providers
* [getServerList](docs/sdks/server/README.md#getserverlist) - Get Server List * [getServerList](docs/sdks/server/README.md#getserverlist) - Get Server List
### [media](docs/sdks/media/README.md) ### [media](docs/sdks/media/README.md)
@@ -82,6 +108,8 @@ run();
* [markPlayed](docs/sdks/media/README.md#markplayed) - Mark Media Played * [markPlayed](docs/sdks/media/README.md#markplayed) - Mark Media Played
* [markUnplayed](docs/sdks/media/README.md#markunplayed) - Mark Media Unplayed * [markUnplayed](docs/sdks/media/README.md#markunplayed) - Mark Media Unplayed
* [updatePlayProgress](docs/sdks/media/README.md#updateplayprogress) - Update Media Play Progress * [updatePlayProgress](docs/sdks/media/README.md#updateplayprogress) - Update Media Play Progress
* [getBannerImage](docs/sdks/media/README.md#getbannerimage) - Get Banner Image
* [getThumbImage](docs/sdks/media/README.md#getthumbimage) - Get Thumb Image
### [video](docs/sdks/video/README.md) ### [video](docs/sdks/video/README.md)
@@ -103,9 +131,13 @@ run();
### [plex](docs/sdks/plex/README.md) ### [plex](docs/sdks/plex/README.md)
* [getCompanionsData](docs/sdks/plex/README.md#getcompanionsdata) - Get Companions Data
* [getUserFriends](docs/sdks/plex/README.md#getuserfriends) - Get list of friends of the user logged in
* [getGeoData](docs/sdks/plex/README.md#getgeodata) - Get Geo Data
* [getHomeData](docs/sdks/plex/README.md#gethomedata) - Get Plex Home Data * [getHomeData](docs/sdks/plex/README.md#gethomedata) - Get Plex Home Data
* [getServerResources](docs/sdks/plex/README.md#getserverresources) - Get Server Resources
* [getPin](docs/sdks/plex/README.md#getpin) - Get a Pin * [getPin](docs/sdks/plex/README.md#getpin) - Get a Pin
* [getToken](docs/sdks/plex/README.md#gettoken) - Get Access Token * [getTokenByPinId](docs/sdks/plex/README.md#gettokenbypinid) - Get Access Token by PinId
### [hubs](docs/sdks/hubs/README.md) ### [hubs](docs/sdks/hubs/README.md)
@@ -122,17 +154,21 @@ run();
* [getFileHash](docs/sdks/library/README.md#getfilehash) - Get Hash Value * [getFileHash](docs/sdks/library/README.md#getfilehash) - Get Hash Value
* [getRecentlyAdded](docs/sdks/library/README.md#getrecentlyadded) - Get Recently Added * [getRecentlyAdded](docs/sdks/library/README.md#getrecentlyadded) - Get Recently Added
* [getLibraries](docs/sdks/library/README.md#getlibraries) - Get All Libraries * [getAllLibraries](docs/sdks/library/README.md#getalllibraries) - Get All Libraries
* [getLibrary](docs/sdks/library/README.md#getlibrary) - Get Library Details * [getLibraryDetails](docs/sdks/library/README.md#getlibrarydetails) - Get Library Details
* [deleteLibrary](docs/sdks/library/README.md#deletelibrary) - Delete Library Section * [deleteLibrary](docs/sdks/library/README.md#deletelibrary) - Delete Library Section
* [getLibraryItems](docs/sdks/library/README.md#getlibraryitems) - Get Library Items * [getLibraryItems](docs/sdks/library/README.md#getlibraryitems) - Get Library Items
* [refreshLibrary](docs/sdks/library/README.md#refreshlibrary) - Refresh Library * [getRefreshLibraryMetadata](docs/sdks/library/README.md#getrefreshlibrarymetadata) - Refresh Metadata Of The Library
* [searchLibrary](docs/sdks/library/README.md#searchlibrary) - Search Library * [getSearchLibrary](docs/sdks/library/README.md#getsearchlibrary) - Search Library
* [getMetadata](docs/sdks/library/README.md#getmetadata) - Get Items Metadata * [getMetaDataByRatingKey](docs/sdks/library/README.md#getmetadatabyratingkey) - Get Metadata by RatingKey
* [getMetadataChildren](docs/sdks/library/README.md#getmetadatachildren) - Get Items Children * [getMetadataChildren](docs/sdks/library/README.md#getmetadatachildren) - Get Items Children
* [getTopWatchedContent](docs/sdks/library/README.md#gettopwatchedcontent) - Get Top Watched Content * [getTopWatchedContent](docs/sdks/library/README.md#gettopwatchedcontent) - Get Top Watched Content
* [getOnDeck](docs/sdks/library/README.md#getondeck) - Get On Deck * [getOnDeck](docs/sdks/library/README.md#getondeck) - Get On Deck
### [watchlist](docs/sdks/watchlist/README.md)
* [getWatchList](docs/sdks/watchlist/README.md#getwatchlist) - Get User Watchlist
### [log](docs/sdks/log/README.md) ### [log](docs/sdks/log/README.md)
* [logLine](docs/sdks/log/README.md#logline) - Logging a single line message. * [logLine](docs/sdks/log/README.md#logline) - Logging a single line message.
@@ -155,6 +191,8 @@ run();
* [getTransientToken](docs/sdks/authentication/README.md#gettransienttoken) - Get a Transient Token. * [getTransientToken](docs/sdks/authentication/README.md#gettransienttoken) - Get a Transient Token.
* [getSourceConnectionInformation](docs/sdks/authentication/README.md#getsourceconnectioninformation) - Get Source Connection Information * [getSourceConnectionInformation](docs/sdks/authentication/README.md#getsourceconnectioninformation) - Get Source Connection Information
* [getUserDetails](docs/sdks/authentication/README.md#getuserdetails) - Get User Data By Token
* [postUsersSignInData](docs/sdks/authentication/README.md#postuserssignindata) - Get User SignIn Data
### [statistics](docs/sdks/statistics/README.md) ### [statistics](docs/sdks/statistics/README.md)
@@ -174,10 +212,6 @@ run();
* [getUpdateStatus](docs/sdks/updater/README.md#getupdatestatus) - Querying status of updates * [getUpdateStatus](docs/sdks/updater/README.md#getupdatestatus) - Querying status of updates
* [checkForUpdates](docs/sdks/updater/README.md#checkforupdates) - Checking for updates * [checkForUpdates](docs/sdks/updater/README.md#checkforupdates) - Checking for updates
* [applyUpdates](docs/sdks/updater/README.md#applyupdates) - Apply Updates * [applyUpdates](docs/sdks/updater/README.md#applyupdates) - Apply Updates
### [watchlist](docs/sdks/watchlist/README.md)
* [getWatchlist](docs/sdks/watchlist/README.md#getwatchlist) - Get User Watchlist
<!-- End Available Resources and Operations [operations] --> <!-- End Available Resources and Operations [operations] -->
<!-- Start Error Handling [errors] --> <!-- Start Error Handling [errors] -->
@@ -194,18 +228,21 @@ Validation errors can also occur when either method arguments or data returned f
```typescript ```typescript
import { PlexAPI } from "@lukehagar/plexjs"; import { GetServerCapabilitiesServerResponseBody, PlexAPI } from "@lukehagar/plexjs";
import { SDKValidationError } from "@lukehagar/plexjs/models"; import { SDKValidationError } from "@lukehagar/plexjs/models";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "Postman", xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {
let result; let result;
try { try {
result = await plexAPI.server.getServerCapabilities(); result = await plexAPI.server.getServerCapabilities();
// Handle the result
console.log(result);
} catch (err) { } catch (err) {
switch (true) { switch (true) {
case err instanceof SDKValidationError: { case err instanceof SDKValidationError: {
@@ -215,8 +252,9 @@ async function run() {
console.error(err.rawValue); console.error(err.rawValue);
return; return;
} }
case err instanceof models.GetServerCapabilitiesServerResponseBody: { case err instanceof GetServerCapabilitiesServerResponseBody: {
console.error(err); // handle exception // Handle err.data$: GetServerCapabilitiesServerResponseBodyData
console.error(err);
return; return;
} }
default: { default: {
@@ -224,9 +262,6 @@ async function run() {
} }
} }
} }
// Handle the result
console.log(result);
} }
run(); run();
@@ -243,7 +278,7 @@ You can override the default server globally by passing a server index to the `s
| # | Server | Variables | | # | Server | Variables |
| - | ------ | --------- | | - | ------ | --------- |
| 0 | `{protocol}://{ip}:{port}` | `protocol` (default is `http`), `ip` (default is `10.10.10.47`), `port` (default is `32400`) | | 0 | `{protocol}://{ip}:{port}` | `protocol` (default is `https`), `ip` (default is `10.10.10.47`), `port` (default is `32400`) |
```typescript ```typescript
import { PlexAPI } from "@lukehagar/plexjs"; import { PlexAPI } from "@lukehagar/plexjs";
@@ -251,7 +286,7 @@ import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
serverIdx: 0, serverIdx: 0,
accessToken: "<YOUR_API_KEY_HERE>", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "Postman", xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {
@@ -282,7 +317,7 @@ import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
serverURL: "{protocol}://{ip}:{port}", serverURL: "{protocol}://{ip}:{port}",
accessToken: "<YOUR_API_KEY_HERE>", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "Postman", xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {
@@ -303,11 +338,12 @@ The server URL can also be overridden on a per-operation basis, provided a serve
import { PlexAPI } from "@lukehagar/plexjs"; import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
xPlexClientIdentifier: "Postman", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {
const result = await plexAPI.plex.getPin("Postman", false, "Postman", { const result = await plexAPI.plex.getCompanionsData({
serverURL: "https://plex.tv/api/v2", serverURL: "https://plex.tv/api/v2",
}); });
@@ -386,7 +422,7 @@ import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "Postman", xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {
@@ -407,12 +443,106 @@ run();
For supported JavaScript runtimes, please consult [RUNTIMES.md](RUNTIMES.md). For supported JavaScript runtimes, please consult [RUNTIMES.md](RUNTIMES.md).
<!-- End Requirements [requirements] --> <!-- End Requirements [requirements] -->
<!-- Start Standalone functions [standalone-funcs] -->
## Standalone functions
All the methods listed above are available as standalone functions. These
functions are ideal for use in applications running in the browser, serverless
runtimes or other environments where application bundle size is a primary
concern. When using a bundler to build your application, all unused
functionality will be either excluded from the final bundle or tree-shaken away.
To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
<details>
<summary>Available standalone functions</summary>
- [activitiesCancelServerActivities](docs/sdks/activities/README.md#cancelserveractivities)
- [activitiesGetServerActivities](docs/sdks/activities/README.md#getserveractivities)
- [authenticationGetSourceConnectionInformation](docs/sdks/authentication/README.md#getsourceconnectioninformation)
- [authenticationGetTransientToken](docs/sdks/authentication/README.md#gettransienttoken)
- [authenticationGetUserDetails](docs/sdks/authentication/README.md#getuserdetails)
- [authenticationPostUsersSignInData](docs/sdks/authentication/README.md#postuserssignindata)
- [butlerGetButlerTasks](docs/sdks/butler/README.md#getbutlertasks)
- [butlerStartAllTasks](docs/sdks/butler/README.md#startalltasks)
- [butlerStartTask](docs/sdks/butler/README.md#starttask)
- [butlerStopAllTasks](docs/sdks/butler/README.md#stopalltasks)
- [butlerStopTask](docs/sdks/butler/README.md#stoptask)
- [hubsGetGlobalHubs](docs/sdks/hubs/README.md#getglobalhubs)
- [hubsGetLibraryHubs](docs/sdks/hubs/README.md#getlibraryhubs)
- [libraryDeleteLibrary](docs/sdks/library/README.md#deletelibrary)
- [libraryGetAllLibraries](docs/sdks/library/README.md#getalllibraries)
- [libraryGetFileHash](docs/sdks/library/README.md#getfilehash)
- [libraryGetLibraryDetails](docs/sdks/library/README.md#getlibrarydetails)
- [libraryGetLibraryItems](docs/sdks/library/README.md#getlibraryitems)
- [libraryGetMetaDataByRatingKey](docs/sdks/library/README.md#getmetadatabyratingkey)
- [libraryGetMetadataChildren](docs/sdks/library/README.md#getmetadatachildren)
- [libraryGetOnDeck](docs/sdks/library/README.md#getondeck)
- [libraryGetRecentlyAdded](docs/sdks/library/README.md#getrecentlyadded)
- [libraryGetRefreshLibraryMetadata](docs/sdks/library/README.md#getrefreshlibrarymetadata)
- [libraryGetSearchLibrary](docs/sdks/library/README.md#getsearchlibrary)
- [libraryGetTopWatchedContent](docs/sdks/library/README.md#gettopwatchedcontent)
- [logEnablePaperTrail](docs/sdks/log/README.md#enablepapertrail)
- [logLogLine](docs/sdks/log/README.md#logline)
- [logLogMultiLine](docs/sdks/log/README.md#logmultiline)
- [mediaGetBannerImage](docs/sdks/media/README.md#getbannerimage)
- [mediaGetThumbImage](docs/sdks/media/README.md#getthumbimage)
- [mediaMarkPlayed](docs/sdks/media/README.md#markplayed)
- [mediaMarkUnplayed](docs/sdks/media/README.md#markunplayed)
- [mediaUpdatePlayProgress](docs/sdks/media/README.md#updateplayprogress)
- [playlistsAddPlaylistContents](docs/sdks/playlists/README.md#addplaylistcontents)
- [playlistsClearPlaylistContents](docs/sdks/playlists/README.md#clearplaylistcontents)
- [playlistsCreatePlaylist](docs/sdks/playlists/README.md#createplaylist)
- [playlistsDeletePlaylist](docs/sdks/playlists/README.md#deleteplaylist)
- [playlistsGetPlaylistContents](docs/sdks/playlists/README.md#getplaylistcontents)
- [playlistsGetPlaylist](docs/sdks/playlists/README.md#getplaylist)
- [playlistsGetPlaylists](docs/sdks/playlists/README.md#getplaylists)
- [playlistsUpdatePlaylist](docs/sdks/playlists/README.md#updateplaylist)
- [playlistsUploadPlaylist](docs/sdks/playlists/README.md#uploadplaylist)
- [plexGetCompanionsData](docs/sdks/plex/README.md#getcompanionsdata)
- [plexGetGeoData](docs/sdks/plex/README.md#getgeodata)
- [plexGetHomeData](docs/sdks/plex/README.md#gethomedata)
- [plexGetPin](docs/sdks/plex/README.md#getpin)
- [plexGetServerResources](docs/sdks/plex/README.md#getserverresources)
- [plexGetTokenByPinId](docs/sdks/plex/README.md#gettokenbypinid)
- [plexGetUserFriends](docs/sdks/plex/README.md#getuserfriends)
- [searchGetSearchResults](docs/sdks/search/README.md#getsearchresults)
- [searchPerformSearch](docs/sdks/search/README.md#performsearch)
- [searchPerformVoiceSearch](docs/sdks/search/README.md#performvoicesearch)
- [serverGetAvailableClients](docs/sdks/server/README.md#getavailableclients)
- [serverGetDevices](docs/sdks/server/README.md#getdevices)
- [serverGetMediaProviders](docs/sdks/server/README.md#getmediaproviders)
- [serverGetMyPlexAccount](docs/sdks/server/README.md#getmyplexaccount)
- [serverGetResizedPhoto](docs/sdks/server/README.md#getresizedphoto)
- [serverGetServerCapabilities](docs/sdks/server/README.md#getservercapabilities)
- [serverGetServerIdentity](docs/sdks/server/README.md#getserveridentity)
- [serverGetServerList](docs/sdks/server/README.md#getserverlist)
- [serverGetServerPreferences](docs/sdks/server/README.md#getserverpreferences)
- [sessionsGetSessionHistory](docs/sdks/sessions/README.md#getsessionhistory)
- [sessionsGetSessions](docs/sdks/sessions/README.md#getsessions)
- [sessionsGetTranscodeSessions](docs/sdks/sessions/README.md#gettranscodesessions)
- [sessionsStopTranscodeSession](docs/sdks/sessions/README.md#stoptranscodesession)
- [statisticsGetBandwidthStatistics](docs/sdks/statistics/README.md#getbandwidthstatistics)
- [statisticsGetResourcesStatistics](docs/sdks/statistics/README.md#getresourcesstatistics)
- [statisticsGetStatistics](docs/sdks/statistics/README.md#getstatistics)
- [updaterApplyUpdates](docs/sdks/updater/README.md#applyupdates)
- [updaterCheckForUpdates](docs/sdks/updater/README.md#checkforupdates)
- [updaterGetUpdateStatus](docs/sdks/updater/README.md#getupdatestatus)
- [videoGetTimeline](docs/sdks/video/README.md#gettimeline)
- [videoStartUniversalTranscode](docs/sdks/video/README.md#startuniversaltranscode)
- [watchlistGetWatchList](docs/sdks/watchlist/README.md#getwatchlist)
</details>
<!-- End Standalone functions [standalone-funcs] -->
<!-- Start Global Parameters [global-parameters] --> <!-- Start Global Parameters [global-parameters] -->
## Global Parameters ## Global Parameters
A parameter is configured globally. This parameter may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, This global value will be used as the default on the operations that use it. When such operations are called, there is a place in each to override the global value, if needed. A parameter is configured globally. This parameter may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, This global value will be used as the default on the operations that use it. When such operations are called, there is a place in each to override the global value, if needed.
For example, you can set `X-Plex-Client-Identifier` to `"Postman"` at SDK initialization and then you do not have to pass the same value on calls to operations like `getPin`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration. For example, you can set `X-Plex-Client-Identifier` to `"gcgzw5rz2xovp84b4vha3a40"` at SDK initialization and then you do not have to pass the same value on calls to operations like `getServerResources`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.
### Available Globals ### Available Globals
@@ -430,14 +560,20 @@ This is used to track the client application and its usage
### Example ### Example
```typescript ```typescript
import { PlexAPI } from "@lukehagar/plexjs"; import { IncludeHttps, IncludeIPv6, IncludeRelay, PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
xPlexClientIdentifier: "Postman", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {
const result = await plexAPI.plex.getPin("Postman", false, "Postman"); const result = await plexAPI.plex.getServerResources({
xPlexToken: "CV5xoxjTpFKUzBTShsaf",
includeHttps: IncludeHttps.One,
includeRelay: IncludeRelay.One,
includeIPv6: IncludeIPv6.One,
});
// Handle the result // Handle the result
console.log(result); console.log(result);
@@ -448,6 +584,90 @@ run();
``` ```
<!-- End Global Parameters [global-parameters] --> <!-- End Global Parameters [global-parameters] -->
<!-- Start Retries [retries] -->
## Retries
Some of the endpoints in this SDK support retries. If you use the SDK without any configuration, it will fall back to the default retry strategy provided by the API. However, the default retry strategy can be overridden on a per-operation basis, or across the entire SDK.
To change the default retry strategy for a single API call, simply provide a retryConfig object to the call:
```typescript
import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
});
async function run() {
const result = await plexAPI.server.getServerCapabilities({
retries: {
strategy: "backoff",
backoff: {
initialInterval: 1,
maxInterval: 50,
exponent: 1.1,
maxElapsedTime: 100,
},
retryConnectionErrors: false,
},
});
// Handle the result
console.log(result);
}
run();
```
If you'd like to override the default retry strategy for all operations that support retries, you can provide a retryConfig at SDK initialization:
```typescript
import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({
retryConfig: {
strategy: "backoff",
backoff: {
initialInterval: 1,
maxInterval: 50,
exponent: 1.1,
maxElapsedTime: 100,
},
retryConnectionErrors: false,
},
accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
});
async function run() {
const result = await plexAPI.server.getServerCapabilities();
// Handle the result
console.log(result);
}
run();
```
<!-- End Retries [retries] -->
<!-- Start Debugging [debug] -->
## Debugging
You can setup your SDK to emit debug logs for SDK requests and responses.
You can pass a logger that matches `console`'s interface as an SDK option.
> [!WARNING]
> Beware that debug logging will reveal secrets, like API tokens in headers, in log messages printed to a console or files. It's recommended to use this feature only during local development and not in production.
```typescript
import { PlexAPI } from "@lukehagar/plexjs";
const sdk = new PlexAPI({ debugLogger: console });
```
<!-- End Debugging [debug] -->
<!-- Placeholder for Future Speakeasy SDK Sections --> <!-- Placeholder for Future Speakeasy SDK Sections -->
# Development # Development

View File

@@ -919,3 +919,33 @@ Based on:
- [typescript v0.18.1] . - [typescript v0.18.1] .
### Releases ### Releases
- [NPM v0.18.1] https://www.npmjs.com/package/@lukehagar/plexjs/v/0.18.1 - . - [NPM v0.18.1] https://www.npmjs.com/package/@lukehagar/plexjs/v/0.18.1 - .
## 2024-07-01 16:23:41
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.323.0 (2.356.0) https://github.com/speakeasy-api/speakeasy
### Generated
- [typescript v0.18.2] .
### Releases
- [NPM v0.18.2] https://www.npmjs.com/package/@lukehagar/plexjs/v/0.18.2 - .
## 2024-08-22 05:15:43
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.377.1 (2.404.1) https://github.com/speakeasy-api/speakeasy
### Generated
- [typescript v0.19.0] .
### Releases
- [NPM v0.19.0] https://www.npmjs.com/package/@lukehagar/plexjs/v/0.19.0 - .
## 2024-09-06 00:01:07
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.390.7 (2.409.8) https://github.com/speakeasy-api/speakeasy
### Generated
- [typescript v0.20.0] .
### Releases
- [NPM v0.20.0] https://www.npmjs.com/package/@lukehagar/plexjs/v/0.20.0 - .

View File

@@ -3,7 +3,7 @@
This SDK is intended to be used in JavaScript runtimes that support the following features: This SDK is intended to be used in JavaScript runtimes that support the following features:
* [Web Fetch API][web-fetch] * [Web Fetch API][web-fetch]
* [Web Streams API](web-streams) and in particular `ReadableStream` * [Web Streams API][web-streams] and in particular `ReadableStream`
* [Async iterables][async-iter] using `Symbol.asyncIterator` * [Async iterables][async-iter] using `Symbol.asyncIterator`
[web-fetch]: https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API [web-fetch]: https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API

View File

@@ -4,7 +4,7 @@ import { PlexAPI } from "@lukehagar/plexjs";
const plexAPI = new PlexAPI({ const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>", accessToken: "<YOUR_API_KEY_HERE>",
xPlexClientIdentifier: "Postman", xPlexClientIdentifier: "gcgzw5rz2xovp84b4vha3a40",
}); });
async function run() { async function run() {

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,24 @@
# RetryConfig
Allows customizing the default retry configuration. It is only permitted in methods that accept retry policies.
## Fields
| Name | Type | Description | Example |
| ------------------------- | ----------------------------------- | ------------------------------------------------------------------------------------------ | ----------- |
| `strategy` | `"backoff" | "none"` | The retry strategy to use. | `"backoff"` |
| `backoff` | [BackoffStrategy](#backoffstrategy) | When strategy is "backoff", this configurates for the backoff parameters. | |
| `retryConnectionErrors` | `*boolean*` | When strategy is "backoff", this determines whether or not to retry on connection errors. | `true` |
## BackoffStrategy
The backoff strategy allows retrying a request with an exponential backoff between each retry.
### Fields
| Name | Type | Description | Example |
| ------------------ | ------------ | ----------------------------------------- | -------- |
| `initialInterval` | `*number*` | The initial interval in milliseconds. | `500` |
| `maxInterval` | `*number*` | The maximum interval in milliseconds. | `60000` |
| `exponent` | `*number*` | The exponent to use for the backoff. | `1.5` |
| `maxElapsedTime` | `*number*` | The maximum elapsed time in milliseconds. | `300000` |

View File

@@ -1,5 +1,21 @@
# Account # Account
## Example Usage
```typescript
import { Account } from "@lukehagar/plexjs";
let value: Account = {
id: 238960586,
key: "/accounts/238960586",
name: "Diane",
defaultAudioLanguage: "en",
autoSelectAudio: true,
defaultSubtitleLanguage: "en",
subtitleMode: 1,
thumb: "https://plex.tv/users/50d83634246da1de/avatar?c=1707110967",
};
```
## Fields ## Fields

View File

@@ -1,5 +1,12 @@
# Activity # Activity
## Example Usage
```typescript
import { Activity } from "@lukehagar/plexjs";
let value: Activity = {};
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# AddPlaylistContentsErrors # AddPlaylistContentsErrors
## Example Usage
```typescript
import { AddPlaylistContentsErrors } from "@lukehagar/plexjs";
let value: AddPlaylistContentsErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,33 @@
# AddPlaylistContentsMediaContainer # AddPlaylistContentsMediaContainer
## Example Usage
```typescript
import { AddPlaylistContentsMediaContainer } from "@lukehagar/plexjs";
let value: AddPlaylistContentsMediaContainer = {
size: 1,
leafCountAdded: 1,
leafCountRequested: 1,
metadata: [
{
ratingKey: "94",
key: "/playlists/94/items",
guid: "com.plexapp.agents.none://972e3047-83d6-4848-a000-261f0af26ba2",
type: "playlist",
title: "A great playlist",
summary: "One of my great playlists",
smart: false,
playlistType: "video",
composite: "/playlists/94/composite/1705800070",
duration: 423000,
leafCount: 3,
addedAt: 1705716458,
updatedAt: 1705800070,
},
],
};
```
## Fields ## Fields

View File

@@ -1,5 +1,26 @@
# AddPlaylistContentsMetadata # AddPlaylistContentsMetadata
## Example Usage
```typescript
import { AddPlaylistContentsMetadata } from "@lukehagar/plexjs";
let value: AddPlaylistContentsMetadata = {
ratingKey: "94",
key: "/playlists/94/items",
guid: "com.plexapp.agents.none://972e3047-83d6-4848-a000-261f0af26ba2",
type: "playlist",
title: "A great playlist",
summary: "One of my great playlists",
smart: false,
playlistType: "video",
composite: "/playlists/94/composite/1705800070",
duration: 423000,
leafCount: 3,
addedAt: 1705716458,
updatedAt: 1705800070,
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { AddPlaylistContentsPlaylistsResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# AddPlaylistContentsRequest # AddPlaylistContentsRequest
## Example Usage
```typescript
import { AddPlaylistContentsRequest } from "@lukehagar/plexjs";
let value: AddPlaylistContentsRequest = {
playlistID: 6625.27,
uri: "server://12345/com.plexapp.plugins.library/library/metadata/1",
playQueueID: 123,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,42 @@
# AddPlaylistContentsResponse # AddPlaylistContentsResponse
## Example Usage
```typescript
import { AddPlaylistContentsResponse } from "@lukehagar/plexjs";
let value: AddPlaylistContentsResponse = {
contentType: "<value>",
statusCode: 820994,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
object: {
mediaContainer: {
size: 1,
leafCountAdded: 1,
leafCountRequested: 1,
metadata: [
{
ratingKey: "94",
key: "/playlists/94/items",
guid: "com.plexapp.agents.none://972e3047-83d6-4848-a000-261f0af26ba2",
type: "playlist",
title: "A great playlist",
summary: "One of my great playlists",
smart: false,
playlistType: "video",
composite: "/playlists/94/composite/1705800070",
duration: 423000,
leafCount: 3,
addedAt: 1705716458,
updatedAt: 1705800070,
},
],
},
},
};
```
## Fields ## Fields

View File

@@ -2,6 +2,36 @@
Playlist Updated Playlist Updated
## Example Usage
```typescript
import { AddPlaylistContentsResponseBody } from "@lukehagar/plexjs";
let value: AddPlaylistContentsResponseBody = {
mediaContainer: {
size: 1,
leafCountAdded: 1,
leafCountRequested: 1,
metadata: [
{
ratingKey: "94",
key: "/playlists/94/items",
guid: "com.plexapp.agents.none://972e3047-83d6-4848-a000-261f0af26ba2",
type: "playlist",
title: "A great playlist",
summary: "One of my great playlists",
smart: false,
playlistType: "video",
composite: "/playlists/94/composite/1705800070",
duration: 423000,
leafCount: 3,
addedAt: 1705716458,
updatedAt: 1705800070,
},
],
},
};
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# ApplyUpdatesErrors # ApplyUpdatesErrors
## Example Usage
```typescript
import { ApplyUpdatesErrors } from "@lukehagar/plexjs";
let value: ApplyUpdatesErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,9 +1,19 @@
# ApplyUpdatesRequest # ApplyUpdatesRequest
## Example Usage
```typescript
import { ApplyUpdatesRequest, Skip, Tonight } from "@lukehagar/plexjs";
let value: ApplyUpdatesRequest = {
tonight: Tonight.One,
skip: Skip.One,
};
```
## Fields ## Fields
| Field | Type | Required | Description | Example | | Field | Type | Required | Description | Example |
| -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `tonight` | [models.Tonight](../models/tonight.md) | :heavy_minus_sign: | Indicate that you want the update to run during the next Butler execution. Omitting this or setting it to false indicates that the update should install | 1 | | `tonight` | [models.Tonight](../models/tonight.md) | :heavy_minus_sign: | Indicate that you want the update to run during the next Butler execution. Omitting this or setting it to false indicates that the update should install | 1 |
| `skip` | [models.Skip](../models/skip.md) | :heavy_minus_sign: | Indicate that the latest version should be marked as skipped. The <Release> entry for this version will have the `state` set to `skipped`. | 1 | | `skip` | [models.Skip](../models/skip.md) | :heavy_minus_sign: | Indicate that the latest version should be marked as skipped. The [Release] entry for this version will have the `state` set to `skipped`. | 1 |

View File

@@ -1,5 +1,18 @@
# ApplyUpdatesResponse # ApplyUpdatesResponse
## Example Usage
```typescript
import { ApplyUpdatesResponse } from "@lukehagar/plexjs";
let value: ApplyUpdatesResponse = {
contentType: "<value>",
statusCode: 318569,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { ApplyUpdatesResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -0,0 +1,18 @@
# AutoSelectSubtitle
The auto-select subtitle mode (0 = Manually selected, 1 = Shown with foreign audio, 2 = Always enabled)
## Example Usage
```typescript
import { AutoSelectSubtitle } from "@lukehagar/plexjs";
let value: AutoSelectSubtitle = AutoSelectSubtitle.One;
```
## Values
| Name | Value |
| ------ | ------ |
| `Zero` | 0 |
| `One` | 1 |

19
docs/models/billing.md Normal file
View File

@@ -0,0 +1,19 @@
# Billing
## Example Usage
```typescript
import { Billing } from "@lukehagar/plexjs";
let value: Billing = {
internalPaymentMethod: {},
paymentMethodId: 317983,
};
```
## Fields
| Field | Type | Required | Description |
| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ |
| `internalPaymentMethod` | [models.InternalPaymentMethod](../models/internalpaymentmethod.md) | :heavy_check_mark: | N/A |
| `paymentMethodId` | *number* | :heavy_check_mark: | N/A |

View File

@@ -1,5 +1,17 @@
# ButlerTask # ButlerTask
## Example Usage
```typescript
import { ButlerTask } from "@lukehagar/plexjs";
let value: ButlerTask = {
name: "BackupDatabase",
interval: 3,
title: "Backup Database",
description: "Create a backup copy of the server's database in the configured backup directory",
};
```
## Fields ## Fields

View File

@@ -1,5 +1,22 @@
# ButlerTasks # ButlerTasks
## Example Usage
```typescript
import { ButlerTasks } from "@lukehagar/plexjs";
let value: ButlerTasks = {
butlerTask: [
{
name: "BackupDatabase",
interval: 3,
title: "Backup Database",
description:
"Create a backup copy of the server's database in the configured backup directory",
},
],
};
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# CancelServerActivitiesErrors # CancelServerActivitiesErrors
## Example Usage
```typescript
import { CancelServerActivitiesErrors } from "@lukehagar/plexjs";
let value: CancelServerActivitiesErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,14 @@
# CancelServerActivitiesRequest # CancelServerActivitiesRequest
## Example Usage
```typescript
import { CancelServerActivitiesRequest } from "@lukehagar/plexjs";
let value: CancelServerActivitiesRequest = {
activityUUID: "25b71ed5-0f9d-461c-baa7-d404e9e10d3e",
};
```
## Fields ## Fields

View File

@@ -1,5 +1,18 @@
# CancelServerActivitiesResponse # CancelServerActivitiesResponse
## Example Usage
```typescript
import { CancelServerActivitiesResponse } from "@lukehagar/plexjs";
let value: CancelServerActivitiesResponse = {
contentType: "<value>",
statusCode: 791725,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { CancelServerActivitiesResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# CheckForUpdatesErrors # CheckForUpdatesErrors
## Example Usage
```typescript
import { CheckForUpdatesErrors } from "@lukehagar/plexjs";
let value: CheckForUpdatesErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,14 @@
# CheckForUpdatesRequest # CheckForUpdatesRequest
## Example Usage
```typescript
import { CheckForUpdatesRequest, Download } from "@lukehagar/plexjs";
let value: CheckForUpdatesRequest = {
download: Download.One,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,18 @@
# CheckForUpdatesResponse # CheckForUpdatesResponse
## Example Usage
```typescript
import { CheckForUpdatesResponse } from "@lukehagar/plexjs";
let value: CheckForUpdatesResponse = {
contentType: "<value>",
statusCode: 277718,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { CheckForUpdatesResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# ClearPlaylistContentsErrors # ClearPlaylistContentsErrors
## Example Usage
```typescript
import { ClearPlaylistContentsErrors } from "@lukehagar/plexjs";
let value: ClearPlaylistContentsErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,14 @@
# ClearPlaylistContentsRequest # ClearPlaylistContentsRequest
## Example Usage
```typescript
import { ClearPlaylistContentsRequest } from "@lukehagar/plexjs";
let value: ClearPlaylistContentsRequest = {
playlistID: 9495.72,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,18 @@
# ClearPlaylistContentsResponse # ClearPlaylistContentsResponse
## Example Usage
```typescript
import { ClearPlaylistContentsResponse } from "@lukehagar/plexjs";
let value: ClearPlaylistContentsResponse = {
contentType: "<value>",
statusCode: 368725,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { ClearPlaylistContentsResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -0,0 +1,29 @@
# Connections
## Example Usage
```typescript
import { Connections } from "@lukehagar/plexjs";
let value: Connections = {
protocol: "<value>",
address: "971 Strosin Wall",
port: 4736.08,
uri: "https://starry-initialise.name",
local: false,
relay: false,
iPv6: false,
};
```
## Fields
| Field | Type | Required | Description |
| ------------------ | ------------------ | ------------------ | ------------------ |
| `protocol` | *string* | :heavy_check_mark: | N/A |
| `address` | *string* | :heavy_check_mark: | N/A |
| `port` | *number* | :heavy_check_mark: | N/A |
| `uri` | *string* | :heavy_check_mark: | N/A |
| `local` | *boolean* | :heavy_check_mark: | N/A |
| `relay` | *boolean* | :heavy_check_mark: | N/A |
| `iPv6` | *boolean* | :heavy_check_mark: | N/A |

View File

@@ -1,5 +1,12 @@
# Context # Context
## Example Usage
```typescript
import { Context } from "@lukehagar/plexjs";
let value: Context = {};
```
## Fields ## Fields

View File

@@ -1,5 +1,14 @@
# Country # Country
## Example Usage
```typescript
import { Country } from "@lukehagar/plexjs";
let value: Country = {
tag: "United States of America",
};
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# CreatePlaylistErrors # CreatePlaylistErrors
## Example Usage
```typescript
import { CreatePlaylistErrors } from "@lukehagar/plexjs";
let value: CreatePlaylistErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,34 @@
# CreatePlaylistMediaContainer # CreatePlaylistMediaContainer
## Example Usage
```typescript
import { CreatePlaylistMediaContainer } from "@lukehagar/plexjs";
let value: CreatePlaylistMediaContainer = {
size: 7,
metadata: [
{
ratingKey: "96",
key: "/playlists/96/items",
guid: "com.plexapp.agents.none://a2f92937-1408-40e2-b022-63a8a9377e55",
type: "playlist",
title: "A Great Playlist",
summary: "What a great playlist",
smart: false,
playlistType: "video",
icon: "playlist://image.smart",
viewCount: 1,
lastViewedAt: 1705719589,
leafCount: 1,
addedAt: 1705719589,
updatedAt: 1705724593,
composite: "/playlists/96/composite/1705724593",
duration: 141000,
},
],
};
```
## Fields ## Fields

View File

@@ -1,5 +1,29 @@
# CreatePlaylistMetadata # CreatePlaylistMetadata
## Example Usage
```typescript
import { CreatePlaylistMetadata } from "@lukehagar/plexjs";
let value: CreatePlaylistMetadata = {
ratingKey: "96",
key: "/playlists/96/items",
guid: "com.plexapp.agents.none://a2f92937-1408-40e2-b022-63a8a9377e55",
type: "playlist",
title: "A Great Playlist",
summary: "What a great playlist",
smart: false,
playlistType: "video",
icon: "playlist://image.smart",
viewCount: 1,
lastViewedAt: 1705719589,
leafCount: 1,
addedAt: 1705719589,
updatedAt: 1705724593,
composite: "/playlists/96/composite/1705724593",
duration: 141000,
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { CreatePlaylistPlaylistsResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -0,0 +1,19 @@
# CreatePlaylistQueryParamType
type of playlist to create
## Example Usage
```typescript
import { CreatePlaylistQueryParamType } from "@lukehagar/plexjs";
let value: CreatePlaylistQueryParamType = CreatePlaylistQueryParamType.Video;
```
## Values
| Name | Value |
| ------- | ------- |
| `Audio` | audio |
| `Video` | video |
| `Photo` | photo |

View File

@@ -1,12 +1,24 @@
# CreatePlaylistRequest # CreatePlaylistRequest
## Example Usage
```typescript
import { CreatePlaylistQueryParamType, CreatePlaylistRequest, Smart } from "@lukehagar/plexjs";
let value: CreatePlaylistRequest = {
title: "<value>",
type: CreatePlaylistQueryParamType.Photo,
smart: Smart.One,
uri: "https://exotic-harm.info",
};
```
## Fields ## Fields
| Field | Type | Required | Description | | Field | Type | Required | Description |
| ---------------------------------------------------- | ---------------------------------------------------- | ---------------------------------------------------- | ---------------------------------------------------- | | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- |
| `title` | *string* | :heavy_check_mark: | name of the playlist | | `title` | *string* | :heavy_check_mark: | name of the playlist |
| `type` | [models.QueryParamType](../models/queryparamtype.md) | :heavy_check_mark: | type of playlist to create | | `type` | [models.CreatePlaylistQueryParamType](../models/createplaylistqueryparamtype.md) | :heavy_check_mark: | type of playlist to create |
| `smart` | [models.Smart](../models/smart.md) | :heavy_check_mark: | whether the playlist is smart or not | | `smart` | [models.Smart](../models/smart.md) | :heavy_check_mark: | whether the playlist is smart or not |
| `uri` | *string* | :heavy_check_mark: | the content URI for the playlist | | `uri` | *string* | :heavy_check_mark: | the content URI for the playlist |
| `playQueueID` | *number* | :heavy_minus_sign: | the play queue to copy to a playlist | | `playQueueID` | *number* | :heavy_minus_sign: | the play queue to copy to a playlist |

View File

@@ -1,5 +1,43 @@
# CreatePlaylistResponse # CreatePlaylistResponse
## Example Usage
```typescript
import { CreatePlaylistResponse } from "@lukehagar/plexjs";
let value: CreatePlaylistResponse = {
contentType: "<value>",
statusCode: 474697,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
object: {
mediaContainer: {
size: 7,
metadata: [
{
ratingKey: "96",
key: "/playlists/96/items",
guid: "com.plexapp.agents.none://a2f92937-1408-40e2-b022-63a8a9377e55",
type: "playlist",
title: "A Great Playlist",
summary: "What a great playlist",
smart: false,
playlistType: "video",
icon: "playlist://image.smart",
viewCount: 1,
lastViewedAt: 1705719589,
leafCount: 1,
addedAt: 1705719589,
updatedAt: 1705724593,
composite: "/playlists/96/composite/1705724593",
duration: 141000,
},
],
},
},
};
```
## Fields ## Fields

View File

@@ -2,6 +2,37 @@
returns all playlists returns all playlists
## Example Usage
```typescript
import { CreatePlaylistResponseBody } from "@lukehagar/plexjs";
let value: CreatePlaylistResponseBody = {
mediaContainer: {
size: 7,
metadata: [
{
ratingKey: "96",
key: "/playlists/96/items",
guid: "com.plexapp.agents.none://a2f92937-1408-40e2-b022-63a8a9377e55",
type: "playlist",
title: "A Great Playlist",
summary: "What a great playlist",
smart: false,
playlistType: "video",
icon: "playlist://image.smart",
viewCount: 1,
lastViewedAt: 1705719589,
leafCount: 1,
addedAt: 1705719589,
updatedAt: 1705724593,
composite: "/playlists/96/composite/1705724593",
duration: 141000,
},
],
},
};
```
## Fields ## Fields

View File

@@ -0,0 +1,18 @@
# DefaultSubtitleAccessibility
The subtitles for the deaf or hard-of-hearing (SDH) searches mode (0 = Prefer non-SDH subtitles, 1 = Prefer SDH subtitles, 2 = Only show SDH subtitles, 3 = Only shown non-SDH subtitles)
## Example Usage
```typescript
import { DefaultSubtitleAccessibility } from "@lukehagar/plexjs";
let value: DefaultSubtitleAccessibility = DefaultSubtitleAccessibility.One;
```
## Values
| Name | Value |
| ------ | ------ |
| `Zero` | 0 |
| `One` | 1 |

View File

@@ -0,0 +1,18 @@
# DefaultSubtitleForced
The forced subtitles searches mode (0 = Prefer non-forced subtitles, 1 = Prefer forced subtitles, 2 = Only show forced subtitles, 3 = Only show non-forced subtitles)
## Example Usage
```typescript
import { DefaultSubtitleForced } from "@lukehagar/plexjs";
let value: DefaultSubtitleForced = DefaultSubtitleForced.One;
```
## Values
| Name | Value |
| ------ | ------ |
| `Zero` | 0 |
| `One` | 1 |

View File

@@ -1,5 +1,16 @@
# DeleteLibraryErrors # DeleteLibraryErrors
## Example Usage
```typescript
import { DeleteLibraryErrors } from "@lukehagar/plexjs";
let value: DeleteLibraryErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,8 +1,17 @@
# DeleteLibraryRequest # DeleteLibraryRequest
## Example Usage
```typescript
import { DeleteLibraryRequest } from "@lukehagar/plexjs";
let value: DeleteLibraryRequest = {
sectionKey: 9518,
};
```
## Fields ## Fields
| Field | Type | Required | Description | Example | | Field | Type | Required | Description | Example |
| ------------------------------ | ------------------------------ | ------------------------------ | ------------------------------ | ------------------------------ | | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------- |
| `sectionId` | *number* | :heavy_check_mark: | the Id of the library to query | 1000 | | `sectionKey` | *number* | :heavy_check_mark: | The unique key of the Plex library. <br/>Note: This is unique in the context of the Plex server.<br/> | 9518 |

View File

@@ -1,5 +1,18 @@
# DeleteLibraryResponse # DeleteLibraryResponse
## Example Usage
```typescript
import { DeleteLibraryResponse } from "@lukehagar/plexjs";
let value: DeleteLibraryResponse = {
contentType: "<value>",
statusCode: 697631,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { DeleteLibraryResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# DeletePlaylistErrors # DeletePlaylistErrors
## Example Usage
```typescript
import { DeletePlaylistErrors } from "@lukehagar/plexjs";
let value: DeletePlaylistErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,14 @@
# DeletePlaylistRequest # DeletePlaylistRequest
## Example Usage
```typescript
import { DeletePlaylistRequest } from "@lukehagar/plexjs";
let value: DeletePlaylistRequest = {
playlistID: 6747.52,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,18 @@
# DeletePlaylistResponse # DeletePlaylistResponse
## Example Usage
```typescript
import { DeletePlaylistResponse } from "@lukehagar/plexjs";
let value: DeletePlaylistResponse = {
contentType: "<value>",
statusCode: 656330,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { DeletePlaylistResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -1,5 +1,17 @@
# Device # Device
## Example Usage
```typescript
import { Device } from "@lukehagar/plexjs";
let value: Device = {
id: 1,
name: "iPhone",
platform: "iOS",
createdAt: 1654131230,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,14 @@
# Director # Director
## Example Usage
```typescript
import { Director } from "@lukehagar/plexjs";
let value: Director = {
tag: "Peyton Reed",
};
```
## Fields ## Fields

View File

@@ -1,5 +1,12 @@
# Directory # Directory
## Example Usage
```typescript
import { Directory } from "@lukehagar/plexjs";
let value: Directory = {};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Indicate that you want to start download any updates found. Indicate that you want to start download any updates found.
## Example Usage
```typescript
import { Download } from "@lukehagar/plexjs";
let value: Download = Download.One;
```
## Values ## Values

View File

@@ -1,5 +1,16 @@
# EnablePaperTrailErrors # EnablePaperTrailErrors
## Example Usage
```typescript
import { EnablePaperTrailErrors } from "@lukehagar/plexjs";
let value: EnablePaperTrailErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,18 @@
# EnablePaperTrailResponse # EnablePaperTrailResponse
## Example Usage
```typescript
import { EnablePaperTrailResponse } from "@lukehagar/plexjs";
let value: EnablePaperTrailResponse = {
contentType: "<value>",
statusCode: 208876,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { EnablePaperTrailResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# Errors # Errors
## Example Usage
```typescript
import { Errors } from "@lukehagar/plexjs";
let value: Errors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

17
docs/models/feature.md Normal file
View File

@@ -0,0 +1,17 @@
# Feature
## Example Usage
```typescript
import { Feature } from "@lukehagar/plexjs";
let value: Feature = {};
```
## Fields
| Field | Type | Required | Description |
| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ |
| `key` | *string* | :heavy_minus_sign: | N/A |
| `type` | *string* | :heavy_minus_sign: | N/A |
| `directory` | [models.GetMediaProvidersDirectory](../models/getmediaprovidersdirectory.md)[] | :heavy_minus_sign: | N/A |

73
docs/models/features.md Normal file
View File

@@ -0,0 +1,73 @@
# Features
## Example Usage
```typescript
import { Features } from "@lukehagar/plexjs";
let value: Features = Features.WatchTogetherInvite;
```
## Values
| Name | Value |
| --------------------------------------- | --------------------------------------- |
| `AndroidDolbyVision` | Android - Dolby Vision |
| `AndroidPiP` | Android - PiP |
| `CUSunset` | CU Sunset |
| `HRKEnableEUR` | HRK_enable_EUR |
| `TREBLEShowFeatures` | TREBLE-show-features |
| `AdCountdownTimer` | ad-countdown-timer |
| `AdaptiveBitrate` | adaptive_bitrate |
| `AmazonLoopDebug` | amazon-loop-debug |
| `AvodAdAnalysis` | avod-ad-analysis |
| `AvodNewMedia` | avod-new-media |
| `BlacklistGetSignin` | blacklist_get_signin |
| `ClientRadioStations` | client-radio-stations |
| `CloudflareTurnstileRequired` | cloudflare-turnstile-required |
| `Collections` | collections |
| `CommentsAndRepliesPushNotifications` | comments_and_replies_push_notifications |
| `CommunityAccessPlexTv` | community_access_plex_tv |
| `CompanionsSonos` | companions_sonos |
| `CustomHomeRemoval` | custom-home-removal |
| `DisableHomeUserFriendships` | disable_home_user_friendships |
| `DisableSharingFriendships` | disable_sharing_friendships |
| `DrmSupport` | drm_support |
| `ExcludeRestrictions` | exclude restrictions |
| `FederatedAuth` | federated-auth |
| `FriendRequestPushNotifications` | friend_request_push_notifications |
| `GuidedUpgrade` | guided-upgrade |
| `Home` | home |
| `IncreasePasswordComplexity` | increase-password-complexity |
| `Ios14PrivacyBanner` | ios14-privacy-banner |
| `IterableNotificationTokens` | iterable-notification-tokens |
| `KeepPaymentMethod` | keep-payment-method |
| `KevinBacon` | kevin-bacon |
| `KoreaConsent` | korea-consent |
| `LeIsrgRootX1` | le_isrg_root_x1 |
| `LetsEncrypt` | lets_encrypt |
| `LightningDvrPivot` | lightning-dvr-pivot |
| `LiveTvSupportIncompleteSegments` | live-tv-support-incomplete-segments |
| `Livetv` | livetv |
| `MetadataSearch` | metadata_search |
| `NewPlexPassPrices` | new_plex_pass_prices |
| `NewsProviderSunsetModal` | news-provider-sunset-modal |
| `PhotosFavorites` | photos-favorites |
| `PhotosMetadataEdition` | photos-metadata-edition |
| `PmsHealth` | pms_health |
| `Radio` | radio |
| `RateLimitClientToken` | rate-limit-client-token |
| `ScrobblingServicePlexTv` | scrobbling-service-plex-tv |
| `SharedServerNotification` | shared_server_notification |
| `SharedSourceNotification` | shared_source_notification |
| `SigninWithApple` | signin_with_apple |
| `SpringServeAdProvider` | spring_serve_ad_provider |
| `TranscoderCache` | transcoder_cache |
| `TunerSharing` | tuner-sharing |
| `TwoFactorAuthentication` | two-factor-authentication |
| `Unsupportedtuners` | unsupportedtuners |
| `Upgrade3ds2` | upgrade-3ds2 |
| `VodSchema` | vod-schema |
| `VodCloudflare` | vod_cloudflare |
| `WatchTogetherInvite` | watch-together-invite |
| `WebServerDashboard` | web_server_dashboard |

View File

@@ -1,5 +1,17 @@
# Field # Field
## Example Usage
```typescript
import { Field } from "@lukehagar/plexjs";
let value: Field = {
key: "label",
title: "Label",
type: "tag",
subType: "bitrate",
};
```
## Fields ## Fields

View File

@@ -1,5 +1,20 @@
# FieldType # FieldType
## Example Usage
```typescript
import { FieldType } from "@lukehagar/plexjs";
let value: FieldType = {
type: "resolution",
operator: [
{
key: "=",
title: "is",
},
],
};
```
## Fields ## Fields

View File

@@ -1,11 +1,19 @@
# Filter # Filter
Filters content by field and direction/equality Filter
(Unknown if viewedAt is the only supported column)
## Example Usage
```typescript
import { Filter } from "@lukehagar/plexjs";
## Fields let value: Filter = Filter.Available;
```
| Field | Type | Required | Description | ## Values
| ----------- | ----------- | ----------- | ----------- |
| Name | Value |
| ----------- | ----------- |
| `All` | all |
| `Available` | available |
| `Released` | released |

View File

@@ -1,11 +1,14 @@
# Force # Force
Force overwriting of duplicate playlists. Force the refresh even if the library is already being refreshed.
By default, a playlist file uploaded with the same path will overwrite the existing playlist.
The `force` argument is used to disable overwriting.
If the `force` argument is set to 0, a new playlist will be created suffixed with the date and time that the duplicate was uploaded.
## Example Usage
```typescript
import { Force } from "@lukehagar/plexjs";
let value: Force = Force.One;
```
## Values ## Values

39
docs/models/friend.md Normal file
View File

@@ -0,0 +1,39 @@
# Friend
## Example Usage
```typescript
import { Friend, Status } from "@lukehagar/plexjs";
let value: Friend = {
email: "username@email.com",
friendlyName: "exampleUser",
home: true,
id: 0,
restricted: false,
sharedServers: [{}],
sharedSources: [{}],
status: Status.Accepted,
thumb: "https://plex.tv/users/7d1916e0d8f6e76b/avatar?c=1694481578",
title: "username123",
username: "username123",
uuid: "7d1916e0d8f6e76b",
};
```
## Fields
| Field | Type | Required | Description | Example |
| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- |
| `email` | *string* | :heavy_check_mark: | The account email address | username@email.com |
| `friendlyName` | *string* | :heavy_check_mark: | The account full name | exampleUser |
| `home` | *boolean* | :heavy_check_mark: | If the account is a Plex Home user | |
| `id` | *number* | :heavy_check_mark: | The Plex account ID | |
| `restricted` | *boolean* | :heavy_minus_sign: | If the account is a Plex Home managed user | |
| `sharedServers` | [models.SharedServers](../models/sharedservers.md)[] | :heavy_check_mark: | N/A | |
| `sharedSources` | [models.SharedSources](../models/sharedsources.md)[] | :heavy_check_mark: | N/A | |
| `status` | [models.Status](../models/status.md) | :heavy_check_mark: | Current friend request status | accepted |
| `thumb` | *string* | :heavy_check_mark: | URL of the account thumbnail | https://plex.tv/users/7d1916e0d8f6e76b/avatar?c=1694481578 |
| `title` | *string* | :heavy_check_mark: | The title of the account (username or friendly name) | username123 |
| `username` | *string* | :heavy_check_mark: | The account username | username123 |
| `uuid` | *string* | :heavy_check_mark: | The account Universally Unique Identifier (UUID) | 7d1916e0d8f6e76b |

View File

@@ -1,5 +1,14 @@
# Genre # Genre
## Example Usage
```typescript
import { Genre } from "@lukehagar/plexjs";
let value: Genre = {
tag: "Comedy",
};
```
## Fields ## Fields

39
docs/models/geodata.md Normal file
View File

@@ -0,0 +1,39 @@
# GeoData
Geo location data
## Example Usage
```typescript
import { GeoData } from "@lukehagar/plexjs";
let value: GeoData = {
code: "VI",
continentCode: "NA",
country: "United States Virgin Islands",
city: "Amsterdam",
europeanUnionMember: true,
timeZone: "America/St_Thomas",
postalCode: 802,
inPrivacyRestrictedCountry: true,
inPrivacyRestrictedRegion: true,
subdivisions: "Saint Thomas",
coordinates: "18.3381, -64.8941",
};
```
## Fields
| Field | Type | Required | Description | Example |
| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- |
| `code` | *string* | :heavy_check_mark: | The ISO 3166-1 alpha-2 code of the country. | VI |
| `continentCode` | *string* | :heavy_check_mark: | The continent code where the country is located. | NA |
| `country` | *string* | :heavy_check_mark: | The official name of the country. | United States Virgin Islands |
| `city` | *string* | :heavy_check_mark: | The name of the city. | Amsterdam |
| `europeanUnionMember` | *boolean* | :heavy_minus_sign: | Indicates if the country is a member of the European Union. | true |
| `timeZone` | *string* | :heavy_check_mark: | The time zone of the country. | America/St_Thomas |
| `postalCode` | *number* | :heavy_check_mark: | The postal code of the location. | 802 |
| `inPrivacyRestrictedCountry` | *boolean* | :heavy_minus_sign: | Indicates if the country has privacy restrictions. | true |
| `inPrivacyRestrictedRegion` | *boolean* | :heavy_minus_sign: | Indicates if the region has privacy restrictions. | true |
| `subdivisions` | *string* | :heavy_check_mark: | The name of the primary administrative subdivision. | Saint Thomas |
| `coordinates` | *string* | :heavy_check_mark: | The geographical coordinates (latitude, longitude) of the location. | 18.3381, -64.8941 |

View File

@@ -0,0 +1,62 @@
# GetAllLibrariesDirectory
## Example Usage
```typescript
import { GetAllLibrariesDirectory } from "@lukehagar/plexjs";
let value: GetAllLibrariesDirectory = {
allowSync: true,
art: "/:/resources/movie-fanart.jpg",
composite: "/library/sections/1/composite/1705615584",
filters: true,
refreshing: false,
thumb: "/:/resources/movie.png",
key: "1",
type: "movie",
title: "Movies",
agent: "tv.plex.agents.movie",
scanner: "Plex Movie",
language: "en-US",
uuid: "322a231a-b7f7-49f5-920f-14c61199cd30",
updatedAt: 1556281940,
createdAt: 1556281940,
scannedAt: 1556281940,
content: true,
directory: true,
contentChangedAt: 3192854,
hidden: 0,
location: [
{
id: 1,
path: "/movies",
},
],
};
```
## Fields
| Field | Type | Required | Description | Example |
| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | ------------------------------------------ |
| `allowSync` | *boolean* | :heavy_minus_sign: | N/A | true |
| `art` | *string* | :heavy_minus_sign: | N/A | /:/resources/movie-fanart.jpg |
| `composite` | *string* | :heavy_minus_sign: | N/A | /library/sections/1/composite/1705615584 |
| `filters` | *boolean* | :heavy_minus_sign: | N/A | true |
| `refreshing` | *boolean* | :heavy_minus_sign: | N/A | false |
| `thumb` | *string* | :heavy_minus_sign: | N/A | /:/resources/movie.png |
| `key` | *string* | :heavy_minus_sign: | N/A | 1 |
| `type` | *string* | :heavy_minus_sign: | N/A | movie |
| `title` | *string* | :heavy_minus_sign: | N/A | Movies |
| `agent` | *string* | :heavy_minus_sign: | N/A | tv.plex.agents.movie |
| `scanner` | *string* | :heavy_minus_sign: | N/A | Plex Movie |
| `language` | *string* | :heavy_minus_sign: | N/A | en-US |
| `uuid` | *string* | :heavy_minus_sign: | N/A | 322a231a-b7f7-49f5-920f-14c61199cd30 |
| `updatedAt` | *number* | :heavy_minus_sign: | Unix epoch datetime | 1556281940 |
| `createdAt` | *number* | :heavy_minus_sign: | Unix epoch datetime | 1556281940 |
| `scannedAt` | *number* | :heavy_minus_sign: | Unix epoch datetime | 1556281940 |
| `content` | *boolean* | :heavy_minus_sign: | N/A | true |
| `directory` | *boolean* | :heavy_minus_sign: | N/A | true |
| `contentChangedAt` | *number* | :heavy_minus_sign: | N/A | 3192854 |
| `hidden` | *number* | :heavy_minus_sign: | N/A | 0 |
| `location` | [models.Location](../models/location.md)[] | :heavy_minus_sign: | N/A | |

View File

@@ -0,0 +1,21 @@
# GetAllLibrariesErrors
## Example Usage
```typescript
import { GetAllLibrariesErrors } from "@lukehagar/plexjs";
let value: GetAllLibrariesErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields
| Field | Type | Required | Description | Example |
| ------------------------------- | ------------------------------- | ------------------------------- | ------------------------------- | ------------------------------- |
| `code` | *number* | :heavy_minus_sign: | N/A | 1001 |
| `message` | *string* | :heavy_minus_sign: | N/A | User could not be authenticated |
| `status` | *number* | :heavy_minus_sign: | N/A | 401 |

View File

@@ -0,0 +1,18 @@
# GetAllLibrariesLibraryResponseBody
Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { GetAllLibrariesLibraryResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields
| Field | Type | Required | Description |
| --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- |
| `errors` | [models.GetAllLibrariesErrors](../models/getalllibrarieserrors.md)[] | :heavy_minus_sign: | N/A |
| `rawResponse` | [Response](https://developer.mozilla.org/en-US/docs/Web/API/Response) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |

View File

@@ -0,0 +1,52 @@
# GetAllLibrariesMediaContainer
## Example Usage
```typescript
import { GetAllLibrariesMediaContainer } from "@lukehagar/plexjs";
let value: GetAllLibrariesMediaContainer = {
size: 5,
allowSync: false,
title1: "Plex Library",
directory: [
{
allowSync: true,
art: "/:/resources/movie-fanart.jpg",
composite: "/library/sections/1/composite/1705615584",
filters: true,
refreshing: false,
thumb: "/:/resources/movie.png",
key: "1",
type: "movie",
title: "Movies",
agent: "tv.plex.agents.movie",
scanner: "Plex Movie",
language: "en-US",
uuid: "322a231a-b7f7-49f5-920f-14c61199cd30",
updatedAt: 1556281940,
createdAt: 1556281940,
scannedAt: 1556281940,
content: true,
directory: true,
contentChangedAt: 3192854,
hidden: 0,
location: [
{
id: 1,
path: "/movies",
},
],
},
],
};
```
## Fields
| Field | Type | Required | Description | Example |
| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- |
| `size` | *number* | :heavy_check_mark: | N/A | 5 |
| `allowSync` | *boolean* | :heavy_check_mark: | N/A | false |
| `title1` | *string* | :heavy_check_mark: | N/A | Plex Library |
| `directory` | [models.GetAllLibrariesDirectory](../models/getalllibrariesdirectory.md)[] | :heavy_minus_sign: | N/A | |

View File

@@ -0,0 +1,61 @@
# GetAllLibrariesResponse
## Example Usage
```typescript
import { GetAllLibrariesResponse } from "@lukehagar/plexjs";
let value: GetAllLibrariesResponse = {
contentType: "<value>",
statusCode: 613064,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
object: {
mediaContainer: {
size: 5,
allowSync: false,
title1: "Plex Library",
directory: [
{
allowSync: true,
art: "/:/resources/movie-fanart.jpg",
composite: "/library/sections/1/composite/1705615584",
filters: true,
refreshing: false,
thumb: "/:/resources/movie.png",
key: "1",
type: "movie",
title: "Movies",
agent: "tv.plex.agents.movie",
scanner: "Plex Movie",
language: "en-US",
uuid: "322a231a-b7f7-49f5-920f-14c61199cd30",
updatedAt: 1556281940,
createdAt: 1556281940,
scannedAt: 1556281940,
content: true,
directory: true,
contentChangedAt: 3192854,
hidden: 0,
location: [
{
id: 1,
path: "/movies",
},
],
},
],
},
},
};
```
## Fields
| Field | Type | Required | Description |
| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ |
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
| `rawResponse` | [Response](https://developer.mozilla.org/en-US/docs/Web/API/Response) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing |
| `object` | [models.GetAllLibrariesResponseBody](../models/getalllibrariesresponsebody.md) | :heavy_minus_sign: | The libraries available on the Server |

View File

@@ -0,0 +1,53 @@
# GetAllLibrariesResponseBody
The libraries available on the Server
## Example Usage
```typescript
import { GetAllLibrariesResponseBody } from "@lukehagar/plexjs";
let value: GetAllLibrariesResponseBody = {
mediaContainer: {
size: 5,
allowSync: false,
title1: "Plex Library",
directory: [
{
allowSync: true,
art: "/:/resources/movie-fanart.jpg",
composite: "/library/sections/1/composite/1705615584",
filters: true,
refreshing: false,
thumb: "/:/resources/movie.png",
key: "1",
type: "movie",
title: "Movies",
agent: "tv.plex.agents.movie",
scanner: "Plex Movie",
language: "en-US",
uuid: "322a231a-b7f7-49f5-920f-14c61199cd30",
updatedAt: 1556281940,
createdAt: 1556281940,
scannedAt: 1556281940,
content: true,
directory: true,
contentChangedAt: 3192854,
hidden: 0,
location: [
{
id: 1,
path: "/movies",
},
],
},
],
},
};
```
## Fields
| Field | Type | Required | Description |
| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- |
| `mediaContainer` | [models.GetAllLibrariesMediaContainer](../models/getalllibrariesmediacontainer.md) | :heavy_minus_sign: | N/A |

View File

@@ -1,5 +1,16 @@
# GetAvailableClientsErrors # GetAvailableClientsErrors
## Example Usage
```typescript
import { GetAvailableClientsErrors } from "@lukehagar/plexjs";
let value: GetAvailableClientsErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,29 @@
# GetAvailableClientsMediaContainer # GetAvailableClientsMediaContainer
## Example Usage
```typescript
import { GetAvailableClientsMediaContainer } from "@lukehagar/plexjs";
let value: GetAvailableClientsMediaContainer = {
size: 1,
server: [
{
name: "iPad",
host: "10.10.10.102",
address: "10.10.10.102",
port: 32500,
machineIdentifier: "A2E901F8-E016-43A7-ADFB-EF8CA8A4AC05",
version: "8.17",
protocol: "plex",
product: "Plex for iOS",
deviceClass: "tablet",
protocolVersion: 2,
protocolCapabilities: "playback,playqueues,timeline,provider-playback",
},
],
};
```
## Fields ## Fields

View File

@@ -1,5 +1,38 @@
# GetAvailableClientsResponse # GetAvailableClientsResponse
## Example Usage
```typescript
import { GetAvailableClientsResponse } from "@lukehagar/plexjs";
let value: GetAvailableClientsResponse = {
contentType: "<value>",
statusCode: 715190,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
object: {
mediaContainer: {
size: 1,
server: [
{
name: "iPad",
host: "10.10.10.102",
address: "10.10.10.102",
port: 32500,
machineIdentifier: "A2E901F8-E016-43A7-ADFB-EF8CA8A4AC05",
version: "8.17",
protocol: "plex",
product: "Plex for iOS",
deviceClass: "tablet",
protocolVersion: 2,
protocolCapabilities: "playback,playqueues,timeline,provider-playback",
},
],
},
},
};
```
## Fields ## Fields

View File

@@ -2,6 +2,32 @@
Available Clients Available Clients
## Example Usage
```typescript
import { GetAvailableClientsResponseBody } from "@lukehagar/plexjs";
let value: GetAvailableClientsResponseBody = {
mediaContainer: {
size: 1,
server: [
{
name: "iPad",
host: "10.10.10.102",
address: "10.10.10.102",
port: 32500,
machineIdentifier: "A2E901F8-E016-43A7-ADFB-EF8CA8A4AC05",
version: "8.17",
protocol: "plex",
product: "Plex for iOS",
deviceClass: "tablet",
protocolVersion: 2,
protocolCapabilities: "playback,playqueues,timeline,provider-playback",
},
],
},
};
```
## Fields ## Fields

View File

@@ -1,5 +1,24 @@
# GetAvailableClientsServer # GetAvailableClientsServer
## Example Usage
```typescript
import { GetAvailableClientsServer } from "@lukehagar/plexjs";
let value: GetAvailableClientsServer = {
name: "iPad",
host: "10.10.10.102",
address: "10.10.10.102",
port: 32500,
machineIdentifier: "A2E901F8-E016-43A7-ADFB-EF8CA8A4AC05",
version: "8.17",
protocol: "plex",
product: "Plex for iOS",
deviceClass: "tablet",
protocolVersion: 2,
protocolCapabilities: "playback,playqueues,timeline,provider-playback",
};
```
## Fields ## Fields

View File

@@ -2,6 +2,13 @@
Unauthorized - Returned if the X-Plex-Token is missing from the header or query. Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
## Example Usage
```typescript
import { GetAvailableClientsServerResponseBody } from "@lukehagar/plexjs";
// No examples available for this model
```
## Fields ## Fields

View File

@@ -1,5 +1,21 @@
# GetBandwidthStatisticsAccount # GetBandwidthStatisticsAccount
## Example Usage
```typescript
import { GetBandwidthStatisticsAccount } from "@lukehagar/plexjs";
let value: GetBandwidthStatisticsAccount = {
id: 238960586,
key: "/accounts/238960586",
name: "Diane",
defaultAudioLanguage: "en",
autoSelectAudio: true,
defaultSubtitleLanguage: "en",
subtitleMode: 1,
thumb: "https://plex.tv/users/50d83634246da1de/avatar?c=1707110967",
};
```
## Fields ## Fields

View File

@@ -1,5 +1,18 @@
# GetBandwidthStatisticsDevice # GetBandwidthStatisticsDevice
## Example Usage
```typescript
import { GetBandwidthStatisticsDevice } from "@lukehagar/plexjs";
let value: GetBandwidthStatisticsDevice = {
id: 208,
name: "Roku Express",
platform: "Roku",
clientIdentifier: "793095d235660625108ef785cc7646e9",
createdAt: 1706470556,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,16 @@
# GetBandwidthStatisticsErrors # GetBandwidthStatisticsErrors
## Example Usage
```typescript
import { GetBandwidthStatisticsErrors } from "@lukehagar/plexjs";
let value: GetBandwidthStatisticsErrors = {
code: 1001,
message: "User could not be authenticated",
status: 401,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,45 @@
# GetBandwidthStatisticsMediaContainer # GetBandwidthStatisticsMediaContainer
## Example Usage
```typescript
import { GetBandwidthStatisticsMediaContainer } from "@lukehagar/plexjs";
let value: GetBandwidthStatisticsMediaContainer = {
size: 5497,
device: [
{
id: 208,
name: "Roku Express",
platform: "Roku",
clientIdentifier: "793095d235660625108ef785cc7646e9",
createdAt: 1706470556,
},
],
account: [
{
id: 238960586,
key: "/accounts/238960586",
name: "Diane",
defaultAudioLanguage: "en",
autoSelectAudio: true,
defaultSubtitleLanguage: "en",
subtitleMode: 1,
thumb: "https://plex.tv/users/50d83634246da1de/avatar?c=1707110967",
},
],
statisticsBandwidth: [
{
accountID: 238960586,
deviceID: 208,
timespan: 6,
at: 1718387650,
lan: true,
bytes: 22,
},
],
};
```
## Fields ## Fields

View File

@@ -1,5 +1,14 @@
# GetBandwidthStatisticsRequest # GetBandwidthStatisticsRequest
## Example Usage
```typescript
import { GetBandwidthStatisticsRequest } from "@lukehagar/plexjs";
let value: GetBandwidthStatisticsRequest = {
timespan: 4,
};
```
## Fields ## Fields

View File

@@ -1,5 +1,54 @@
# GetBandwidthStatisticsResponse # GetBandwidthStatisticsResponse
## Example Usage
```typescript
import { GetBandwidthStatisticsResponse } from "@lukehagar/plexjs";
let value: GetBandwidthStatisticsResponse = {
contentType: "<value>",
statusCode: 916723,
rawResponse: new Response('{"message": "hello world"}', {
headers: { "Content-Type": "application/json" },
}),
object: {
mediaContainer: {
size: 5497,
device: [
{
id: 208,
name: "Roku Express",
platform: "Roku",
clientIdentifier: "793095d235660625108ef785cc7646e9",
createdAt: 1706470556,
},
],
account: [
{
id: 238960586,
key: "/accounts/238960586",
name: "Diane",
defaultAudioLanguage: "en",
autoSelectAudio: true,
defaultSubtitleLanguage: "en",
subtitleMode: 1,
thumb: "https://plex.tv/users/50d83634246da1de/avatar?c=1707110967",
},
],
statisticsBandwidth: [
{
accountID: 238960586,
deviceID: 208,
timespan: 6,
at: 1718387650,
lan: true,
bytes: 22,
},
],
},
},
};
```
## Fields ## Fields

View File

@@ -2,6 +2,48 @@
Bandwidth Statistics Bandwidth Statistics
## Example Usage
```typescript
import { GetBandwidthStatisticsResponseBody } from "@lukehagar/plexjs";
let value: GetBandwidthStatisticsResponseBody = {
mediaContainer: {
size: 5497,
device: [
{
id: 208,
name: "Roku Express",
platform: "Roku",
clientIdentifier: "793095d235660625108ef785cc7646e9",
createdAt: 1706470556,
},
],
account: [
{
id: 238960586,
key: "/accounts/238960586",
name: "Diane",
defaultAudioLanguage: "en",
autoSelectAudio: true,
defaultSubtitleLanguage: "en",
subtitleMode: 1,
thumb: "https://plex.tv/users/50d83634246da1de/avatar?c=1707110967",
},
],
statisticsBandwidth: [
{
accountID: 238960586,
deviceID: 208,
timespan: 6,
at: 1718387650,
lan: true,
bytes: 22,
},
],
},
};
```
## Fields ## Fields

Some files were not shown because too many files have changed in this diff Show More