httpclient

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CA

type CA struct {
	GUID      string `json:"guid"`
	Issuer    string `json:"issuer"`
	CreatedOn string `json:"created_on"`
	ExpiresOn string `json:"expires_on"`
	Active    bool   `json:"active"`
	CertPEM   string `json:"cert_pem"`
}

type CertificateAuthorities

type CertificateAuthorities struct {
	CAs []CA `json:"certificate_authorities"`
}

type ClientRequest

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

func NewClientRequest

func NewClientRequest(
	endpoint string,
	httpClient *httpclient.DefaultHTTPClient,
) ClientRequest

func (ClientRequest) Get

func (r ClientRequest) Get(path string, response interface{}) error

func (ClientRequest) RawGet

func (r ClientRequest) RawGet(path string) ([]byte, *http.Response, error)

type Credential

type Credential struct {
	Type  string            `json:"type"`
	Value map[string]string `json:"value"`
}

type DeployedProduct

type DeployedProduct struct {
	Type string
	GUID string
}

type DeployedProductCredential

type DeployedProductCredential struct {
	Credential Credential `json:"credential"`
}

type OpsManHTTPClient

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

func NewHTTPClient

func NewHTTPClient(
	endpoint string,
	httpClient *httpclient.DefaultHTTPClient,
) OpsManHTTPClient

func (OpsManHTTPClient) GetBOSHCredentials

func (c OpsManHTTPClient) GetBOSHCredentials() (string, error)

func (OpsManHTTPClient) GetStagedProductProperties

func (c OpsManHTTPClient) GetStagedProductProperties(product string) (map[string]ResponseProperty, error)

func (OpsManHTTPClient) ListCertificateAuthorities

func (c OpsManHTTPClient) ListCertificateAuthorities() ([]CA, error)

func (OpsManHTTPClient) ListDeployedProductCredentials

func (c OpsManHTTPClient) ListDeployedProductCredentials(deployedProductGUID string, credentialRef string) (DeployedProductCredential, error)

func (OpsManHTTPClient) ListDeployedProducts

func (c OpsManHTTPClient) ListDeployedProducts() ([]DeployedProduct, error)

type ResponseProperty

type ResponseProperty struct {
	Value          interface{}
	SelectedOption string `yaml:"selected_option,omitempty"`
	Configurable   bool
	IsCredential   bool   `yaml:"credential"`
	Type           string `yaml:"type"`
}

Jump to

Keyboard shortcuts

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