api

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2021 License: BSD-3-Clause Imports: 20 Imported by: 3

Documentation

Overview

Package api provides primitives to interact with the openapi HTTP API.

Code generated by github.com/deepmap/oapi-codegen version v1.7.0 DO NOT EDIT.

Package api provides primitives to interact with the openapi HTTP API.

Code generated by github.com/deepmap/oapi-codegen version v1.7.0 DO NOT EDIT.

Index

Constants

View Source
const (
	// ClusterIDPrefix is prefixed to all cluster IDs
	ClusterIDPrefix = "c-"
	// TenantIDPrefix is prefixed to all tenant IDs
	TenantIDPrefix = "t-"
	// ContentJSONPatch is the content type to do JSON updates
	ContentJSONPatch = "application/merge-patch+json"
)
View Source
const (
	BearerAuthScopes = "BearerAuth.Scopes"
)

Variables

This section is empty.

Functions

func GetSwagger

func GetSwagger() (swagger *openapi3.T, err error)

GetSwagger returns the Swagger specification corresponding to the generated code in this file. The external references of Swagger specification are resolved. The logic of resolving external references is tightly connected to "import-mapping" feature. Externally referenced files must be embedded in the corresponding golang packages. Urls can be supported but this task was out of the scope.

func NewCRDFromAPICluster

func NewCRDFromAPICluster(apiCluster Cluster) (*synv1alpha1.Cluster, error)

NewCRDFromAPICluster transforms an API cluster into the CRD representation

func NewCRDFromAPITenant

func NewCRDFromAPITenant(apiTenant Tenant) (*synv1alpha1.Tenant, error)

NewCRDFromAPITenant transforms an API tenant into the CRD representation

func NewCreateClusterRequest

func NewCreateClusterRequest(server string, body CreateClusterJSONRequestBody) (*http.Request, error)

NewCreateClusterRequest calls the generic CreateCluster builder with application/json body

func NewCreateClusterRequestWithBody

func NewCreateClusterRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewCreateClusterRequestWithBody generates requests for CreateCluster with any type of body

func NewCreateTenantRequest

func NewCreateTenantRequest(server string, body CreateTenantJSONRequestBody) (*http.Request, error)

NewCreateTenantRequest calls the generic CreateTenant builder with application/json body

func NewCreateTenantRequestWithBody

func NewCreateTenantRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewCreateTenantRequestWithBody generates requests for CreateTenant with any type of body

func NewDeleteClusterRequest

func NewDeleteClusterRequest(server string, clusterId ClusterIdParameter) (*http.Request, error)

NewDeleteClusterRequest generates requests for DeleteCluster

func NewDeleteTenantRequest

func NewDeleteTenantRequest(server string, tenantId TenantIdParameter) (*http.Request, error)

NewDeleteTenantRequest generates requests for DeleteTenant

func NewDocsRequest added in v0.1.2

func NewDocsRequest(server string) (*http.Request, error)

NewDocsRequest generates requests for Docs

func NewGetClusterRequest

func NewGetClusterRequest(server string, clusterId ClusterIdParameter) (*http.Request, error)

NewGetClusterRequest generates requests for GetCluster

func NewGetTenantRequest

func NewGetTenantRequest(server string, tenantId TenantIdParameter) (*http.Request, error)

NewGetTenantRequest generates requests for GetTenant

func NewHealthzRequest

func NewHealthzRequest(server string) (*http.Request, error)

NewHealthzRequest generates requests for Healthz

func NewInstallStewardRequest

func NewInstallStewardRequest(server string, params *InstallStewardParams) (*http.Request, error)

NewInstallStewardRequest generates requests for InstallSteward

func NewListClustersRequest

func NewListClustersRequest(server string, params *ListClustersParams) (*http.Request, error)

NewListClustersRequest generates requests for ListClusters

func NewListTenantsRequest

func NewListTenantsRequest(server string) (*http.Request, error)

NewListTenantsRequest generates requests for ListTenants

func NewOpenapiRequest added in v0.1.2

func NewOpenapiRequest(server string) (*http.Request, error)

NewOpenapiRequest generates requests for Openapi

func NewPutClusterRequest added in v0.8.0

func NewPutClusterRequest(server string, clusterId ClusterIdParameter, body PutClusterJSONRequestBody) (*http.Request, error)

NewPutClusterRequest calls the generic PutCluster builder with application/json body

func NewPutClusterRequestWithBody added in v0.8.0

func NewPutClusterRequestWithBody(server string, clusterId ClusterIdParameter, contentType string, body io.Reader) (*http.Request, error)

NewPutClusterRequestWithBody generates requests for PutCluster with any type of body

func NewPutTenantRequest added in v0.8.0

func NewPutTenantRequest(server string, tenantId TenantIdParameter, body PutTenantJSONRequestBody) (*http.Request, error)

NewPutTenantRequest calls the generic PutTenant builder with application/json body

func NewPutTenantRequestWithBody added in v0.8.0

func NewPutTenantRequestWithBody(server string, tenantId TenantIdParameter, contentType string, body io.Reader) (*http.Request, error)

NewPutTenantRequestWithBody generates requests for PutTenant with any type of body

func NewQueryInventoryRequest

func NewQueryInventoryRequest(server string, params *QueryInventoryParams) (*http.Request, error)

NewQueryInventoryRequest generates requests for QueryInventory

func NewUpdateClusterRequestWithBody

func NewUpdateClusterRequestWithBody(server string, clusterId ClusterIdParameter, contentType string, body io.Reader) (*http.Request, error)

NewUpdateClusterRequestWithBody generates requests for UpdateCluster with any type of body

func NewUpdateInventoryRequest

func NewUpdateInventoryRequest(server string, body UpdateInventoryJSONRequestBody) (*http.Request, error)

NewUpdateInventoryRequest calls the generic UpdateInventory builder with application/json body

func NewUpdateInventoryRequestWithBody

func NewUpdateInventoryRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewUpdateInventoryRequestWithBody generates requests for UpdateInventory with any type of body

func NewUpdateTenantRequestWithBody

func NewUpdateTenantRequestWithBody(server string, tenantId TenantIdParameter, contentType string, body io.Reader) (*http.Request, error)

NewUpdateTenantRequestWithBody generates requests for UpdateTenant with any type of body

func PathToRawSpec added in v0.5.0

func PathToRawSpec(pathToFile string) map[string]func() ([]byte, error)

Constructs a synthetic filesystem for resolving external references when loading openapi specifications.

func RegisterHandlers

func RegisterHandlers(router EchoRouter, si ServerInterface)

RegisterHandlers adds each server route to the EchoRouter.

func RegisterHandlersWithBaseURL added in v0.4.1

func RegisterHandlersWithBaseURL(router EchoRouter, si ServerInterface, baseURL string)

Registers handlers, and prepends BaseURL to the paths, so that the paths can be served under a prefix.

func SyncCRDFromAPICluster added in v0.4.1

func SyncCRDFromAPICluster(source ClusterProperties, target *synv1alpha1.Cluster) error

func SyncCRDFromAPITenant added in v0.4.1

func SyncCRDFromAPITenant(source TenantProperties, target *synv1alpha1.Tenant)

Types

type Annotations added in v0.3.0

type Annotations map[string]interface{}

Unstructured key value map containing arbitrary metadata

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 HttpRequestDoer

	// A list of callbacks for modifying requests which are generated before sending over
	// the network.
	RequestEditors []RequestEditorFn
}

Client which conforms to the OpenAPI3 specification for this service.

func NewClient

func NewClient(server string, opts ...ClientOption) (*Client, error)

Creates a new Client, with reasonable defaults

func (*Client) CreateCluster

func (c *Client) CreateCluster(ctx context.Context, body CreateClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) CreateClusterWithBody

func (c *Client) CreateClusterWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) CreateTenant

func (c *Client) CreateTenant(ctx context.Context, body CreateTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) CreateTenantWithBody

func (c *Client) CreateTenantWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) DeleteCluster

func (c *Client) DeleteCluster(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) DeleteTenant

func (c *Client) DeleteTenant(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) Docs added in v0.1.2

func (c *Client) Docs(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GetCluster

func (c *Client) GetCluster(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GetTenant

func (c *Client) GetTenant(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) Healthz

func (c *Client) Healthz(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) InstallSteward

func (c *Client) InstallSteward(ctx context.Context, params *InstallStewardParams, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) ListClusters

func (c *Client) ListClusters(ctx context.Context, params *ListClustersParams, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) ListTenants

func (c *Client) ListTenants(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) Openapi added in v0.1.2

func (c *Client) Openapi(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) PutCluster added in v0.8.0

func (c *Client) PutCluster(ctx context.Context, clusterId ClusterIdParameter, body PutClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) PutClusterWithBody added in v0.8.0

func (c *Client) PutClusterWithBody(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) PutTenant added in v0.8.0

func (c *Client) PutTenant(ctx context.Context, tenantId TenantIdParameter, body PutTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) PutTenantWithBody added in v0.8.0

func (c *Client) PutTenantWithBody(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) QueryInventory

func (c *Client) QueryInventory(ctx context.Context, params *QueryInventoryParams, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) UpdateClusterWithBody

func (c *Client) UpdateClusterWithBody(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) UpdateInventory

func (c *Client) UpdateInventory(ctx context.Context, body UpdateInventoryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) UpdateInventoryWithBody

func (c *Client) UpdateInventoryWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) UpdateTenantWithBody

func (c *Client) UpdateTenantWithBody(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

type ClientInterface

type ClientInterface interface {
	// ListClusters request
	ListClusters(ctx context.Context, params *ListClustersParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// CreateCluster request  with any body
	CreateClusterWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	CreateCluster(ctx context.Context, body CreateClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteCluster request
	DeleteCluster(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetCluster request
	GetCluster(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

	// UpdateCluster request  with any body
	UpdateClusterWithBody(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutCluster request  with any body
	PutClusterWithBody(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutCluster(ctx context.Context, clusterId ClusterIdParameter, body PutClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// Docs request
	Docs(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// Healthz request
	Healthz(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// InstallSteward request
	InstallSteward(ctx context.Context, params *InstallStewardParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// QueryInventory request
	QueryInventory(ctx context.Context, params *QueryInventoryParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// UpdateInventory request  with any body
	UpdateInventoryWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	UpdateInventory(ctx context.Context, body UpdateInventoryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// Openapi request
	Openapi(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// ListTenants request
	ListTenants(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// CreateTenant request  with any body
	CreateTenantWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	CreateTenant(ctx context.Context, body CreateTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteTenant request
	DeleteTenant(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetTenant request
	GetTenant(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*http.Response, error)

	// UpdateTenant request  with any body
	UpdateTenantWithBody(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutTenant request  with any body
	PutTenantWithBody(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutTenant(ctx context.Context, tenantId TenantIdParameter, body PutTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
}

The interface specification for the client above.

type ClientOption

type ClientOption func(*Client) error

ClientOption allows setting custom parameters during construction

func WithBaseURL

func WithBaseURL(baseURL string) ClientOption

WithBaseURL overrides the baseURL.

func WithHTTPClient

func WithHTTPClient(doer HttpRequestDoer) ClientOption

WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.

func WithRequestEditorFn

func WithRequestEditorFn(fn RequestEditorFn) ClientOption

WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.

type ClientWithResponses

type ClientWithResponses struct {
	ClientInterface
}

ClientWithResponses builds on ClientInterface to offer response payloads

func NewClientWithResponses

func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)

NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling

func (*ClientWithResponses) CreateClusterWithBodyWithResponse

func (c *ClientWithResponses) CreateClusterWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateClusterResponse, error)

CreateClusterWithBodyWithResponse request with arbitrary body returning *CreateClusterResponse

func (*ClientWithResponses) CreateClusterWithResponse

func (c *ClientWithResponses) CreateClusterWithResponse(ctx context.Context, body CreateClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateClusterResponse, error)

func (*ClientWithResponses) CreateTenantWithBodyWithResponse

func (c *ClientWithResponses) CreateTenantWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTenantResponse, error)

CreateTenantWithBodyWithResponse request with arbitrary body returning *CreateTenantResponse

func (*ClientWithResponses) CreateTenantWithResponse

func (c *ClientWithResponses) CreateTenantWithResponse(ctx context.Context, body CreateTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTenantResponse, error)

func (*ClientWithResponses) DeleteClusterWithResponse

func (c *ClientWithResponses) DeleteClusterWithResponse(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*DeleteClusterResponse, error)

DeleteClusterWithResponse request returning *DeleteClusterResponse

func (*ClientWithResponses) DeleteTenantWithResponse

func (c *ClientWithResponses) DeleteTenantWithResponse(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*DeleteTenantResponse, error)

DeleteTenantWithResponse request returning *DeleteTenantResponse

func (*ClientWithResponses) DocsWithResponse added in v0.1.2

func (c *ClientWithResponses) DocsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*DocsResponse, error)

DocsWithResponse request returning *DocsResponse

func (*ClientWithResponses) GetClusterWithResponse

func (c *ClientWithResponses) GetClusterWithResponse(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*GetClusterResponse, error)

GetClusterWithResponse request returning *GetClusterResponse

func (*ClientWithResponses) GetTenantWithResponse

func (c *ClientWithResponses) GetTenantWithResponse(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*GetTenantResponse, error)

GetTenantWithResponse request returning *GetTenantResponse

func (*ClientWithResponses) HealthzWithResponse

func (c *ClientWithResponses) HealthzWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthzResponse, error)

HealthzWithResponse request returning *HealthzResponse

func (*ClientWithResponses) InstallStewardWithResponse

func (c *ClientWithResponses) InstallStewardWithResponse(ctx context.Context, params *InstallStewardParams, reqEditors ...RequestEditorFn) (*InstallStewardResponse, error)

InstallStewardWithResponse request returning *InstallStewardResponse

func (*ClientWithResponses) ListClustersWithResponse

func (c *ClientWithResponses) ListClustersWithResponse(ctx context.Context, params *ListClustersParams, reqEditors ...RequestEditorFn) (*ListClustersResponse, error)

ListClustersWithResponse request returning *ListClustersResponse

func (*ClientWithResponses) ListTenantsWithResponse

func (c *ClientWithResponses) ListTenantsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListTenantsResponse, error)

ListTenantsWithResponse request returning *ListTenantsResponse

func (*ClientWithResponses) OpenapiWithResponse added in v0.1.2

func (c *ClientWithResponses) OpenapiWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*OpenapiResponse, error)

OpenapiWithResponse request returning *OpenapiResponse

func (*ClientWithResponses) PutClusterWithBodyWithResponse added in v0.8.0

func (c *ClientWithResponses) PutClusterWithBodyWithResponse(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutClusterResponse, error)

PutClusterWithBodyWithResponse request with arbitrary body returning *PutClusterResponse

func (*ClientWithResponses) PutClusterWithResponse added in v0.8.0

func (c *ClientWithResponses) PutClusterWithResponse(ctx context.Context, clusterId ClusterIdParameter, body PutClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*PutClusterResponse, error)

func (*ClientWithResponses) PutTenantWithBodyWithResponse added in v0.8.0

func (c *ClientWithResponses) PutTenantWithBodyWithResponse(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutTenantResponse, error)

PutTenantWithBodyWithResponse request with arbitrary body returning *PutTenantResponse

func (*ClientWithResponses) PutTenantWithResponse added in v0.8.0

func (c *ClientWithResponses) PutTenantWithResponse(ctx context.Context, tenantId TenantIdParameter, body PutTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*PutTenantResponse, error)

func (*ClientWithResponses) QueryInventoryWithResponse

func (c *ClientWithResponses) QueryInventoryWithResponse(ctx context.Context, params *QueryInventoryParams, reqEditors ...RequestEditorFn) (*QueryInventoryResponse, error)

QueryInventoryWithResponse request returning *QueryInventoryResponse

func (*ClientWithResponses) UpdateClusterWithBodyWithResponse

func (c *ClientWithResponses) UpdateClusterWithBodyWithResponse(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateClusterResponse, error)

UpdateClusterWithBodyWithResponse request with arbitrary body returning *UpdateClusterResponse

func (*ClientWithResponses) UpdateInventoryWithBodyWithResponse

func (c *ClientWithResponses) UpdateInventoryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateInventoryResponse, error)

UpdateInventoryWithBodyWithResponse request with arbitrary body returning *UpdateInventoryResponse

func (*ClientWithResponses) UpdateInventoryWithResponse

func (c *ClientWithResponses) UpdateInventoryWithResponse(ctx context.Context, body UpdateInventoryJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateInventoryResponse, error)

func (*ClientWithResponses) UpdateTenantWithBodyWithResponse

func (c *ClientWithResponses) UpdateTenantWithBodyWithResponse(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateTenantResponse, error)

UpdateTenantWithBodyWithResponse request with arbitrary body returning *UpdateTenantResponse

type ClientWithResponsesInterface added in v0.1.2

type ClientWithResponsesInterface interface {
	// ListClusters request
	ListClustersWithResponse(ctx context.Context, params *ListClustersParams, reqEditors ...RequestEditorFn) (*ListClustersResponse, error)

	// CreateCluster request  with any body
	CreateClusterWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateClusterResponse, error)

	CreateClusterWithResponse(ctx context.Context, body CreateClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateClusterResponse, error)

	// DeleteCluster request
	DeleteClusterWithResponse(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*DeleteClusterResponse, error)

	// GetCluster request
	GetClusterWithResponse(ctx context.Context, clusterId ClusterIdParameter, reqEditors ...RequestEditorFn) (*GetClusterResponse, error)

	// UpdateCluster request  with any body
	UpdateClusterWithBodyWithResponse(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateClusterResponse, error)

	// PutCluster request  with any body
	PutClusterWithBodyWithResponse(ctx context.Context, clusterId ClusterIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutClusterResponse, error)

	PutClusterWithResponse(ctx context.Context, clusterId ClusterIdParameter, body PutClusterJSONRequestBody, reqEditors ...RequestEditorFn) (*PutClusterResponse, error)

	// Docs request
	DocsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*DocsResponse, error)

	// Healthz request
	HealthzWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthzResponse, error)

	// InstallSteward request
	InstallStewardWithResponse(ctx context.Context, params *InstallStewardParams, reqEditors ...RequestEditorFn) (*InstallStewardResponse, error)

	// QueryInventory request
	QueryInventoryWithResponse(ctx context.Context, params *QueryInventoryParams, reqEditors ...RequestEditorFn) (*QueryInventoryResponse, error)

	// UpdateInventory request  with any body
	UpdateInventoryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateInventoryResponse, error)

	UpdateInventoryWithResponse(ctx context.Context, body UpdateInventoryJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateInventoryResponse, error)

	// Openapi request
	OpenapiWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*OpenapiResponse, error)

	// ListTenants request
	ListTenantsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListTenantsResponse, error)

	// CreateTenant request  with any body
	CreateTenantWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTenantResponse, error)

	CreateTenantWithResponse(ctx context.Context, body CreateTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTenantResponse, error)

	// DeleteTenant request
	DeleteTenantWithResponse(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*DeleteTenantResponse, error)

	// GetTenant request
	GetTenantWithResponse(ctx context.Context, tenantId TenantIdParameter, reqEditors ...RequestEditorFn) (*GetTenantResponse, error)

	// UpdateTenant request  with any body
	UpdateTenantWithBodyWithResponse(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateTenantResponse, error)

	// PutTenant request  with any body
	PutTenantWithBodyWithResponse(ctx context.Context, tenantId TenantIdParameter, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutTenantResponse, error)

	PutTenantWithResponse(ctx context.Context, tenantId TenantIdParameter, body PutTenantJSONRequestBody, reqEditors ...RequestEditorFn) (*PutTenantResponse, error)
}

ClientWithResponsesInterface is the interface specification for the client with responses above.

type Cluster

type Cluster struct {
	// Embedded struct due to allOf(#/components/schemas/ClusterId)
	ClusterId `yaml:",inline"`
	// Embedded struct due to allOf(#/components/schemas/ClusterTenant)
	ClusterTenant `yaml:",inline"`
	// Embedded struct due to allOf(#/components/schemas/ClusterProperties)
	ClusterProperties `yaml:",inline"`
}

Cluster defines model for Cluster.

func NewAPIClusterFromCRD

func NewAPIClusterFromCRD(cluster synv1alpha1.Cluster) *Cluster

NewAPIClusterFromCRD transforms a CRD cluster into the API representation

type ClusterFacts

type ClusterFacts map[string]interface{}

Facts about a cluster object. Statically configured key/value pairs.

type ClusterId

type ClusterId struct {

	// A unique object identifier string. Automatically generated by the API on creation (in the form "<letter>-<adjective>-<noun>-<digits>" where all letters are lowercase, max 63 characters in total).
	Id Id `json:"id"`
}

ClusterId defines model for ClusterId.

func GenerateClusterID

func GenerateClusterID() (ClusterId, error)

GenerateClusterID creates a new cluster id

type ClusterIdParameter

type ClusterIdParameter Id

A unique object identifier string. Automatically generated by the API on creation (in the form "<letter>-<adjective>-<noun>-<digits>" where all letters are lowercase, max 63 characters in total).

type ClusterProperties

type ClusterProperties struct {

	// Unstructured key value map containing arbitrary metadata
	Annotations *Annotations `json:"annotations,omitempty"`

	// Display Name of the cluster
	DisplayName *string `json:"displayName,omitempty"`

	// Dynamic facts about a cluster object. Are periodically udpated by Project Syn and should not be set manually.
	DynamicFacts *DynamicClusterFacts `json:"dynamicFacts,omitempty"`

	// Facts about a cluster object. Statically configured key/value pairs.
	Facts *ClusterFacts `json:"facts,omitempty"`

	// Configuration Git repository, usually generated by the API
	GitRepo *GitRepo `json:"gitRepo,omitempty"`

	// Git revision to use with the global configruation git repository.
	// This takes precedence over the revision configured on the Tenant.
	GlobalGitRepoRevision *string `json:"globalGitRepoRevision,omitempty"`

	// URL to fetch install manifests for Steward cluster agent. This will only be set if the cluster's token is still valid.
	InstallURL *string `json:"installURL,omitempty"`

	// Git revision to use with the tenant configruation git repository.
	// This takes precedence over the revision configured on the Tenant.
	TenantGitRepoRevision *string `json:"tenantGitRepoRevision,omitempty"`
}

A cluster defition object. The Git repository is usually managed by the API and autogenerated. The sshDeployKey will be managed by Steward

type ClusterTenant added in v0.1.4

type ClusterTenant struct {

	// Id of the tenant this cluster belongs to
	Tenant string `json:"tenant"`
}

ClusterTenant defines model for ClusterTenant.

type CreateClusterJSONBody

type CreateClusterJSONBody Cluster

CreateClusterJSONBody defines parameters for CreateCluster.

type CreateClusterJSONRequestBody

type CreateClusterJSONRequestBody CreateClusterJSONBody

CreateClusterJSONRequestBody defines body for CreateCluster for application/json ContentType.

type CreateClusterResponse added in v0.1.2

type CreateClusterResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON201      *Cluster
	JSON400      *Reason
	JSONDefault  *Reason
}

func ParseCreateClusterResponse

func ParseCreateClusterResponse(rsp *http.Response) (*CreateClusterResponse, error)

ParseCreateClusterResponse parses an HTTP response from a CreateClusterWithResponse call

func (CreateClusterResponse) Status added in v0.1.2

func (r CreateClusterResponse) Status() string

Status returns HTTPResponse.Status

func (CreateClusterResponse) StatusCode added in v0.1.2

func (r CreateClusterResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type CreateTenantJSONBody

type CreateTenantJSONBody Tenant

CreateTenantJSONBody defines parameters for CreateTenant.

type CreateTenantJSONRequestBody

type CreateTenantJSONRequestBody CreateTenantJSONBody

CreateTenantJSONRequestBody defines body for CreateTenant for application/json ContentType.

type CreateTenantResponse added in v0.1.2

type CreateTenantResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON201      *Tenant
	JSON400      *Reason
	JSONDefault  *Reason
}

func ParseCreateTenantResponse

func ParseCreateTenantResponse(rsp *http.Response) (*CreateTenantResponse, error)

ParseCreateTenantResponse parses an HTTP response from a CreateTenantWithResponse call

func (CreateTenantResponse) Status added in v0.1.2

func (r CreateTenantResponse) Status() string

Status returns HTTPResponse.Status

func (CreateTenantResponse) StatusCode added in v0.1.2

func (r CreateTenantResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Default

type Default Reason

A reason for responses

type DeleteClusterResponse added in v0.1.2

type DeleteClusterResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON403      *Reason
	JSONDefault  *Reason
}

func ParseDeleteClusterResponse

func ParseDeleteClusterResponse(rsp *http.Response) (*DeleteClusterResponse, error)

ParseDeleteClusterResponse parses an HTTP response from a DeleteClusterWithResponse call

func (DeleteClusterResponse) Status added in v0.1.2

func (r DeleteClusterResponse) Status() string

Status returns HTTPResponse.Status

func (DeleteClusterResponse) StatusCode added in v0.1.2

func (r DeleteClusterResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type DeleteTenantResponse added in v0.1.2

type DeleteTenantResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON403      *Reason
	JSONDefault  *Reason
}

func ParseDeleteTenantResponse

func ParseDeleteTenantResponse(rsp *http.Response) (*DeleteTenantResponse, error)

ParseDeleteTenantResponse parses an HTTP response from a DeleteTenantWithResponse call

func (DeleteTenantResponse) Status added in v0.1.2

func (r DeleteTenantResponse) Status() string

Status returns HTTPResponse.Status

func (DeleteTenantResponse) StatusCode added in v0.1.2

func (r DeleteTenantResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type DocsResponse added in v0.1.2

type DocsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
}

func ParseDocsResponse added in v0.1.2

func ParseDocsResponse(rsp *http.Response) (*DocsResponse, error)

ParseDocsResponse parses an HTTP response from a DocsWithResponse call

func (DocsResponse) Status added in v0.1.2

func (r DocsResponse) Status() string

Status returns HTTPResponse.Status

func (DocsResponse) StatusCode added in v0.1.2

func (r DocsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type DynamicClusterFacts added in v0.7.0

type DynamicClusterFacts map[string]interface{}

Dynamic facts about a cluster object. Are periodically udpated by Project Syn and should not be set manually.

type EchoRouter added in v0.1.1

type EchoRouter interface {
	CONNECT(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	DELETE(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	GET(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	HEAD(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	OPTIONS(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	PATCH(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	POST(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	PUT(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
	TRACE(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route
}

This is a simple interface which specifies echo.Route addition functions which are present on both echo.Echo and echo.Group, since we want to allow using either of them for path registration

type GetClusterResponse added in v0.1.2

type GetClusterResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Cluster
	JSONDefault  *Reason
}

func ParseGetClusterResponse

func ParseGetClusterResponse(rsp *http.Response) (*GetClusterResponse, error)

ParseGetClusterResponse parses an HTTP response from a GetClusterWithResponse call

func (GetClusterResponse) Status added in v0.1.2

func (r GetClusterResponse) Status() string

Status returns HTTPResponse.Status

func (GetClusterResponse) StatusCode added in v0.1.2

func (r GetClusterResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetTenantResponse added in v0.1.2

type GetTenantResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Tenant
	JSONDefault  *Reason
}

func ParseGetTenantResponse

func ParseGetTenantResponse(rsp *http.Response) (*GetTenantResponse, error)

ParseGetTenantResponse parses an HTTP response from a GetTenantWithResponse call

func (GetTenantResponse) Status added in v0.1.2

func (r GetTenantResponse) Status() string

Status returns HTTPResponse.Status

func (GetTenantResponse) StatusCode added in v0.1.2

func (r GetTenantResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GitRepo

type GitRepo struct {

	// SSH public key / deploy key for clusterconfiguration catalog Git repository. This property is managed by Steward.
	DeployKey *string `json:"deployKey,omitempty"`

	// SSH known hosts of the git server (multiline possible for multiple keys)
	HostKeys *string `json:"hostKeys,omitempty"`

	// Specifies if a repo should be managed by the git controller. A value of 'unmanaged' means it's not manged by the controller
	Type *string `json:"type,omitempty"`

	// Full URL of the git repo
	Url *string `json:"url,omitempty"`
}

Configuration Git repository, usually generated by the API

type HealthzResponse added in v0.1.2

type HealthzResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *Reason
}

func ParseHealthzResponse

func ParseHealthzResponse(rsp *http.Response) (*HealthzResponse, error)

ParseHealthzResponse parses an HTTP response from a HealthzWithResponse call

func (HealthzResponse) Status added in v0.1.2

func (r HealthzResponse) Status() string

Status returns HTTPResponse.Status

func (HealthzResponse) StatusCode added in v0.1.2

func (r HealthzResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type HttpRequestDoer

type HttpRequestDoer interface {
	Do(req *http.Request) (*http.Response, error)
}

Doer performs HTTP requests.

The standard http.Client implements this interface.

type Id

type Id string

A unique object identifier string. Automatically generated by the API on creation (in the form "<letter>-<adjective>-<noun>-<digits>" where all letters are lowercase, max 63 characters in total).

func (Id) String added in v0.4.1

func (id Id) String() string

String returns the underlying string value of `Id`.

type InstallStewardParams

type InstallStewardParams struct {

	// Initial bootstrap token
	Token *string `json:"token,omitempty"`
}

InstallStewardParams defines parameters for InstallSteward.

type InstallStewardResponse added in v0.1.2

type InstallStewardResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *map[string]interface{}
	JSONDefault  *Reason
}

func ParseInstallStewardResponse

func ParseInstallStewardResponse(rsp *http.Response) (*InstallStewardResponse, error)

ParseInstallStewardResponse parses an HTTP response from a InstallStewardWithResponse call

func (InstallStewardResponse) Status added in v0.1.2

func (r InstallStewardResponse) Status() string

Status returns HTTPResponse.Status

func (InstallStewardResponse) StatusCode added in v0.1.2

func (r InstallStewardResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Inventory

type Inventory struct {
	Cluster   string                  `json:"cluster"`
	Inventory *map[string]interface{} `json:"inventory,omitempty"`
}

Inventory data of a cluster

type ListClustersParams

type ListClustersParams struct {

	// Filter clusters by tenant id
	Tenant *string `json:"tenant,omitempty"`
}

ListClustersParams defines parameters for ListClusters.

type ListClustersResponse added in v0.1.2

type ListClustersResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]Cluster
	JSONDefault  *Reason
}

func ParseListClustersResponse

func ParseListClustersResponse(rsp *http.Response) (*ListClustersResponse, error)

ParseListClustersResponse parses an HTTP response from a ListClustersWithResponse call

func (ListClustersResponse) Status added in v0.1.2

func (r ListClustersResponse) Status() string

Status returns HTTPResponse.Status

func (ListClustersResponse) StatusCode added in v0.1.2

func (r ListClustersResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type ListTenantsResponse added in v0.1.2

type ListTenantsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]Tenant
	JSONDefault  *Reason
}

func ParseListTenantsResponse

func ParseListTenantsResponse(rsp *http.Response) (*ListTenantsResponse, error)

ParseListTenantsResponse parses an HTTP response from a ListTenantsWithResponse call

func (ListTenantsResponse) Status added in v0.1.2

func (r ListTenantsResponse) Status() string

Status returns HTTPResponse.Status

func (ListTenantsResponse) StatusCode added in v0.1.2

func (r ListTenantsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type OpenapiResponse added in v0.1.2

type OpenapiResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *map[string]interface{}
}

func ParseOpenapiResponse added in v0.1.2

func ParseOpenapiResponse(rsp *http.Response) (*OpenapiResponse, error)

ParseOpenapiResponse parses an HTTP response from a OpenapiWithResponse call

func (OpenapiResponse) Status added in v0.1.2

func (r OpenapiResponse) Status() string

Status returns HTTPResponse.Status

func (OpenapiResponse) StatusCode added in v0.1.2

func (r OpenapiResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PutClusterJSONBody added in v0.8.0

type PutClusterJSONBody Cluster

PutClusterJSONBody defines parameters for PutCluster.

type PutClusterJSONRequestBody added in v0.8.0

type PutClusterJSONRequestBody PutClusterJSONBody

PutClusterJSONRequestBody defines body for PutCluster for application/json ContentType.

type PutClusterResponse added in v0.8.0

type PutClusterResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Cluster
	JSON201      *Cluster
	JSON403      *Reason
	JSONDefault  *Reason
}

func ParsePutClusterResponse added in v0.8.0

func ParsePutClusterResponse(rsp *http.Response) (*PutClusterResponse, error)

ParsePutClusterResponse parses an HTTP response from a PutClusterWithResponse call

func (PutClusterResponse) Status added in v0.8.0

func (r PutClusterResponse) Status() string

Status returns HTTPResponse.Status

func (PutClusterResponse) StatusCode added in v0.8.0

func (r PutClusterResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PutTenantJSONBody added in v0.8.0

type PutTenantJSONBody Tenant

PutTenantJSONBody defines parameters for PutTenant.

type PutTenantJSONRequestBody added in v0.8.0

type PutTenantJSONRequestBody PutTenantJSONBody

PutTenantJSONRequestBody defines body for PutTenant for application/json ContentType.

type PutTenantResponse added in v0.8.0

type PutTenantResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Tenant
	JSON201      *Tenant
	JSON403      *Reason
	JSONDefault  *Reason
}

func ParsePutTenantResponse added in v0.8.0

func ParsePutTenantResponse(rsp *http.Response) (*PutTenantResponse, error)

ParsePutTenantResponse parses an HTTP response from a PutTenantWithResponse call

func (PutTenantResponse) Status added in v0.8.0

func (r PutTenantResponse) Status() string

Status returns HTTPResponse.Status

func (PutTenantResponse) StatusCode added in v0.8.0

func (r PutTenantResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type QueryInventoryParams

type QueryInventoryParams struct {

	// InfluxQL query string
	Q *string `json:"q,omitempty"`
}

QueryInventoryParams defines parameters for QueryInventory.

type QueryInventoryResponse added in v0.1.2

type QueryInventoryResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Inventory
	JSONDefault  *Reason
}

func ParseQueryInventoryResponse

func ParseQueryInventoryResponse(rsp *http.Response) (*QueryInventoryResponse, error)

ParseQueryInventoryResponse parses an HTTP response from a QueryInventoryWithResponse call

func (QueryInventoryResponse) Status added in v0.1.2

func (r QueryInventoryResponse) Status() string

Status returns HTTPResponse.Status

func (QueryInventoryResponse) StatusCode added in v0.1.2

func (r QueryInventoryResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Reason

type Reason struct {

	// The reason message
	Reason string `json:"reason"`
}

A reason for responses

type RequestEditorFn

type RequestEditorFn func(ctx context.Context, req *http.Request) error

RequestEditorFn is the function signature for the RequestEditor callback function

type Revision added in v0.4.0

type Revision struct {

	// Revision to use with a git repository.
	Revision *string `json:"revision,omitempty"`
}

Revision defines model for Revision.

type RevisionedGitRepo added in v0.4.0

type RevisionedGitRepo struct {
	// Embedded struct due to allOf(#/components/schemas/GitRepo)
	GitRepo `yaml:",inline"`
	// Embedded struct due to allOf(#/components/schemas/Revision)
	Revision `yaml:",inline"`
}

RevisionedGitRepo defines model for RevisionedGitRepo.

type ServerInterface

type ServerInterface interface {
	// Returns a list of clusters
	// (GET /clusters)
	ListClusters(ctx echo.Context, params ListClustersParams) error
	// Creates a new cluster
	// (POST /clusters)
	CreateCluster(ctx echo.Context) error
	// Deletes a cluster
	// (DELETE /clusters/{clusterId})
	DeleteCluster(ctx echo.Context, clusterId ClusterIdParameter) error
	// Returns all values of a cluster
	// (GET /clusters/{clusterId})
	GetCluster(ctx echo.Context, clusterId ClusterIdParameter) error
	// Updates a cluster
	// (PATCH /clusters/{clusterId})
	UpdateCluster(ctx echo.Context, clusterId ClusterIdParameter) error
	// Updates or creates a cluster
	// (PUT /clusters/{clusterId})
	PutCluster(ctx echo.Context, clusterId ClusterIdParameter) error
	// API documentation
	// (GET /docs)
	Docs(ctx echo.Context) error
	// API health check
	// (GET /healthz)
	Healthz(ctx echo.Context) error
	// Returns the Steward JSON installation manifest
	// (GET /install/steward.json)
	InstallSteward(ctx echo.Context, params InstallStewardParams) error
	// Returns inventory data according to query
	// (GET /inventory)
	QueryInventory(ctx echo.Context, params QueryInventoryParams) error
	// Write inventory data
	// (POST /inventory)
	UpdateInventory(ctx echo.Context) error
	// OpenAPI JSON spec
	// (GET /openapi.json)
	Openapi(ctx echo.Context) error
	// Returns a list of tenants
	// (GET /tenants)
	ListTenants(ctx echo.Context) error
	// Creates a new tenant
	// (POST /tenants)
	CreateTenant(ctx echo.Context) error
	// Deletes a tenant
	// (DELETE /tenants/{tenantId})
	DeleteTenant(ctx echo.Context, tenantId TenantIdParameter) error
	// Returns all values of a tenant
	// (GET /tenants/{tenantId})
	GetTenant(ctx echo.Context, tenantId TenantIdParameter) error
	// Updates a tenant
	// (PATCH /tenants/{tenantId})
	UpdateTenant(ctx echo.Context, tenantId TenantIdParameter) error
	// Updates or creates a tenant
	// (PUT /tenants/{tenantId})
	PutTenant(ctx echo.Context, tenantId TenantIdParameter) error
}

ServerInterface represents all server handlers.

type ServerInterfaceWrapper

type ServerInterfaceWrapper struct {
	Handler ServerInterface
}

ServerInterfaceWrapper converts echo contexts to parameters.

func (*ServerInterfaceWrapper) CreateCluster

func (w *ServerInterfaceWrapper) CreateCluster(ctx echo.Context) error

CreateCluster converts echo context to params.

func (*ServerInterfaceWrapper) CreateTenant

func (w *ServerInterfaceWrapper) CreateTenant(ctx echo.Context) error

CreateTenant converts echo context to params.

func (*ServerInterfaceWrapper) DeleteCluster

func (w *ServerInterfaceWrapper) DeleteCluster(ctx echo.Context) error

DeleteCluster converts echo context to params.

func (*ServerInterfaceWrapper) DeleteTenant

func (w *ServerInterfaceWrapper) DeleteTenant(ctx echo.Context) error

DeleteTenant converts echo context to params.

func (*ServerInterfaceWrapper) Docs added in v0.1.2

func (w *ServerInterfaceWrapper) Docs(ctx echo.Context) error

Docs converts echo context to params.

func (*ServerInterfaceWrapper) GetCluster

func (w *ServerInterfaceWrapper) GetCluster(ctx echo.Context) error

GetCluster converts echo context to params.

func (*ServerInterfaceWrapper) GetTenant

func (w *ServerInterfaceWrapper) GetTenant(ctx echo.Context) error

GetTenant converts echo context to params.

func (*ServerInterfaceWrapper) Healthz

func (w *ServerInterfaceWrapper) Healthz(ctx echo.Context) error

Healthz converts echo context to params.

func (*ServerInterfaceWrapper) InstallSteward

func (w *ServerInterfaceWrapper) InstallSteward(ctx echo.Context) error

InstallSteward converts echo context to params.

func (*ServerInterfaceWrapper) ListClusters

func (w *ServerInterfaceWrapper) ListClusters(ctx echo.Context) error

ListClusters converts echo context to params.

func (*ServerInterfaceWrapper) ListTenants

func (w *ServerInterfaceWrapper) ListTenants(ctx echo.Context) error

ListTenants converts echo context to params.

func (*ServerInterfaceWrapper) Openapi added in v0.1.2

func (w *ServerInterfaceWrapper) Openapi(ctx echo.Context) error

Openapi converts echo context to params.

func (*ServerInterfaceWrapper) PutCluster added in v0.8.0

func (w *ServerInterfaceWrapper) PutCluster(ctx echo.Context) error

PutCluster converts echo context to params.

func (*ServerInterfaceWrapper) PutTenant added in v0.8.0

func (w *ServerInterfaceWrapper) PutTenant(ctx echo.Context) error

PutTenant converts echo context to params.

func (*ServerInterfaceWrapper) QueryInventory

func (w *ServerInterfaceWrapper) QueryInventory(ctx echo.Context) error

QueryInventory converts echo context to params.

func (*ServerInterfaceWrapper) UpdateCluster

func (w *ServerInterfaceWrapper) UpdateCluster(ctx echo.Context) error

UpdateCluster converts echo context to params.

func (*ServerInterfaceWrapper) UpdateInventory

func (w *ServerInterfaceWrapper) UpdateInventory(ctx echo.Context) error

UpdateInventory converts echo context to params.

func (*ServerInterfaceWrapper) UpdateTenant

func (w *ServerInterfaceWrapper) UpdateTenant(ctx echo.Context) error

UpdateTenant converts echo context to params.

type Tenant

type Tenant struct {
	// Embedded struct due to allOf(#/components/schemas/TenantId)
	TenantId `yaml:",inline"`
	// Embedded struct due to allOf(#/components/schemas/TenantProperties)
	TenantProperties `yaml:",inline"`
}

Tenant defines model for Tenant.

func NewAPITenantFromCRD

func NewAPITenantFromCRD(tenant synv1alpha1.Tenant) *Tenant

NewAPITenantFromCRD transforms a CRD tenant into the API representation

type TenantId

type TenantId struct {

	// A unique object identifier string. Automatically generated by the API on creation (in the form "<letter>-<adjective>-<noun>-<digits>" where all letters are lowercase, max 63 characters in total).
	Id Id `json:"id"`
}

TenantId defines model for TenantId.

func GenerateTenantID

func GenerateTenantID() (TenantId, error)

GenerateTenantID creates a new tenant id

type TenantIdParameter

type TenantIdParameter Id

A unique object identifier string. Automatically generated by the API on creation (in the form "<letter>-<adjective>-<noun>-<digits>" where all letters are lowercase, max 63 characters in total).

type TenantProperties

type TenantProperties struct {

	// Unstructured key value map containing arbitrary metadata
	Annotations *Annotations `json:"annotations,omitempty"`

	// Display name of the tenant
	DisplayName *string            `json:"displayName,omitempty"`
	GitRepo     *RevisionedGitRepo `json:"gitRepo,omitempty"`

	// Git revision to use with the global configruation git repository.
	GlobalGitRepoRevision *string `json:"globalGitRepoRevision,omitempty"`

	// Full URL of the global configuration git repo
	GlobalGitRepoURL *string `json:"globalGitRepoURL,omitempty"`
}

A tenant definition object. The Git repository is usually managed by the API and autogenerated. All properties except name are optional on creation.

type UpdateClusterResponse added in v0.1.2

type UpdateClusterResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Cluster
	JSON403      *Reason
	JSONDefault  *Reason
}

func ParseUpdateClusterResponse

func ParseUpdateClusterResponse(rsp *http.Response) (*UpdateClusterResponse, error)

ParseUpdateClusterResponse parses an HTTP response from a UpdateClusterWithResponse call

func (UpdateClusterResponse) Status added in v0.1.2

func (r UpdateClusterResponse) Status() string

Status returns HTTPResponse.Status

func (UpdateClusterResponse) StatusCode added in v0.1.2

func (r UpdateClusterResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type UpdateInventoryJSONBody

type UpdateInventoryJSONBody Inventory

UpdateInventoryJSONBody defines parameters for UpdateInventory.

type UpdateInventoryJSONRequestBody

type UpdateInventoryJSONRequestBody UpdateInventoryJSONBody

UpdateInventoryJSONRequestBody defines body for UpdateInventory for application/json ContentType.

type UpdateInventoryResponse added in v0.1.2

type UpdateInventoryResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *Reason
}

func ParseUpdateInventoryResponse

func ParseUpdateInventoryResponse(rsp *http.Response) (*UpdateInventoryResponse, error)

ParseUpdateInventoryResponse parses an HTTP response from a UpdateInventoryWithResponse call

func (UpdateInventoryResponse) Status added in v0.1.2

func (r UpdateInventoryResponse) Status() string

Status returns HTTPResponse.Status

func (UpdateInventoryResponse) StatusCode added in v0.1.2

func (r UpdateInventoryResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type UpdateTenantResponse added in v0.1.2

type UpdateTenantResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Tenant
	JSON403      *Reason
	JSONDefault  *Reason
}

func ParseUpdateTenantResponse

func ParseUpdateTenantResponse(rsp *http.Response) (*UpdateTenantResponse, error)

ParseUpdateTenantResponse parses an HTTP response from a UpdateTenantWithResponse call

func (UpdateTenantResponse) Status added in v0.1.2

func (r UpdateTenantResponse) Status() string

Status returns HTTPResponse.Status

func (UpdateTenantResponse) StatusCode added in v0.1.2

func (r UpdateTenantResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

Jump to

Keyboard shortcuts

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