package
2.6.1+incompatible
Repository: https://github.com/storageos/go-api.git
Documentation: pkg.go.dev

# README

Go API client for api

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)

Overview

This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.

  • API version: 2.5.0
  • Package version: 2.4.0
  • Build package: org.openapitools.codegen.languages.GoClientCodegen For more information, please visit https://storageos.com

Installation

Install the following dependencies:

go get github.com/stretchr/testify/assert
go get golang.org/x/oauth2
go get golang.org/x/net/context
go get github.com/antihax/optional

Put the package under your project folder and add the following in import:

import "./api"

Documentation for API Endpoints

All URIs are relative to http://localhost/v2

ClassMethodHTTP requestDescription
DefaultApiAttachNFSVolumePost /namespaces/{namespaceID}/volumes/{id}/nfs/attachattach and share the volume using NFS
DefaultApiAttachVolumePost /namespaces/{namespaceID}/volumes/{id}/attachAttach a volume to the given node
DefaultApiAuthenticateUserPost /auth/loginAuthenticate a user
DefaultApiCreateNamespacePost /namespacesCreate a new namespace
DefaultApiCreatePolicyGroupPost /policiesCreate a new policy group
DefaultApiCreateUserPost /usersCreate a new user
DefaultApiCreateVolumePost /namespaces/{namespaceID}/volumesCreate a new Volume in the specified namespace
DefaultApiDeleteAuthenticatedUserDelete /users/selfDelete the authenticated user
DefaultApiDeleteAuthenticatedUserSessionsDelete /users/self/sessionsInvalidate the logged in user's sessions
DefaultApiDeleteNamespaceDelete /namespaces/{id}Delete a namespace
DefaultApiDeleteNodeDelete /nodes/{id}Delete a node
DefaultApiDeletePolicyGroupDelete /policies/{id}Delete a policy group
DefaultApiDeleteSessionsDelete /users/{id}/sessionsInvalidate login sessions
DefaultApiDeleteUserDelete /users/{id}Delete a user
DefaultApiDeleteVolumeDelete /namespaces/{namespaceID}/volumes/{id}Delete a volume
DefaultApiDetachVolumeDelete /namespaces/{namespaceID}/volumes/{id}/attachDetach the given volume
DefaultApiGetAuthenticatedUserGet /users/selfGet the currently authenticated user's information
DefaultApiGetClusterGet /clusterRetrieves the cluster's global configuration settings
DefaultApiGetDiagnosticsGet /diagnosticsRetrieves a diagnostics bundle from the target node
DefaultApiGetLicenceGet /cluster/licenceRetrieves the cluster's licence information
DefaultApiGetNamespaceGet /namespaces/{id}Fetch a namespace
DefaultApiGetNodeGet /nodes/{id}Fetch a node
DefaultApiGetPolicyGroupGet /policies/{id}Fetch a policy group
DefaultApiGetSingleNodeDiagnosticsGet /diagnostics/{id}Retrieves a single node diagnostics bundle from the target node
DefaultApiGetUserGet /users/{id}Fetch a user
DefaultApiGetVolumeGet /namespaces/{namespaceID}/volumes/{id}Fetch a volume
DefaultApiListNamespacesGet /namespacesFetch the list of namespaces
DefaultApiListNodesGet /nodesFetch the list of nodes
DefaultApiListPolicyGroupsGet /policiesFetch the list of policy groups
DefaultApiListUsersGet /usersFetch the list of users
DefaultApiListVolumesGet /namespaces/{namespaceID}/volumesFetch the list of volumes in the given namespace
DefaultApiRefreshJwtPost /auth/refreshRefresh the JWT
DefaultApiResizeVolumePut /namespaces/{namespaceID}/volumes/{id}/sizeIncrease the size of a volume.
DefaultApiSetComputeOnlyPut /nodes/{id}/compute-onlyModify the computeonly behaviour state for a node
DefaultApiSetCordonedPut /nodes/{id}/cordonModify the cordoned state for a node
DefaultApiSetFailureModePut /namespaces/{namespaceID}/volumes/{id}/failure-modeSet the failure mode of the volume.
DefaultApiSetPlacementStrategyPut /namespaces/{namespaceID}/volumes/{id}/placement-strategySets the placement strategy of the volume.
DefaultApiSetReplicasPut /namespaces/{namespaceID}/volumes/{id}/replicasSet the number of replicas to maintain for the volume.
DefaultApiSpecGet /openapiServes this openapi spec file
DefaultApiUpdateAuthenticatedUserPut /users/selfUpdate the authenticated user's information
DefaultApiUpdateClusterPut /clusterUpdate the cluster's global configuration settings
DefaultApiUpdateLicencePut /cluster/licenceUpdate the licence global configuration settings
DefaultApiUpdateNFSVolumeExportsPut /namespaces/{namespaceID}/volumes/{id}/nfs/export-configUpdate an nfs volume's export configuration
DefaultApiUpdateNFSVolumeMountEndpointPut /namespaces/{namespaceID}/volumes/{id}/nfs/mount-endpointUpdate an nfs volume's mount endpoint
DefaultApiUpdateNamespacePut /namespaces/{id}Update a namespace
DefaultApiUpdateNodePut /nodes/{id}Update a node
DefaultApiUpdatePolicyGroupPut /policies/{id}Update a policy group
DefaultApiUpdateUserPut /users/{id}Update a user
DefaultApiUpdateVolumePut /namespaces/{namespaceID}/volumes/{id}Update a volume

Documentation For Models

Documentation For Authorization

jwt

  • Type: HTTP basic authentication

Example

auth := context.WithValue(context.Background(), sw.ContextBasicAuth, sw.BasicAuth{
    UserName: "username",
    Password: "password",
})
r, err := client.Service.Operation(auth, args)

Author

[email protected]

# Functions

CacheExpires helper function to determine remaining time before repeating a request.
NewAPIClient creates a new API client.
NewAPIResponse returns a new APIResonse object.
NewAPIResponseWithError returns a new APIResponse object with the provided error message.
NewConfiguration returns a new Configuration object.

# Constants

List of AttachType.
List of AttachType.
List of AttachType.
List of AttachType.
List of FailureModeIntent.
List of FailureModeIntent.
List of FailureModeIntent.
List of FsType.
List of FsType.
List of FsType.
List of FsType.
List of FsType.
List of FsType.
List of LogFormat.
List of LogFormat.
List of LogLevel.
List of LogLevel.
List of LogLevel.
List of LogLevel.
List of MasterHealth.
List of MasterHealth.
List of MasterHealth.
List of NodeHealth.
List of NodeHealth.
List of NodeHealth.
List of ReplicaHealth.
List of ReplicaHealth.
List of ReplicaHealth.
List of ReplicaHealth.
List of ReplicaHealth.
List of ReplicaHealth.
List of ReplicaHealth.
List of ReplicaHealth.

# Variables

ContextAccessToken takes a string oauth2 access token as authentication for the request.
ContextAPIKey takes an APIKey as authentication for the request.
ContextBasicAuth takes BasicAuth as authentication for the request.
ContextOAuth2 takes an oauth2.TokenSource as authentication for the request.

# Structs

AcceptedMessage struct for AcceptedMessage.
APIClient manages communication with the StorageOS API API v2.5.0 In most cases there should be only one, shared, APIClient.
APIKey provides API key based authentication to a request passed via context using ContextAPIKey.
APIResponse stores the API response returned by the server.
AttachNfsVolumeData struct for AttachNfsVolumeData.
AttachNFSVolumeOpts Optional parameters for the method 'AttachNFSVolume'.
AttachVolumeData struct for AttachVolumeData.
AuthUserData struct for AuthUserData.
BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth.
CapacityStats struct for CapacityStats.
Cluster struct for Cluster.
Configuration stores the configuration of the API client.
CreateNamespaceData struct for CreateNamespaceData.
CreatePolicyGroupData struct for CreatePolicyGroupData.
CreateUserData struct for CreateUserData.
CreateVolumeData struct for CreateVolumeData.
CreateVolumeOpts Optional parameters for the method 'CreateVolume'.
DeleteAuthenticatedUserOpts Optional parameters for the method 'DeleteAuthenticatedUser'.
DeleteNamespaceOpts Optional parameters for the method 'DeleteNamespace'.
DeleteNodeOpts Optional parameters for the method 'DeleteNode'.
DeletePolicyGroupOpts Optional parameters for the method 'DeletePolicyGroup'.
DeleteUserOpts Optional parameters for the method 'DeleteUser'.
DeleteVolumeOpts Optional parameters for the method 'DeleteVolume'.
DeploymentInfo struct for DeploymentInfo.
DetachVolumeOpts Optional parameters for the method 'DetachVolume'.
Error struct for Error.
GenericOpenAPIError Provides access to the body, error and model on returned errors.
Licence A representation of a cluster's licence properties .
MasterDeploymentInfo struct for MasterDeploymentInfo.
MasterDeploymentInfoAllOf struct for MasterDeploymentInfoAllOf.
Namespace struct for Namespace.
NfsAcl struct for NfsAcl.
NfsAclIdentity struct for NfsAclIdentity.
NfsAclSquashConfig struct for NfsAclSquashConfig.
NfsConfig struct for NfsConfig.
NfsExportConfig struct for NfsExportConfig.
NfsVolumeExports struct for NfsVolumeExports.
NfsVolumeMountEndpoint struct for NfsVolumeMountEndpoint.
Node struct for Node.
PoliciesIdSpecs struct for PoliciesIdSpecs.
PoliciesSpecs struct for PoliciesSpecs.
PolicyGroup struct for PolicyGroup.
PolicyGroupUsers struct for PolicyGroupUsers.
ReplicaDeploymentInfo struct for ReplicaDeploymentInfo.
ReplicaDeploymentInfoAllOf struct for ReplicaDeploymentInfoAllOf.
ResizeVolumeOpts Optional parameters for the method 'ResizeVolume'.
ResizeVolumeRequest struct for ResizeVolumeRequest.
ServerConfiguration stores the information about a server.
ServerVariable stores the information about a server variable.
SetComputeOnlyNodeData struct for SetComputeOnlyNodeData.
SetComputeOnlyOpts Optional parameters for the method 'SetComputeOnly'.
SetCordonedNodeData struct for SetCordonedNodeData.
SetCordonedOpts Optional parameters for the method 'SetCordoned'.
SetFailureModeIntentRequestData struct for SetFailureModeIntentRequestData.
SetFailureModeOpts Optional parameters for the method 'SetFailureMode'.
SetFailureModeRequest struct for SetFailureModeRequest.
SetFailureThresholdRequestData struct for SetFailureThresholdRequestData.
SetPlacementStrategyData struct for SetPlacementStrategyData.
SetPlacementStrategyOpts Optional parameters for the method 'SetPlacementStrategy'.
SetReplicasOpts Optional parameters for the method 'SetReplicas'.
SetReplicasRequest struct for SetReplicasRequest.
Strategy The logic to use when placing the volume replicas across the available nodes.
StrategyOptions Used together with topology-aware strategy to further specify how the placement should be done.
SyncProgress The progress report for an ongoing sync.
UpdateAuthenticatedUserData struct for UpdateAuthenticatedUserData.
UpdateAuthenticatedUserOpts Optional parameters for the method 'UpdateAuthenticatedUser'.
UpdateClusterData struct for UpdateClusterData.
UpdateClusterOpts Optional parameters for the method 'UpdateCluster'.
UpdateLicence struct for UpdateLicence.
UpdateLicenceOpts Optional parameters for the method 'UpdateLicence'.
UpdateNamespaceData struct for UpdateNamespaceData.
UpdateNamespaceOpts Optional parameters for the method 'UpdateNamespace'.
UpdateNFSVolumeExportsOpts Optional parameters for the method 'UpdateNFSVolumeExports'.
UpdateNFSVolumeMountEndpointOpts Optional parameters for the method 'UpdateNFSVolumeMountEndpoint'.
UpdateNodeData struct for UpdateNodeData.
UpdatePolicyGroupData struct for UpdatePolicyGroupData.
UpdatePolicyGroupOpts Optional parameters for the method 'UpdatePolicyGroup'.
UpdateUserData struct for UpdateUserData.
UpdateUserOpts Optional parameters for the method 'UpdateUser'.
UpdateVolumeData struct for UpdateVolumeData.
UpdateVolumeOpts Optional parameters for the method 'UpdateVolume'.
User struct for User.
UserSession struct for UserSession.
UserSessionAllOf struct for UserSessionAllOf.
UserSessionAllOfSession struct for UserSessionAllOfSession.
Volume struct for Volume.

# Type aliases

AttachType The attachment type of a volume.
DefaultApiService DefaultApi service.
FailureModeIntent The intent-based failure mode behaviour of a volume.
FsType The file system type of a volume.
LogFormat This setting determines the format nodes in the cluster will use for log entries.
LogLevel This setting determines the log level for nodes across the cluster to use when recording entries in the log.
MasterHealth The operational health of a volume master deployment .
NodeHealth The operational health of a node entity .
ReplicaHealth The operational health of a volume replica deployment .