Documentation ¶
Overview ¶
Package apigatewaymanagementapi provides the client and types for making API requests to AmazonApiGatewayManagementApi.
The Amazon API Gateway Management API allows you to directly manage runtime aspects of your deployed APIs. To use it, you must explicitly set the SDK's endpoint to point to the endpoint of your deployed API. The endpoint will be of the form https://{api-id}.execute-api.{region}.amazonaws.com/{stage}, or will be the endpoint corresponding to your API's custom domain and base path, if applicable.
See https://docs.aws.amazon.com/goto/WebAPI/apigatewaymanagementapi-2018-11-29 for more information on this service.
See apigatewaymanagementapi package documentation for more information. https://docs.aws.amazon.com/sdk-for-go/api/service/apigatewaymanagementapi/
Using the Client ¶
To use AmazonApiGatewayManagementApi with the SDK use the New function to create a new service client. With that client you can make API requests to the service. These clients are safe to use concurrently.
See the SDK's documentation for more information on how to use the SDK. https://docs.aws.amazon.com/sdk-for-go/api/
See aws.Config documentation for more information on configuring SDK clients. https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config
See the AmazonApiGatewayManagementApi client for more information on creating client for this service. https://docs.aws.amazon.com/sdk-for-go/api/service/apigatewaymanagementapi/#New
Index ¶
- Constants
- type Client
- type DeleteConnectionInput
- type DeleteConnectionOutput
- type DeleteConnectionRequest
- type DeleteConnectionResponse
- type GetConnectionInput
- type GetConnectionOutput
- type GetConnectionRequest
- type GetConnectionResponse
- type Identity
- type PostToConnectionInput
- type PostToConnectionOutput
- type PostToConnectionRequest
- type PostToConnectionResponse
Constants ¶
const ( ServiceName = "AmazonApiGatewayManagementApi" // Service's name ServiceID = "ApiGatewayManagementApi" // Service's identifier EndpointsID = "execute-api" // Service's Endpoint identifier )
const ( // ErrCodeForbiddenException for service response error code // "ForbiddenException". // // The caller is not authorized to invoke this operation. ErrCodeForbiddenException = "ForbiddenException" // ErrCodeGoneException for service response error code // "GoneException". // // The connection with the provided id no longer exists. ErrCodeGoneException = "GoneException" // ErrCodeLimitExceededException for service response error code // "LimitExceededException". // // The client is sending more than the allowed number of requests per unit of // time or the WebSocket client side buffer is full. ErrCodeLimitExceededException = "LimitExceededException" // ErrCodePayloadTooLargeException for service response error code // "PayloadTooLargeException". // // The data has exceeded the maximum size allowed. ErrCodePayloadTooLargeException = "PayloadTooLargeException" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶ added in v0.9.0
Client provides the API operation methods for making requests to AmazonApiGatewayManagementApi. See this package's package overview docs for details on the service.
The client's methods are safe to use concurrently. It is not safe to modify mutate any of the struct's properties though.
func New ¶
New creates a new instance of the client from the provided Config.
Example:
// Create a client from just a config. svc := apigatewaymanagementapi.New(myConfig)
func (*Client) DeleteConnectionRequest ¶ added in v0.12.0
func (c *Client) DeleteConnectionRequest(input *DeleteConnectionInput) DeleteConnectionRequest
DeleteConnectionRequest returns a request value for making API operation for AmazonApiGatewayManagementApi.
Delete the connection with the provided id.
// Example sending a request using DeleteConnectionRequest. req := client.DeleteConnectionRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/apigatewaymanagementapi-2018-11-29/DeleteConnection
func (*Client) GetConnectionRequest ¶ added in v0.12.0
func (c *Client) GetConnectionRequest(input *GetConnectionInput) GetConnectionRequest
GetConnectionRequest returns a request value for making API operation for AmazonApiGatewayManagementApi.
Get information about the connection with the provided id.
// Example sending a request using GetConnectionRequest. req := client.GetConnectionRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/apigatewaymanagementapi-2018-11-29/GetConnection
func (*Client) PostToConnectionRequest ¶ added in v0.9.0
func (c *Client) PostToConnectionRequest(input *PostToConnectionInput) PostToConnectionRequest
PostToConnectionRequest returns a request value for making API operation for AmazonApiGatewayManagementApi.
Sends the provided data to the specified connection.
// Example sending a request using PostToConnectionRequest. req := client.PostToConnectionRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/apigatewaymanagementapi-2018-11-29/PostToConnection
type DeleteConnectionInput ¶ added in v0.12.0
type DeleteConnectionInput struct { // ConnectionId is a required field ConnectionId *string `location:"uri" locationName:"connectionId" type:"string" required:"true"` // contains filtered or unexported fields }
func (DeleteConnectionInput) MarshalFields ¶ added in v0.12.0
func (s DeleteConnectionInput) MarshalFields(e protocol.FieldEncoder) error
MarshalFields encodes the AWS API shape using the passed in protocol encoder.
func (DeleteConnectionInput) String ¶ added in v0.12.0
func (s DeleteConnectionInput) String() string
String returns the string representation
func (*DeleteConnectionInput) Validate ¶ added in v0.12.0
func (s *DeleteConnectionInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type DeleteConnectionOutput ¶ added in v0.12.0
type DeleteConnectionOutput struct {
// contains filtered or unexported fields
}
func (DeleteConnectionOutput) MarshalFields ¶ added in v0.12.0
func (s DeleteConnectionOutput) MarshalFields(e protocol.FieldEncoder) error
MarshalFields encodes the AWS API shape using the passed in protocol encoder.
func (DeleteConnectionOutput) String ¶ added in v0.12.0
func (s DeleteConnectionOutput) String() string
String returns the string representation
type DeleteConnectionRequest ¶ added in v0.12.0
type DeleteConnectionRequest struct { *aws.Request Input *DeleteConnectionInput Copy func(*DeleteConnectionInput) DeleteConnectionRequest }
DeleteConnectionRequest is the request type for the DeleteConnection API operation.
func (DeleteConnectionRequest) Send ¶ added in v0.12.0
func (r DeleteConnectionRequest) Send(ctx context.Context) (*DeleteConnectionResponse, error)
Send marshals and sends the DeleteConnection API request.
type DeleteConnectionResponse ¶ added in v0.12.0
type DeleteConnectionResponse struct { *DeleteConnectionOutput // contains filtered or unexported fields }
DeleteConnectionResponse is the response type for the DeleteConnection API operation.
func (*DeleteConnectionResponse) SDKResponseMetdata ¶ added in v0.12.0
func (r *DeleteConnectionResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the DeleteConnection request.
type GetConnectionInput ¶ added in v0.12.0
type GetConnectionInput struct { // ConnectionId is a required field ConnectionId *string `location:"uri" locationName:"connectionId" type:"string" required:"true"` // contains filtered or unexported fields }
func (GetConnectionInput) MarshalFields ¶ added in v0.12.0
func (s GetConnectionInput) MarshalFields(e protocol.FieldEncoder) error
MarshalFields encodes the AWS API shape using the passed in protocol encoder.
func (GetConnectionInput) String ¶ added in v0.12.0
func (s GetConnectionInput) String() string
String returns the string representation
func (*GetConnectionInput) Validate ¶ added in v0.12.0
func (s *GetConnectionInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type GetConnectionOutput ¶ added in v0.12.0
type GetConnectionOutput struct { ConnectedAt *time.Time `locationName:"connectedAt" type:"timestamp" timestampFormat:"iso8601"` Identity *Identity `locationName:"identity" type:"structure"` LastActiveAt *time.Time `locationName:"lastActiveAt" type:"timestamp" timestampFormat:"iso8601"` // contains filtered or unexported fields }
func (GetConnectionOutput) MarshalFields ¶ added in v0.12.0
func (s GetConnectionOutput) MarshalFields(e protocol.FieldEncoder) error
MarshalFields encodes the AWS API shape using the passed in protocol encoder.
func (GetConnectionOutput) String ¶ added in v0.12.0
func (s GetConnectionOutput) String() string
String returns the string representation
type GetConnectionRequest ¶ added in v0.12.0
type GetConnectionRequest struct { *aws.Request Input *GetConnectionInput Copy func(*GetConnectionInput) GetConnectionRequest }
GetConnectionRequest is the request type for the GetConnection API operation.
func (GetConnectionRequest) Send ¶ added in v0.12.0
func (r GetConnectionRequest) Send(ctx context.Context) (*GetConnectionResponse, error)
Send marshals and sends the GetConnection API request.
type GetConnectionResponse ¶ added in v0.12.0
type GetConnectionResponse struct { *GetConnectionOutput // contains filtered or unexported fields }
GetConnectionResponse is the response type for the GetConnection API operation.
func (*GetConnectionResponse) SDKResponseMetdata ¶ added in v0.12.0
func (r *GetConnectionResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the GetConnection request.
type Identity ¶ added in v0.12.0
type Identity struct { // The source IP address of the TCP connection making the request to API Gateway. // // SourceIp is a required field SourceIp *string `locationName:"sourceIp" type:"string" required:"true"` // The User Agent of the API caller. // // UserAgent is a required field UserAgent *string `locationName:"userAgent" type:"string" required:"true"` // contains filtered or unexported fields }
func (Identity) MarshalFields ¶ added in v0.12.0
func (s Identity) MarshalFields(e protocol.FieldEncoder) error
MarshalFields encodes the AWS API shape using the passed in protocol encoder.
type PostToConnectionInput ¶
type PostToConnectionInput struct { // ConnectionId is a required field ConnectionId *string `location:"uri" locationName:"connectionId" type:"string" required:"true"` // The data to be sent to the client specified by its connection id. // // Data is a required field Data []byte `type:"blob" required:"true"` // contains filtered or unexported fields }
func (PostToConnectionInput) MarshalFields ¶
func (s PostToConnectionInput) MarshalFields(e protocol.FieldEncoder) error
MarshalFields encodes the AWS API shape using the passed in protocol encoder.
func (PostToConnectionInput) String ¶
func (s PostToConnectionInput) String() string
String returns the string representation
func (*PostToConnectionInput) Validate ¶
func (s *PostToConnectionInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type PostToConnectionOutput ¶
type PostToConnectionOutput struct {
// contains filtered or unexported fields
}
func (PostToConnectionOutput) MarshalFields ¶
func (s PostToConnectionOutput) MarshalFields(e protocol.FieldEncoder) error
MarshalFields encodes the AWS API shape using the passed in protocol encoder.
func (PostToConnectionOutput) String ¶
func (s PostToConnectionOutput) String() string
String returns the string representation
type PostToConnectionRequest ¶
type PostToConnectionRequest struct { *aws.Request Input *PostToConnectionInput Copy func(*PostToConnectionInput) PostToConnectionRequest }
PostToConnectionRequest is the request type for the PostToConnection API operation.
func (PostToConnectionRequest) Send ¶
func (r PostToConnectionRequest) Send(ctx context.Context) (*PostToConnectionResponse, error)
Send marshals and sends the PostToConnection API request.
type PostToConnectionResponse ¶ added in v0.9.0
type PostToConnectionResponse struct { *PostToConnectionOutput // contains filtered or unexported fields }
PostToConnectionResponse is the response type for the PostToConnection API operation.
func (*PostToConnectionResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *PostToConnectionResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the PostToConnection request.
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
Package apigatewaymanagementapiiface provides an interface to enable mocking the AmazonApiGatewayManagementApi service client for testing your code.
|
Package apigatewaymanagementapiiface provides an interface to enable mocking the AmazonApiGatewayManagementApi service client for testing your code. |