Documentation ¶
Overview ¶
Package ibmcloudshellv1 : Operations and models for the IBMCloudShellV1 service
Index ¶
- Constants
- func GetServiceURLForRegion(region string) (string, error)
- func UnmarshalAccountSettings(m map[string]json.RawMessage, result interface{}) (err error)
- func UnmarshalFeature(m map[string]json.RawMessage, result interface{}) (err error)
- func UnmarshalRegionSetting(m map[string]json.RawMessage, result interface{}) (err error)
- type AccountSettings
- type Feature
- type GetAccountSettingsOptions
- type IBMCloudShellV1
- func (ibmCloudShell *IBMCloudShellV1) Clone() *IBMCloudShellV1
- func (ibmCloudShell *IBMCloudShellV1) DisableRetries()
- func (ibmCloudShell *IBMCloudShellV1) EnableRetries(maxRetries int, maxRetryInterval time.Duration)
- func (ibmCloudShell *IBMCloudShellV1) GetAccountSettings(getAccountSettingsOptions *GetAccountSettingsOptions) (result *AccountSettings, response *core.DetailedResponse, err error)
- func (ibmCloudShell *IBMCloudShellV1) GetAccountSettingsWithContext(ctx context.Context, getAccountSettingsOptions *GetAccountSettingsOptions) (result *AccountSettings, response *core.DetailedResponse, err error)
- func (ibmCloudShell *IBMCloudShellV1) GetEnableGzipCompression() bool
- func (ibmCloudShell *IBMCloudShellV1) GetServiceURL() string
- func (*IBMCloudShellV1) NewGetAccountSettingsOptions(accountID string) *GetAccountSettingsOptions
- func (*IBMCloudShellV1) NewUpdateAccountSettingsOptions(accountID string) *UpdateAccountSettingsOptions
- func (ibmCloudShell *IBMCloudShellV1) SetDefaultHeaders(headers http.Header)
- func (ibmCloudShell *IBMCloudShellV1) SetEnableGzipCompression(enableGzip bool)
- func (ibmCloudShell *IBMCloudShellV1) SetServiceURL(url string) error
- func (ibmCloudShell *IBMCloudShellV1) UpdateAccountSettings(updateAccountSettingsOptions *UpdateAccountSettingsOptions) (result *AccountSettings, response *core.DetailedResponse, err error)
- func (ibmCloudShell *IBMCloudShellV1) UpdateAccountSettingsWithContext(ctx context.Context, ...) (result *AccountSettings, response *core.DetailedResponse, err error)
- type IBMCloudShellV1Options
- type RegionSetting
- type UpdateAccountSettingsOptions
- func (_options *UpdateAccountSettingsOptions) SetAccountID(accountID string) *UpdateAccountSettingsOptions
- func (_options *UpdateAccountSettingsOptions) SetDefaultEnableNewFeatures(defaultEnableNewFeatures bool) *UpdateAccountSettingsOptions
- func (_options *UpdateAccountSettingsOptions) SetDefaultEnableNewRegions(defaultEnableNewRegions bool) *UpdateAccountSettingsOptions
- func (_options *UpdateAccountSettingsOptions) SetEnabled(enabled bool) *UpdateAccountSettingsOptions
- func (_options *UpdateAccountSettingsOptions) SetFeatures(features []Feature) *UpdateAccountSettingsOptions
- func (options *UpdateAccountSettingsOptions) SetHeaders(param map[string]string) *UpdateAccountSettingsOptions
- func (_options *UpdateAccountSettingsOptions) SetRegions(regions []RegionSetting) *UpdateAccountSettingsOptions
- func (_options *UpdateAccountSettingsOptions) SetRev(rev string) *UpdateAccountSettingsOptions
Constants ¶
const DefaultServiceName = "ibm_cloud_shell"
DefaultServiceName is the default key used to find external configuration information.
const DefaultServiceURL = "https://api.shell.cloud.ibm.com"
DefaultServiceURL is the default URL to make service requests to.
Variables ¶
This section is empty.
Functions ¶
func GetServiceURLForRegion ¶
GetServiceURLForRegion returns the service URL to be used for the specified region
func UnmarshalAccountSettings ¶
func UnmarshalAccountSettings(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalAccountSettings unmarshals an instance of AccountSettings from the specified map of raw messages.
func UnmarshalFeature ¶
func UnmarshalFeature(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalFeature unmarshals an instance of Feature from the specified map of raw messages.
func UnmarshalRegionSetting ¶
func UnmarshalRegionSetting(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalRegionSetting unmarshals an instance of RegionSetting from the specified map of raw messages.
Types ¶
type AccountSettings ¶
type AccountSettings struct { // Unique id of the settings object. ID *string `json:"_id,omitempty"` // Unique revision number for the settings object. Rev *string `json:"_rev,omitempty"` // The id of the account the settings belong to. AccountID *string `json:"account_id,omitempty"` // Creation timestamp in Unix epoch time. CreatedAt *int64 `json:"created_at,omitempty"` // IAM ID of creator. CreatedBy *string `json:"created_by,omitempty"` // You can choose which Cloud Shell features are available in the account and whether any new features are enabled as // they become available. The feature settings apply only to the enabled Cloud Shell locations. DefaultEnableNewFeatures *bool `json:"default_enable_new_features,omitempty"` // Set whether Cloud Shell is enabled in a specific location for the account. The location determines where user and // session data are stored. By default, users are routed to the nearest available location. DefaultEnableNewRegions *bool `json:"default_enable_new_regions,omitempty"` // When enabled, Cloud Shell is available to all users in the account. Enabled *bool `json:"enabled,omitempty"` // List of Cloud Shell features. Features []Feature `json:"features,omitempty"` // List of Cloud Shell region settings. Regions []RegionSetting `json:"regions,omitempty"` // Type of api response object. Type *string `json:"type,omitempty"` // Timestamp of last update in Unix epoch time. UpdatedAt *int64 `json:"updated_at,omitempty"` // IAM ID of last updater. UpdatedBy *string `json:"updated_by,omitempty"` }
AccountSettings : Definition of Cloud Shell account settings.
type Feature ¶
type Feature struct { // State of the feature. Enabled *bool `json:"enabled,omitempty"` // Name of the feature. Key *string `json:"key,omitempty"` }
Feature : Describes a Cloud Shell feature.
type GetAccountSettingsOptions ¶
type GetAccountSettingsOptions struct { // The account ID in which the account settings belong to. AccountID *string `json:"account_id" validate:"required,ne="` // Allows users to set headers on API requests. Headers map[string]string }
GetAccountSettingsOptions : The GetAccountSettings options.
func (*GetAccountSettingsOptions) SetAccountID ¶
func (_options *GetAccountSettingsOptions) SetAccountID(accountID string) *GetAccountSettingsOptions
SetAccountID : Allow user to set AccountID
func (*GetAccountSettingsOptions) SetHeaders ¶
func (options *GetAccountSettingsOptions) SetHeaders(param map[string]string) *GetAccountSettingsOptions
SetHeaders : Allow user to set Headers
type IBMCloudShellV1 ¶
type IBMCloudShellV1 struct {
Service *core.BaseService
}
IBMCloudShellV1 : API docs for IBM Cloud Shell repository
API Version: 1.0
func NewIBMCloudShellV1 ¶
func NewIBMCloudShellV1(options *IBMCloudShellV1Options) (service *IBMCloudShellV1, err error)
NewIBMCloudShellV1 : constructs an instance of IBMCloudShellV1 with passed in options.
func NewIBMCloudShellV1UsingExternalConfig ¶
func NewIBMCloudShellV1UsingExternalConfig(options *IBMCloudShellV1Options) (ibmCloudShell *IBMCloudShellV1, err error)
NewIBMCloudShellV1UsingExternalConfig : constructs an instance of IBMCloudShellV1 with passed in options and external configuration.
func (*IBMCloudShellV1) Clone ¶
func (ibmCloudShell *IBMCloudShellV1) Clone() *IBMCloudShellV1
Clone makes a copy of "ibmCloudShell" suitable for processing requests.
func (*IBMCloudShellV1) DisableRetries ¶
func (ibmCloudShell *IBMCloudShellV1) DisableRetries()
DisableRetries disables automatic retries for requests invoked for this service instance.
func (*IBMCloudShellV1) EnableRetries ¶
func (ibmCloudShell *IBMCloudShellV1) EnableRetries(maxRetries int, maxRetryInterval time.Duration)
EnableRetries enables automatic retries for requests invoked for this service instance. If either parameter is specified as 0, then a default value is used instead.
func (*IBMCloudShellV1) GetAccountSettings ¶
func (ibmCloudShell *IBMCloudShellV1) GetAccountSettings(getAccountSettingsOptions *GetAccountSettingsOptions) (result *AccountSettings, response *core.DetailedResponse, err error)
GetAccountSettings : Get account settings Retrieve account settings for the given account ID. Call this method to get details about a particular account setting, whether Cloud Shell is enabled, the list of enabled regions and the list of enabled features. Users need to be an account owner or users need to be assigned an IAM policy with the Administrator role for the Cloud Shell account management service.
func (*IBMCloudShellV1) GetAccountSettingsWithContext ¶
func (ibmCloudShell *IBMCloudShellV1) GetAccountSettingsWithContext(ctx context.Context, getAccountSettingsOptions *GetAccountSettingsOptions) (result *AccountSettings, response *core.DetailedResponse, err error)
GetAccountSettingsWithContext is an alternate form of the GetAccountSettings method which supports a Context parameter
func (*IBMCloudShellV1) GetEnableGzipCompression ¶
func (ibmCloudShell *IBMCloudShellV1) GetEnableGzipCompression() bool
GetEnableGzipCompression returns the service's EnableGzipCompression field
func (*IBMCloudShellV1) GetServiceURL ¶
func (ibmCloudShell *IBMCloudShellV1) GetServiceURL() string
GetServiceURL returns the service URL
func (*IBMCloudShellV1) NewGetAccountSettingsOptions ¶
func (*IBMCloudShellV1) NewGetAccountSettingsOptions(accountID string) *GetAccountSettingsOptions
NewGetAccountSettingsOptions : Instantiate GetAccountSettingsOptions
func (*IBMCloudShellV1) NewUpdateAccountSettingsOptions ¶
func (*IBMCloudShellV1) NewUpdateAccountSettingsOptions(accountID string) *UpdateAccountSettingsOptions
NewUpdateAccountSettingsOptions : Instantiate UpdateAccountSettingsOptions
func (*IBMCloudShellV1) SetDefaultHeaders ¶
func (ibmCloudShell *IBMCloudShellV1) SetDefaultHeaders(headers http.Header)
SetDefaultHeaders sets HTTP headers to be sent in every request
func (*IBMCloudShellV1) SetEnableGzipCompression ¶
func (ibmCloudShell *IBMCloudShellV1) SetEnableGzipCompression(enableGzip bool)
SetEnableGzipCompression sets the service's EnableGzipCompression field
func (*IBMCloudShellV1) SetServiceURL ¶
func (ibmCloudShell *IBMCloudShellV1) SetServiceURL(url string) error
SetServiceURL sets the service URL
func (*IBMCloudShellV1) UpdateAccountSettings ¶
func (ibmCloudShell *IBMCloudShellV1) UpdateAccountSettings(updateAccountSettingsOptions *UpdateAccountSettingsOptions) (result *AccountSettings, response *core.DetailedResponse, err error)
UpdateAccountSettings : Update account settings Update account settings for the given account ID. Call this method to update account settings configuration, you can enable or disable Cloud Shell, enable or disable available regions and enable and disable features. To update account settings, users need to be an account owner or users need to be assigned an IAM policy with the Administrator role for the Cloud Shell account management service.
func (*IBMCloudShellV1) UpdateAccountSettingsWithContext ¶
func (ibmCloudShell *IBMCloudShellV1) UpdateAccountSettingsWithContext(ctx context.Context, updateAccountSettingsOptions *UpdateAccountSettingsOptions) (result *AccountSettings, response *core.DetailedResponse, err error)
UpdateAccountSettingsWithContext is an alternate form of the UpdateAccountSettings method which supports a Context parameter
type IBMCloudShellV1Options ¶
type IBMCloudShellV1Options struct { ServiceName string URL string Authenticator core.Authenticator }
IBMCloudShellV1Options : Service options
type RegionSetting ¶
type RegionSetting struct { // State of the region. Enabled *bool `json:"enabled,omitempty"` // Name of the region. Key *string `json:"key,omitempty"` }
RegionSetting : Describes a Cloud Shell region setting.
type UpdateAccountSettingsOptions ¶
type UpdateAccountSettingsOptions struct { // The account ID in which the account settings belong to. AccountID *string `json:"account_id" validate:"required,ne="` // Unique revision number for the settings object. Rev *string `json:"_rev,omitempty"` // You can choose which Cloud Shell features are available in the account and whether any new features are enabled as // they become available. The feature settings apply only to the enabled Cloud Shell locations. DefaultEnableNewFeatures *bool `json:"default_enable_new_features,omitempty"` // Set whether Cloud Shell is enabled in a specific location for the account. The location determines where user and // session data are stored. By default, users are routed to the nearest available location. DefaultEnableNewRegions *bool `json:"default_enable_new_regions,omitempty"` // When enabled, Cloud Shell is available to all users in the account. Enabled *bool `json:"enabled,omitempty"` // List of Cloud Shell features. Features []Feature `json:"features,omitempty"` // List of Cloud Shell region settings. Regions []RegionSetting `json:"regions,omitempty"` // Allows users to set headers on API requests. Headers map[string]string }
UpdateAccountSettingsOptions : The UpdateAccountSettings options.
func (*UpdateAccountSettingsOptions) SetAccountID ¶
func (_options *UpdateAccountSettingsOptions) SetAccountID(accountID string) *UpdateAccountSettingsOptions
SetAccountID : Allow user to set AccountID
func (*UpdateAccountSettingsOptions) SetDefaultEnableNewFeatures ¶
func (_options *UpdateAccountSettingsOptions) SetDefaultEnableNewFeatures(defaultEnableNewFeatures bool) *UpdateAccountSettingsOptions
SetDefaultEnableNewFeatures : Allow user to set DefaultEnableNewFeatures
func (*UpdateAccountSettingsOptions) SetDefaultEnableNewRegions ¶
func (_options *UpdateAccountSettingsOptions) SetDefaultEnableNewRegions(defaultEnableNewRegions bool) *UpdateAccountSettingsOptions
SetDefaultEnableNewRegions : Allow user to set DefaultEnableNewRegions
func (*UpdateAccountSettingsOptions) SetEnabled ¶
func (_options *UpdateAccountSettingsOptions) SetEnabled(enabled bool) *UpdateAccountSettingsOptions
SetEnabled : Allow user to set Enabled
func (*UpdateAccountSettingsOptions) SetFeatures ¶
func (_options *UpdateAccountSettingsOptions) SetFeatures(features []Feature) *UpdateAccountSettingsOptions
SetFeatures : Allow user to set Features
func (*UpdateAccountSettingsOptions) SetHeaders ¶
func (options *UpdateAccountSettingsOptions) SetHeaders(param map[string]string) *UpdateAccountSettingsOptions
SetHeaders : Allow user to set Headers
func (*UpdateAccountSettingsOptions) SetRegions ¶
func (_options *UpdateAccountSettingsOptions) SetRegions(regions []RegionSetting) *UpdateAccountSettingsOptions
SetRegions : Allow user to set Regions
func (*UpdateAccountSettingsOptions) SetRev ¶
func (_options *UpdateAccountSettingsOptions) SetRev(rev string) *UpdateAccountSettingsOptions
SetRev : Allow user to set Rev