staticip

package
v0.171.0 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ProjectStaticIPAssociateStateTypeChoices added in v0.159.0

func ProjectStaticIPAssociateStateTypeChoices() []string

func ProjectStaticIPDissociateStateTypeChoices added in v0.159.0

func ProjectStaticIPDissociateStateTypeChoices() []string

func ProjectStaticIPPatchStateTypeChoices added in v0.159.0

func ProjectStaticIPPatchStateTypeChoices() []string

func StaticIPStateTypeChoices added in v0.159.0

func StaticIPStateTypeChoices() []string

Types

type Handler

type Handler interface {
	// ProjectStaticIPAssociate associate a static IP address with a service
	// POST /v1/project/{project}/static-ips/{static_ip_address_id}/association
	// https://api.aiven.io/doc/#tag/StaticIP/operation/ProjectStaticIPAssociate
	// Required roles or permissions: service:configuration:write
	ProjectStaticIPAssociate(ctx context.Context, project string, staticIpaddressId string, in *ProjectStaticIPAssociateIn) (*ProjectStaticIPAssociateOut, error)

	// ProjectStaticIPAvailabilityList list static IP address cloud availability and prices for a project
	// GET /v1/project/{project}/static-ip-availability
	// https://api.aiven.io/doc/#tag/StaticIP/operation/ProjectStaticIPAvailabilityList
	// Required roles or permissions: developer, operator, read_only
	ProjectStaticIPAvailabilityList(ctx context.Context, project string) ([]StaticIPAddressAvailabilityOut, error)

	// ProjectStaticIPDissociate dissociate a static IP address from a service
	// DELETE /v1/project/{project}/static-ips/{static_ip_address_id}/association
	// https://api.aiven.io/doc/#tag/StaticIP/operation/ProjectStaticIPDissociate
	// Required roles or permissions: service:configuration:write
	ProjectStaticIPDissociate(ctx context.Context, project string, staticIpaddressId string) (*ProjectStaticIPDissociateOut, error)

	// ProjectStaticIPPatch update a static IP address configuration
	// PATCH /v1/project/{project}/static-ips/{static_ip_address_id}
	// https://api.aiven.io/doc/#tag/StaticIP/operation/ProjectStaticIPPatch
	// Required roles or permissions: operator
	ProjectStaticIPPatch(ctx context.Context, project string, staticIpaddressId string, in *ProjectStaticIPPatchIn) (*ProjectStaticIPPatchOut, error)

	// PublicStaticIPAvailabilityList list static IP clouds and prices
	// GET /v1/tenants/{tenant}/static-ip-availability
	// https://api.aiven.io/doc/#tag/Cloud_platforms/operation/PublicStaticIPAvailabilityList
	PublicStaticIPAvailabilityList(ctx context.Context, tenant string) ([]StaticIPAddressAvailabilityOut, error)

	// StaticIPCreate create static IP address
	// POST /v1/project/{project}/static-ips
	// https://api.aiven.io/doc/#tag/StaticIP/operation/StaticIPCreate
	// Required roles or permissions: operator
	StaticIPCreate(ctx context.Context, project string, in *StaticIPCreateIn) (*StaticIPCreateOut, error)

	// StaticIPDelete delete a static IP address
	// DELETE /v1/project/{project}/static-ips/{static_ip_address_id}
	// https://api.aiven.io/doc/#tag/StaticIP/operation/StaticIPDelete
	StaticIPDelete(ctx context.Context, project string, staticIpaddressId string) (*StaticIPDeleteOut, error)

	// StaticIPList list static IP addresses
	// GET /v1/project/{project}/static-ips
	// https://api.aiven.io/doc/#tag/StaticIP/operation/StaticIPList
	// Required roles or permissions: developer, operator, read_only
	StaticIPList(ctx context.Context, project string) ([]StaticIPOut, error)
}

type ProjectStaticIPAssociateIn added in v0.159.0

type ProjectStaticIPAssociateIn struct {
	ServiceName string `json:"service_name"` // Service name
}

ProjectStaticIPAssociateIn ProjectStaticIPAssociateRequestBody

type ProjectStaticIPAssociateOut added in v0.159.0

type ProjectStaticIPAssociateOut struct {
	CloudName             string                            `json:"cloud_name"`             // Target cloud
	IPAddress             string                            `json:"ip_address"`             // IPv4 address
	ServiceName           string                            `json:"service_name"`           // Service name
	State                 ProjectStaticIPAssociateStateType `json:"state"`                  // Static IP address state
	StaticIPAddressId     string                            `json:"static_ip_address_id"`   // Static IP address identifier
	TerminationProtection bool                              `json:"termination_protection"` // Static IP address is protected against deletion
}

ProjectStaticIPAssociateOut ProjectStaticIPAssociateResponse

type ProjectStaticIPAssociateStateType added in v0.159.0

type ProjectStaticIPAssociateStateType string
const (
	ProjectStaticIPAssociateStateTypeAssigned  ProjectStaticIPAssociateStateType = "assigned"
	ProjectStaticIPAssociateStateTypeAvailable ProjectStaticIPAssociateStateType = "available"
	ProjectStaticIPAssociateStateTypeCreated   ProjectStaticIPAssociateStateType = "created"
	ProjectStaticIPAssociateStateTypeCreating  ProjectStaticIPAssociateStateType = "creating"
	ProjectStaticIPAssociateStateTypeDeleted   ProjectStaticIPAssociateStateType = "deleted"
	ProjectStaticIPAssociateStateTypeDeleting  ProjectStaticIPAssociateStateType = "deleting"
)

type ProjectStaticIPDissociateOut added in v0.159.0

type ProjectStaticIPDissociateOut struct {
	CloudName             string                             `json:"cloud_name"`             // Target cloud
	IPAddress             string                             `json:"ip_address"`             // IPv4 address
	ServiceName           string                             `json:"service_name"`           // Service name
	State                 ProjectStaticIPDissociateStateType `json:"state"`                  // Static IP address state
	StaticIPAddressId     string                             `json:"static_ip_address_id"`   // Static IP address identifier
	TerminationProtection bool                               `json:"termination_protection"` // Static IP address is protected against deletion
}

ProjectStaticIPDissociateOut ProjectStaticIPDissociateResponse

type ProjectStaticIPDissociateStateType added in v0.159.0

type ProjectStaticIPDissociateStateType string
const (
	ProjectStaticIPDissociateStateTypeAssigned  ProjectStaticIPDissociateStateType = "assigned"
	ProjectStaticIPDissociateStateTypeAvailable ProjectStaticIPDissociateStateType = "available"
	ProjectStaticIPDissociateStateTypeCreated   ProjectStaticIPDissociateStateType = "created"
	ProjectStaticIPDissociateStateTypeCreating  ProjectStaticIPDissociateStateType = "creating"
	ProjectStaticIPDissociateStateTypeDeleted   ProjectStaticIPDissociateStateType = "deleted"
	ProjectStaticIPDissociateStateTypeDeleting  ProjectStaticIPDissociateStateType = "deleting"
)

type ProjectStaticIPPatchIn added in v0.159.0

type ProjectStaticIPPatchIn struct {
	TerminationProtection *bool `json:"termination_protection,omitempty"` // Static IP address is protected against deletion
}

ProjectStaticIPPatchIn ProjectStaticIPPatchRequestBody

type ProjectStaticIPPatchOut added in v0.159.0

type ProjectStaticIPPatchOut struct {
	CloudName             string                        `json:"cloud_name"`             // Target cloud
	IPAddress             string                        `json:"ip_address"`             // IPv4 address
	ServiceName           string                        `json:"service_name"`           // Service name
	State                 ProjectStaticIPPatchStateType `json:"state"`                  // Static IP address state
	StaticIPAddressId     string                        `json:"static_ip_address_id"`   // Static IP address identifier
	TerminationProtection bool                          `json:"termination_protection"` // Static IP address is protected against deletion
}

ProjectStaticIPPatchOut ProjectStaticIPPatchResponse

type ProjectStaticIPPatchStateType added in v0.159.0

type ProjectStaticIPPatchStateType string
const (
	ProjectStaticIPPatchStateTypeAssigned  ProjectStaticIPPatchStateType = "assigned"
	ProjectStaticIPPatchStateTypeAvailable ProjectStaticIPPatchStateType = "available"
	ProjectStaticIPPatchStateTypeCreated   ProjectStaticIPPatchStateType = "created"
	ProjectStaticIPPatchStateTypeCreating  ProjectStaticIPPatchStateType = "creating"
	ProjectStaticIPPatchStateTypeDeleted   ProjectStaticIPPatchStateType = "deleted"
	ProjectStaticIPPatchStateTypeDeleting  ProjectStaticIPPatchStateType = "deleting"
)

type StaticIPAddressAvailabilityOut added in v0.159.0

type StaticIPAddressAvailabilityOut struct {
	CloudName string `json:"cloud_name"` // Target cloud
	PriceUsd  string `json:"price_usd"`  // Hourly static IP address price in this cloud region
}

type StaticIPCreateIn added in v0.159.0

type StaticIPCreateIn struct {
	CloudName             string `json:"cloud_name"`                       // Target cloud
	TerminationProtection *bool  `json:"termination_protection,omitempty"` // Static IP address is protected against deletion
}

StaticIPCreateIn StaticIPCreateRequestBody

type StaticIPCreateOut added in v0.159.0

type StaticIPCreateOut struct {
	CloudName             string            `json:"cloud_name"`             // Target cloud
	IPAddress             string            `json:"ip_address"`             // IPv4 address
	ServiceName           string            `json:"service_name"`           // Service name
	State                 StaticIPStateType `json:"state"`                  // Static IP address state
	StaticIPAddressId     string            `json:"static_ip_address_id"`   // Static IP address identifier
	TerminationProtection bool              `json:"termination_protection"` // Static IP address is protected against deletion
}

StaticIPCreateOut StaticIPCreateResponse

type StaticIPDeleteOut added in v0.159.0

type StaticIPDeleteOut struct {
	CloudName             string            `json:"cloud_name"`             // Target cloud
	IPAddress             string            `json:"ip_address"`             // IPv4 address
	ServiceName           string            `json:"service_name"`           // Service name
	State                 StaticIPStateType `json:"state"`                  // Static IP address state
	StaticIPAddressId     string            `json:"static_ip_address_id"`   // Static IP address identifier
	TerminationProtection bool              `json:"termination_protection"` // Static IP address is protected against deletion
}

StaticIPDeleteOut StaticIPDeleteResponse

type StaticIPHandler

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

func NewHandler

func NewHandler(doer doer) StaticIPHandler

func (*StaticIPHandler) ProjectStaticIPAssociate

func (h *StaticIPHandler) ProjectStaticIPAssociate(ctx context.Context, project string, staticIpaddressId string, in *ProjectStaticIPAssociateIn) (*ProjectStaticIPAssociateOut, error)

func (*StaticIPHandler) ProjectStaticIPAvailabilityList

func (h *StaticIPHandler) ProjectStaticIPAvailabilityList(ctx context.Context, project string) ([]StaticIPAddressAvailabilityOut, error)

func (*StaticIPHandler) ProjectStaticIPDissociate

func (h *StaticIPHandler) ProjectStaticIPDissociate(ctx context.Context, project string, staticIpaddressId string) (*ProjectStaticIPDissociateOut, error)

func (*StaticIPHandler) ProjectStaticIPPatch

func (h *StaticIPHandler) ProjectStaticIPPatch(ctx context.Context, project string, staticIpaddressId string, in *ProjectStaticIPPatchIn) (*ProjectStaticIPPatchOut, error)

func (*StaticIPHandler) PublicStaticIPAvailabilityList

func (h *StaticIPHandler) PublicStaticIPAvailabilityList(ctx context.Context, tenant string) ([]StaticIPAddressAvailabilityOut, error)

func (*StaticIPHandler) StaticIPCreate

func (h *StaticIPHandler) StaticIPCreate(ctx context.Context, project string, in *StaticIPCreateIn) (*StaticIPCreateOut, error)

func (*StaticIPHandler) StaticIPDelete added in v0.158.0

func (h *StaticIPHandler) StaticIPDelete(ctx context.Context, project string, staticIpaddressId string) (*StaticIPDeleteOut, error)

func (*StaticIPHandler) StaticIPList

func (h *StaticIPHandler) StaticIPList(ctx context.Context, project string) ([]StaticIPOut, error)

type StaticIPOut added in v0.159.0

type StaticIPOut struct {
	CloudName             string            `json:"cloud_name"`             // Target cloud
	IPAddress             string            `json:"ip_address"`             // IPv4 address
	ServiceName           string            `json:"service_name"`           // Service name
	State                 StaticIPStateType `json:"state"`                  // Static IP address state
	StaticIPAddressId     string            `json:"static_ip_address_id"`   // Static IP address identifier
	TerminationProtection bool              `json:"termination_protection"` // Static IP address is protected against deletion
}

type StaticIPStateType added in v0.159.0

type StaticIPStateType string
const (
	StaticIPStateTypeAssigned  StaticIPStateType = "assigned"
	StaticIPStateTypeAvailable StaticIPStateType = "available"
	StaticIPStateTypeCreated   StaticIPStateType = "created"
	StaticIPStateTypeCreating  StaticIPStateType = "creating"
	StaticIPStateTypeDeleted   StaticIPStateType = "deleted"
	StaticIPStateTypeDeleting  StaticIPStateType = "deleting"
)

Jump to

Keyboard shortcuts

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