v1

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 21, 2026 License: MIT Imports: 61 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BackupDownloadHandler

func BackupDownloadHandler(svc *backup.Service, logger *slog.Logger) http.HandlerFunc

BackupDownloadHandler serves one backup file as a download.

func BackupHandler

func BackupHandler(db *sql.DB, dbPath string, logger *slog.Logger) http.HandlerFunc

BackupHandler returns an http.HandlerFunc that streams a consistent SQLite backup as a downloadable file using VACUUM INTO.

func NewAutoSearchRetryHandler

func NewAutoSearchRetryHandler(
	showSvc *show.Service,
	indexerSvc *indexer.Service,
	downloaderSvc *downloader.Service,
	blocklistSvc *blocklist.Service,
	qualitySvc *quality.Service,
	logger *slog.Logger,
) events.Handler

NewAutoSearchRetryHandler returns an event-bus handler that performs the re-search requested by TypeAutoSearchRetry. The stall watcher and the failed-download handler publish that event after blocklisting a dead release; this is what actually searches again and grabs the next best release. The blocklist entry they wrote keeps the dead release out.

Before this existed the event had no subscriber, so stalled or failed automatic grabs were blocklisted and then nothing happened.

func RegisterActivityRoutes

func RegisterActivityRoutes(humaAPI huma.API, svc *activity.Service)

RegisterActivityRoutes registers the /api/v1/activity endpoints.

func RegisterAuthSettingsRoutes

func RegisterAuthSettingsRoutes(api huma.API, auth *middleware.Auth, configFile string)

RegisterAuthSettingsRoutes registers GET/PUT /api/v1/system/auth, which read and change the browser login settings. Changes apply immediately and are written to config.yaml.

func RegisterBackupRoutes

func RegisterBackupRoutes(api huma.API, svc *backup.Service)

RegisterBackupRoutes registers the backup list, create, delete, restore and settings endpoints. Downloads are served by BackupDownloadHandler (a binary response).

func RegisterBlocklistRoutes

func RegisterBlocklistRoutes(api huma.API, svc *blocklist.Service)

RegisterBlocklistRoutes registers the blocklist management endpoints.

func RegisterCalendarRoutes

func RegisterCalendarRoutes(api huma.API, q db.Querier)

RegisterCalendarRoutes registers the calendar endpoint.

func RegisterDelayRoutes

func RegisterDelayRoutes(api huma.API, q db.Querier)

RegisterDelayRoutes registers the delay profile and pending-release endpoints.

func RegisterDiscoverRoutes

func RegisterDiscoverRoutes(api huma.API, showSvc *show.Service)

RegisterDiscoverRoutes registers the /api/v1/discover/* endpoints used by the Discover detail page.

func RegisterDownloadClientRoutes

func RegisterDownloadClientRoutes(api huma.API, svc *downloader.Service)

RegisterDownloadClientRoutes registers all /api/v1/download-clients endpoints.

func RegisterEnvRoutes

func RegisterEnvRoutes(api huma.API)

RegisterEnvRoutes exposes the relevant env vars for this process so the Pulse dashboard can show what the operator configured. Secrets are redacted by substring match on the key.

func RegisterEpisodeFileRoutes

func RegisterEpisodeFileRoutes(api huma.API, svc *show.Service, mmSvc *mediamanagement.Service)

RegisterEpisodeFileRoutes registers file management endpoints for a series.

func RegisterFilesystemRoutes

func RegisterFilesystemRoutes(api huma.API)

RegisterFilesystemRoutes registers the server-side filesystem browsing endpoint.

func RegisterHaulHistoryRoutes

func RegisterHaulHistoryRoutes(api huma.API, q db.Querier, downloaderSvc *downloader.Service, importerSvc *importer.Service, paths *remotepath.Service)

RegisterHaulHistoryRoutes wires the haul-history endpoints.

Haul reports paths as it sees them; paths maps them to Pilot's view (remote path mappings). A nil paths uses them as reported.

func RegisterHealthRoutes

func RegisterHealthRoutes(api huma.API, svc *health.Service)

RegisterHealthRoutes registers the health check endpoints.

func RegisterHistoryRoutes

func RegisterHistoryRoutes(humaAPI huma.API, q db.Querier)

RegisterHistoryRoutes registers the global grab history endpoint and the per-series grab history endpoint.

func RegisterImportListRoutes

func RegisterImportListRoutes(api huma.API, svc *importlist.Service)

func RegisterImportRoutes

func RegisterImportRoutes(api huma.API, svc *sonarrimport.Service)

func RegisterIndexerRoutes

func RegisterIndexerRoutes(api huma.API, svc *indexer.Service)

RegisterIndexerRoutes registers all /api/v1/indexers endpoints.

func RegisterLanguageRoutes

func RegisterLanguageRoutes(api huma.API, q db.Querier)

RegisterLanguageRoutes registers the language preference endpoints.

func RegisterLibraryRoutes

func RegisterLibraryRoutes(api huma.API, librarySvc *library.Service)

RegisterLibraryRoutes registers all /api/v1/libraries endpoints.

func RegisterManualImportRoutes

func RegisterManualImportRoutes(api huma.API, svc *importer.Service)

RegisterManualImportRoutes registers the manual import endpoints.

func RegisterMediaManagementRoutes

func RegisterMediaManagementRoutes(api huma.API, svc *mediamanagement.Service)

RegisterMediaManagementRoutes registers /api/v1/media-management endpoints.

func RegisterMediaServerRoutes

func RegisterMediaServerRoutes(api huma.API, svc *mediaserver.Service)

RegisterMediaServerRoutes registers the /api/v1/media-servers endpoints.

func RegisterNotificationRoutes

func RegisterNotificationRoutes(api huma.API, svc *notification.Service)

RegisterNotificationRoutes registers the /api/v1/notifications endpoints.

func RegisterPeopleRoutes

func RegisterPeopleRoutes(api huma.API, showSvc *show.Service)

RegisterPeopleRoutes registers the /api/v1/people/{id} endpoint.

func RegisterProviderRoutes

func RegisterProviderRoutes(api huma.API, r *provider.Resolver)

RegisterProviderRoutes wires the /api/v1/settings/providers/{name} endpoints onto the given Huma API.

func RegisterQualityDefinitionRoutes

func RegisterQualityDefinitionRoutes(api huma.API, svc *quality.DefinitionService)

RegisterQualityDefinitionRoutes registers /api/v1/quality-definitions endpoints.

func RegisterQualityProfileRoutes

func RegisterQualityProfileRoutes(api huma.API, qualitySvc *quality.Service)

RegisterQualityProfileRoutes registers all /api/v1/quality-profiles endpoints.

func RegisterQueueRoutes

func RegisterQueueRoutes(api huma.API, svc *queue.Service, bl *blocklist.Service)

RegisterQueueRoutes registers the /api/v1/queue endpoints.

func RegisterRecycleBinRoutes

func RegisterRecycleBinRoutes(api huma.API, svc *recyclebin.Service)

RegisterRecycleBinRoutes registers the recycle bin endpoints. The bin's folder and cleanup period are media management settings.

func RegisterReleaseProfileRoutes

func RegisterReleaseProfileRoutes(api huma.API, svc *releaseprofile.Service)

RegisterReleaseProfileRoutes registers CRUD for release profiles.

func RegisterReleaseRoutes

func RegisterReleaseRoutes(api huma.API, indexerSvc *indexer.Service, showSvc *show.Service, downloaderSvc *downloader.Service, blocklistSvc *blocklist.Service, qualitySvc *quality.Service)

RegisterReleaseRoutes registers the release search and grab history endpoints. qualitySvc may be nil; when nil, the quality-profile gate is skipped and all releases are considered acceptable regardless of the series profile.

func RegisterRemotePathMappingRoutes

func RegisterRemotePathMappingRoutes(api huma.API, svc *remotepath.Service)

RegisterRemotePathMappingRoutes registers CRUD for remote path mappings.

func RegisterRuntimeRoutes

func RegisterRuntimeRoutes(api huma.API, startTime time.Time)

RegisterRuntimeRoutes registers the Go-runtime stats endpoint.

func RegisterSeriesBulkRoutes

func RegisterSeriesBulkRoutes(api huma.API, svc *seriesbulk.Service)

RegisterSeriesBulkRoutes registers the series mass editor endpoints. Each request changes every listed series or none.

func RegisterSeriesRoutes

func RegisterSeriesRoutes(api huma.API, showSvc *show.Service)

RegisterSeriesRoutes registers all /api/v1/series, /api/v1/episodes, and /api/v1/seasons endpoints.

func RegisterStatsRoutes

func RegisterStatsRoutes(humaAPI huma.API, svc *stats.Service)

RegisterStatsRoutes registers the /api/v1/stats/* endpoints.

func RegisterSystemRoutes

func RegisterSystemRoutes(api huma.API, startTime time.Time, dbType, dbPath, configFile, apiKey string, tmdbKeyConfigured, tmdbKeyIsDefault bool, logger *slog.Logger)

RegisterSystemRoutes registers the /api/v1/system/* endpoints.

func RegisterTaskRoutes

func RegisterTaskRoutes(api huma.API, sched *scheduler.Scheduler)

RegisterTaskRoutes registers the /api/v1/tasks endpoints.

func RegisterUnmappedFolderRoutes

func RegisterUnmappedFolderRoutes(api huma.API, svc *unmapped.Service, scan func(), logger *slog.Logger)

RegisterUnmappedFolderRoutes registers the library-import review endpoints. scan, when not nil, starts a library scan after a folder is confirmed so its files are picked up right away.

func RegisterUpdateRoutes

func RegisterUpdateRoutes(api huma.API)

RegisterUpdateRoutes registers GET /api/v1/system/updates.

func RegisterWantedRoutes

func RegisterWantedRoutes(api huma.API, q db.Querier, profiles wanted.ProfileGetter)

RegisterWantedRoutes registers the wanted/missing and wanted/cutoff endpoints.

func RegisterWantedSearchRoutes

func RegisterWantedSearchRoutes(
	api huma.API,
	q db.Querier,
	showSvc *show.Service,
	indexerSvc *indexer.Service,
	downloaderSvc *downloader.Service,
	blocklistSvc *blocklist.Service,
	qualitySvc *quality.Service,
	logger *slog.Logger,
)

RegisterWantedSearchRoutes registers the "search all missing" and "search all cutoff unmet" actions. Each queues the matching episodes and searches them one at a time in the background, grabbing the best release the profile accepts (an upgrade, for cutoff-unmet episodes).

func RestoreHandler

func RestoreHandler(dbPath string, logger *slog.Logger) http.HandlerFunc

RestoreHandler returns an http.HandlerFunc that accepts a raw SQLite database upload and writes it to a staging path. The actual swap happens on next application startup.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL