generated

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2026 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Overview

Package generated provides primitives to interact with the openapi HTTP API.

Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.6.0 DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handler

func Handler(si ServerInterface) http.Handler

Handler creates http.Handler with routing matching OpenAPI spec.

func HandlerFromMux

func HandlerFromMux(si ServerInterface, m ServeMux) http.Handler

HandlerFromMux creates http.Handler with routing matching OpenAPI spec based on the provided mux.

func HandlerFromMuxWithBaseURL

func HandlerFromMuxWithBaseURL(si ServerInterface, m ServeMux, baseURL string) http.Handler

func HandlerWithOptions

func HandlerWithOptions(si ServerInterface, options StdHTTPServerOptions) http.Handler

HandlerWithOptions creates http.Handler with additional options

Types

type ActionResponse

type ActionResponse struct {
	// Message Human-readable result message
	Message string `json:"message"`

	// Timestamp When the action was triggered
	Timestamp *time.Time `json:"timestamp,omitempty"`
}

ActionResponse Response for action endpoints

type ApplyNowServer202JSONResponse

type ApplyNowServer202JSONResponse ActionResponse

func (ApplyNowServer202JSONResponse) VisitApplyNowServerResponse

func (response ApplyNowServer202JSONResponse) VisitApplyNowServerResponse(w http.ResponseWriter) error

type ApplyNowServer404JSONResponse

type ApplyNowServer404JSONResponse struct{ NotFoundJSONResponse }

func (ApplyNowServer404JSONResponse) VisitApplyNowServerResponse

func (response ApplyNowServer404JSONResponse) VisitApplyNowServerResponse(w http.ResponseWriter) error

type ApplyNowServer500JSONResponse

type ApplyNowServer500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (ApplyNowServer500JSONResponse) VisitApplyNowServerResponse

func (response ApplyNowServer500JSONResponse) VisitApplyNowServerResponse(w http.ResponseWriter) error

type ApplyNowServerRequestObject

type ApplyNowServerRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      ServerName `json:"name"`
}

type ApplyNowServerResponseObject

type ApplyNowServerResponseObject interface {
	VisitApplyNowServerResponse(w http.ResponseWriter) error
}

type AvailableUpdate

type AvailableUpdate struct {
	// Build Available Paper build number
	Build *int `json:"build,omitempty"`

	// FoundAt When this update was discovered
	FoundAt *time.Time `json:"foundAt,omitempty"`

	// Plugins Plugin versions for this update
	Plugins *[]PluginVersionPair `json:"plugins,omitempty"`

	// ReleasedAt When this version was released
	ReleasedAt *time.Time `json:"releasedAt,omitempty"`

	// Version Available Paper version
	Version *string `json:"version,omitempty"`
}

AvailableUpdate Information about an available update

type BadRequest

type BadRequest = ErrorResponse

BadRequest Error response body

type BadRequestJSONResponse

type BadRequestJSONResponse ErrorResponse

type BlockedByInfo

type BlockedByInfo struct {
	// Plugin Name of the blocking plugin
	Plugin *string `json:"plugin,omitempty"`

	// SupportedVersions Minecraft versions this plugin supports
	SupportedVersions *[]string `json:"supportedVersions,omitempty"`

	// Version Version of the blocking plugin
	Version *string `json:"version,omitempty"`
}

BlockedByInfo Details about what is blocking an update

type CompatibilityOverride

type CompatibilityOverride struct {
	// Enabled Whether to use override instead of API metadata
	Enabled *bool `json:"enabled,omitempty"`

	// MinecraftVersions Supported Minecraft versions
	MinecraftVersions *[]string `json:"minecraftVersions,omitempty"`
}

CompatibilityOverride Manual compatibility specification

type Condition

type Condition struct {
	// LastTransitionTime When the condition last changed
	LastTransitionTime *time.Time `json:"lastTransitionTime,omitempty"`

	// Message Human-readable message
	Message *string `json:"message,omitempty"`

	// ObservedGeneration Generation of the resource when condition was set
	ObservedGeneration *int64 `json:"observedGeneration,omitempty"`

	// Reason Machine-readable reason for the condition
	Reason *string `json:"reason,omitempty"`

	// Status Status of a condition (True, False, or Unknown)
	Status ConditionStatus `json:"status"`

	// Type Condition type
	Type string `json:"type"`
}

Condition Kubernetes condition

type ConditionStatus

type ConditionStatus string

ConditionStatus Status of a condition (True, False, or Unknown)

const (
	ConditionStatusFalse   ConditionStatus = "False"
	ConditionStatusTrue    ConditionStatus = "True"
	ConditionStatusUnknown ConditionStatus = "Unknown"
)

Defines values for ConditionStatus.

func (ConditionStatus) Valid

func (e ConditionStatus) Valid() bool

Valid indicates whether the value is a known member of the ConditionStatus enum.

type Conflict

type Conflict = ErrorResponse

Conflict Error response body

type ConflictJSONResponse

type ConflictJSONResponse ErrorResponse

type CreatePlugin201JSONResponse

type CreatePlugin201JSONResponse PluginDetail

func (CreatePlugin201JSONResponse) VisitCreatePluginResponse

func (response CreatePlugin201JSONResponse) VisitCreatePluginResponse(w http.ResponseWriter) error

type CreatePlugin400JSONResponse

type CreatePlugin400JSONResponse struct{ BadRequestJSONResponse }

func (CreatePlugin400JSONResponse) VisitCreatePluginResponse

func (response CreatePlugin400JSONResponse) VisitCreatePluginResponse(w http.ResponseWriter) error

type CreatePlugin409JSONResponse

type CreatePlugin409JSONResponse struct{ ConflictJSONResponse }

func (CreatePlugin409JSONResponse) VisitCreatePluginResponse

func (response CreatePlugin409JSONResponse) VisitCreatePluginResponse(w http.ResponseWriter) error

type CreatePlugin500JSONResponse

type CreatePlugin500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (CreatePlugin500JSONResponse) VisitCreatePluginResponse

func (response CreatePlugin500JSONResponse) VisitCreatePluginResponse(w http.ResponseWriter) error

type CreatePluginJSONRequestBody

type CreatePluginJSONRequestBody = PluginCreateRequest

CreatePluginJSONRequestBody defines body for CreatePlugin for application/json ContentType.

type CreatePluginRequestObject

type CreatePluginRequestObject struct {
	Body *CreatePluginJSONRequestBody
}

type CreatePluginResponseObject

type CreatePluginResponseObject interface {
	VisitCreatePluginResponse(w http.ResponseWriter) error
}

type CreateServer201JSONResponse

type CreateServer201JSONResponse ServerDetail

func (CreateServer201JSONResponse) VisitCreateServerResponse

func (response CreateServer201JSONResponse) VisitCreateServerResponse(w http.ResponseWriter) error

type CreateServer400JSONResponse

type CreateServer400JSONResponse struct{ BadRequestJSONResponse }

func (CreateServer400JSONResponse) VisitCreateServerResponse

func (response CreateServer400JSONResponse) VisitCreateServerResponse(w http.ResponseWriter) error

type CreateServer409JSONResponse

type CreateServer409JSONResponse struct{ ConflictJSONResponse }

func (CreateServer409JSONResponse) VisitCreateServerResponse

func (response CreateServer409JSONResponse) VisitCreateServerResponse(w http.ResponseWriter) error

type CreateServer500JSONResponse

type CreateServer500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (CreateServer500JSONResponse) VisitCreateServerResponse

func (response CreateServer500JSONResponse) VisitCreateServerResponse(w http.ResponseWriter) error

type CreateServerJSONRequestBody

type CreateServerJSONRequestBody = ServerCreateRequest

CreateServerJSONRequestBody defines body for CreateServer for application/json ContentType.

type CreateServerRequestObject

type CreateServerRequestObject struct {
	Body *CreateServerJSONRequestBody
}

type CreateServerResponseObject

type CreateServerResponseObject interface {
	VisitCreateServerResponse(w http.ResponseWriter) error
}

type DeletePlugin204Response

type DeletePlugin204Response struct {
}

func (DeletePlugin204Response) VisitDeletePluginResponse

func (response DeletePlugin204Response) VisitDeletePluginResponse(w http.ResponseWriter) error

type DeletePlugin404JSONResponse

type DeletePlugin404JSONResponse struct{ NotFoundJSONResponse }

func (DeletePlugin404JSONResponse) VisitDeletePluginResponse

func (response DeletePlugin404JSONResponse) VisitDeletePluginResponse(w http.ResponseWriter) error

type DeletePlugin500JSONResponse

type DeletePlugin500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (DeletePlugin500JSONResponse) VisitDeletePluginResponse

func (response DeletePlugin500JSONResponse) VisitDeletePluginResponse(w http.ResponseWriter) error

type DeletePluginRequestObject

type DeletePluginRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      PluginName `json:"name"`
}

type DeletePluginResponseObject

type DeletePluginResponseObject interface {
	VisitDeletePluginResponse(w http.ResponseWriter) error
}

type DeleteServer204Response

type DeleteServer204Response struct {
}

func (DeleteServer204Response) VisitDeleteServerResponse

func (response DeleteServer204Response) VisitDeleteServerResponse(w http.ResponseWriter) error

type DeleteServer404JSONResponse

type DeleteServer404JSONResponse struct{ NotFoundJSONResponse }

func (DeleteServer404JSONResponse) VisitDeleteServerResponse

func (response DeleteServer404JSONResponse) VisitDeleteServerResponse(w http.ResponseWriter) error

type DeleteServer500JSONResponse

type DeleteServer500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (DeleteServer500JSONResponse) VisitDeleteServerResponse

func (response DeleteServer500JSONResponse) VisitDeleteServerResponse(w http.ResponseWriter) error

type DeleteServerRequestObject

type DeleteServerRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      ServerName `json:"name"`
}

type DeleteServerResponseObject

type DeleteServerResponseObject interface {
	VisitDeleteServerResponse(w http.ResponseWriter) error
}

type DeletionProgressEntry

type DeletionProgressEntry struct {
	// DeletedAt When the JAR was deleted
	DeletedAt *time.Time `json:"deletedAt,omitempty"`

	// JarDeleted Whether the JAR has been deleted
	JarDeleted bool `json:"jarDeleted"`

	// Namespace Server namespace
	Namespace string `json:"namespace"`

	// ServerName Server name
	ServerName string `json:"serverName"`
}

DeletionProgressEntry JAR cleanup progress for a server

type ErrorResponse

type ErrorResponse struct {
	// Code Machine-readable error code
	Code *ErrorResponseCode `json:"code,omitempty"`

	// Details Additional error details
	Details *map[string]interface{} `json:"details,omitempty"`

	// Error Human-readable error message
	Error string `json:"error"`
}

ErrorResponse Error response body

type ErrorResponseCode

type ErrorResponseCode string

ErrorResponseCode Machine-readable error code

const (
	ALREADYEXISTS  ErrorResponseCode = "ALREADY_EXISTS"
	FORBIDDEN      ErrorResponseCode = "FORBIDDEN"
	INTERNALERROR  ErrorResponseCode = "INTERNAL_ERROR"
	INVALIDREQUEST ErrorResponseCode = "INVALID_REQUEST"
	NOTFOUND       ErrorResponseCode = "NOT_FOUND"
	UNAUTHORIZED   ErrorResponseCode = "UNAUTHORIZED"
)

Defines values for ErrorResponseCode.

func (ErrorResponseCode) Valid

func (e ErrorResponseCode) Valid() bool

Valid indicates whether the value is a known member of the ErrorResponseCode enum.

type GetHealth200JSONResponse

type GetHealth200JSONResponse HealthResponse

func (GetHealth200JSONResponse) VisitGetHealthResponse

func (response GetHealth200JSONResponse) VisitGetHealthResponse(w http.ResponseWriter) error

type GetHealth503JSONResponse

type GetHealth503JSONResponse HealthResponse

func (GetHealth503JSONResponse) VisitGetHealthResponse

func (response GetHealth503JSONResponse) VisitGetHealthResponse(w http.ResponseWriter) error

type GetHealthRequestObject

type GetHealthRequestObject struct {
}

type GetHealthResponseObject

type GetHealthResponseObject interface {
	VisitGetHealthResponse(w http.ResponseWriter) error
}

type GetPlugin200JSONResponse

type GetPlugin200JSONResponse PluginDetail

func (GetPlugin200JSONResponse) VisitGetPluginResponse

func (response GetPlugin200JSONResponse) VisitGetPluginResponse(w http.ResponseWriter) error

type GetPlugin404JSONResponse

type GetPlugin404JSONResponse struct{ NotFoundJSONResponse }

func (GetPlugin404JSONResponse) VisitGetPluginResponse

func (response GetPlugin404JSONResponse) VisitGetPluginResponse(w http.ResponseWriter) error

type GetPlugin500JSONResponse

type GetPlugin500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (GetPlugin500JSONResponse) VisitGetPluginResponse

func (response GetPlugin500JSONResponse) VisitGetPluginResponse(w http.ResponseWriter) error

type GetPluginRequestObject

type GetPluginRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      PluginName `json:"name"`
}

type GetPluginResponseObject

type GetPluginResponseObject interface {
	VisitGetPluginResponse(w http.ResponseWriter) error
}

type GetServer200JSONResponse

type GetServer200JSONResponse ServerDetail

func (GetServer200JSONResponse) VisitGetServerResponse

func (response GetServer200JSONResponse) VisitGetServerResponse(w http.ResponseWriter) error

type GetServer404JSONResponse

type GetServer404JSONResponse struct{ NotFoundJSONResponse }

func (GetServer404JSONResponse) VisitGetServerResponse

func (response GetServer404JSONResponse) VisitGetServerResponse(w http.ResponseWriter) error

type GetServer500JSONResponse

type GetServer500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (GetServer500JSONResponse) VisitGetServerResponse

func (response GetServer500JSONResponse) VisitGetServerResponse(w http.ResponseWriter) error

type GetServerRequestObject

type GetServerRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      ServerName `json:"name"`
}

type GetServerResponseObject

type GetServerResponseObject interface {
	VisitGetServerResponse(w http.ResponseWriter) error
}

type GetVersion200JSONResponse

type GetVersion200JSONResponse VersionResponse

func (GetVersion200JSONResponse) VisitGetVersionResponse

func (response GetVersion200JSONResponse) VisitGetVersionResponse(w http.ResponseWriter) error

type GetVersionRequestObject

type GetVersionRequestObject struct {
}

type GetVersionResponseObject

type GetVersionResponseObject interface {
	VisitGetVersionResponse(w http.ResponseWriter) error
}

type HealthResponse

type HealthResponse struct {
	// Error Error message if unhealthy
	Error *string `json:"error,omitempty"`

	// Status Health status of the API server
	Status HealthResponseStatus `json:"status"`

	// Timestamp Timestamp when health check was performed
	Timestamp time.Time `json:"timestamp"`
}

HealthResponse Health check response

type HealthResponseStatus

type HealthResponseStatus string

HealthResponseStatus Health status of the API server

const (
	Healthy   HealthResponseStatus = "healthy"
	Unhealthy HealthResponseStatus = "unhealthy"
)

Defines values for HealthResponseStatus.

func (HealthResponseStatus) Valid

func (e HealthResponseStatus) Valid() bool

Valid indicates whether the value is a known member of the HealthResponseStatus enum.

type InternalServerError

type InternalServerError = ErrorResponse

InternalServerError Error response body

type InternalServerErrorJSONResponse

type InternalServerErrorJSONResponse ErrorResponse

type InvalidParamFormatError

type InvalidParamFormatError struct {
	ParamName string
	Err       error
}

func (*InvalidParamFormatError) Error

func (e *InvalidParamFormatError) Error() string

func (*InvalidParamFormatError) Unwrap

func (e *InvalidParamFormatError) Unwrap() error

type LabelSelector

type LabelSelector struct {
	// MatchExpressions Label selector expressions
	MatchExpressions *[]LabelSelectorRequirement `json:"matchExpressions,omitempty"`

	// MatchLabels Labels that must match exactly
	MatchLabels *map[string]string `json:"matchLabels,omitempty"`
}

LabelSelector Kubernetes label selector

type LabelSelectorRequirement

type LabelSelectorRequirement struct {
	// Key Label key
	Key string `json:"key"`

	// Operator Operator (In, NotIn, Exists, DoesNotExist)
	Operator LabelSelectorRequirementOperator `json:"operator"`

	// Values Values for In/NotIn operators
	Values *[]string `json:"values,omitempty"`
}

LabelSelectorRequirement A label selector requirement

type LabelSelectorRequirementOperator

type LabelSelectorRequirementOperator string

LabelSelectorRequirementOperator Operator (In, NotIn, Exists, DoesNotExist)

const (
	DoesNotExist LabelSelectorRequirementOperator = "DoesNotExist"
	Exists       LabelSelectorRequirementOperator = "Exists"
	In           LabelSelectorRequirementOperator = "In"
	NotIn        LabelSelectorRequirementOperator = "NotIn"
)

Defines values for LabelSelectorRequirementOperator.

func (LabelSelectorRequirementOperator) Valid

Valid indicates whether the value is a known member of the LabelSelectorRequirementOperator enum.

type ListNamespaces200JSONResponse

type ListNamespaces200JSONResponse NamespaceListResponse

func (ListNamespaces200JSONResponse) VisitListNamespacesResponse

func (response ListNamespaces200JSONResponse) VisitListNamespacesResponse(w http.ResponseWriter) error

type ListNamespaces500JSONResponse

type ListNamespaces500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (ListNamespaces500JSONResponse) VisitListNamespacesResponse

func (response ListNamespaces500JSONResponse) VisitListNamespacesResponse(w http.ResponseWriter) error

type ListNamespacesRequestObject

type ListNamespacesRequestObject struct {
}

type ListNamespacesResponseObject

type ListNamespacesResponseObject interface {
	VisitListNamespacesResponse(w http.ResponseWriter) error
}

type ListPlugins200JSONResponse

type ListPlugins200JSONResponse PluginListResponse

func (ListPlugins200JSONResponse) VisitListPluginsResponse

func (response ListPlugins200JSONResponse) VisitListPluginsResponse(w http.ResponseWriter) error

type ListPlugins500JSONResponse

type ListPlugins500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (ListPlugins500JSONResponse) VisitListPluginsResponse

func (response ListPlugins500JSONResponse) VisitListPluginsResponse(w http.ResponseWriter) error

type ListPluginsParams

type ListPluginsParams struct {
	// Namespace Filter plugins by Kubernetes namespace
	Namespace *string `form:"namespace,omitempty" json:"namespace,omitempty"`
}

ListPluginsParams defines parameters for ListPlugins.

type ListPluginsRequestObject

type ListPluginsRequestObject struct {
	Params ListPluginsParams
}

type ListPluginsResponseObject

type ListPluginsResponseObject interface {
	VisitListPluginsResponse(w http.ResponseWriter) error
}

type ListServers200JSONResponse

type ListServers200JSONResponse ServerListResponse

func (ListServers200JSONResponse) VisitListServersResponse

func (response ListServers200JSONResponse) VisitListServersResponse(w http.ResponseWriter) error

type ListServers500JSONResponse

type ListServers500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (ListServers500JSONResponse) VisitListServersResponse

func (response ListServers500JSONResponse) VisitListServersResponse(w http.ResponseWriter) error

type ListServersParams

type ListServersParams struct {
	// Namespace Filter servers by Kubernetes namespace
	Namespace *string `form:"namespace,omitempty" json:"namespace,omitempty"`
}

ListServersParams defines parameters for ListServers.

type ListServersRequestObject

type ListServersRequestObject struct {
	Params ListServersParams
}

type ListServersResponseObject

type ListServersResponseObject interface {
	VisitListServersResponse(w http.ResponseWriter) error
}

type MaintenanceSchedule

type MaintenanceSchedule struct {
	// CheckCron Cron expression for update checks
	CheckCron *string `json:"checkCron,omitempty"`

	// Enabled Whether maintenance window is enabled
	Enabled *bool `json:"enabled,omitempty"`

	// NextWindow Human-readable next maintenance window
	NextWindow *string `json:"nextWindow,omitempty"`

	// WindowCron Cron expression for maintenance window
	WindowCron *string `json:"windowCron,omitempty"`
}

MaintenanceSchedule Maintenance schedule configuration

type MaintenanceWindowConfig

type MaintenanceWindowConfig struct {
	// Cron Cron expression for maintenance window
	Cron *string `json:"cron,omitempty"`

	// Enabled Whether to enable maintenance window
	Enabled *bool `json:"enabled,omitempty"`
}

MaintenanceWindowConfig Maintenance window configuration for create/update requests

type MatchedInstance

type MatchedInstance struct {
	// Compatible Whether the plugin is compatible with this server
	Compatible bool `json:"compatible"`

	// Name Server resource name
	Name string `json:"name"`

	// Namespace Server namespace
	Namespace string `json:"namespace"`

	// Version Server's current Paper version
	Version *string `json:"version,omitempty"`
}

MatchedInstance A server instance matched by the plugin's instance selector

type MiddlewareFunc

type MiddlewareFunc func(http.Handler) http.Handler

type Namespace

type Namespace = string

Namespace defines model for Namespace.

type NamespaceListResponse

type NamespaceListResponse struct {
	// Namespaces List of namespace names
	Namespaces []string `json:"namespaces"`
}

NamespaceListResponse defines model for NamespaceListResponse.

type NotFound

type NotFound = ErrorResponse

NotFound Error response body

type NotFoundJSONResponse

type NotFoundJSONResponse ErrorResponse

type PluginCreateRequest

type PluginCreateRequest struct {
	// Build Pinned build number (for build-pin strategy)
	Build *int `json:"build,omitempty"`

	// CompatibilityOverride Manual compatibility specification
	CompatibilityOverride *CompatibilityOverride `json:"compatibilityOverride,omitempty"`

	// InstanceSelector Kubernetes label selector
	InstanceSelector LabelSelector `json:"instanceSelector"`

	// Name Kubernetes resource name
	Name string `json:"name"`

	// Namespace Kubernetes namespace
	Namespace string `json:"namespace"`

	// Port Network port to expose via Service
	Port *int `json:"port,omitempty"`

	// Source Plugin source configuration
	Source PluginSource `json:"source"`

	// UpdateDelay Grace period before applying updates
	UpdateDelay *string `json:"updateDelay,omitempty"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy *UpdateStrategy `json:"updateStrategy,omitempty"`

	// Version Pinned version (required for pin/build-pin strategies)
	Version *string `json:"version,omitempty"`
}

PluginCreateRequest Request body for creating a new Plugin

type PluginDetail

type PluginDetail struct {
	// AvailableVersions Cached version metadata from repository
	AvailableVersions *[]PluginVersion `json:"availableVersions,omitempty"`

	// Build Pinned build number (for build-pin strategy)
	Build *int `json:"build,omitempty"`

	// CompatibilityOverride Manual compatibility specification
	CompatibilityOverride *CompatibilityOverride `json:"compatibilityOverride,omitempty"`

	// Conditions Kubernetes conditions for the plugin
	Conditions *[]Condition `json:"conditions,omitempty"`

	// DeletionProgress JAR cleanup progress during plugin deletion
	DeletionProgress *[]DeletionProgressEntry `json:"deletionProgress,omitempty"`

	// InstanceSelector Kubernetes label selector
	InstanceSelector *LabelSelector `json:"instanceSelector,omitempty"`

	// LastFetched When metadata was last fetched from repository
	LastFetched *time.Time `json:"lastFetched,omitempty"`

	// MatchedInstances List of servers this plugin is matched to
	MatchedInstances *[]MatchedInstance `json:"matchedInstances,omitempty"`

	// MatchedServers Number of servers this plugin is matched to
	MatchedServers *int `json:"matchedServers,omitempty"`

	// Name Kubernetes resource name
	Name string `json:"name"`

	// Namespace Kubernetes namespace
	Namespace string `json:"namespace"`

	// Port Network port exposed by the plugin (added to Service)
	Port *int `json:"port,omitempty"`

	// Project Project identifier in the repository
	Project *string `json:"project,omitempty"`

	// RepositoryStatus Status of the plugin repository connection.
	//
	// - **available**: Repository is accessible and returning metadata
	// - **unavailable**: Repository is temporarily unavailable (using cached data)
	// - **orphaned**: Plugin source no longer exists in repository
	RepositoryStatus *RepositoryStatus `json:"repositoryStatus,omitempty"`

	// ResolvedVersion Version resolved by the constraint solver
	ResolvedVersion *string `json:"resolvedVersion,omitempty"`

	// SourceType Type of plugin repository.
	//
	// - **hangar**: PaperMC Hangar repository (hangar.papermc.io)
	// - **url**: Direct URL download (no version management)
	SourceType PluginSourceType `json:"sourceType"`

	// UpdateDelay Grace period before applying updates
	UpdateDelay *string `json:"updateDelay,omitempty"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy UpdateStrategy `json:"updateStrategy"`

	// Url Direct download URL (for type=url)
	Url *string `json:"url,omitempty"`

	// Version Pinned version (for pin/build-pin strategies)
	Version *string `json:"version,omitempty"`
}

PluginDetail defines model for PluginDetail.

type PluginListResponse

type PluginListResponse struct {
	// Plugins List of plugin summaries
	Plugins []PluginSummary `json:"plugins"`
}

PluginListResponse defines model for PluginListResponse.

type PluginName

type PluginName = string

PluginName defines model for PluginName.

type PluginSource

type PluginSource struct {
	// Checksum Expected SHA256 hash of the JAR file (for url type).
	// If not provided, downloads will not be verified.
	Checksum *string `json:"checksum,omitempty"`

	// Project Project identifier in the repository.
	// Required for hangar type.
	Project *string `json:"project,omitempty"`

	// Type Type of plugin repository.
	//
	// - **hangar**: PaperMC Hangar repository (hangar.papermc.io)
	// - **url**: Direct URL download (no version management)
	Type PluginSourceType `json:"type"`

	// Url Direct download URL.
	// Required for url type.
	Url *string `json:"url,omitempty"`
}

PluginSource Plugin source configuration

type PluginSourceType

type PluginSourceType string

PluginSourceType Type of plugin repository.

- **hangar**: PaperMC Hangar repository (hangar.papermc.io) - **url**: Direct URL download (no version management)

const (
	Hangar PluginSourceType = "hangar"
	Url    PluginSourceType = "url"
)

Defines values for PluginSourceType.

func (PluginSourceType) Valid

func (e PluginSourceType) Valid() bool

Valid indicates whether the value is a known member of the PluginSourceType enum.

type PluginSummary

type PluginSummary struct {
	// Build Pinned build number (for build-pin strategy)
	Build *int `json:"build,omitempty"`

	// MatchedServers Number of servers this plugin is matched to
	MatchedServers *int `json:"matchedServers,omitempty"`

	// Name Kubernetes resource name
	Name string `json:"name"`

	// Namespace Kubernetes namespace
	Namespace string `json:"namespace"`

	// Project Project identifier in the repository
	Project *string `json:"project,omitempty"`

	// RepositoryStatus Status of the plugin repository connection.
	//
	// - **available**: Repository is accessible and returning metadata
	// - **unavailable**: Repository is temporarily unavailable (using cached data)
	// - **orphaned**: Plugin source no longer exists in repository
	RepositoryStatus *RepositoryStatus `json:"repositoryStatus,omitempty"`

	// ResolvedVersion Version resolved by the constraint solver
	ResolvedVersion *string `json:"resolvedVersion,omitempty"`

	// SourceType Type of plugin repository.
	//
	// - **hangar**: PaperMC Hangar repository (hangar.papermc.io)
	// - **url**: Direct URL download (no version management)
	SourceType PluginSourceType `json:"sourceType"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy UpdateStrategy `json:"updateStrategy"`

	// Url Direct download URL (for type=url)
	Url *string `json:"url,omitempty"`

	// Version Pinned version (for pin/build-pin strategies)
	Version *string `json:"version,omitempty"`
}

PluginSummary Summary information about a Plugin

type PluginUpdateRequest

type PluginUpdateRequest struct {
	// Build Pinned build number
	Build *int `json:"build,omitempty"`

	// CompatibilityOverride Manual compatibility specification
	CompatibilityOverride *CompatibilityOverride `json:"compatibilityOverride,omitempty"`

	// InstanceSelector Kubernetes label selector
	InstanceSelector *LabelSelector `json:"instanceSelector,omitempty"`

	// Port Network port to expose
	Port *int `json:"port,omitempty"`

	// Source Plugin source configuration
	Source *PluginSource `json:"source,omitempty"`

	// UpdateDelay Grace period before applying updates
	UpdateDelay *string `json:"updateDelay,omitempty"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy *UpdateStrategy `json:"updateStrategy,omitempty"`

	// Version Pinned version
	Version *string `json:"version,omitempty"`
}

PluginUpdateRequest Request body for updating an existing Plugin

type PluginVersion

type PluginVersion struct {
	// CachedAt When this metadata was cached
	CachedAt *time.Time `json:"cachedAt,omitempty"`

	// DownloadUrl URL to download this version
	DownloadUrl string `json:"downloadUrl"`

	// Hash SHA256 hash of the JAR file
	Hash *string `json:"hash,omitempty"`

	// MinecraftVersions Compatible Minecraft versions
	MinecraftVersions []string `json:"minecraftVersions"`

	// ReleasedAt When this version was released
	ReleasedAt *time.Time `json:"releasedAt,omitempty"`

	// Version Plugin version string
	Version string `json:"version"`
}

PluginVersion Metadata about a specific plugin version

type PluginVersionPair

type PluginVersionPair struct {
	// Name Plugin name
	Name *string `json:"name,omitempty"`

	// Namespace Plugin namespace
	Namespace *string `json:"namespace,omitempty"`

	// Version Plugin version
	Version *string `json:"version,omitempty"`
}

PluginVersionPair A plugin paired with its version for an update

type RCONConfig

type RCONConfig struct {
	// Enabled Whether RCON is enabled
	Enabled *bool `json:"enabled,omitempty"`

	// PasswordSecretKey Key within the Secret containing the password
	PasswordSecretKey *string `json:"passwordSecretKey,omitempty"`

	// PasswordSecretName Name of the Secret containing the RCON password
	PasswordSecretName *string `json:"passwordSecretName,omitempty"`

	// Port RCON port
	Port *int `json:"port,omitempty"`
}

RCONConfig RCON configuration for create/update requests

type RCONStatus

type RCONStatus struct {
	// Enabled Whether RCON is enabled
	Enabled *bool `json:"enabled,omitempty"`

	// Port RCON port
	Port *int `json:"port,omitempty"`
}

RCONStatus RCON status information

type RepositoryStatus

type RepositoryStatus string

RepositoryStatus Status of the plugin repository connection.

- **available**: Repository is accessible and returning metadata - **unavailable**: Repository is temporarily unavailable (using cached data) - **orphaned**: Plugin source no longer exists in repository

const (
	Available   RepositoryStatus = "available"
	Orphaned    RepositoryStatus = "orphaned"
	Unavailable RepositoryStatus = "unavailable"
)

Defines values for RepositoryStatus.

func (RepositoryStatus) Valid

func (e RepositoryStatus) Valid() bool

Valid indicates whether the value is a known member of the RepositoryStatus enum.

type RequiredHeaderError

type RequiredHeaderError struct {
	ParamName string
	Err       error
}

func (*RequiredHeaderError) Error

func (e *RequiredHeaderError) Error() string

func (*RequiredHeaderError) Unwrap

func (e *RequiredHeaderError) Unwrap() error

type RequiredParamError

type RequiredParamError struct {
	ParamName string
}

func (*RequiredParamError) Error

func (e *RequiredParamError) Error() string

type ResolvePlugin202JSONResponse

type ResolvePlugin202JSONResponse ActionResponse

func (ResolvePlugin202JSONResponse) VisitResolvePluginResponse

func (response ResolvePlugin202JSONResponse) VisitResolvePluginResponse(w http.ResponseWriter) error

type ResolvePlugin404JSONResponse

type ResolvePlugin404JSONResponse struct{ NotFoundJSONResponse }

func (ResolvePlugin404JSONResponse) VisitResolvePluginResponse

func (response ResolvePlugin404JSONResponse) VisitResolvePluginResponse(w http.ResponseWriter) error

type ResolvePlugin500JSONResponse

type ResolvePlugin500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (ResolvePlugin500JSONResponse) VisitResolvePluginResponse

func (response ResolvePlugin500JSONResponse) VisitResolvePluginResponse(w http.ResponseWriter) error

type ResolvePluginRequestObject

type ResolvePluginRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      PluginName `json:"name"`
}

type ResolvePluginResponseObject

type ResolvePluginResponseObject interface {
	VisitResolvePluginResponse(w http.ResponseWriter) error
}

type ResolveServer202JSONResponse

type ResolveServer202JSONResponse ActionResponse

func (ResolveServer202JSONResponse) VisitResolveServerResponse

func (response ResolveServer202JSONResponse) VisitResolveServerResponse(w http.ResponseWriter) error

type ResolveServer404JSONResponse

type ResolveServer404JSONResponse struct{ NotFoundJSONResponse }

func (ResolveServer404JSONResponse) VisitResolveServerResponse

func (response ResolveServer404JSONResponse) VisitResolveServerResponse(w http.ResponseWriter) error

type ResolveServer500JSONResponse

type ResolveServer500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (ResolveServer500JSONResponse) VisitResolveServerResponse

func (response ResolveServer500JSONResponse) VisitResolveServerResponse(w http.ResponseWriter) error

type ResolveServerRequestObject

type ResolveServerRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      ServerName `json:"name"`
}

type ResolveServerResponseObject

type ResolveServerResponseObject interface {
	VisitResolveServerResponse(w http.ResponseWriter) error
}

type ServeMux

type ServeMux interface {
	HandleFunc(pattern string, handler func(http.ResponseWriter, *http.Request))
	ServeHTTP(w http.ResponseWriter, r *http.Request)
}

ServeMux is an abstraction of http.ServeMux.

type ServerCreateRequest

type ServerCreateRequest struct {
	// Build Target Paper build number (required for build-pin strategy).
	// For pin strategy, serves as minimum build.
	Build *int `json:"build,omitempty"`

	// CheckCron Cron expression for update checks.
	// Format: minute hour day month weekday
	CheckCron *string `json:"checkCron,omitempty"`

	// GracefulShutdownTimeout Graceful shutdown timeout (Go duration format).
	// Must match StatefulSet terminationGracePeriodSeconds.
	GracefulShutdownTimeout *string `json:"gracefulShutdownTimeout,omitempty"`

	// Labels Labels to apply to the server resource
	Labels *map[string]string `json:"labels,omitempty"`

	// MaintenanceWindow Maintenance window configuration for create/update requests
	MaintenanceWindow *MaintenanceWindowConfig `json:"maintenanceWindow,omitempty"`

	// Name Kubernetes resource name (must be valid DNS subdomain)
	Name string `json:"name"`

	// Namespace Kubernetes namespace to create the server in
	Namespace string `json:"namespace"`

	// Rcon RCON configuration for create/update requests
	Rcon *RCONConfig `json:"rcon,omitempty"`

	// Service Kubernetes Service configuration
	Service *ServiceConfig `json:"service,omitempty"`

	// UpdateDelay Grace period before applying updates (Go duration format).
	// Examples: "168h" (7 days), "24h", "30m"
	UpdateDelay *string `json:"updateDelay,omitempty"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy UpdateStrategy `json:"updateStrategy"`

	// Version Target Paper version (required for pin and build-pin strategies).
	// Example: "1.21.1" for Minecraft 1.21.1
	Version *string `json:"version,omitempty"`
}

ServerCreateRequest Request body for creating a new PaperMCServer

type ServerDetail

type ServerDetail struct {
	// AvailableUpdate Information about an available update
	AvailableUpdate *AvailableUpdate `json:"availableUpdate,omitempty"`

	// Conditions Kubernetes conditions for the server
	Conditions *[]Condition `json:"conditions,omitempty"`

	// CurrentBuild Currently running Paper build number
	CurrentBuild *int `json:"currentBuild,omitempty"`

	// CurrentVersion Currently running Paper version with build number (e.g., "1.21.1-100")
	CurrentVersion *string `json:"currentVersion,omitempty"`

	// DesiredBuild Target Paper build number
	DesiredBuild *int `json:"desiredBuild,omitempty"`

	// DesiredVersion Target Paper version the operator wants to run
	DesiredVersion *string `json:"desiredVersion,omitempty"`

	// Labels Kubernetes labels from the server resource
	Labels *map[string]string `json:"labels,omitempty"`

	// LastUpdate Record of the last update attempt
	LastUpdate *UpdateHistory `json:"lastUpdate,omitempty"`

	// MaintenanceSchedule Maintenance schedule configuration
	MaintenanceSchedule *MaintenanceSchedule `json:"maintenanceSchedule,omitempty"`

	// Name Kubernetes resource name
	Name string `json:"name"`

	// Namespace Kubernetes namespace
	Namespace string `json:"namespace"`

	// NextMaintenance Human-readable description of next maintenance window
	NextMaintenance *string `json:"nextMaintenance,omitempty"`

	// PluginCount Number of plugins matched to this server
	PluginCount *int `json:"pluginCount,omitempty"`

	// Plugins List of plugins matched to this server
	Plugins *[]ServerPlugin `json:"plugins,omitempty"`

	// Rcon RCON status information
	Rcon *RCONStatus `json:"rcon,omitempty"`

	// Service Service status information
	Service *ServiceStatus `json:"service,omitempty"`

	// Status Current operational status of the server.
	//
	// - **running**: Server is running normally with all replicas ready
	// - **updating**: Server is being updated (StatefulSet rolling update in progress)
	// - **unknown**: Status cannot be determined (no condition or StatefulSet data)
	Status ServerStatus `json:"status"`

	// UpdateBlocked Information about blocked updates
	UpdateBlocked *UpdateBlockedStatus `json:"updateBlocked,omitempty"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy UpdateStrategy `json:"updateStrategy"`
}

ServerDetail defines model for ServerDetail.

type ServerInterface

type ServerInterface interface {
	// Health check endpoint
	// (GET /health)
	GetHealth(w http.ResponseWriter, r *http.Request)
	// List available namespaces
	// (GET /namespaces)
	ListNamespaces(w http.ResponseWriter, r *http.Request)
	// List all plugins
	// (GET /plugins)
	ListPlugins(w http.ResponseWriter, r *http.Request, params ListPluginsParams)
	// Create a new plugin
	// (POST /plugins)
	CreatePlugin(w http.ResponseWriter, r *http.Request)
	// Delete a plugin
	// (DELETE /plugins/{namespace}/{name})
	DeletePlugin(w http.ResponseWriter, r *http.Request, namespace Namespace, name PluginName)
	// Get a specific plugin
	// (GET /plugins/{namespace}/{name})
	GetPlugin(w http.ResponseWriter, r *http.Request, namespace Namespace, name PluginName)
	// Update a plugin
	// (PUT /plugins/{namespace}/{name})
	UpdatePlugin(w http.ResponseWriter, r *http.Request, namespace Namespace, name PluginName)
	// Trigger plugin reconciliation
	// (POST /plugins/{namespace}/{name}/actions/resolve)
	ResolvePlugin(w http.ResponseWriter, r *http.Request, namespace Namespace, name PluginName)
	// List all PaperMC servers
	// (GET /servers)
	ListServers(w http.ResponseWriter, r *http.Request, params ListServersParams)
	// Create a new PaperMC server
	// (POST /servers)
	CreateServer(w http.ResponseWriter, r *http.Request)
	// Delete a server
	// (DELETE /servers/{namespace}/{name})
	DeleteServer(w http.ResponseWriter, r *http.Request, namespace Namespace, name ServerName)
	// Get a specific server
	// (GET /servers/{namespace}/{name})
	GetServer(w http.ResponseWriter, r *http.Request, namespace Namespace, name ServerName)
	// Update a server
	// (PUT /servers/{namespace}/{name})
	UpdateServer(w http.ResponseWriter, r *http.Request, namespace Namespace, name ServerName)
	// Apply pending updates immediately
	// (POST /servers/{namespace}/{name}/actions/apply-now)
	ApplyNowServer(w http.ResponseWriter, r *http.Request, namespace Namespace, name ServerName)
	// Trigger server reconciliation
	// (POST /servers/{namespace}/{name}/actions/resolve)
	ResolveServer(w http.ResponseWriter, r *http.Request, namespace Namespace, name ServerName)
	// Get API version information
	// (GET /version)
	GetVersion(w http.ResponseWriter, r *http.Request)
}

ServerInterface represents all server handlers.

func NewStrictHandler

func NewStrictHandler(ssi StrictServerInterface, middlewares []StrictMiddlewareFunc) ServerInterface

func NewStrictHandlerWithOptions

func NewStrictHandlerWithOptions(ssi StrictServerInterface, middlewares []StrictMiddlewareFunc, options StrictHTTPServerOptions) ServerInterface

type ServerInterfaceWrapper

type ServerInterfaceWrapper struct {
	Handler            ServerInterface
	HandlerMiddlewares []MiddlewareFunc
	ErrorHandlerFunc   func(w http.ResponseWriter, r *http.Request, err error)
}

ServerInterfaceWrapper converts contexts to parameters.

func (*ServerInterfaceWrapper) ApplyNowServer

func (siw *ServerInterfaceWrapper) ApplyNowServer(w http.ResponseWriter, r *http.Request)

ApplyNowServer operation middleware

func (*ServerInterfaceWrapper) CreatePlugin

func (siw *ServerInterfaceWrapper) CreatePlugin(w http.ResponseWriter, r *http.Request)

CreatePlugin operation middleware

func (*ServerInterfaceWrapper) CreateServer

func (siw *ServerInterfaceWrapper) CreateServer(w http.ResponseWriter, r *http.Request)

CreateServer operation middleware

func (*ServerInterfaceWrapper) DeletePlugin

func (siw *ServerInterfaceWrapper) DeletePlugin(w http.ResponseWriter, r *http.Request)

DeletePlugin operation middleware

func (*ServerInterfaceWrapper) DeleteServer

func (siw *ServerInterfaceWrapper) DeleteServer(w http.ResponseWriter, r *http.Request)

DeleteServer operation middleware

func (*ServerInterfaceWrapper) GetHealth

func (siw *ServerInterfaceWrapper) GetHealth(w http.ResponseWriter, r *http.Request)

GetHealth operation middleware

func (*ServerInterfaceWrapper) GetPlugin

func (siw *ServerInterfaceWrapper) GetPlugin(w http.ResponseWriter, r *http.Request)

GetPlugin operation middleware

func (*ServerInterfaceWrapper) GetServer

func (siw *ServerInterfaceWrapper) GetServer(w http.ResponseWriter, r *http.Request)

GetServer operation middleware

func (*ServerInterfaceWrapper) GetVersion

func (siw *ServerInterfaceWrapper) GetVersion(w http.ResponseWriter, r *http.Request)

GetVersion operation middleware

func (*ServerInterfaceWrapper) ListNamespaces

func (siw *ServerInterfaceWrapper) ListNamespaces(w http.ResponseWriter, r *http.Request)

ListNamespaces operation middleware

func (*ServerInterfaceWrapper) ListPlugins

func (siw *ServerInterfaceWrapper) ListPlugins(w http.ResponseWriter, r *http.Request)

ListPlugins operation middleware

func (*ServerInterfaceWrapper) ListServers

func (siw *ServerInterfaceWrapper) ListServers(w http.ResponseWriter, r *http.Request)

ListServers operation middleware

func (*ServerInterfaceWrapper) ResolvePlugin

func (siw *ServerInterfaceWrapper) ResolvePlugin(w http.ResponseWriter, r *http.Request)

ResolvePlugin operation middleware

func (*ServerInterfaceWrapper) ResolveServer

func (siw *ServerInterfaceWrapper) ResolveServer(w http.ResponseWriter, r *http.Request)

ResolveServer operation middleware

func (*ServerInterfaceWrapper) UpdatePlugin

func (siw *ServerInterfaceWrapper) UpdatePlugin(w http.ResponseWriter, r *http.Request)

UpdatePlugin operation middleware

func (*ServerInterfaceWrapper) UpdateServer

func (siw *ServerInterfaceWrapper) UpdateServer(w http.ResponseWriter, r *http.Request)

UpdateServer operation middleware

type ServerListResponse

type ServerListResponse struct {
	// Servers List of server summaries
	Servers []ServerSummary `json:"servers"`
}

ServerListResponse defines model for ServerListResponse.

type ServerName

type ServerName = string

ServerName defines model for ServerName.

type ServerPlugin

type ServerPlugin struct {
	// Compatible Whether the plugin is compatible with the server version
	Compatible bool `json:"compatible"`

	// CurrentVersion Currently installed version on the server
	CurrentVersion *string `json:"currentVersion,omitempty"`

	// DesiredVersion Target version to install
	DesiredVersion *string `json:"desiredVersion,omitempty"`

	// InstalledJarName Filename of the installed JAR in /data/plugins/
	InstalledJarName *string `json:"installedJarName,omitempty"`

	// Name Plugin resource name
	Name string `json:"name"`

	// Namespace Plugin resource namespace
	Namespace *string `json:"namespace,omitempty"`

	// PendingDeletion Whether the plugin is marked for removal
	PendingDeletion *bool `json:"pendingDeletion,omitempty"`

	// Project Project identifier in the repository
	Project *string `json:"project,omitempty"`

	// ResolvedVersion Version resolved by the constraint solver
	ResolvedVersion *string `json:"resolvedVersion,omitempty"`

	// Source Plugin source type
	Source *string `json:"source,omitempty"`
}

ServerPlugin Status of a plugin on a specific server

type ServerStatus

type ServerStatus string

ServerStatus Current operational status of the server.

- **running**: Server is running normally with all replicas ready - **updating**: Server is being updated (StatefulSet rolling update in progress) - **unknown**: Status cannot be determined (no condition or StatefulSet data)

const (
	ServerStatusRunning  ServerStatus = "running"
	ServerStatusUnknown  ServerStatus = "unknown"
	ServerStatusUpdating ServerStatus = "updating"
)

Defines values for ServerStatus.

func (ServerStatus) Valid

func (e ServerStatus) Valid() bool

Valid indicates whether the value is a known member of the ServerStatus enum.

type ServerSummary

type ServerSummary struct {
	// AvailableUpdate Information about an available update
	AvailableUpdate *AvailableUpdate `json:"availableUpdate,omitempty"`

	// CurrentVersion Currently running Paper version with build number (e.g., "1.21.1-100")
	CurrentVersion *string `json:"currentVersion,omitempty"`

	// DesiredVersion Target Paper version the operator wants to run
	DesiredVersion *string `json:"desiredVersion,omitempty"`

	// Labels Kubernetes labels from the server resource
	Labels *map[string]string `json:"labels,omitempty"`

	// Name Kubernetes resource name
	Name string `json:"name"`

	// Namespace Kubernetes namespace
	Namespace string `json:"namespace"`

	// NextMaintenance Human-readable description of next maintenance window
	NextMaintenance *string `json:"nextMaintenance,omitempty"`

	// PluginCount Number of plugins matched to this server
	PluginCount *int `json:"pluginCount,omitempty"`

	// Status Current operational status of the server.
	//
	// - **running**: Server is running normally with all replicas ready
	// - **updating**: Server is being updated (StatefulSet rolling update in progress)
	// - **unknown**: Status cannot be determined (no condition or StatefulSet data)
	Status ServerStatus `json:"status"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy UpdateStrategy `json:"updateStrategy"`
}

ServerSummary Summary information about a PaperMCServer

type ServerUpdateRequest

type ServerUpdateRequest struct {
	// Build Target Paper build number
	Build *int `json:"build,omitempty"`

	// CheckCron Cron expression for update checks
	CheckCron *string `json:"checkCron,omitempty"`

	// Labels Labels to set on the server resource
	Labels *map[string]string `json:"labels,omitempty"`

	// MaintenanceWindow Maintenance window configuration for create/update requests
	MaintenanceWindow *MaintenanceWindowConfig `json:"maintenanceWindow,omitempty"`

	// UpdateDelay Grace period before applying updates
	UpdateDelay *string `json:"updateDelay,omitempty"`

	// UpdateStrategy Defines how versions are managed for servers and plugins.
	//
	// - **latest**: Always use the latest available version from the repository
	// - **auto**: Use constraint solver to find best version compatible with all dependencies
	// - **pin**: Pin to specific version, auto-update to latest build within that version
	// - **build-pin**: Pin to specific version AND build number, no automatic updates
	UpdateStrategy *UpdateStrategy `json:"updateStrategy,omitempty"`

	// Version Target Paper version
	Version *string `json:"version,omitempty"`
}

ServerUpdateRequest Request body for updating an existing PaperMCServer

type ServiceConfig

type ServiceConfig struct {
	// Annotations Custom annotations for the Service
	Annotations *map[string]string `json:"annotations,omitempty"`

	// LoadBalancerIP Static IP for LoadBalancer type
	LoadBalancerIP *string `json:"loadBalancerIP,omitempty"`

	// Type Kubernetes Service type for the server.
	//
	// - **LoadBalancer**: External load balancer (requires cloud provider or MetalLB)
	// - **NodePort**: Expose on a static port on each node
	// - **ClusterIP**: Internal cluster IP only
	Type *ServiceType `json:"type,omitempty"`
}

ServiceConfig Kubernetes Service configuration

type ServiceStatus

type ServiceStatus struct {
	// ClusterIP Cluster IP address
	ClusterIP *string `json:"clusterIP,omitempty"`

	// ExternalIP External IP address (for LoadBalancer)
	ExternalIP *string `json:"externalIP,omitempty"`

	// Type Kubernetes Service type for the server.
	//
	// - **LoadBalancer**: External load balancer (requires cloud provider or MetalLB)
	// - **NodePort**: Expose on a static port on each node
	// - **ClusterIP**: Internal cluster IP only
	Type *ServiceType `json:"type,omitempty"`
}

ServiceStatus Service status information

type ServiceType

type ServiceType string

ServiceType Kubernetes Service type for the server.

- **LoadBalancer**: External load balancer (requires cloud provider or MetalLB) - **NodePort**: Expose on a static port on each node - **ClusterIP**: Internal cluster IP only

const (
	ClusterIP    ServiceType = "ClusterIP"
	LoadBalancer ServiceType = "LoadBalancer"
	NodePort     ServiceType = "NodePort"
)

Defines values for ServiceType.

func (ServiceType) Valid

func (e ServiceType) Valid() bool

Valid indicates whether the value is a known member of the ServiceType enum.

type StdHTTPServerOptions

type StdHTTPServerOptions struct {
	BaseURL          string
	BaseRouter       ServeMux
	Middlewares      []MiddlewareFunc
	ErrorHandlerFunc func(w http.ResponseWriter, r *http.Request, err error)
}

type StrictHTTPServerOptions

type StrictHTTPServerOptions struct {
	RequestErrorHandlerFunc  func(w http.ResponseWriter, r *http.Request, err error)
	ResponseErrorHandlerFunc func(w http.ResponseWriter, r *http.Request, err error)
}

type StrictServerInterface

type StrictServerInterface interface {
	// Health check endpoint
	// (GET /health)
	GetHealth(ctx context.Context, request GetHealthRequestObject) (GetHealthResponseObject, error)
	// List available namespaces
	// (GET /namespaces)
	ListNamespaces(ctx context.Context, request ListNamespacesRequestObject) (ListNamespacesResponseObject, error)
	// List all plugins
	// (GET /plugins)
	ListPlugins(ctx context.Context, request ListPluginsRequestObject) (ListPluginsResponseObject, error)
	// Create a new plugin
	// (POST /plugins)
	CreatePlugin(ctx context.Context, request CreatePluginRequestObject) (CreatePluginResponseObject, error)
	// Delete a plugin
	// (DELETE /plugins/{namespace}/{name})
	DeletePlugin(ctx context.Context, request DeletePluginRequestObject) (DeletePluginResponseObject, error)
	// Get a specific plugin
	// (GET /plugins/{namespace}/{name})
	GetPlugin(ctx context.Context, request GetPluginRequestObject) (GetPluginResponseObject, error)
	// Update a plugin
	// (PUT /plugins/{namespace}/{name})
	UpdatePlugin(ctx context.Context, request UpdatePluginRequestObject) (UpdatePluginResponseObject, error)
	// Trigger plugin reconciliation
	// (POST /plugins/{namespace}/{name}/actions/resolve)
	ResolvePlugin(ctx context.Context, request ResolvePluginRequestObject) (ResolvePluginResponseObject, error)
	// List all PaperMC servers
	// (GET /servers)
	ListServers(ctx context.Context, request ListServersRequestObject) (ListServersResponseObject, error)
	// Create a new PaperMC server
	// (POST /servers)
	CreateServer(ctx context.Context, request CreateServerRequestObject) (CreateServerResponseObject, error)
	// Delete a server
	// (DELETE /servers/{namespace}/{name})
	DeleteServer(ctx context.Context, request DeleteServerRequestObject) (DeleteServerResponseObject, error)
	// Get a specific server
	// (GET /servers/{namespace}/{name})
	GetServer(ctx context.Context, request GetServerRequestObject) (GetServerResponseObject, error)
	// Update a server
	// (PUT /servers/{namespace}/{name})
	UpdateServer(ctx context.Context, request UpdateServerRequestObject) (UpdateServerResponseObject, error)
	// Apply pending updates immediately
	// (POST /servers/{namespace}/{name}/actions/apply-now)
	ApplyNowServer(ctx context.Context, request ApplyNowServerRequestObject) (ApplyNowServerResponseObject, error)
	// Trigger server reconciliation
	// (POST /servers/{namespace}/{name}/actions/resolve)
	ResolveServer(ctx context.Context, request ResolveServerRequestObject) (ResolveServerResponseObject, error)
	// Get API version information
	// (GET /version)
	GetVersion(ctx context.Context, request GetVersionRequestObject) (GetVersionResponseObject, error)
}

StrictServerInterface represents all server handlers.

type TooManyValuesForParamError

type TooManyValuesForParamError struct {
	ParamName string
	Count     int
}

func (*TooManyValuesForParamError) Error

type UnescapedCookieParamError

type UnescapedCookieParamError struct {
	ParamName string
	Err       error
}

func (*UnescapedCookieParamError) Error

func (e *UnescapedCookieParamError) Error() string

func (*UnescapedCookieParamError) Unwrap

func (e *UnescapedCookieParamError) Unwrap() error

type UnmarshalingParamError

type UnmarshalingParamError struct {
	ParamName string
	Err       error
}

func (*UnmarshalingParamError) Error

func (e *UnmarshalingParamError) Error() string

func (*UnmarshalingParamError) Unwrap

func (e *UnmarshalingParamError) Unwrap() error

type UpdateBlockedStatus

type UpdateBlockedStatus struct {
	// Blocked Whether updates are currently blocked
	Blocked *bool `json:"blocked,omitempty"`

	// BlockedBy Details about what is blocking an update
	BlockedBy *BlockedByInfo `json:"blockedBy,omitempty"`

	// Reason Human-readable reason for the block
	Reason *string `json:"reason,omitempty"`
}

UpdateBlockedStatus Information about blocked updates

type UpdateHistory

type UpdateHistory struct {
	// AppliedAt When the update was applied
	AppliedAt *time.Time `json:"appliedAt,omitempty"`

	// PreviousVersion Version before the update
	PreviousVersion *string `json:"previousVersion,omitempty"`

	// Successful Whether the update succeeded
	Successful *bool `json:"successful,omitempty"`
}

UpdateHistory Record of the last update attempt

type UpdatePlugin200JSONResponse

type UpdatePlugin200JSONResponse PluginDetail

func (UpdatePlugin200JSONResponse) VisitUpdatePluginResponse

func (response UpdatePlugin200JSONResponse) VisitUpdatePluginResponse(w http.ResponseWriter) error

type UpdatePlugin400JSONResponse

type UpdatePlugin400JSONResponse struct{ BadRequestJSONResponse }

func (UpdatePlugin400JSONResponse) VisitUpdatePluginResponse

func (response UpdatePlugin400JSONResponse) VisitUpdatePluginResponse(w http.ResponseWriter) error

type UpdatePlugin404JSONResponse

type UpdatePlugin404JSONResponse struct{ NotFoundJSONResponse }

func (UpdatePlugin404JSONResponse) VisitUpdatePluginResponse

func (response UpdatePlugin404JSONResponse) VisitUpdatePluginResponse(w http.ResponseWriter) error

type UpdatePlugin500JSONResponse

type UpdatePlugin500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (UpdatePlugin500JSONResponse) VisitUpdatePluginResponse

func (response UpdatePlugin500JSONResponse) VisitUpdatePluginResponse(w http.ResponseWriter) error

type UpdatePluginJSONRequestBody

type UpdatePluginJSONRequestBody = PluginUpdateRequest

UpdatePluginJSONRequestBody defines body for UpdatePlugin for application/json ContentType.

type UpdatePluginRequestObject

type UpdatePluginRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      PluginName `json:"name"`
	Body      *UpdatePluginJSONRequestBody
}

type UpdatePluginResponseObject

type UpdatePluginResponseObject interface {
	VisitUpdatePluginResponse(w http.ResponseWriter) error
}

type UpdateServer200JSONResponse

type UpdateServer200JSONResponse ServerDetail

func (UpdateServer200JSONResponse) VisitUpdateServerResponse

func (response UpdateServer200JSONResponse) VisitUpdateServerResponse(w http.ResponseWriter) error

type UpdateServer400JSONResponse

type UpdateServer400JSONResponse struct{ BadRequestJSONResponse }

func (UpdateServer400JSONResponse) VisitUpdateServerResponse

func (response UpdateServer400JSONResponse) VisitUpdateServerResponse(w http.ResponseWriter) error

type UpdateServer404JSONResponse

type UpdateServer404JSONResponse struct{ NotFoundJSONResponse }

func (UpdateServer404JSONResponse) VisitUpdateServerResponse

func (response UpdateServer404JSONResponse) VisitUpdateServerResponse(w http.ResponseWriter) error

type UpdateServer500JSONResponse

type UpdateServer500JSONResponse struct {
	InternalServerErrorJSONResponse
}

func (UpdateServer500JSONResponse) VisitUpdateServerResponse

func (response UpdateServer500JSONResponse) VisitUpdateServerResponse(w http.ResponseWriter) error

type UpdateServerJSONRequestBody

type UpdateServerJSONRequestBody = ServerUpdateRequest

UpdateServerJSONRequestBody defines body for UpdateServer for application/json ContentType.

type UpdateServerRequestObject

type UpdateServerRequestObject struct {
	Namespace Namespace  `json:"namespace"`
	Name      ServerName `json:"name"`
	Body      *UpdateServerJSONRequestBody
}

type UpdateServerResponseObject

type UpdateServerResponseObject interface {
	VisitUpdateServerResponse(w http.ResponseWriter) error
}

type UpdateStrategy

type UpdateStrategy string

UpdateStrategy Defines how versions are managed for servers and plugins.

- **latest**: Always use the latest available version from the repository - **auto**: Use constraint solver to find best version compatible with all dependencies - **pin**: Pin to specific version, auto-update to latest build within that version - **build-pin**: Pin to specific version AND build number, no automatic updates

const (
	Auto     UpdateStrategy = "auto"
	BuildPin UpdateStrategy = "build-pin"
	Latest   UpdateStrategy = "latest"
	Pin      UpdateStrategy = "pin"
)

Defines values for UpdateStrategy.

func (UpdateStrategy) Valid

func (e UpdateStrategy) Valid() bool

Valid indicates whether the value is a known member of the UpdateStrategy enum.

type VersionResponse

type VersionResponse struct {
	// ApiVersion API version
	ApiVersion string `json:"apiVersion"`

	// BuildDate Date and time when the operator was built
	BuildDate *time.Time `json:"buildDate,omitempty"`

	// GitCommit Git commit hash of the build
	GitCommit *string `json:"gitCommit,omitempty"`

	// GoVersion Go version used to build the operator
	GoVersion *string `json:"goVersion,omitempty"`

	// Version Semantic version of the operator
	Version string `json:"version"`
}

VersionResponse Version information about the operator

Jump to

Keyboard shortcuts

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