Documentation
¶
Index ¶
- Constants
- func DecodeError(statusCode int, body []byte) error
- func IsAccessDenied(err error) bool
- func IsNotSupportedEndpoint(err error) bool
- func NewHTTPClient() *http.Client
- func NewTransport() *http.Transport
- func NormalizeRegion(region string) string
- type APIError
- type AccountBalanceData
- type AttachRAMPolicyToRoleResponse
- type AttachRAMPolicyToUserResponse
- type Client
- func (c *Client) AttachRAMPolicyToRole(ctx context.Context, region, roleName, policyName, policyType string) (AttachRAMPolicyToRoleResponse, error)
- func (c *Client) AttachRAMPolicyToUser(ctx context.Context, region, userName, policyName, policyType string) (AttachRAMPolicyToUserResponse, error)
- func (c *Client) CreateRAMLoginProfile(ctx context.Context, region, userName, password string) (CreateRAMLoginProfileResponse, error)
- func (c *Client) CreateRAMRole(ctx context.Context, region, roleName, assumeRolePolicyDocument string) (CreateRAMRoleResponse, error)
- func (c *Client) CreateRAMUser(ctx context.Context, region, userName string) (CreateRAMUserResponse, error)
- func (c *Client) CreateRDSAccount(ctx context.Context, region, instanceID, accountName, password string) (CreateRDSAccountResponse, error)
- func (c *Client) DeleteRAMRole(ctx context.Context, region, roleName string) (DeleteRAMRoleResponse, error)
- func (c *Client) DeleteRAMUser(ctx context.Context, region, userName string) (DeleteRAMUserResponse, error)
- func (c *Client) DeleteRDSAccount(ctx context.Context, region, instanceID, accountName string) (DeleteRDSAccountResponse, error)
- func (c *Client) DescribeDomainRecords(ctx context.Context, region, domainName string, pageNumber, pageSize int) (DescribeDomainRecordsResponse, error)
- func (c *Client) DescribeDomains(ctx context.Context, region string, pageNumber, pageSize int) (DescribeDomainsResponse, error)
- func (c *Client) DescribeECSInstances(ctx context.Context, region string, pageNumber, pageSize int) (DescribeECSInstancesResponse, error)
- func (c *Client) DescribeECSInvocationResults(ctx context.Context, region, commandID string) (DescribeECSInvocationResultsResponse, error)
- func (c *Client) DescribeECSRegions(ctx context.Context, region string) (DescribeECSRegionsResponse, error)
- func (c *Client) DescribeRDSDatabases(ctx context.Context, region, instanceID string) (DescribeRDSDatabasesResponse, error)
- func (c *Client) DescribeRDSInstances(ctx context.Context, region string, pageNumber, pageSize int) (DescribeRDSInstancesResponse, error)
- func (c *Client) DescribeRDSRegions(ctx context.Context, region string) (DescribeRDSRegionsResponse, error)
- func (c *Client) DescribeSASSuspEvents(ctx context.Context, region string) (DescribeSASSuspEventsResponse, error)
- func (c *Client) DetachRAMPolicyFromRole(ctx context.Context, region, roleName, policyName, policyType string) (DetachRAMPolicyFromRoleResponse, error)
- func (c *Client) DetachRAMPolicyFromUser(ctx context.Context, region, userName, policyName, policyType string) (DetachRAMPolicyFromUserResponse, error)
- func (c *Client) Do(ctx context.Context, req Request, resp any) error
- func (c *Client) GetCallerIdentity(ctx context.Context, region string) (GetCallerIdentityResponse, error)
- func (c *Client) GetRAMAccountAlias(ctx context.Context, region string) (GetRAMAccountAliasResponse, error)
- func (c *Client) GetRAMLoginProfile(ctx context.Context, region, userName string) (GetRAMLoginProfileResponse, error)
- func (c *Client) GetRAMPolicy(ctx context.Context, region, policyName, policyType string) (GetRAMPolicyResponse, error)
- func (c *Client) GetRAMUser(ctx context.Context, region, userName string) (GetRAMUserResponse, error)
- func (c *Client) GrantRDSAccountPrivilege(ctx context.Context, region, instanceID, accountName, dbName, privilege string) (GrantRDSAccountPrivilegeResponse, error)
- func (c *Client) HandleSASSecurityEvents(ctx context.Context, region, operationCode string, securityEventIDs []string) (HandleSASSecurityEventsResponse, error)
- func (c *Client) ListRAMPoliciesForUser(ctx context.Context, region, userName string) (ListRAMPoliciesForUserResponse, error)
- func (c *Client) ListRAMUsers(ctx context.Context, region, marker string, maxItems int) (ListRAMUsersResponse, error)
- func (c *Client) QueryAccountBalance(ctx context.Context, region string) (QueryAccountBalanceResponse, error)
- func (c *Client) QuerySMSSendStatistics(ctx context.Context, region, date string) (QuerySMSSendStatisticsResponse, error)
- func (c *Client) QuerySMSSignList(ctx context.Context, region string) (QuerySMSSignListResponse, error)
- func (c *Client) QuerySMSTemplateList(ctx context.Context, region string) (QuerySMSTemplateListResponse, error)
- func (c *Client) RunECSCommand(ctx context.Context, ...) (RunECSCommandResponse, error)
- type CreateRAMLoginProfileResponse
- type CreateRAMRoleResponse
- type CreateRAMUserResponse
- type CreateRDSAccountResponse
- type DeleteRAMRoleResponse
- type DeleteRAMUserResponse
- type DeleteRDSAccountResponse
- type DescribeDomainRecordsResponse
- type DescribeDomainsResponse
- type DescribeECSInstancesResponse
- type DescribeECSInvocationResultsResponse
- type DescribeECSRegionsResponse
- type DescribeRDSDatabasesResponse
- type DescribeRDSInstancesResponse
- type DescribeRDSRegionsResponse
- type DescribeSASSuspEventsResponse
- type DetachRAMPolicyFromRoleResponse
- type DetachRAMPolicyFromUserResponse
- type DomainList
- type DomainRecord
- type DomainRecordList
- type DomainSummary
- type ECSEIPAddress
- type ECSInstance
- type ECSInstanceList
- type ECSInvocation
- type ECSInvocationResult
- type ECSInvocationResults
- type ECSNetworkInterface
- type ECSNetworkInterfaces
- type ECSPrivateIPSet
- type ECSPrivateIPSets
- type ECSPublicIPList
- type ECSRegion
- type ECSRegionList
- type GetCallerIdentityResponse
- type GetRAMAccountAliasResponse
- type GetRAMLoginProfileResponse
- type GetRAMPolicyResponse
- type GetRAMUserResponse
- type GrantRDSAccountPrivilegeResponse
- type HTTPStatusError
- type HandleSASSecurityEventsResponse
- type HandleSASSecurityEventsResponseItem
- type ListRAMPoliciesForUserResponse
- type ListRAMUsersResponse
- type Option
- type QueryAccountBalanceResponse
- type QuerySMSSendStatisticsResponse
- type QuerySMSSignListResponse
- type QuerySMSTemplateListResponse
- type RAMDefaultPolicyVersion
- type RAMLoginProfile
- type RAMPolicy
- type RAMPolicyList
- type RAMRole
- type RAMUser
- type RAMUserList
- type RDSDatabase
- type RDSDatabaseList
- type RDSInstance
- type RDSInstanceList
- type RDSRegion
- type RDSRegionList
- type RPCSigner
- type Request
- type RetryPolicy
- type RunECSCommandResponse
- type SASEventDetail
- type SASSuspEvent
- type SMSSendStatisticsData
- type SMSSignInfo
- type SMSTemplateInfo
- type SignInput
Constants ¶
View Source
const DefaultRegion = "cn-hangzhou"
View Source
const (
DefaultTimeout = 30 * time.Second
)
Variables ¶
This section is empty.
Functions ¶
func DecodeError ¶
func IsAccessDenied ¶ added in v0.2.5
func IsNotSupportedEndpoint ¶ added in v0.2.5
func NewHTTPClient ¶
func NewTransport ¶
func NormalizeRegion ¶
Types ¶
type APIError ¶
type AccountBalanceData ¶
type AccountBalanceData struct {
AvailableCashAmount string `json:"AvailableCashAmount"`
}
type AttachRAMPolicyToRoleResponse ¶
type AttachRAMPolicyToRoleResponse struct {
RequestID string `json:"RequestId"`
}
type AttachRAMPolicyToUserResponse ¶
type AttachRAMPolicyToUserResponse struct {
RequestID string `json:"RequestId"`
}
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) AttachRAMPolicyToRole ¶
func (*Client) AttachRAMPolicyToUser ¶
func (*Client) CreateRAMLoginProfile ¶
func (*Client) CreateRAMRole ¶
func (*Client) CreateRAMUser ¶
func (*Client) CreateRDSAccount ¶
func (*Client) DeleteRAMRole ¶
func (*Client) DeleteRAMUser ¶
func (*Client) DeleteRDSAccount ¶
func (*Client) DescribeDomainRecords ¶
func (*Client) DescribeDomains ¶
func (*Client) DescribeECSInstances ¶
func (*Client) DescribeECSInvocationResults ¶
func (*Client) DescribeECSRegions ¶
func (*Client) DescribeRDSDatabases ¶
func (*Client) DescribeRDSInstances ¶
func (*Client) DescribeRDSRegions ¶
func (*Client) DescribeSASSuspEvents ¶
func (*Client) DetachRAMPolicyFromRole ¶
func (*Client) DetachRAMPolicyFromUser ¶
func (*Client) GetCallerIdentity ¶
func (*Client) GetRAMAccountAlias ¶
func (*Client) GetRAMLoginProfile ¶
func (*Client) GetRAMPolicy ¶
func (*Client) GetRAMUser ¶
func (*Client) GrantRDSAccountPrivilege ¶
func (*Client) HandleSASSecurityEvents ¶
func (*Client) ListRAMPoliciesForUser ¶
func (*Client) ListRAMUsers ¶
func (*Client) QueryAccountBalance ¶
func (*Client) QuerySMSSendStatistics ¶
func (*Client) QuerySMSSignList ¶
func (*Client) QuerySMSTemplateList ¶
func (*Client) RunECSCommand ¶
type CreateRAMLoginProfileResponse ¶
type CreateRAMLoginProfileResponse struct {
RequestID string `json:"RequestId"`
LoginProfile RAMLoginProfile `json:"LoginProfile"`
}
type CreateRAMRoleResponse ¶
type CreateRAMUserResponse ¶
type CreateRDSAccountResponse ¶
type CreateRDSAccountResponse struct {
RequestID string `json:"RequestId"`
}
type DeleteRAMRoleResponse ¶
type DeleteRAMRoleResponse struct {
RequestID string `json:"RequestId"`
}
type DeleteRAMUserResponse ¶
type DeleteRAMUserResponse struct {
RequestID string `json:"RequestId"`
}
type DeleteRDSAccountResponse ¶
type DeleteRDSAccountResponse struct {
RequestID string `json:"RequestId"`
}
type DescribeDomainRecordsResponse ¶
type DescribeDomainRecordsResponse struct {
TotalCount int `json:"TotalCount"`
PageSize int `json:"PageSize"`
RequestID string `json:"RequestId"`
PageNumber int `json:"PageNumber"`
DomainRecords DomainRecordList `json:"DomainRecords"`
}
type DescribeDomainsResponse ¶
type DescribeDomainsResponse struct {
TotalCount int `json:"TotalCount"`
PageSize int `json:"PageSize"`
RequestID string `json:"RequestId"`
PageNumber int `json:"PageNumber"`
Domains DomainList `json:"Domains"`
}
type DescribeECSInstancesResponse ¶
type DescribeECSInstancesResponse struct {
PageSize int `json:"PageSize"`
PageNumber int `json:"PageNumber"`
RequestID string `json:"RequestId"`
TotalCount int `json:"TotalCount"`
Instances ECSInstanceList `json:"Instances"`
}
type DescribeECSInvocationResultsResponse ¶
type DescribeECSInvocationResultsResponse struct {
RequestID string `json:"RequestId"`
Invocation ECSInvocation `json:"Invocation"`
}
type DescribeECSRegionsResponse ¶
type DescribeECSRegionsResponse struct {
RequestID string `json:"RequestId"`
Regions ECSRegionList `json:"Regions"`
}
type DescribeRDSDatabasesResponse ¶
type DescribeRDSDatabasesResponse struct {
RequestID string `json:"RequestId"`
Databases RDSDatabaseList `json:"Databases"`
}
type DescribeRDSInstancesResponse ¶
type DescribeRDSInstancesResponse struct {
RequestID string `json:"RequestId"`
PageNumber int `json:"PageNumber"`
PageRecordCount int `json:"PageRecordCount"`
TotalRecordCount int `json:"TotalRecordCount"`
Items RDSInstanceList `json:"Items"`
}
type DescribeRDSRegionsResponse ¶
type DescribeRDSRegionsResponse struct {
RequestID string `json:"RequestId"`
Regions RDSRegionList `json:"Regions"`
}
type DetachRAMPolicyFromRoleResponse ¶
type DetachRAMPolicyFromRoleResponse struct {
RequestID string `json:"RequestId"`
}
type DetachRAMPolicyFromUserResponse ¶
type DetachRAMPolicyFromUserResponse struct {
RequestID string `json:"RequestId"`
}
type DomainList ¶
type DomainList struct {
Domain []DomainSummary `json:"Domain"`
}
type DomainRecord ¶
type DomainRecordList ¶
type DomainRecordList struct {
Record []DomainRecord `json:"Record"`
}
type DomainSummary ¶
type DomainSummary struct {
DomainName string `json:"DomainName"`
}
type ECSEIPAddress ¶
type ECSEIPAddress struct {
IPAddress string `json:"IpAddress"`
}
type ECSInstance ¶
type ECSInstance struct {
HostName string `json:"HostName"`
InstanceID string `json:"InstanceId"`
OSType string `json:"OSType"`
PublicIP ECSPublicIPList `json:"PublicIpAddress"`
NetworkInterfaces ECSNetworkInterfaces `json:"NetworkInterfaces"`
EIPAddress ECSEIPAddress `json:"EipAddress"`
}
type ECSInstanceList ¶
type ECSInstanceList struct {
Instance []ECSInstance `json:"Instance"`
}
type ECSInvocation ¶
type ECSInvocation struct {
CommandID string `json:"CommandId"`
InvokeID string `json:"InvokeId"`
InvocationResults ECSInvocationResults `json:"InvocationResults"`
}
type ECSInvocationResult ¶
type ECSInvocationResults ¶
type ECSInvocationResults struct {
InvocationResult []ECSInvocationResult `json:"InvocationResult"`
}
type ECSNetworkInterface ¶
type ECSNetworkInterface struct {
PrimaryIPAddress string `json:"PrimaryIpAddress"`
PrivateIPSets ECSPrivateIPSets `json:"PrivateIpSets"`
}
type ECSNetworkInterfaces ¶
type ECSNetworkInterfaces struct {
NetworkInterface []ECSNetworkInterface `json:"NetworkInterface"`
}
type ECSPrivateIPSet ¶
type ECSPrivateIPSet struct {
PrivateIPAddress string `json:"PrivateIpAddress"`
}
type ECSPrivateIPSets ¶
type ECSPrivateIPSets struct {
PrivateIPSet []ECSPrivateIPSet `json:"PrivateIpSet"`
}
type ECSPublicIPList ¶
type ECSPublicIPList struct {
IPAddress []string `json:"IpAddress"`
}
type ECSRegionList ¶
type ECSRegionList struct {
Region []ECSRegion `json:"Region"`
}
type GetRAMLoginProfileResponse ¶
type GetRAMLoginProfileResponse struct {
RequestID string `json:"RequestId"`
LoginProfile RAMLoginProfile `json:"LoginProfile"`
}
type GetRAMPolicyResponse ¶
type GetRAMPolicyResponse struct {
RequestID string `json:"RequestId"`
Policy RAMPolicy `json:"Policy"`
DefaultPolicyVersion RAMDefaultPolicyVersion `json:"DefaultPolicyVersion"`
}
type GetRAMUserResponse ¶
type GrantRDSAccountPrivilegeResponse ¶
type GrantRDSAccountPrivilegeResponse struct {
RequestID string `json:"RequestId"`
}
type HTTPStatusError ¶
func (*HTTPStatusError) Error ¶
func (e *HTTPStatusError) Error() string
type HandleSASSecurityEventsResponse ¶
type HandleSASSecurityEventsResponse struct {
RequestID string `json:"RequestId"`
HandleSecurityEventsResponse HandleSASSecurityEventsResponseItem `json:"HandleSecurityEventsResponse"`
}
type HandleSASSecurityEventsResponseItem ¶
type HandleSASSecurityEventsResponseItem struct {
TaskID int64 `json:"TaskId"`
}
type ListRAMPoliciesForUserResponse ¶
type ListRAMPoliciesForUserResponse struct {
RequestID string `json:"RequestId"`
Policies RAMPolicyList `json:"Policies"`
}
type ListRAMUsersResponse ¶
type ListRAMUsersResponse struct {
RequestID string `json:"RequestId"`
IsTruncated bool `json:"IsTruncated"`
Marker string `json:"Marker"`
Users RAMUserList `json:"Users"`
}
type Option ¶
type Option func(*Client)
func WithBaseURL ¶
func WithHTTPClient ¶
func WithRetryPolicy ¶
func WithRetryPolicy(policy RetryPolicy) Option
func WithUserAgent ¶
type QueryAccountBalanceResponse ¶
type QueryAccountBalanceResponse struct {
Code string `json:"Code"`
Message string `json:"Message"`
RequestID string `json:"RequestId"`
Success bool `json:"Success"`
Data AccountBalanceData `json:"Data"`
}
type QuerySMSSendStatisticsResponse ¶
type QuerySMSSendStatisticsResponse struct {
RequestID string `json:"RequestId"`
Code string `json:"Code"`
Message string `json:"Message"`
Data SMSSendStatisticsData `json:"Data"`
}
type QuerySMSTemplateListResponse ¶
type QuerySMSTemplateListResponse struct {
RequestID string `json:"RequestId"`
Code string `json:"Code"`
Message string `json:"Message"`
TotalCount int64 `json:"TotalCount"`
CurrentPage int `json:"CurrentPage"`
PageSize int `json:"PageSize"`
SmsTemplateList []SMSTemplateInfo `json:"SmsTemplateList"`
}
type RAMDefaultPolicyVersion ¶
type RAMLoginProfile ¶
type RAMPolicy ¶
type RAMPolicy struct {
PolicyDocument string `json:"PolicyDocument"`
CreateDate string `json:"CreateDate"`
AttachDate string `json:"AttachDate"`
PolicyType string `json:"PolicyType"`
UpdateDate string `json:"UpdateDate"`
AttachmentCount int `json:"AttachmentCount"`
DefaultVersion string `json:"DefaultVersion"`
PolicyName string `json:"PolicyName"`
Description string `json:"Description"`
}
type RAMPolicyList ¶
type RAMPolicyList struct {
Policy []RAMPolicy `json:"Policy"`
}
type RAMRole ¶
type RAMRole struct {
CreateDate string `json:"CreateDate"`
RoleID string `json:"RoleId"`
AttachDate string `json:"AttachDate"`
Arn string `json:"Arn"`
UpdateDate string `json:"UpdateDate"`
MaxSessionDuration int64 `json:"MaxSessionDuration"`
Description string `json:"Description"`
AssumeRolePolicyDocument string `json:"AssumeRolePolicyDocument"`
RoleName string `json:"RoleName"`
}
type RAMUser ¶
type RAMUser struct {
MobilePhone string `json:"MobilePhone"`
Comments string `json:"Comments"`
CreateDate string `json:"CreateDate"`
AttachDate string `json:"AttachDate"`
Email string `json:"Email"`
UserID string `json:"UserId"`
UpdateDate string `json:"UpdateDate"`
UserName string `json:"UserName"`
JoinDate string `json:"JoinDate"`
LastLoginDate string `json:"LastLoginDate"`
DisplayName string `json:"DisplayName"`
}
type RAMUserList ¶
type RAMUserList struct {
User []RAMUser `json:"User"`
}
type RDSDatabase ¶
type RDSDatabase struct {
DBName string `json:"DBName"`
}
type RDSDatabaseList ¶
type RDSDatabaseList struct {
Database []RDSDatabase `json:"Database"`
}
type RDSInstance ¶
type RDSInstanceList ¶
type RDSInstanceList struct {
DBInstance []RDSInstance `json:"DBInstance"`
}
type RDSRegionList ¶
type RDSRegionList struct {
RDSRegion []RDSRegion `json:"RDSRegion"`
}
type RetryPolicy ¶
type RetryPolicy struct {
MaxAttempts int
BaseDelay time.Duration
MaxDelay time.Duration
Sleep func(context.Context, time.Duration) error
}
func DefaultRetryPolicy ¶
func DefaultRetryPolicy() RetryPolicy
type RunECSCommandResponse ¶
type SASEventDetail ¶
type SASSuspEvent ¶
type SMSSendStatisticsData ¶
type SMSSendStatisticsData struct {
TotalSize int64 `json:"TotalSize"`
}
type SMSSignInfo ¶
type SMSTemplateInfo ¶
Click to show internal directories.
Click to hide internal directories.