cfsync

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2023 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TrigCFSyncRadarr    common.TriggerName = "Starting Radarr TRaSH Profiles sync."
	TrigCFSyncRadarrInt common.TriggerName = "Starting Radarr %d TRaSH Profiles sync."
)
View Source
const (
	TrigRPSyncSonarr    common.TriggerName = "Starting Sonarr TRaSH Profiles sync."
	TrigRPSyncSonarrInt common.TriggerName = "Starting Sonarr %d TRaSH Profiles sync."
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action struct {
	// contains filtered or unexported fields
}

Action contains the exported methods for this package.

func New

func New(config *common.Config) *Action

New configures the library.

func (*Action) Create

func (a *Action) Create()

Create initializes the library.

func (*Action) Handler added in v0.4.0

func (a *Action) Handler(req *http.Request) (int, interface{})

Handler is passed into the webserver as an HTTP handler. @Description Returns custom format and related data for multiple Sonarr instances at once. May be slow. @Summary Retrieve custom format data from multiple Sonarr instances. @Tags TRaSH,Sonarr @Produce json @Accept json @Param request body TrashAggInput true "list of instances" @Success 200 {object} apps.Respond.apiResponse{message=[]SonarrTrashPayload} "contains app info included appStatus" @Failure 400 {object} apps.Respond.apiResponse{message=string} "bad input payload or missing app" @Failure 404 {object} string "bad token or api key" @Router /api/trash/sonarr [post] @Security ApiKeyAuth

func (*Action) SyncRadarrCF

func (a *Action) SyncRadarrCF(event website.EventType)

SyncRadarrCF initializes a custom format sync with radarr.

func (*Action) SyncRadarrInstanceCF added in v0.4.1

func (a *Action) SyncRadarrInstanceCF(event website.EventType, instance int) error

SyncRadarrInstanceCF initializes a custom format sync with a specific radarr instance.

func (*Action) SyncSonarrInstanceRP added in v0.4.1

func (a *Action) SyncSonarrInstanceRP(event website.EventType, instance int) error

SyncSonarrInstanceRP initializes a release profile sync with a specific sonarr instance.

func (*Action) SyncSonarrRP

func (a *Action) SyncSonarrRP(event website.EventType)

SyncSonarrRP initializes a release profile sync with sonarr.

type RadarrTrashPayload

type RadarrTrashPayload struct {
	Instance           int                          `json:"instance"`
	Name               string                       `json:"name"`
	CustomFormats      []*radarr.CustomFormatOutput `json:"customFormats,omitempty"`
	QualityProfiles    []*radarr.QualityProfile     `json:"qualityProfiles,omitempty"`
	QualityDefinitions []*radarr.QualityDefinition  `json:"qualityDefinitions,omitempty"`
	Naming             *radarr.Naming               `json:"naming"`
	Error              string                       `json:"error"`
}

RadarrTrashPayload is the payload sent and received to/from notifarr.com when updating custom formats for Radarr. This is used in other places, like the trash API handler in the 'client' module.

type SonarrTrashPayload

type SonarrTrashPayload struct {
	Instance           int                          `json:"instance"`
	Name               string                       `json:"name"`
	ReleaseProfiles    []*sonarr.ReleaseProfile     `json:"releaseProfiles,omitempty"`
	QualityProfiles    []*sonarr.QualityProfile     `json:"qualityProfiles,omitempty"`
	CustomFormats      []*sonarr.CustomFormatOutput `json:"customFormats,omitempty"`
	QualityDefinitions []*sonarr.QualityDefinition  `json:"qualityDefinitions,omitempty"`
	Naming             *sonarr.Naming               `json:"naming"`
	Error              string                       `json:"error"`
}

SonarrTrashPayload is the payload sent and received to/from notifarr.com when updating custom formats for Sonarr.

type TrashAggInput added in v0.4.1

type TrashAggInput struct {
	Instances clientinfo.IntList `json:"instances"`
}

TrashAggInput is the data input for a Trash aggregate request.

Jump to

Keyboard shortcuts

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