Documentation ¶
Index ¶
- type CreateOpts
- type CreateOptsBuilder
- type CreateResult
- type CreateTemporaryOpts
- type CreateTemporaryOptsBuilder
- type CreateTemporaryResult
- type Credential
- type DeleteResult
- type GetResult
- type ListOpts
- type ListOptsBuilder
- type ListResult
- type Status
- type TemporaryCredential
- type UpdateOpts
- type UpdateOptsBuilder
- type UpdateResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateOpts ¶
func (CreateOpts) ToCredentialCreateMap ¶
func (opts CreateOpts) ToCredentialCreateMap() (map[string]interface{}, error)
type CreateOptsBuilder ¶
type CreateResult ¶
type CreateResult struct {
// contains filtered or unexported fields
}
CreateResult is the response of a Get operations. Call its Extract method to interpret it as a Credential.
func Create ¶
func Create(client *golangsdk.ServiceClient, opts CreateOptsBuilder) (r CreateResult)
func Update ¶
func Update(client *golangsdk.ServiceClient, credentialID string, opts UpdateOptsBuilder) (r CreateResult)
func (CreateResult) Extract ¶
func (r CreateResult) Extract() (*Credential, error)
Extract provides access to the individual Flavor returned by the Get and Create functions.
type CreateTemporaryOpts ¶ added in v0.2.0
type CreateTemporaryOpts struct { // For obtaining a temporary AK/SK with an agency token for use "assume_role" // For user with federated token fill "token" in this field Methods []string `json:"methods"` // Common token or federated token required for obtaining a temporary AK/SK. // You need to choose either the ID in this object or X-Auth-Token in the request header. // X-Auth-Token takes priority over the ID in this object. Token string `json:"token,omitempty"` // Validity period (in seconds) of an AK/SK and security token. // The value ranges from 15 minutes to 24 hours. // The default value is 15 minutes. Duration int `json:"duration_seconds,omitempty"` // Name or ID of the domain to which the delegating party belongs DomainName string `json:"domain_name,omitempty"` DomainID string `json:"domain_id,omitempty"` // Name of the agency created by a delegating party AgencyName string `json:"agency_name,omitempty"` }
func (CreateTemporaryOpts) ToTempCredentialCreateMap ¶ added in v0.2.0
func (opts CreateTemporaryOpts) ToTempCredentialCreateMap() (map[string]interface{}, error)
ToTempCredentialCreateMap
type CreateTemporaryOptsBuilder ¶ added in v0.2.0
type CreateTemporaryResult ¶ added in v0.2.0
type CreateTemporaryResult struct {
golangsdk.Result
}
func CreateTemporary ¶ added in v0.2.0
func CreateTemporary(client *golangsdk.ServiceClient, opts CreateTemporaryOptsBuilder) (r CreateTemporaryResult)
func (CreateTemporaryResult) Extract ¶ added in v0.2.0
func (r CreateTemporaryResult) Extract() (*TemporaryCredential, error)
type Credential ¶
type Credential struct { // IAM user ID UserID string `json:"user_id"` // Description of the access key Description string `json:"description"` // Time when the access key was created CreateTime string `json:"create_time"` // Time when the access key was last used LastUseTime string `json:"last_use_time,omitempty"` // AK AccessKey string `json:"access"` // SK, returned only during creation SecretKey string `json:"secret,omitempty"` // Status of the access key, active/inactive Status Status `json:"status"` }
type DeleteResult ¶
type DeleteResult struct {
golangsdk.ErrResult
}
DeleteResult is the response from a Delete operation. Call its ExtractErr to determine if the request succeeded or failed.
func Delete ¶
func Delete(client *golangsdk.ServiceClient, credentialID string) (r DeleteResult)
type GetResult ¶
type GetResult struct {
// contains filtered or unexported fields
}
GetResult is the response of a Get operations. Call its Extract method to interpret it as a Credential.
func (GetResult) Extract ¶
func (r GetResult) Extract() (*Credential, error)
Extract provides access to the individual Flavor returned by the Get and Create functions.
type ListOpts ¶
type ListOpts struct {
UserID string `json:"user_id,omitempty"`
}
func (ListOpts) ToCredentialListQuery ¶
type ListOptsBuilder ¶
type ListResult ¶
type ListResult struct {
golangsdk.Result
}
func List ¶
func List(client *golangsdk.ServiceClient, opts ListOptsBuilder) (l ListResult)
func (ListResult) Extract ¶
func (lr ListResult) Extract() ([]Credential, error)
type TemporaryCredential ¶ added in v0.2.0
type UpdateOpts ¶
type UpdateOpts struct { Status string `json:"status,omitempty"` Description string `json:"description,omitempty"` }
func (UpdateOpts) ToCredentialUpdateMap ¶
func (opts UpdateOpts) ToCredentialUpdateMap() (map[string]interface{}, error)
type UpdateOptsBuilder ¶
type UpdateResult ¶
type UpdateResult struct {
// contains filtered or unexported fields
}
UpdateResult is the response from an Update operation. Call its Extract method to interpret it as a Role.
func (UpdateResult) Extract ¶
func (r UpdateResult) Extract() (*Credential, error)
Extract provides access to the individual Flavor returned by the Get and Create functions.