Package: pycliarr
What's pycliarrPython client for radarr and sonarr apis.
The package provides python client and CLI to use in command line.Documentation homepageUsageSonarr CLIpyvenv/bin/pycliarr-t"http://192.168.0.199:8989"-k"2ac2d8f667524da3bx1849e81dba5a84"-dsonarrget-i65pyvenv/bin/pycliarr-t"http://192.168.0.199:8989"-k"2ac2d8f667524da3bax849e81dba5a84"-dsonarradd-t"the walking dead"Radarr CLIpyvenv/bin/pycliarr-t"http://192.168.0.199:7878"-k"2ac2d8f667524da3bx1849e81dba5a84"-dradarrget-i65pyvenv/bin/pycliarr-t"http://192.168.0.199:7878"-k"2ac2d8f667524da3bax849e81dba5a84"-dradarradd-t"wonder woman"Using radarr clientfrompycliarr.apiimportRadarrCliradarr_cli=RadarrCli('http://192.168.0.199:7878','5f5e32qf3ff8463e9f3d2388af0fd3e8')radarr_cli.add_movie(imdb_id="tt1234",quality=1)movie=radarr_cli.get_movie(12)print(movie.title)Using sonarr clientfrompycliarr.apiimportSonarrClisonarr_cli=SonarrCli('http://192.168.0.199:8989','2ac2d8f667524da3bx1849e81dba5a84')sonarr_cli.add_serie(imdb_id="tt1234",quality=1)serie=sonarr_cli.get_serie(12)print(serie.title)CLI helpClients:pyvenv/bin/pycliarr--help
PyCliarrversion1.0.22
usage:pycliarr[-h]--hostHOST--api-keyAPI_KEY[--userUSER][--passwordPASSWORD][--debug]{sonarr,radarr}...

Radarr/Sonarrclient

positionalarguments:{sonarr,radarr}sonarrusesonarrclientradarruseradarrclientconfiguseconfigclient

optionalarguments:-h,--helpshowthishelpmessageandexit--hostHOST,-tHOSTHosturl,e.g'http://192.168.0.1'--api-keyAPI_KEY,-kAPI_KEYAPIkey,e.g'5f5e32xf3ff8463d9f1d2u88ef0fd3e8'--userUSER,-uUSERUsernameifusingbasicauthentication--passwordPASSWORD,-pPASSWORDPasswordifusingbasicauthentication--debug,-dEnabledebugloggingRadarr CLI:pyvenv/bin/pycliarrradarr--help
PyCliarrversion1.0.21
usage:pycliarrradarr[-h]{get,delete,add,edit,refresh,rescan,profiles,system-status,disk-space,queue,calendar,delete-queue,wanted,status,blocklist,delete-blocklist,notification,delete-notification,put-notification,tag,tag-detail,delete-tag,edit-tag,create-tag,tag-items,exclusion,delete-exclusion,create-exclusion,search-missing,root-folders}...

positionalarguments:{get,delete,add,edit,refresh,rescan,profiles,system-status,disk-space,queue,calendar,delete-queue,wanted,status,blocklist,delete-blocklist,notification,delete-notification,put-notification,tag,tag-detail,delete-tag,edit-tag,create-tag,tag-items,exclusion,delete-exclusion,create-exclusion,search-missing,root-folders}getGetinfoonaofmoviedeleteDeleteamovieaddAddamoviefromtheimdb/tmdbid,orlookforkeywordseditPushanupdateditemtothemovielibraryrefreshRefreshmoviesrescanRescanmoviesprofilesGetlistofqualityprofilessystem-statusGetsystemstatusdisk-spaceGetdiskspacequeueGetcurrentdownloadingqueuecalendarGeteventsfromcalendardelete-queueGetlistofqualityprofileswantedListwanted/missingstatusGetstatusof1orallcurrentlyrunningcommandsblocklistGetblocklisteditemsdelete-blocklistGetlistofqualityprofilesnotificationGetnotification(s)delete-notificationDeletethespecifiednotificationorallput-notificationCreatethespecifiednotificationtagGettag(s)tag-detailGettag(s)detailsdelete-tagDeletethespecifiedtagedit-tagEditthespecifiedtagcreate-tagCreatethespecifiedtagtag-itemsListitemswithspecifedtagexclusionGetexclusion(s)delete-exclusionDeletethespecifiedexclusioncreate-exclusionCreatethespecifiedexclusionsearch-missingSearchmissingmoviesroot-foldersGetrootfolderlist

optionalarguments:-h,--helpshowthishelpmessageandexitSonarr CLI:pyvenv/bin/pycliarrsonarr--help
PyCliarrversion1.0.22
usage:pycliarrsonarr[-h]{get,delete,add,refresh,rescan,get-episode,get-episode-file,delete-episode-file,profiles,system-status,disk-space,queue,calendar,delete-queue,wanted,status,blocklist,delete-blocklist,notification,delete-notification,put-notification,tag,tag-detail,delete-tag,edit-tag,create-tag,tag-items,exclusion,delete-exclusion,create-exclusion,search-missing,root-folders}...

positionalarguments:{get,delete,add,refresh,rescan,get-episode,get-episode-file,delete-episode-file,profiles,system-status,disk-space,queue,calendar,delete-queue,wanted,status,blocklist,delete-blocklist,notification,delete-notification,put-notification,tag,tag-detail,delete-tag,edit-tag,create-tag,tag-items,exclusion,delete-exclusion,create-exclusion,search-missing,root-folders}getGetinfoonaofseriedeleteDeleteaserieaddAddaseriefromthetvdbid,orlookforkeywordsrefreshRefreshseriesrescanRescanseriesget-episodeGetinfoonanepisodeget-episode-fileGetinfoonanepisodefiledelete-episode-fileGetinfoonaofserieprofilesGetlistofqualityprofilessystem-statusGetsystemstatusdisk-spaceGetdiskspacequeueGetcurrentdownloadingqueuecalendarGeteventsfromcalendardelete-queueGetlistofqualityprofileswantedListwanted/missingstatusGetstatusof1orallcurrentlyrunningcommandsblocklistGetblocklisteditemsdelete-blocklistGetlistofqualityprofilesnotificationGetnotification(s)delete-notificationDeletethespecifiednotificationorallput-notificationCreatethespecifiednotificationtagGettag(s)tag-detailGettag(s)detailsdelete-tagDeletethespecifiedtagedit-tagEditthespecifiedtagcreate-tagCreatethespecifiedtagtag-itemsListitemswithspecifedtagexclusionGetexclusion(s)delete-exclusionDeletethespecifiedexclusioncreate-exclusionCreatethespecifiedexclusionsearch-missingSearchmissingepisodsroot-foldersGetrootfolderlist

optionalarguments:-h,--helpshowthishelpmessageandexitConfig CLI:Allows storing default argument values for all commands. Note that while -t and -k arguments are mandatory, they are not used. so any value works.
The config values will be stored in"/tmp/pycliarr_cfg.json"and can be freely edited (all default will be reset) or edited manually.To display all the possible arguments that can be set:pycliarr-t""-k""configshowTo change for instance the default value of the queue command page size:pycliarr-t""-k""configconfigset-n"CliGetQueueCommand.--page-size"-v"3"Before running the command above, running the following would use a default page size of 20. After running the command, the same command would use a default page size of 3:pycliarr-t<url>-k<apikey>sonarrqueueBut specifying the argument works normally, only the defaults (when parameter is not specified) are affected:pycliarr-t<url>-k<apikey>sonarrqueue--page-size5To clear all defaults and reset them to their orignal value:pycliarr-t""-k""configclearHelp:pyvenv/bin/pycliarrconfig--help
PyCliarrversion1.0.22
usage:pycliarrconfig[-h]{clear,set,show}...

positionalarguments:{clear,set,show}clearDisplaycurrentconfigsetSetadefaultvalueforthespecified(Use'show'todisplayavailablekeys)showDisplaycurrentconfig

options:-h,--helpshowthishelpmessageandexit## InstallationFrompip:```sh
pippycliarrFrom git:gitclonehttps://github.com/vche/pycliarr.git
pipinstall-e.DevelopmentInstalling sources projectsGet the project:gitclonehttps://github.com/vche/pycliarr.gitcdpycliarrUsingpixi# Install dependencies and pycliarrpixibuild# Run the binarypixirunpycliarr# Or start a termpixishell# Run testspixiruntests#generate docpixirundocUsing venv and pipCreate the virtual env:virtualenvpyvenv
.pyvenv/bin/activate
pipinstall-e.Note: Entry points will be installed in pyvenv/bin, libs with pyvenv libsRun testspipinstalltox
toxIf mypy fails due to missing import stubs:.tox/checkers/bin/mypy --install-typesGenerate documentation:pipinstallsphinxsphinx_rtd_themem2r2
./setup.pydocIn case new classes/modules are added, update the autodoc list:rmdocs/sphinx_conf/source/*
sphinx-apidoc-f-odocs/sphinx_conf/source/src/pycliarr--separate