quotas

package
v1.77.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const RegionNameUsChi1 = shared.RegionNameUsChi1

Equals "us-chi-1"

View Source
const RegionNameUsSva1 = shared.RegionNameUsSva1

Equals "us-sva-1"

View Source
const RegionNameUsSva2 = shared.RegionNameUsSva2

Equals "us-sva-2"

View Source
const ResourceStatusCreating = shared.ResourceStatusCreating

Equals "creating"

View Source
const ResourceStatusDeleted = shared.ResourceStatusDeleted

Equals "deleted"

View Source
const ResourceStatusDeleting = shared.ResourceStatusDeleting

Equals "deleting"

View Source
const ResourceStatusError = shared.ResourceStatusError

Equals "error"

View Source
const ResourceStatusPending = shared.ResourceStatusPending

Equals "pending"

View Source
const ResourceStatusReady = shared.ResourceStatusReady

Equals "ready"

View Source
const ResourceStatusUpdating = shared.ResourceStatusUpdating

Equals "updating"

Variables

This section is empty.

Functions

This section is empty.

Types

type Error

type Error = apierror.Error

type Pagination

type Pagination = shared.Pagination

Pagination response details.

This is an alias to an internal type.

type Quota

type Quota struct {
	// Compute quota.
	Compute QuotaCompute `json:"compute" api:"required"`
	// Networking quota.
	Networking QuotaNetworking `json:"networking" api:"required"`
	// NKS quota.
	NKS QuotaNKS `json:"nks" api:"required"`
	// Region the resource is in.
	//
	// Any of "us-sva-1", "us-sva-2", "us-chi-1".
	Region shared.RegionName `json:"region" api:"required"`
	// Storage quota.
	Storage QuotaStorage `json:"storage" api:"required"`
	// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
	JSON struct {
		Compute     respjson.Field
		Networking  respjson.Field
		NKS         respjson.Field
		Region      respjson.Field
		Storage     respjson.Field
		ExtraFields map[string]respjson.Field
		// contains filtered or unexported fields
	} `json:"-"`
}

Quota response.

func (Quota) RawJSON

func (r Quota) RawJSON() string

Returns the unmodified JSON received from the API

func (*Quota) UnmarshalJSON

func (r *Quota) UnmarshalJSON(data []byte) error

type QuotaCompute

type QuotaCompute struct {
	// Quota resource detail.
	MemoryGB QuotaResourceDetail `json:"memory_gb" api:"required"`
	// Quota resource detail.
	Vcpu QuotaResourceDetail `json:"vcpu" api:"required"`
	// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
	JSON struct {
		MemoryGB    respjson.Field
		Vcpu        respjson.Field
		ExtraFields map[string]respjson.Field
		// contains filtered or unexported fields
	} `json:"-"`
}

Compute quota.

func (QuotaCompute) RawJSON

func (r QuotaCompute) RawJSON() string

Returns the unmodified JSON received from the API

func (*QuotaCompute) UnmarshalJSON

func (r *QuotaCompute) UnmarshalJSON(data []byte) error

type QuotaGetParamsRegion

type QuotaGetParamsRegion string
const (
	QuotaGetParamsRegionUsSva1 QuotaGetParamsRegion = "us-sva-1"
	QuotaGetParamsRegionUsSva2 QuotaGetParamsRegion = "us-sva-2"
	QuotaGetParamsRegionUsChi1 QuotaGetParamsRegion = "us-chi-1"
)

type QuotaList

type QuotaList struct {
	Items []Quota `json:"items" api:"required"`
	// Pagination response details.
	Pagination shared.Pagination `json:"pagination" api:"required"`
	// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
	JSON struct {
		Items       respjson.Field
		Pagination  respjson.Field
		ExtraFields map[string]respjson.Field
		// contains filtered or unexported fields
	} `json:"-"`
}

func (QuotaList) RawJSON

func (r QuotaList) RawJSON() string

Returns the unmodified JSON received from the API

func (*QuotaList) UnmarshalJSON

func (r *QuotaList) UnmarshalJSON(data []byte) error

type QuotaNKS

type QuotaNKS struct {
	// Quota resource detail.
	Clusters QuotaResourceDetail `json:"clusters" api:"required"`
	// Quota resource detail.
	NodePoolMemoryGB QuotaResourceDetail `json:"node_pool_memory_gb" api:"required"`
	// Quota resource detail.
	NodePoolVcpu QuotaResourceDetail `json:"node_pool_vcpu" api:"required"`
	// Quota resource detail.
	PublicIPs QuotaResourceDetail `json:"public_ips" api:"required"`
	// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
	JSON struct {
		Clusters         respjson.Field
		NodePoolMemoryGB respjson.Field
		NodePoolVcpu     respjson.Field
		PublicIPs        respjson.Field
		ExtraFields      map[string]respjson.Field
		// contains filtered or unexported fields
	} `json:"-"`
}

NKS quota.

func (QuotaNKS) RawJSON

func (r QuotaNKS) RawJSON() string

Returns the unmodified JSON received from the API

func (*QuotaNKS) UnmarshalJSON

func (r *QuotaNKS) UnmarshalJSON(data []byte) error

type QuotaNetworking

type QuotaNetworking struct {
	// Quota resource detail.
	ConnectConnections QuotaResourceDetail `json:"connect_connections" api:"required"`
	// Quota resource detail.
	PublicIPs QuotaResourceDetail `json:"public_ips" api:"required"`
	// Quota resource detail.
	VPCs QuotaResourceDetail `json:"vpcs" api:"required"`
	// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
	JSON struct {
		ConnectConnections respjson.Field
		PublicIPs          respjson.Field
		VPCs               respjson.Field
		ExtraFields        map[string]respjson.Field
		// contains filtered or unexported fields
	} `json:"-"`
}

Networking quota.

func (QuotaNetworking) RawJSON

func (r QuotaNetworking) RawJSON() string

Returns the unmodified JSON received from the API

func (*QuotaNetworking) UnmarshalJSON

func (r *QuotaNetworking) UnmarshalJSON(data []byte) error

type QuotaResourceDetail

type QuotaResourceDetail struct {
	Limit     int64 `json:"limit" api:"required"`
	Remaining int64 `json:"remaining" api:"required"`
	Used      int64 `json:"used" api:"required"`
	// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
	JSON struct {
		Limit       respjson.Field
		Remaining   respjson.Field
		Used        respjson.Field
		ExtraFields map[string]respjson.Field
		// contains filtered or unexported fields
	} `json:"-"`
}

Quota resource detail.

func (QuotaResourceDetail) RawJSON

func (r QuotaResourceDetail) RawJSON() string

Returns the unmodified JSON received from the API

func (*QuotaResourceDetail) UnmarshalJSON

func (r *QuotaResourceDetail) UnmarshalJSON(data []byte) error

type QuotaService

type QuotaService struct {
	Options []option.RequestOption
}

QuotaService contains methods and other services that help with interacting with the Nirvana Labs API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewQuotaService method instead.

func NewQuotaService

func NewQuotaService(opts ...option.RequestOption) (r QuotaService)

NewQuotaService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*QuotaService) Get

func (r *QuotaService) Get(ctx context.Context, region QuotaGetParamsRegion, opts ...option.RequestOption) (res *Quota, err error)

Get quota usage and limits for the current organization in a single region

func (*QuotaService) List

func (r *QuotaService) List(ctx context.Context, opts ...option.RequestOption) (res *QuotaList, err error)

List quota usage and limits for the current organization across all regions

type QuotaStorage

type QuotaStorage struct {
	// Quota resource detail.
	ABS QuotaResourceDetail `json:"abs" api:"required"`
	// Quota resource detail.
	LocalNvme QuotaResourceDetail `json:"local_nvme" api:"required"`
	// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
	JSON struct {
		ABS         respjson.Field
		LocalNvme   respjson.Field
		ExtraFields map[string]respjson.Field
		// contains filtered or unexported fields
	} `json:"-"`
}

Storage quota.

func (QuotaStorage) RawJSON

func (r QuotaStorage) RawJSON() string

Returns the unmodified JSON received from the API

func (*QuotaStorage) UnmarshalJSON

func (r *QuotaStorage) UnmarshalJSON(data []byte) error

type RegionName

type RegionName = shared.RegionName

Region the resource is in.

This is an alias to an internal type.

type ResourceStatus

type ResourceStatus = shared.ResourceStatus

Status of the resource.

This is an alias to an internal type.

type SourceIPRuleParam

type SourceIPRuleParam = shared.SourceIPRuleParam

IP filter rules.

This is an alias to an internal type.

type SourceIPRuleResponse

type SourceIPRuleResponse = shared.SourceIPRuleResponse

IP filter rules.

This is an alias to an internal type.

Jump to

Keyboard shortcuts

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