package client
import "github.com/aws/aws-sdk-go-v2/credentials/endpointcreds/internal/client"
Index ¶
- Constants
- type Client
- func New(options Options, optFns ...func(*Options)) *Client
- func (c *Client) GetCredentials(ctx context.Context, params *GetCredentialsInput, optFns ...func(*Options)) (*GetCredentialsOutput, error)
- type EndpointError
- func (e *EndpointError) Error() string
- func (e *EndpointError) ErrorCode() string
- func (e *EndpointError) ErrorFault() smithy.ErrorFault
- func (e *EndpointError) ErrorMessage() string
- func (e *EndpointError) HTTPStatusCode() int
- type GetCredentialsInput
- type GetCredentialsOutput
- type HTTPClient
- type Options
Constants ¶
const ServiceID = "endpoint-credentials"
ServiceID is the client identifer
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is an client for retrieving AWS credentials from an endpoint
func New ¶
New constructs a new Client from the given options
func (*Client) GetCredentials ¶
func (c *Client) GetCredentials(ctx context.Context, params *GetCredentialsInput, optFns ...func(*Options)) (*GetCredentialsOutput, error)
GetCredentials retrieves credentials from credential endpoint
type EndpointError ¶
type EndpointError struct { Code string `json:"code"` Message string `json:"message"` Fault smithy.ErrorFault `json:"-"` // contains filtered or unexported fields }
EndpointError is an error returned from the endpoint service
func (*EndpointError) Error ¶
func (e *EndpointError) Error() string
Error is the error mesage string
func (*EndpointError) ErrorCode ¶
func (e *EndpointError) ErrorCode() string
ErrorCode is the error code returned by the endpoint
func (*EndpointError) ErrorFault ¶
func (e *EndpointError) ErrorFault() smithy.ErrorFault
ErrorFault indicates error fault classification
func (*EndpointError) ErrorMessage ¶
func (e *EndpointError) ErrorMessage() string
ErrorMessage is the error message returned by the endpoint
func (*EndpointError) HTTPStatusCode ¶
func (e *EndpointError) HTTPStatusCode() int
HTTPStatusCode implements retry.HTTPStatusCode.
type GetCredentialsInput ¶
type GetCredentialsInput struct { AuthorizationToken string }
GetCredentialsInput is the input to send with the endpoint service to receive credentials.
type GetCredentialsOutput ¶
type GetCredentialsOutput struct { Expiration *time.Time AccessKeyID string SecretAccessKey string Token string AccountID string }
GetCredentialsOutput is the response from the credential endpoint
type HTTPClient ¶
HTTPClient is a client for sending HTTP requests
type Options ¶
type Options struct { // The endpoint to retrieve credentials from Endpoint string // The HTTP client to invoke API calls with. Defaults to client's default HTTP // implementation if nil. HTTPClient HTTPClient // Retryer guides how HTTP requests should be retried in case of recoverable // failures. When nil the API client will use a default retryer. Retryer aws.Retryer // Set of options to modify how the credentials operation is invoked. APIOptions []func(*smithymiddleware.Stack) error }
Options is the endpoint client configurable options
func (Options) Copy ¶
Copy creates a copy of the API options.
Source Files ¶
auth.go client.go endpoints.go middleware.go
- Version
- v1.17.67 (latest)
- Published
- Apr 10, 2025
- Platform
- darwin/amd64
- Imports
- 14 packages
- Last checked
- 11 hours ago –
Tools for package owners.