Categorygithub.com/devopsarr/lidarr-go
module
0.3.1
Repository: https://github.com/devopsarr/lidarr-go.git
Documentation: pkg.go.dev

# README

Go API client for lidarr

Lidarr API docs

Overview

This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.

  • Package version: 0.3.1
  • API version: 1.0.0

  • Build package: org.openapitools.codegen.languages.GoClientCodegen

Installation

Install the following dependencies:

go get github.com/stretchr/testify/assert
go get golang.org/x/oauth2
go get golang.org/x/net/context

Put the package under your project folder and add the following in import:

import lidarr "github.com/devopsarr/lidarr-go"

To use a proxy, set the environment variable HTTP_PROXY:

os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")

Configuration of Server URL

Default configuration comes with Servers field that contains server objects as defined in the OpenAPI specification.

Select Server Configuration

For using other server than the one defined on index 0 set context value sw.ContextServerIndex of type int.

ctx := context.WithValue(context.Background(), lidarr.ContextServerIndex, 1)

Templated Server URL

Templated server URL is formatted using default variables from configuration or from context value sw.ContextServerVariables of type map[string]string.

ctx := context.WithValue(context.Background(), lidarr.ContextServerVariables, map[string]string{
	"basePath": "v2",
})

Note, enum values are always validated and all unused variables are silently ignored.

URLs Configuration per Operation

Each operation can use different server URL defined using OperationServers map in the Configuration. An operation is uniquely identified by "{classname}Service.{nickname}" string. Similar rules for overriding default operation server index and variables applies by using sw.ContextOperationServerIndices and sw.ContextOperationServerVariables context maps.

ctx := context.WithValue(context.Background(), lidarr.ContextOperationServerIndices, map[string]int{
	"{classname}Service.{nickname}": 2,
})
ctx = context.WithValue(context.Background(), lidarr.ContextOperationServerVariables, map[string]map[string]string{
	"{classname}Service.{nickname}": {
		"port": "8443",
	},
})

Documentation for API Endpoints

All URIs are relative to http://localhost:8686

ClassMethodHTTP requestDescription
AlbumAPICreateAlbumPost /api/v1/album
AlbumAPIDeleteAlbumDelete /api/v1/album/{id}
AlbumAPIGetAlbumByIdGet /api/v1/album/{id}
AlbumAPIListAlbumGet /api/v1/album
AlbumAPIPutAlbumMonitorPut /api/v1/album/monitor
AlbumAPIUpdateAlbumPut /api/v1/album/{id}
AlbumLookupAPIGetAlbumLookupGet /api/v1/album/lookup
AlbumStudioAPICreateAlbumStudioPost /api/v1/albumstudio
ApiInfoAPIGetApiGet /api
ArtistAPICreateArtistPost /api/v1/artist
ArtistAPIDeleteArtistDelete /api/v1/artist/{id}
ArtistAPIGetArtistByIdGet /api/v1/artist/{id}
ArtistAPIListArtistGet /api/v1/artist
ArtistAPIUpdateArtistPut /api/v1/artist/{id}
ArtistEditorAPIDeleteArtistEditorDelete /api/v1/artist/editor
ArtistEditorAPIPutArtistEditorPut /api/v1/artist/editor
ArtistLookupAPIGetArtistLookupGet /api/v1/artist/lookup
AuthenticationAPICreateLoginPost /login
AuthenticationAPIGetLogoutGet /logout
AutoTaggingAPICreateAutoTaggingPost /api/v1/autotagging
AutoTaggingAPIDeleteAutoTaggingDelete /api/v1/autotagging/{id}
AutoTaggingAPIGetAutoTaggingByIdGet /api/v1/autotagging/{id}
AutoTaggingAPIGetAutoTaggingSchemaGet /api/v1/autotagging/schema
AutoTaggingAPIListAutoTaggingGet /api/v1/autotagging
AutoTaggingAPIUpdateAutoTaggingPut /api/v1/autotagging/{id}
BackupAPICreateSystemBackupRestoreByIdPost /api/v1/system/backup/restore/{id}
BackupAPICreateSystemBackupRestoreUploadPost /api/v1/system/backup/restore/upload
BackupAPIDeleteSystemBackupDelete /api/v1/system/backup/{id}
BackupAPIListSystemBackupGet /api/v1/system/backup
BlocklistAPIDeleteBlocklistDelete /api/v1/blocklist/{id}
BlocklistAPIDeleteBlocklistBulkDelete /api/v1/blocklist/bulk
BlocklistAPIGetBlocklistGet /api/v1/blocklist
CalendarAPIGetCalendarByIdGet /api/v1/calendar/{id}
CalendarAPIListCalendarGet /api/v1/calendar
CalendarFeedAPIGetFeedV1CalendarLidarrIcsGet /feed/v1/calendar/lidarr.ics
CommandAPICreateCommandPost /api/v1/command
CommandAPIDeleteCommandDelete /api/v1/command/{id}
CommandAPIGetCommandByIdGet /api/v1/command/{id}
CommandAPIListCommandGet /api/v1/command
CustomFilterAPICreateCustomFilterPost /api/v1/customfilter
CustomFilterAPIDeleteCustomFilterDelete /api/v1/customfilter/{id}
CustomFilterAPIGetCustomFilterByIdGet /api/v1/customfilter/{id}
CustomFilterAPIListCustomFilterGet /api/v1/customfilter
CustomFilterAPIUpdateCustomFilterPut /api/v1/customfilter/{id}
CustomFormatAPICreateCustomFormatPost /api/v1/customformat
CustomFormatAPIDeleteCustomFormatDelete /api/v1/customformat/{id}
CustomFormatAPIGetCustomFormatByIdGet /api/v1/customformat/{id}
CustomFormatAPIGetCustomFormatSchemaGet /api/v1/customformat/schema
CustomFormatAPIListCustomFormatGet /api/v1/customformat
CustomFormatAPIUpdateCustomFormatPut /api/v1/customformat/{id}
CutoffAPIGetWantedCutoffGet /api/v1/wanted/cutoff
CutoffAPIGetWantedCutoffByIdGet /api/v1/wanted/cutoff/{id}
DelayProfileAPICreateDelayProfilePost /api/v1/delayprofile
DelayProfileAPIDeleteDelayProfileDelete /api/v1/delayprofile/{id}
DelayProfileAPIGetDelayProfileByIdGet /api/v1/delayprofile/{id}
DelayProfileAPIListDelayProfileGet /api/v1/delayprofile
DelayProfileAPIUpdateDelayProfilePut /api/v1/delayprofile/{id}
DelayProfileAPIUpdateDelayProfileReorderPut /api/v1/delayprofile/reorder/{id}
DiskSpaceAPIListDiskSpaceGet /api/v1/diskspace
DownloadClientAPICreateDownloadClientPost /api/v1/downloadclient
DownloadClientAPICreateDownloadClientActionByNamePost /api/v1/downloadclient/action/{name}
DownloadClientAPIDeleteDownloadClientDelete /api/v1/downloadclient/{id}
DownloadClientAPIDeleteDownloadClientBulkDelete /api/v1/downloadclient/bulk
DownloadClientAPIGetDownloadClientByIdGet /api/v1/downloadclient/{id}
DownloadClientAPIListDownloadClientGet /api/v1/downloadclient
DownloadClientAPIListDownloadClientSchemaGet /api/v1/downloadclient/schema
DownloadClientAPIPutDownloadClientBulkPut /api/v1/downloadclient/bulk
DownloadClientAPITestDownloadClientPost /api/v1/downloadclient/test
DownloadClientAPITestallDownloadClientPost /api/v1/downloadclient/testall
DownloadClientAPIUpdateDownloadClientPut /api/v1/downloadclient/{id}
DownloadClientConfigAPIGetDownloadClientConfigGet /api/v1/config/downloadclient
DownloadClientConfigAPIGetDownloadClientConfigByIdGet /api/v1/config/downloadclient/{id}
DownloadClientConfigAPIUpdateDownloadClientConfigPut /api/v1/config/downloadclient/{id}
FileSystemAPIGetFileSystemGet /api/v1/filesystem
FileSystemAPIGetFileSystemMediafilesGet /api/v1/filesystem/mediafiles
FileSystemAPIGetFileSystemTypeGet /api/v1/filesystem/type
HealthAPIListHealthGet /api/v1/health
HistoryAPICreateHistoryFailedByIdPost /api/v1/history/failed/{id}
HistoryAPIGetHistoryGet /api/v1/history
HistoryAPIListHistoryArtistGet /api/v1/history/artist
HistoryAPIListHistorySinceGet /api/v1/history/since
HostConfigAPIGetHostConfigGet /api/v1/config/host
HostConfigAPIGetHostConfigByIdGet /api/v1/config/host/{id}
HostConfigAPIUpdateHostConfigPut /api/v1/config/host/{id}
ImportListAPICreateImportListPost /api/v1/importlist
ImportListAPICreateImportListActionByNamePost /api/v1/importlist/action/{name}
ImportListAPIDeleteImportListDelete /api/v1/importlist/{id}
ImportListAPIDeleteImportListBulkDelete /api/v1/importlist/bulk
ImportListAPIGetImportListByIdGet /api/v1/importlist/{id}
ImportListAPIListImportListGet /api/v1/importlist
ImportListAPIListImportListSchemaGet /api/v1/importlist/schema
ImportListAPIPutImportListBulkPut /api/v1/importlist/bulk
ImportListAPITestImportListPost /api/v1/importlist/test
ImportListAPITestallImportListPost /api/v1/importlist/testall
ImportListAPIUpdateImportListPut /api/v1/importlist/{id}
ImportListExclusionAPICreateImportListExclusionPost /api/v1/importlistexclusion
ImportListExclusionAPIDeleteImportListExclusionDelete /api/v1/importlistexclusion/{id}
ImportListExclusionAPIGetImportListExclusionByIdGet /api/v1/importlistexclusion/{id}
ImportListExclusionAPIListImportListExclusionGet /api/v1/importlistexclusion
ImportListExclusionAPIUpdateImportListExclusionPut /api/v1/importlistexclusion/{id}
IndexerAPICreateIndexerPost /api/v1/indexer
IndexerAPICreateIndexerActionByNamePost /api/v1/indexer/action/{name}
IndexerAPIDeleteIndexerDelete /api/v1/indexer/{id}
IndexerAPIDeleteIndexerBulkDelete /api/v1/indexer/bulk
IndexerAPIGetIndexerByIdGet /api/v1/indexer/{id}
IndexerAPIListIndexerGet /api/v1/indexer
IndexerAPIListIndexerSchemaGet /api/v1/indexer/schema
IndexerAPIPutIndexerBulkPut /api/v1/indexer/bulk
IndexerAPITestIndexerPost /api/v1/indexer/test
IndexerAPITestallIndexerPost /api/v1/indexer/testall
IndexerAPIUpdateIndexerPut /api/v1/indexer/{id}
IndexerConfigAPIGetIndexerConfigGet /api/v1/config/indexer
IndexerConfigAPIGetIndexerConfigByIdGet /api/v1/config/indexer/{id}
IndexerConfigAPIUpdateIndexerConfigPut /api/v1/config/indexer/{id}
LanguageAPIGetLanguageByIdGet /api/v1/language/{id}
LanguageAPIListLanguageGet /api/v1/language
LocalizationAPIGetLocalizationGet /api/v1/localization
LogAPIGetLogGet /api/v1/log
LogFileAPIGetLogFileByFilenameGet /api/v1/log/file/{filename}
LogFileAPIListLogFileGet /api/v1/log/file
ManualImportAPICreateManualImportPost /api/v1/manualimport
ManualImportAPIListManualImportGet /api/v1/manualimport
MediaCoverAPIGetMediaCoverAlbumByFilenameGet /api/v1/mediacover/album/{albumId}/{filename}
MediaCoverAPIGetMediaCoverArtistByFilenameGet /api/v1/mediacover/artist/{artistId}/{filename}
MediaManagementConfigAPIGetMediaManagementConfigGet /api/v1/config/mediamanagement
MediaManagementConfigAPIGetMediaManagementConfigByIdGet /api/v1/config/mediamanagement/{id}
MediaManagementConfigAPIUpdateMediaManagementConfigPut /api/v1/config/mediamanagement/{id}
MetadataAPICreateMetadataPost /api/v1/metadata
MetadataAPICreateMetadataActionByNamePost /api/v1/metadata/action/{name}
MetadataAPIDeleteMetadataDelete /api/v1/metadata/{id}
MetadataAPIGetMetadataByIdGet /api/v1/metadata/{id}
MetadataAPIListMetadataGet /api/v1/metadata
MetadataAPIListMetadataSchemaGet /api/v1/metadata/schema
MetadataAPITestMetadataPost /api/v1/metadata/test
MetadataAPITestallMetadataPost /api/v1/metadata/testall
MetadataAPIUpdateMetadataPut /api/v1/metadata/{id}
MetadataProfileAPICreateMetadataProfilePost /api/v1/metadataprofile
MetadataProfileAPIDeleteMetadataProfileDelete /api/v1/metadataprofile/{id}
MetadataProfileAPIGetMetadataProfileByIdGet /api/v1/metadataprofile/{id}
MetadataProfileAPIListMetadataProfileGet /api/v1/metadataprofile
MetadataProfileAPIUpdateMetadataProfilePut /api/v1/metadataprofile/{id}
MetadataProfileSchemaAPIGetMetadataprofileSchemaGet /api/v1/metadataprofile/schema
MetadataProviderConfigAPIGetMetadataProviderConfigGet /api/v1/config/metadataprovider
MetadataProviderConfigAPIGetMetadataProviderConfigByIdGet /api/v1/config/metadataprovider/{id}
MetadataProviderConfigAPIUpdateMetadataProviderConfigPut /api/v1/config/metadataprovider/{id}
MissingAPIGetWantedMissingGet /api/v1/wanted/missing
MissingAPIGetWantedMissingByIdGet /api/v1/wanted/missing/{id}
NamingConfigAPIGetNamingConfigGet /api/v1/config/naming
NamingConfigAPIGetNamingConfigByIdGet /api/v1/config/naming/{id}
NamingConfigAPIGetNamingConfigExamplesGet /api/v1/config/naming/examples
NamingConfigAPIUpdateNamingConfigPut /api/v1/config/naming/{id}
NotificationAPICreateNotificationPost /api/v1/notification
NotificationAPICreateNotificationActionByNamePost /api/v1/notification/action/{name}
NotificationAPIDeleteNotificationDelete /api/v1/notification/{id}
NotificationAPIGetNotificationByIdGet /api/v1/notification/{id}
NotificationAPIListNotificationGet /api/v1/notification
NotificationAPIListNotificationSchemaGet /api/v1/notification/schema
NotificationAPITestNotificationPost /api/v1/notification/test
NotificationAPITestallNotificationPost /api/v1/notification/testall
NotificationAPIUpdateNotificationPut /api/v1/notification/{id}
ParseAPIGetParseGet /api/v1/parse
PingAPIGetPingGet /ping
QualityDefinitionAPIGetQualityDefinitionByIdGet /api/v1/qualitydefinition/{id}
QualityDefinitionAPIListQualityDefinitionGet /api/v1/qualitydefinition
QualityDefinitionAPIPutQualityDefinitionUpdatePut /api/v1/qualitydefinition/update
QualityDefinitionAPIUpdateQualityDefinitionPut /api/v1/qualitydefinition/{id}
QualityProfileAPICreateQualityProfilePost /api/v1/qualityprofile
QualityProfileAPIDeleteQualityProfileDelete /api/v1/qualityprofile/{id}
QualityProfileAPIGetQualityProfileByIdGet /api/v1/qualityprofile/{id}
QualityProfileAPIListQualityProfileGet /api/v1/qualityprofile
QualityProfileAPIUpdateQualityProfilePut /api/v1/qualityprofile/{id}
QualityProfileSchemaAPIGetQualityprofileSchemaGet /api/v1/qualityprofile/schema
QueueAPIDeleteQueueDelete /api/v1/queue/{id}
QueueAPIDeleteQueueBulkDelete /api/v1/queue/bulk
QueueAPIGetQueueGet /api/v1/queue
QueueActionAPICreateQueueGrabBulkPost /api/v1/queue/grab/bulk
QueueActionAPICreateQueueGrabByIdPost /api/v1/queue/grab/{id}
QueueDetailsAPIListQueueDetailsGet /api/v1/queue/details
QueueStatusAPIGetQueueStatusGet /api/v1/queue/status
ReleaseAPICreateReleasePost /api/v1/release
ReleaseAPIListReleaseGet /api/v1/release
ReleaseProfileAPICreateReleaseProfilePost /api/v1/releaseprofile
ReleaseProfileAPIDeleteReleaseProfileDelete /api/v1/releaseprofile/{id}
ReleaseProfileAPIGetReleaseProfileByIdGet /api/v1/releaseprofile/{id}
ReleaseProfileAPIListReleaseProfileGet /api/v1/releaseprofile
ReleaseProfileAPIUpdateReleaseProfilePut /api/v1/releaseprofile/{id}
ReleasePushAPICreateReleasePushPost /api/v1/release/push
RemotePathMappingAPICreateRemotePathMappingPost /api/v1/remotepathmapping
RemotePathMappingAPIDeleteRemotePathMappingDelete /api/v1/remotepathmapping/{id}
RemotePathMappingAPIGetRemotePathMappingByIdGet /api/v1/remotepathmapping/{id}
RemotePathMappingAPIListRemotePathMappingGet /api/v1/remotepathmapping
RemotePathMappingAPIUpdateRemotePathMappingPut /api/v1/remotepathmapping/{id}
RenameTrackAPIListRenameGet /api/v1/rename
RetagTrackAPIListRetagGet /api/v1/retag
RootFolderAPICreateRootFolderPost /api/v1/rootfolder
RootFolderAPIDeleteRootFolderDelete /api/v1/rootfolder/{id}
RootFolderAPIGetRootFolderByIdGet /api/v1/rootfolder/{id}
RootFolderAPIListRootFolderGet /api/v1/rootfolder
RootFolderAPIUpdateRootFolderPut /api/v1/rootfolder/{id}
SearchAPIGetSearchGet /api/v1/search
StaticResourceAPIGetGet /
StaticResourceAPIGetByPathGet /{path}
StaticResourceAPIGetContentByPathGet /content/{path}
StaticResourceAPIGetLoginGet /login
SystemAPICreateSystemRestartPost /api/v1/system/restart
SystemAPICreateSystemShutdownPost /api/v1/system/shutdown
SystemAPIGetSystemRoutesGet /api/v1/system/routes
SystemAPIGetSystemRoutesDuplicateGet /api/v1/system/routes/duplicate
SystemAPIGetSystemStatusGet /api/v1/system/status
TagAPICreateTagPost /api/v1/tag
TagAPIDeleteTagDelete /api/v1/tag/{id}
TagAPIGetTagByIdGet /api/v1/tag/{id}
TagAPIListTagGet /api/v1/tag
TagAPIUpdateTagPut /api/v1/tag/{id}
TagDetailsAPIGetTagDetailByIdGet /api/v1/tag/detail/{id}
TagDetailsAPIListTagDetailGet /api/v1/tag/detail
TaskAPIGetSystemTaskByIdGet /api/v1/system/task/{id}
TaskAPIListSystemTaskGet /api/v1/system/task
TrackAPIGetTrackByIdGet /api/v1/track/{id}
TrackAPIListTrackGet /api/v1/track
TrackFileAPIDeleteTrackFileDelete /api/v1/trackfile/{id}
TrackFileAPIDeleteTrackFileBulkDelete /api/v1/trackfile/bulk
TrackFileAPIGetTrackFileByIdGet /api/v1/trackfile/{id}
TrackFileAPIListTrackFileGet /api/v1/trackfile
TrackFileAPIPutTrackFileEditorPut /api/v1/trackfile/editor
TrackFileAPIUpdateTrackFilePut /api/v1/trackfile/{id}
UiConfigAPIGetUiConfigGet /api/v1/config/ui
UiConfigAPIGetUiConfigByIdGet /api/v1/config/ui/{id}
UiConfigAPIUpdateUiConfigPut /api/v1/config/ui/{id}
UpdateAPIListUpdateGet /api/v1/update
UpdateLogFileAPIGetLogFileUpdateByFilenameGet /api/v1/log/file/update/{filename}
UpdateLogFileAPIListLogFileUpdateGet /api/v1/log/file/update

Documentation For Models

Documentation For Authorization

X-Api-Key

  • Type: API key
  • API key parameter name: X-Api-Key
  • Location: HTTP header

Note, each API key must be added to a map of map[string]APIKey where the key is: X-Api-Key and passed in as the auth context for each request.

apikey

  • Type: API key
  • API key parameter name: apikey
  • Location: URL query string

Note, each API key must be added to a map of map[string]APIKey where the key is: apikey and passed in as the auth context for each request.

Documentation for Utility Methods

Due to the fact that model structure members are all pointers, this package contains a number of utility functions to easily obtain pointers to values of basic types. Each of these functions takes a value of the given basic type and returns a pointer to it:

  • PtrBool
  • PtrInt
  • PtrInt32
  • PtrInt64
  • PtrFloat
  • PtrFloat32
  • PtrFloat64
  • PtrString
  • PtrTime

Author

# Packages

No description provided by the author