nginxproxymanager

package
v0.4.13 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CertificateMeta

type CertificateMeta struct {
	Certificate             string `json:"certificate"`
	CertificateKey          string `json:"certificate_key"`
	IntermediateCertificate string `json:"intermediate_certificate"`
}

type CertificateRecord

type CertificateRecord struct {
	Id          int64           `json:"id"`
	CreatedOn   string          `json:"created_on"`
	ModifiedOn  string          `json:"modified_on"`
	Provider    string          `json:"provider"`
	NiceName    string          `json:"nice_name"`
	DomainNames []string        `json:"domain_names"`
	ExpiresOn   string          `json:"expires_on"`
	Meta        CertificateMeta `json:"meta"`
}

type Client

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

func NewClient

func NewClient(serverUrl, identity, secret string) (*Client, error)

func NewClientWithJwtToken

func NewClientWithJwtToken(serverUrl, jwtToken string) (*Client, error)

func (*Client) NginxCreateCertificate

func (c *Client) NginxCreateCertificate(req *NginxCreateCertificateRequest) (*NginxCreateCertificateResponse, error)

func (*Client) NginxCreateCertificateWithContext

func (c *Client) NginxCreateCertificateWithContext(ctx context.Context, req *NginxCreateCertificateRequest) (*NginxCreateCertificateResponse, error)

func (*Client) NginxListCertificates

func (c *Client) NginxListCertificates(req *NginxListCertificatesRequest) (*NginxListCertificatesResponse, error)

func (*Client) NginxListCertificatesWithContext

func (c *Client) NginxListCertificatesWithContext(ctx context.Context, req *NginxListCertificatesRequest) (*NginxListCertificatesResponse, error)

func (*Client) NginxListDeadHosts

func (c *Client) NginxListDeadHosts(req *NginxListDeadHostsRequest) (*NginxListDeadHostsResponse, error)

func (*Client) NginxListDeadHostsWithContext

func (c *Client) NginxListDeadHostsWithContext(ctx context.Context, req *NginxListDeadHostsRequest) (*NginxListDeadHostsResponse, error)

func (*Client) NginxListProxyHosts

func (c *Client) NginxListProxyHosts(req *NginxListProxyHostsRequest) (*NginxListProxyHostsResponse, error)

func (*Client) NginxListProxyHostsWithContext

func (c *Client) NginxListProxyHostsWithContext(ctx context.Context, req *NginxListProxyHostsRequest) (*NginxListProxyHostsResponse, error)

func (*Client) NginxListRedirectionHostsWithContext

func (c *Client) NginxListRedirectionHostsWithContext(ctx context.Context, req *NginxListRedirectionHostsRequest) (*NginxListRedirectionHostsResponse, error)

func (*Client) NginxListStreams

func (c *Client) NginxListStreams(req *NginxListStreamsRequest) (*NginxListStreamsResponse, error)

func (*Client) NginxListStreamsWithContext

func (c *Client) NginxListStreamsWithContext(ctx context.Context, req *NginxListStreamsRequest) (*NginxListStreamsResponse, error)

func (*Client) NginxUpdateDeadHost

func (c *Client) NginxUpdateDeadHost(hostId int64, req *NginxUpdateDeadHostRequest) (*NginxUpdateDeadHostResponse, error)

func (*Client) NginxUpdateDeadHostWithContext

func (c *Client) NginxUpdateDeadHostWithContext(ctx context.Context, hostId int64, req *NginxUpdateDeadHostRequest) (*NginxUpdateDeadHostResponse, error)

func (*Client) NginxUpdateProxyHost

func (c *Client) NginxUpdateProxyHost(hostId int64, req *NginxUpdateProxyHostRequest) (*NginxUpdateProxyHostResponse, error)

func (*Client) NginxUpdateProxyHostWithContext

func (c *Client) NginxUpdateProxyHostWithContext(ctx context.Context, hostId int64, req *NginxUpdateProxyHostRequest) (*NginxUpdateProxyHostResponse, error)

func (*Client) NginxUpdateRedirectionHost

func (c *Client) NginxUpdateRedirectionHost(hostId int64, req *NginxUpdateRedirectionHostRequest) (*NginxUpdateRedirectionHostResponse, error)

func (*Client) NginxUpdateRedirectionHostWithContext

func (c *Client) NginxUpdateRedirectionHostWithContext(ctx context.Context, hostId int64, req *NginxUpdateRedirectionHostRequest) (*NginxUpdateRedirectionHostResponse, error)

func (*Client) NginxUpdateStream

func (c *Client) NginxUpdateStream(hostId int64, req *NginxUpdateStreamRequest) (*NginxUpdateStreamResponse, error)

func (*Client) NginxUpdateStreamWithContext

func (c *Client) NginxUpdateStreamWithContext(ctx context.Context, hostId int64, req *NginxUpdateStreamRequest) (*NginxUpdateStreamResponse, error)

func (*Client) NginxUploadCertificate

func (c *Client) NginxUploadCertificate(certId int64, req *NginxUploadCertificateRequest) (*NginxUploadCertificateResponse, error)

func (*Client) NginxUploadCertificateWithContext

func (c *Client) NginxUploadCertificateWithContext(ctx context.Context, certId int64, req *NginxUploadCertificateRequest) (*NginxUploadCertificateResponse, error)

func (*Client) SetTLSConfig

func (c *Client) SetTLSConfig(config *tls.Config) *Client

func (*Client) SetTimeout

func (c *Client) SetTimeout(timeout time.Duration) *Client

func (*Client) SettingsGetDefaultSite

func (c *Client) SettingsGetDefaultSite(req *SettingsGetDefaultSiteRequest) (*SettingsGetDefaultSiteResponse, error)

func (*Client) SettingsGetDefaultSiteWithContext

func (c *Client) SettingsGetDefaultSiteWithContext(ctx context.Context, req *SettingsGetDefaultSiteRequest) (*SettingsGetDefaultSiteResponse, error)

func (*Client) SettingsSetDefaultSite

func (c *Client) SettingsSetDefaultSite(req *SettingsSetDefaultSiteRequest) (*SettingsSetDefaultSiteResponse, error)

func (*Client) SettingsSetDefaultSiteWithContext

func (c *Client) SettingsSetDefaultSiteWithContext(ctx context.Context, req *SettingsSetDefaultSiteRequest) (*SettingsSetDefaultSiteResponse, error)

type DeadHostRecord

type DeadHostRecord struct {
	HostRecord
	SslForced      bool `json:"ssl_forced"`
	Http2Support   bool `json:"http2_support"`
	HstsEnabled    bool `json:"hsts_enabled"`
	HstsSubdomains bool `json:"hsts_subdomains"`
}

type HostMeta

type HostMeta struct {
	NginxOnline bool `json:"nginx_online"`
	NginxErr    any  `json:"nginx_err"`
}

type HostRecord

type HostRecord struct {
	Id            int64    `json:"id"`
	CreatedOn     string   `json:"created_on"`
	ModifiedOn    string   `json:"modified_on"`
	DomainNames   []string `json:"domain_names"`
	CertificateId int64    `json:"certificate_id"`
	Meta          HostMeta `json:"meta"`
	Enabled       bool     `json:"enabled"`
}

type NginxCreateCertificateRequest

type NginxCreateCertificateRequest struct {
	Provider string `json:"provider"`
	NiceName string `json:"nice_name"`
}

type NginxCreateCertificateResponse

type NginxCreateCertificateResponse struct {
	CertificateRecord
}

type NginxListCertificatesRequest

type NginxListCertificatesRequest struct {
	Expand *string `json:"expand,omitempty" url:"expand,omitempty"`
}

type NginxListCertificatesResponse

type NginxListCertificatesResponse = []*CertificateRecord

type NginxListDeadHostsRequest

type NginxListDeadHostsRequest struct {
	Expand *string `json:"expand,omitempty" url:"expand,omitempty"`
}

type NginxListDeadHostsResponse

type NginxListDeadHostsResponse = []*DeadHostRecord

type NginxListProxyHostsRequest

type NginxListProxyHostsRequest struct {
	Expand *string `json:"expand,omitempty" url:"expand,omitempty"`
}

type NginxListProxyHostsResponse

type NginxListProxyHostsResponse = []*ProxyHostRecord

type NginxListRedirectionHostsRequest

type NginxListRedirectionHostsRequest struct {
	Expand *string `json:"expand,omitempty" url:"expand,omitempty"`
}

type NginxListRedirectionHostsResponse

type NginxListRedirectionHostsResponse = []*RedirectionHostRecord

type NginxListStreamsRequest

type NginxListStreamsRequest struct {
	Expand *string `json:"expand,omitempty" url:"expand,omitempty"`
}

type NginxListStreamsResponse

type NginxListStreamsResponse = []*StreamHostRecord

type NginxUpdateDeadHostRequest

type NginxUpdateDeadHostRequest struct {
	CertificateId *int64 `json:"certificate_id,omitempty"`
}

type NginxUpdateDeadHostResponse

type NginxUpdateDeadHostResponse struct {
	DeadHostRecord
}

type NginxUpdateProxyHostRequest

type NginxUpdateProxyHostRequest struct {
	CertificateId *int64 `json:"certificate_id,omitempty"`
}

type NginxUpdateProxyHostResponse

type NginxUpdateProxyHostResponse struct {
	ProxyHostRecord
}

type NginxUpdateRedirectionHostRequest

type NginxUpdateRedirectionHostRequest struct {
	CertificateId *int64 `json:"certificate_id,omitempty"`
}

type NginxUpdateRedirectionHostResponse

type NginxUpdateRedirectionHostResponse struct {
	RedirectionHostRecord
}

type NginxUpdateStreamRequest

type NginxUpdateStreamRequest struct {
	CertificateId *int64 `json:"certificate_id,omitempty"`
}

type NginxUpdateStreamResponse

type NginxUpdateStreamResponse struct {
	StreamHostRecord
}

type NginxUploadCertificateRequest

type NginxUploadCertificateRequest struct {
	CertificateMeta
}

type NginxUploadCertificateResponse

type NginxUploadCertificateResponse struct {
	CertificateMeta
}

type ProxyHostRecord

type ProxyHostRecord struct {
	HostRecord
	ForwardScheme  string `json:"forward_scheme"`
	ForwardHost    string `json:"forward_host"`
	ForwardPort    int32  `json:"forward_port"`
	SslForced      bool   `json:"ssl_forced"`
	Http2Support   bool   `json:"http2_support"`
	HstsEnabled    bool   `json:"hsts_enabled"`
	HstsSubdomains bool   `json:"hsts_subdomains"`
}

type RedirectionHostRecord

type RedirectionHostRecord struct {
	HostRecord
	ForwardScheme     string `json:"forward_scheme"`
	ForwardDomainName string `json:"forward_domain_name"`
	ForwardHttpCode   int32  `json:"forward_http_code"`
	SslForced         bool   `json:"ssl_forced"`
	Http2Support      bool   `json:"http2_support"`
	HstsEnabled       bool   `json:"hsts_enabled"`
	HstsSubdomains    bool   `json:"hsts_subdomains"`
}

type SettingsGetDefaultSiteRequest

type SettingsGetDefaultSiteRequest struct{}

type SettingsGetDefaultSiteResponse

type SettingsGetDefaultSiteResponse struct {
	Id          string `json:"id"`
	Name        string `json:"name"`
	Description string `json:"description"`
	Value       string `json:"value"`
	Meta        struct {
		Redirect string `json:"redirect"`
		Html     string `json:"urhtmll"`
	} `json:"meta"`
}

type SettingsSetDefaultSiteRequest

type SettingsSetDefaultSiteRequest struct {
	Value string `json:"value"`
	Meta  struct {
		Redirect string `json:"redirect"`
		Html     string `json:"html"`
	} `json:"meta"`
}

type SettingsSetDefaultSiteResponse

type SettingsSetDefaultSiteResponse struct{}

type StreamHostRecord

type StreamHostRecord struct {
	HostRecord
	ForwardingHost string `json:"forwarding_host"`
	ForwardingPort int32  `json:"forwarding_port"`
	IncomingPort   int32  `json:"incoming_port"`
	TcpForwarding  bool   `json:"tcp_forwarding"`
	UdpForwarding  bool   `json:"udp_forwarding"`
}

Jump to

Keyboard shortcuts

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