Documentation ¶
Overview ¶
Package instance provides primitives to interact with the openapi HTTP API.
Code generated by github.com/do87/oapi-codegen version v0.5.1 DO NOT EDIT.
Index ¶
- Constants
- func NewCreateCloneRequest(ctx context.Context, server string, projectID string, instanceID string, ...) (*http.Request, error)
- func NewCreateCloneRequestWithBody(ctx context.Context, server string, projectID string, instanceID string, ...) (*http.Request, error)
- func NewCreateRequest(ctx context.Context, server string, projectID string, ...) (*http.Request, error)
- func NewCreateRequestWithBody(ctx context.Context, server string, projectID string, contentType string, ...) (*http.Request, error)
- func NewDeleteRequest(ctx context.Context, server string, projectID string, instanceID string) (*http.Request, error)
- func NewGetRequest(ctx context.Context, server string, projectID string, instanceID string) (*http.Request, error)
- func NewListRequest(ctx context.Context, server string, projectID string) (*http.Request, error)
- func NewPatchUpdateRequest(ctx context.Context, server string, projectID string, instanceID string, ...) (*http.Request, error)
- func NewPatchUpdateRequestWithBody(ctx context.Context, server string, projectID string, instanceID string, ...) (*http.Request, error)
- func NewUpdateRequest(ctx context.Context, server string, projectID string, instanceID string, ...) (*http.Request, error)
- func NewUpdateRequestWithBody(ctx context.Context, server string, projectID string, instanceID string, ...) (*http.Request, error)
- type Client
- func (c *Client) Create(ctx context.Context, projectID string, body CreateJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) CreateClone(ctx context.Context, projectID string, instanceID string, ...) (*http.Response, error)
- func (c *Client) CreateCloneWithBody(ctx context.Context, projectID string, instanceID string, contentType string, ...) (*http.Response, error)
- func (c *Client) CreateWithBody(ctx context.Context, projectID string, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) Delete(ctx context.Context, projectID string, instanceID string, ...) (*http.Response, error)
- func (c *Client) Get(ctx context.Context, projectID string, instanceID string, ...) (*http.Response, error)
- func (c *Client) List(ctx context.Context, projectID string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) PatchUpdate(ctx context.Context, projectID string, instanceID string, ...) (*http.Response, error)
- func (c *Client) PatchUpdateWithBody(ctx context.Context, projectID string, instanceID string, contentType string, ...) (*http.Response, error)
- func (c *Client) Update(ctx context.Context, projectID string, instanceID string, ...) (*http.Response, error)
- func (c *Client) UpdateWithBody(ctx context.Context, projectID string, instanceID string, contentType string, ...) (*http.Response, error)
- type ClientInterface
- type ClientWithResponses
- func (c *ClientWithResponses) CreateCloneWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, ...) (*CreateCloneResponse, error)
- func (c *ClientWithResponses) CreateCloneWithResponse(ctx context.Context, projectID string, instanceID string, ...) (*CreateCloneResponse, error)
- func (c *ClientWithResponses) CreateWithBodyWithResponse(ctx context.Context, projectID string, contentType string, body io.Reader, ...) (*CreateResponse, error)
- func (c *ClientWithResponses) CreateWithResponse(ctx context.Context, projectID string, body CreateJSONRequestBody, ...) (*CreateResponse, error)
- func (c *ClientWithResponses) DeleteWithResponse(ctx context.Context, projectID string, instanceID string, ...) (*DeleteResponse, error)
- func (c *ClientWithResponses) GetWithResponse(ctx context.Context, projectID string, instanceID string, ...) (*GetResponse, error)
- func (c *ClientWithResponses) ListWithResponse(ctx context.Context, projectID string, reqEditors ...RequestEditorFn) (*ListResponse, error)
- func (c *ClientWithResponses) ParseCreateCloneResponse(rsp *http.Response) (*CreateCloneResponse, error)
- func (c *ClientWithResponses) ParseCreateResponse(rsp *http.Response) (*CreateResponse, error)
- func (c *ClientWithResponses) ParseDeleteResponse(rsp *http.Response) (*DeleteResponse, error)
- func (c *ClientWithResponses) ParseGetResponse(rsp *http.Response) (*GetResponse, error)
- func (c *ClientWithResponses) ParseListResponse(rsp *http.Response) (*ListResponse, error)
- func (c *ClientWithResponses) ParsePatchUpdateResponse(rsp *http.Response) (*PatchUpdateResponse, error)
- func (c *ClientWithResponses) ParseUpdateResponse(rsp *http.Response) (*UpdateResponse, error)
- func (c *ClientWithResponses) PatchUpdateWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, ...) (*PatchUpdateResponse, error)
- func (c *ClientWithResponses) PatchUpdateWithResponse(ctx context.Context, projectID string, instanceID string, ...) (*PatchUpdateResponse, error)
- func (c *ClientWithResponses) UpdateWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, ...) (*UpdateResponse, error)
- func (c *ClientWithResponses) UpdateWithResponse(ctx context.Context, projectID string, instanceID string, ...) (*UpdateResponse, error)
- type ClientWithResponsesInterface
- type CreateCloneJSONRequestBody
- type CreateCloneResponse
- type CreateJSONRequestBody
- type CreateResponse
- type DeleteResponse
- type GetResponse
- type InstanceACL
- type InstanceCreateCloneInstanceRequest
- type InstanceCreateCloneInstanceResponse
- type InstanceCreateInstanceRequest
- type InstanceCreateInstanceResponse
- type InstanceError
- type InstanceFlavor
- type InstanceGetInstanceResponse
- type InstanceListInstance
- type InstanceListInstanceResponse
- type InstanceSingleInstance
- type InstanceStorage
- type InstanceUpdateInstanceRequest
- type InstanceUpdateInstanceResponse
- type ListResponse
- type PatchUpdateJSONRequestBody
- type PatchUpdateResponse
- type RequestEditorFn
- type UpdateJSONRequestBody
- type UpdateResponse
Constants ¶
const ( // Instance status options STATUS_READY = "READY" STATUS_FAILED = "FAILED" STATUS_PROCESSING = "PROCESSING" )
const (
BearerAuthScopes = "BearerAuth.Scopes"
)
Variables ¶
This section is empty.
Functions ¶
func NewCreateCloneRequest ¶ added in v1.15.1
func NewCreateCloneRequest(ctx context.Context, server string, projectID string, instanceID string, body CreateCloneJSONRequestBody) (*http.Request, error)
NewCreateCloneRequest calls the generic CreateClone builder with application/json body
func NewCreateCloneRequestWithBody ¶ added in v1.15.1
func NewCreateCloneRequestWithBody(ctx context.Context, server string, projectID string, instanceID string, contentType string, body io.Reader) (*http.Request, error)
NewCreateCloneRequestWithBody generates requests for CreateClone with any type of body
func NewCreateRequest ¶ added in v1.4.0
func NewCreateRequest(ctx context.Context, server string, projectID string, body CreateJSONRequestBody) (*http.Request, error)
NewCreateRequest calls the generic Create builder with application/json body
func NewCreateRequestWithBody ¶ added in v1.4.0
func NewCreateRequestWithBody(ctx context.Context, server string, projectID string, contentType string, body io.Reader) (*http.Request, error)
NewCreateRequestWithBody generates requests for Create with any type of body
func NewDeleteRequest ¶ added in v1.4.0
func NewDeleteRequest(ctx context.Context, server string, projectID string, instanceID string) (*http.Request, error)
NewDeleteRequest generates requests for Delete
func NewGetRequest ¶ added in v1.4.0
func NewGetRequest(ctx context.Context, server string, projectID string, instanceID string) (*http.Request, error)
NewGetRequest generates requests for Get
func NewListRequest ¶ added in v1.4.0
NewListRequest generates requests for List
func NewPatchUpdateRequest ¶ added in v1.4.0
func NewPatchUpdateRequest(ctx context.Context, server string, projectID string, instanceID string, body PatchUpdateJSONRequestBody) (*http.Request, error)
NewPatchUpdateRequest calls the generic PatchUpdate builder with application/json body
func NewPatchUpdateRequestWithBody ¶ added in v1.4.0
func NewPatchUpdateRequestWithBody(ctx context.Context, server string, projectID string, instanceID string, contentType string, body io.Reader) (*http.Request, error)
NewPatchUpdateRequestWithBody generates requests for PatchUpdate with any type of body
Types ¶
type Client ¶
type Client struct { // The endpoint of the server conforming to this interface, with scheme, // https://api.deepmap.com for example. This can contain a path relative // to the server, such as https://api.deepmap.com/dev-test, and all the // paths in the swagger spec will be appended to the server. Server string // Doer for performing requests, typically a *http.Client with any // customized settings, such as certificate chains. Client common.Client }
Client which conforms to the OpenAPI3 specification for this service.
func (*Client) Create ¶ added in v1.4.0
func (c *Client) Create(ctx context.Context, projectID string, body CreateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateClone ¶ added in v1.15.1
func (c *Client) CreateClone(ctx context.Context, projectID string, instanceID string, body CreateCloneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateCloneWithBody ¶ added in v1.15.1
func (*Client) CreateWithBody ¶ added in v1.4.0
func (*Client) PatchUpdate ¶ added in v1.4.0
func (c *Client) PatchUpdate(ctx context.Context, projectID string, instanceID string, body PatchUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) PatchUpdateWithBody ¶ added in v1.4.0
type ClientInterface ¶
type ClientInterface interface { // List request List(ctx context.Context, projectID string, reqEditors ...RequestEditorFn) (*http.Response, error) // Create request with any body CreateWithBody(ctx context.Context, projectID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) Create(ctx context.Context, projectID string, body CreateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // Delete request Delete(ctx context.Context, projectID string, instanceID string, reqEditors ...RequestEditorFn) (*http.Response, error) // Get request Get(ctx context.Context, projectID string, instanceID string, reqEditors ...RequestEditorFn) (*http.Response, error) // PatchUpdate request with any body PatchUpdateWithBody(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) PatchUpdate(ctx context.Context, projectID string, instanceID string, body PatchUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // Update request with any body UpdateWithBody(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) Update(ctx context.Context, projectID string, instanceID string, body UpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateClone request with any body CreateCloneWithBody(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) CreateClone(ctx context.Context, projectID string, instanceID string, body CreateCloneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) }
The interface specification for the client above.
type ClientWithResponses ¶
type ClientWithResponses struct {
ClientInterface
}
ClientWithResponses builds on ClientInterface to offer response payloads
func NewClientWithResponses ¶
func NewClientWithResponses(server string, httpClient common.Client) *ClientWithResponses
NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling
func (*ClientWithResponses) CreateCloneWithBodyWithResponse ¶ added in v1.15.1
func (c *ClientWithResponses) CreateCloneWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateCloneResponse, error)
CreateCloneWithBodyWithResponse request with arbitrary body returning *CreateCloneResponse
func (*ClientWithResponses) CreateCloneWithResponse ¶ added in v1.15.1
func (c *ClientWithResponses) CreateCloneWithResponse(ctx context.Context, projectID string, instanceID string, body CreateCloneJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateCloneResponse, error)
func (*ClientWithResponses) CreateWithBodyWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) CreateWithBodyWithResponse(ctx context.Context, projectID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateResponse, error)
CreateWithBodyWithResponse request with arbitrary body returning *CreateResponse
func (*ClientWithResponses) CreateWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) CreateWithResponse(ctx context.Context, projectID string, body CreateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateResponse, error)
func (*ClientWithResponses) DeleteWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) DeleteWithResponse(ctx context.Context, projectID string, instanceID string, reqEditors ...RequestEditorFn) (*DeleteResponse, error)
DeleteWithResponse request returning *DeleteResponse
func (*ClientWithResponses) GetWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) GetWithResponse(ctx context.Context, projectID string, instanceID string, reqEditors ...RequestEditorFn) (*GetResponse, error)
GetWithResponse request returning *GetResponse
func (*ClientWithResponses) ListWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) ListWithResponse(ctx context.Context, projectID string, reqEditors ...RequestEditorFn) (*ListResponse, error)
ListWithResponse request returning *ListResponse
func (*ClientWithResponses) ParseCreateCloneResponse ¶ added in v1.15.1
func (c *ClientWithResponses) ParseCreateCloneResponse(rsp *http.Response) (*CreateCloneResponse, error)
ParseCreateCloneResponse parses an HTTP response from a CreateCloneWithResponse call
func (*ClientWithResponses) ParseCreateResponse ¶ added in v1.4.0
func (c *ClientWithResponses) ParseCreateResponse(rsp *http.Response) (*CreateResponse, error)
ParseCreateResponse parses an HTTP response from a CreateWithResponse call
func (*ClientWithResponses) ParseDeleteResponse ¶ added in v1.4.0
func (c *ClientWithResponses) ParseDeleteResponse(rsp *http.Response) (*DeleteResponse, error)
ParseDeleteResponse parses an HTTP response from a DeleteWithResponse call
func (*ClientWithResponses) ParseGetResponse ¶ added in v1.4.0
func (c *ClientWithResponses) ParseGetResponse(rsp *http.Response) (*GetResponse, error)
ParseGetResponse parses an HTTP response from a GetWithResponse call
func (*ClientWithResponses) ParseListResponse ¶ added in v1.4.0
func (c *ClientWithResponses) ParseListResponse(rsp *http.Response) (*ListResponse, error)
ParseListResponse parses an HTTP response from a ListWithResponse call
func (*ClientWithResponses) ParsePatchUpdateResponse ¶ added in v1.4.0
func (c *ClientWithResponses) ParsePatchUpdateResponse(rsp *http.Response) (*PatchUpdateResponse, error)
ParsePatchUpdateResponse parses an HTTP response from a PatchUpdateWithResponse call
func (*ClientWithResponses) ParseUpdateResponse ¶ added in v1.4.0
func (c *ClientWithResponses) ParseUpdateResponse(rsp *http.Response) (*UpdateResponse, error)
ParseUpdateResponse parses an HTTP response from a UpdateWithResponse call
func (*ClientWithResponses) PatchUpdateWithBodyWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) PatchUpdateWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchUpdateResponse, error)
PatchUpdateWithBodyWithResponse request with arbitrary body returning *PatchUpdateResponse
func (*ClientWithResponses) PatchUpdateWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) PatchUpdateWithResponse(ctx context.Context, projectID string, instanceID string, body PatchUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchUpdateResponse, error)
func (*ClientWithResponses) UpdateWithBodyWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) UpdateWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateResponse, error)
UpdateWithBodyWithResponse request with arbitrary body returning *UpdateResponse
func (*ClientWithResponses) UpdateWithResponse ¶ added in v1.4.0
func (c *ClientWithResponses) UpdateWithResponse(ctx context.Context, projectID string, instanceID string, body UpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateResponse, error)
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface { // List request ListWithResponse(ctx context.Context, projectID string, reqEditors ...RequestEditorFn) (*ListResponse, error) // Create request with any body CreateWithBodyWithResponse(ctx context.Context, projectID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateResponse, error) CreateWithResponse(ctx context.Context, projectID string, body CreateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateResponse, error) // Delete request DeleteWithResponse(ctx context.Context, projectID string, instanceID string, reqEditors ...RequestEditorFn) (*DeleteResponse, error) // Get request GetWithResponse(ctx context.Context, projectID string, instanceID string, reqEditors ...RequestEditorFn) (*GetResponse, error) // PatchUpdate request with any body PatchUpdateWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchUpdateResponse, error) PatchUpdateWithResponse(ctx context.Context, projectID string, instanceID string, body PatchUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchUpdateResponse, error) // Update request with any body UpdateWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateResponse, error) UpdateWithResponse(ctx context.Context, projectID string, instanceID string, body UpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateResponse, error) // CreateClone request with any body CreateCloneWithBodyWithResponse(ctx context.Context, projectID string, instanceID string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateCloneResponse, error) CreateCloneWithResponse(ctx context.Context, projectID string, instanceID string, body CreateCloneJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateCloneResponse, error) }
ClientWithResponsesInterface is the interface specification for the client with responses above.
type CreateCloneJSONRequestBody ¶ added in v1.15.1
type CreateCloneJSONRequestBody = InstanceCreateCloneInstanceRequest
CreateCloneJSONRequestBody defines body for CreateClone for application/json ContentType.
type CreateCloneResponse ¶ added in v1.15.1
type CreateCloneResponse struct { Body []byte HTTPResponse *http.Response JSON201 *InstanceCreateCloneInstanceResponse JSON400 *InstanceError HasError error // Aggregated error }
func (CreateCloneResponse) Status ¶ added in v1.15.1
func (r CreateCloneResponse) Status() string
Status returns HTTPResponse.Status
func (CreateCloneResponse) StatusCode ¶ added in v1.15.1
func (r CreateCloneResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type CreateJSONRequestBody ¶ added in v1.4.0
type CreateJSONRequestBody = InstanceCreateInstanceRequest
CreateJSONRequestBody defines body for Create for application/json ContentType.
type CreateResponse ¶ added in v1.4.0
type CreateResponse struct { Body []byte HTTPResponse *http.Response JSON201 *InstanceCreateInstanceResponse JSON400 *InstanceError HasError error // Aggregated error }
func (CreateResponse) Status ¶ added in v1.4.0
func (r CreateResponse) Status() string
Status returns HTTPResponse.Status
func (CreateResponse) StatusCode ¶ added in v1.4.0
func (r CreateResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
func (CreateResponse) WaitHandler ¶ added in v1.4.0
func (r CreateResponse) WaitHandler(ctx context.Context, c *ClientWithResponses, projectID, instanceID string) *wait.Handler
WaitHandler will wait for instance creation to complete returned interface is of *InstanceSingleInstance
type DeleteResponse ¶ added in v1.4.0
type DeleteResponse struct { Body []byte HTTPResponse *http.Response JSON400 *InstanceError HasError error // Aggregated error }
func (DeleteResponse) Status ¶ added in v1.4.0
func (r DeleteResponse) Status() string
Status returns HTTPResponse.Status
func (DeleteResponse) StatusCode ¶ added in v1.4.0
func (r DeleteResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
func (DeleteResponse) WaitHandler ¶ added in v1.4.0
func (r DeleteResponse) WaitHandler(ctx context.Context, c *ClientWithResponses, projectID, instanceID string) *wait.Handler
WaitHandler will wait for instance deletion returned value for deletion wait will always be nil
type GetResponse ¶ added in v1.4.0
type GetResponse struct { Body []byte HTTPResponse *http.Response JSON200 *InstanceGetInstanceResponse JSON400 *InstanceError HasError error // Aggregated error }
func (GetResponse) Status ¶ added in v1.4.0
func (r GetResponse) Status() string
Status returns HTTPResponse.Status
func (GetResponse) StatusCode ¶ added in v1.4.0
func (r GetResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type InstanceACL ¶ added in v1.5.1
type InstanceACL struct { // Items TODO validating in api (middleware) Items *[]string `json:"items,omitempty"` }
InstanceACL defines model for instance.ACL.
type InstanceCreateCloneInstanceRequest ¶ added in v1.15.1
type InstanceCreateCloneInstanceRequest struct { InstanceID *string `json:"instanceId,omitempty"` Timestamp *string `json:"timestamp,omitempty"` }
InstanceCreateCloneInstanceRequest defines model for instance.CreateCloneInstanceRequest.
type InstanceCreateCloneInstanceResponse ¶ added in v1.15.1
type InstanceCreateCloneInstanceResponse struct {
InstanceID *string `json:"instanceId,omitempty"`
}
InstanceCreateCloneInstanceResponse defines model for instance.CreateCloneInstanceResponse.
type InstanceCreateInstanceRequest ¶
type InstanceCreateInstanceRequest struct { ACL *InstanceACL `json:"acl,omitempty"` BackupSchedule *string `json:"backupSchedule,omitempty"` FlavorID *string `json:"flavorId,omitempty"` // Labels Following fields are not certain/clear Labels *map[string]string `json:"labels,omitempty"` Name *string `json:"name,omitempty"` Options *map[string]string `json:"options,omitempty"` Replicas *int `json:"replicas,omitempty"` Storage *InstanceStorage `json:"storage,omitempty"` Version *string `json:"version,omitempty"` }
InstanceCreateInstanceRequest defines model for instance.CreateInstanceRequest.
type InstanceCreateInstanceResponse ¶
type InstanceCreateInstanceResponse struct {
ID *string `json:"id,omitempty"`
}
InstanceCreateInstanceResponse defines model for instance.CreateInstanceResponse.
type InstanceError ¶
type InstanceError struct { Code *int `json:"code,omitempty"` Fields *map[string][]string `json:"fields,omitempty"` Message *string `json:"message,omitempty"` Type *string `json:"type,omitempty"` }
InstanceError defines model for instance.Error.
type InstanceFlavor ¶
type InstanceFlavor struct { Cpu *int `json:"cpu,omitempty"` Description *string `json:"description,omitempty"` ID *string `json:"id,omitempty"` Memory *int `json:"memory,omitempty"` }
InstanceFlavor defines model for instance.Flavor.
type InstanceGetInstanceResponse ¶
type InstanceGetInstanceResponse struct {
Item *InstanceSingleInstance `json:"item,omitempty"`
}
InstanceGetInstanceResponse defines model for instance.GetInstanceResponse.
type InstanceListInstance ¶
type InstanceListInstance struct { ID *string `json:"id,omitempty"` Name *string `json:"name,omitempty"` Status *string `json:"status,omitempty"` }
InstanceListInstance defines model for instance.ListInstance.
type InstanceListInstanceResponse ¶
type InstanceListInstanceResponse struct { // Count TODO pagination ? Count *int `json:"count,omitempty"` Items *[]InstanceListInstance `json:"items,omitempty"` }
InstanceListInstanceResponse defines model for instance.ListInstanceResponse.
type InstanceSingleInstance ¶
type InstanceSingleInstance struct { ACL *InstanceACL `json:"acl,omitempty"` BackupSchedule *string `json:"backupSchedule,omitempty"` Flavor *InstanceFlavor `json:"flavor,omitempty"` ID *string `json:"id,omitempty"` Name *string `json:"name,omitempty"` Options *map[string]string `json:"options,omitempty"` Replicas *int `json:"replicas,omitempty"` Status *string `json:"status,omitempty"` Storage *InstanceStorage `json:"storage,omitempty"` Version *string `json:"version,omitempty"` }
InstanceSingleInstance defines model for instance.SingleInstance.
type InstanceStorage ¶
type InstanceStorage struct { Class *string `json:"class,omitempty"` Size *int `json:"size,omitempty"` }
InstanceStorage defines model for instance.Storage.
type InstanceUpdateInstanceRequest ¶
type InstanceUpdateInstanceRequest struct { ACL *InstanceACL `json:"acl,omitempty"` BackupSchedule *string `json:"backupSchedule,omitempty"` FlavorID *string `json:"flavorId,omitempty"` // Labels Following fields are not certain/clear Labels *map[string]string `json:"labels,omitempty"` Name *string `json:"name,omitempty"` Options *map[string]string `json:"options,omitempty"` Replicas *int `json:"replicas,omitempty"` Storage *InstanceStorage `json:"storage,omitempty"` Version *string `json:"version,omitempty"` }
InstanceUpdateInstanceRequest defines model for instance.UpdateInstanceRequest.
type InstanceUpdateInstanceResponse ¶
type InstanceUpdateInstanceResponse struct {
Item *InstanceSingleInstance `json:"item,omitempty"`
}
InstanceUpdateInstanceResponse defines model for instance.UpdateInstanceResponse.
type ListResponse ¶ added in v1.4.0
type ListResponse struct { Body []byte HTTPResponse *http.Response JSON200 *InstanceListInstanceResponse JSON400 *InstanceError HasError error // Aggregated error }
func (ListResponse) Status ¶ added in v1.4.0
func (r ListResponse) Status() string
Status returns HTTPResponse.Status
func (ListResponse) StatusCode ¶ added in v1.4.0
func (r ListResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type PatchUpdateJSONRequestBody ¶ added in v1.4.0
type PatchUpdateJSONRequestBody = InstanceUpdateInstanceRequest
PatchUpdateJSONRequestBody defines body for PatchUpdate for application/json ContentType.
type PatchUpdateResponse ¶ added in v1.4.0
type PatchUpdateResponse struct { Body []byte HTTPResponse *http.Response JSON200 *InstanceUpdateInstanceResponse JSON400 *InstanceError HasError error // Aggregated error }
func (PatchUpdateResponse) Status ¶ added in v1.4.0
func (r PatchUpdateResponse) Status() string
Status returns HTTPResponse.Status
func (PatchUpdateResponse) StatusCode ¶ added in v1.4.0
func (r PatchUpdateResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
func (PatchUpdateResponse) WaitHandler ¶ added in v1.15.2
func (r PatchUpdateResponse) WaitHandler(ctx context.Context, c *ClientWithResponses, projectID, instanceID string) *wait.Handler
WaitHandler will wait for instance update to complete returned interface is of *InstanceSingleInstance
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type UpdateJSONRequestBody ¶ added in v1.4.0
type UpdateJSONRequestBody = InstanceUpdateInstanceRequest
UpdateJSONRequestBody defines body for Update for application/json ContentType.
type UpdateResponse ¶ added in v1.4.0
type UpdateResponse struct { Body []byte HTTPResponse *http.Response JSON200 *InstanceUpdateInstanceResponse JSON400 *InstanceError HasError error // Aggregated error }
func (UpdateResponse) Status ¶ added in v1.4.0
func (r UpdateResponse) Status() string
Status returns HTTPResponse.Status
func (UpdateResponse) StatusCode ¶ added in v1.4.0
func (r UpdateResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
func (UpdateResponse) WaitHandler ¶ added in v1.4.0
func (r UpdateResponse) WaitHandler(ctx context.Context, c *ClientWithResponses, projectID, instanceID string) *wait.Handler
WaitHandler will wait for instance update to complete returned interface is of *InstanceSingleInstance