image

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package image provides access to the `/cloud/stack/image` API endpoint.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client is a Service to work with API Jobs.

func New

func New(c *api.Client) *Client

New is an initialisation function.

func (*Client) Get

func (s *Client) Get(ctx context.Context, request GetRequest) (*models.StackImage, error)

Get fetches a cloud image with the spcified code. calls list and filters. basically a helper.

func (*Client) List

func (s *Client) List(ctx context.Context) (response ListResponse, err error)

List returns a list of stack images, specific to the customer.

type GetRequest

type GetRequest struct {
	Code string `json:"code"`
}

GetRequest represents a filtered request to the /cloud/stack/image/list_all.json endpoint.

type ListResponse

type ListResponse struct {
	Return []models.StackImage `json:"return"`
	models.APIResponse
}

ListResponse represents the return from the /cloud/stack/image/list_all.json endpoint.

Jump to

Keyboard shortcuts

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