Documentation ¶
Overview ¶
Package sns provides the client and types for making API requests to Amazon SNS.
Amazon Simple Notification Service (Amazon SNS) is a web service that enables you to build distributed web-enabled applications. Applications can use Amazon SNS to easily push real-time notification messages to interested subscribers over multiple delivery protocols. For more information about this product see https://aws.amazon.com/sns (http://aws.amazon.com/sns/). For detailed information about Amazon SNS features and their associated API calls, see the Amazon SNS Developer Guide (https://docs.aws.amazon.com/sns/latest/dg/).
We also provide SDKs that enable you to access Amazon SNS from your preferred programming language. The SDKs contain functionality that automatically takes care of tasks such as: cryptographically signing your service requests, retrying requests, and handling error responses. For a list of available SDKs, go to Tools for Amazon Web Services (http://aws.amazon.com/tools/).
See https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31 for more information on this service.
See sns package documentation for more information. https://docs.aws.amazon.com/sdk-for-go/api/service/sns/
Using the Client ¶
To use Amazon SNS 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 Amazon SNS client for more information on creating client for this service. https://docs.aws.amazon.com/sdk-for-go/api/service/sns/#New
Index ¶
- Constants
- type AddPermissionInput
- type AddPermissionOutput
- type AddPermissionRequest
- type AddPermissionResponse
- type CheckIfPhoneNumberIsOptedOutInput
- type CheckIfPhoneNumberIsOptedOutOutput
- type CheckIfPhoneNumberIsOptedOutRequest
- type CheckIfPhoneNumberIsOptedOutResponse
- type Client
- func (c *Client) AddPermissionRequest(input *AddPermissionInput) AddPermissionRequest
- func (c *Client) CheckIfPhoneNumberIsOptedOutRequest(input *CheckIfPhoneNumberIsOptedOutInput) CheckIfPhoneNumberIsOptedOutRequest
- func (c *Client) ConfirmSubscriptionRequest(input *ConfirmSubscriptionInput) ConfirmSubscriptionRequest
- func (c *Client) CreatePlatformApplicationRequest(input *CreatePlatformApplicationInput) CreatePlatformApplicationRequest
- func (c *Client) CreatePlatformEndpointRequest(input *CreatePlatformEndpointInput) CreatePlatformEndpointRequest
- func (c *Client) CreateTopicRequest(input *CreateTopicInput) CreateTopicRequest
- func (c *Client) DeleteEndpointRequest(input *DeleteEndpointInput) DeleteEndpointRequest
- func (c *Client) DeletePlatformApplicationRequest(input *DeletePlatformApplicationInput) DeletePlatformApplicationRequest
- func (c *Client) DeleteTopicRequest(input *DeleteTopicInput) DeleteTopicRequest
- func (c *Client) GetEndpointAttributesRequest(input *GetEndpointAttributesInput) GetEndpointAttributesRequest
- func (c *Client) GetPlatformApplicationAttributesRequest(input *GetPlatformApplicationAttributesInput) GetPlatformApplicationAttributesRequest
- func (c *Client) GetSMSAttributesRequest(input *GetSMSAttributesInput) GetSMSAttributesRequest
- func (c *Client) GetSubscriptionAttributesRequest(input *GetSubscriptionAttributesInput) GetSubscriptionAttributesRequest
- func (c *Client) GetTopicAttributesRequest(input *GetTopicAttributesInput) GetTopicAttributesRequest
- func (c *Client) ListEndpointsByPlatformApplicationRequest(input *ListEndpointsByPlatformApplicationInput) ListEndpointsByPlatformApplicationRequest
- func (c *Client) ListPhoneNumbersOptedOutRequest(input *ListPhoneNumbersOptedOutInput) ListPhoneNumbersOptedOutRequest
- func (c *Client) ListPlatformApplicationsRequest(input *ListPlatformApplicationsInput) ListPlatformApplicationsRequest
- func (c *Client) ListSubscriptionsByTopicRequest(input *ListSubscriptionsByTopicInput) ListSubscriptionsByTopicRequest
- func (c *Client) ListSubscriptionsRequest(input *ListSubscriptionsInput) ListSubscriptionsRequest
- func (c *Client) ListTagsForResourceRequest(input *ListTagsForResourceInput) ListTagsForResourceRequest
- func (c *Client) ListTopicsRequest(input *ListTopicsInput) ListTopicsRequest
- func (c *Client) OptInPhoneNumberRequest(input *OptInPhoneNumberInput) OptInPhoneNumberRequest
- func (c *Client) PublishRequest(input *PublishInput) PublishRequest
- func (c *Client) RemovePermissionRequest(input *RemovePermissionInput) RemovePermissionRequest
- func (c *Client) SetEndpointAttributesRequest(input *SetEndpointAttributesInput) SetEndpointAttributesRequest
- func (c *Client) SetPlatformApplicationAttributesRequest(input *SetPlatformApplicationAttributesInput) SetPlatformApplicationAttributesRequest
- func (c *Client) SetSMSAttributesRequest(input *SetSMSAttributesInput) SetSMSAttributesRequest
- func (c *Client) SetSubscriptionAttributesRequest(input *SetSubscriptionAttributesInput) SetSubscriptionAttributesRequest
- func (c *Client) SetTopicAttributesRequest(input *SetTopicAttributesInput) SetTopicAttributesRequest
- func (c *Client) SubscribeRequest(input *SubscribeInput) SubscribeRequest
- func (c *Client) TagResourceRequest(input *TagResourceInput) TagResourceRequest
- func (c *Client) UnsubscribeRequest(input *UnsubscribeInput) UnsubscribeRequest
- func (c *Client) UntagResourceRequest(input *UntagResourceInput) UntagResourceRequest
- type ConfirmSubscriptionInput
- type ConfirmSubscriptionOutput
- type ConfirmSubscriptionRequest
- type ConfirmSubscriptionResponse
- type CreatePlatformApplicationInput
- type CreatePlatformApplicationOutput
- type CreatePlatformApplicationRequest
- type CreatePlatformApplicationResponse
- type CreatePlatformEndpointInput
- type CreatePlatformEndpointOutput
- type CreatePlatformEndpointRequest
- type CreatePlatformEndpointResponse
- type CreateTopicInput
- type CreateTopicOutput
- type CreateTopicRequest
- type CreateTopicResponse
- type DeleteEndpointInput
- type DeleteEndpointOutput
- type DeleteEndpointRequest
- type DeleteEndpointResponse
- type DeletePlatformApplicationInput
- type DeletePlatformApplicationOutput
- type DeletePlatformApplicationRequest
- type DeletePlatformApplicationResponse
- type DeleteTopicInput
- type DeleteTopicOutput
- type DeleteTopicRequest
- type DeleteTopicResponse
- type Endpoint
- type GetEndpointAttributesInput
- type GetEndpointAttributesOutput
- type GetEndpointAttributesRequest
- type GetEndpointAttributesResponse
- type GetPlatformApplicationAttributesInput
- type GetPlatformApplicationAttributesOutput
- type GetPlatformApplicationAttributesRequest
- type GetPlatformApplicationAttributesResponse
- type GetSMSAttributesInput
- type GetSMSAttributesOutput
- type GetSMSAttributesRequest
- type GetSMSAttributesResponse
- type GetSubscriptionAttributesInput
- type GetSubscriptionAttributesOutput
- type GetSubscriptionAttributesRequest
- type GetSubscriptionAttributesResponse
- type GetTopicAttributesInput
- type GetTopicAttributesOutput
- type GetTopicAttributesRequest
- type GetTopicAttributesResponse
- type ListEndpointsByPlatformApplicationInput
- type ListEndpointsByPlatformApplicationOutput
- type ListEndpointsByPlatformApplicationPaginator
- type ListEndpointsByPlatformApplicationRequest
- type ListEndpointsByPlatformApplicationResponse
- type ListPhoneNumbersOptedOutInput
- type ListPhoneNumbersOptedOutOutput
- type ListPhoneNumbersOptedOutRequest
- type ListPhoneNumbersOptedOutResponse
- type ListPlatformApplicationsInput
- type ListPlatformApplicationsOutput
- type ListPlatformApplicationsPaginator
- type ListPlatformApplicationsRequest
- type ListPlatformApplicationsResponse
- type ListSubscriptionsByTopicInput
- type ListSubscriptionsByTopicOutput
- type ListSubscriptionsByTopicPaginator
- type ListSubscriptionsByTopicRequest
- type ListSubscriptionsByTopicResponse
- type ListSubscriptionsInput
- type ListSubscriptionsOutput
- type ListSubscriptionsPaginator
- type ListSubscriptionsRequest
- type ListSubscriptionsResponse
- type ListTagsForResourceInput
- type ListTagsForResourceOutput
- type ListTagsForResourceRequest
- type ListTagsForResourceResponse
- type ListTopicsInput
- type ListTopicsOutput
- type ListTopicsPaginator
- type ListTopicsRequest
- type ListTopicsResponse
- type MessageAttributeValue
- type OptInPhoneNumberInput
- type OptInPhoneNumberOutput
- type OptInPhoneNumberRequest
- type OptInPhoneNumberResponse
- type PlatformApplication
- type PublishInput
- type PublishOutput
- type PublishRequest
- type PublishResponse
- type RemovePermissionInput
- type RemovePermissionOutput
- type RemovePermissionRequest
- type RemovePermissionResponse
- type SetEndpointAttributesInput
- type SetEndpointAttributesOutput
- type SetEndpointAttributesRequest
- type SetEndpointAttributesResponse
- type SetPlatformApplicationAttributesInput
- type SetPlatformApplicationAttributesOutput
- type SetPlatformApplicationAttributesRequest
- type SetPlatformApplicationAttributesResponse
- type SetSMSAttributesInput
- type SetSMSAttributesOutput
- type SetSMSAttributesRequest
- type SetSMSAttributesResponse
- type SetSubscriptionAttributesInput
- type SetSubscriptionAttributesOutput
- type SetSubscriptionAttributesRequest
- type SetSubscriptionAttributesResponse
- type SetTopicAttributesInput
- type SetTopicAttributesOutput
- type SetTopicAttributesRequest
- type SetTopicAttributesResponse
- type SubscribeInput
- type SubscribeOutput
- type SubscribeRequest
- type SubscribeResponse
- type Subscription
- type Tag
- type TagResourceInput
- type TagResourceOutput
- type TagResourceRequest
- type TagResourceResponse
- type Topic
- type UnsubscribeInput
- type UnsubscribeOutput
- type UnsubscribeRequest
- type UnsubscribeResponse
- type UntagResourceInput
- type UntagResourceOutput
- type UntagResourceRequest
- type UntagResourceResponse
Constants ¶
const ( ServiceName = "Amazon SNS" // Service's name ServiceID = "SNS" // Service's identifier EndpointsID = "sns" // Service's Endpoint identifier )
const ( // ErrCodeAuthorizationErrorException for service response error code // "AuthorizationError". // // Indicates that the user has been denied access to the requested resource. ErrCodeAuthorizationErrorException = "AuthorizationError" // ErrCodeConcurrentAccessException for service response error code // "ConcurrentAccess". // // Can't perform multiple operations on a tag simultaneously. Perform the operations // sequentially. ErrCodeConcurrentAccessException = "ConcurrentAccess" // ErrCodeEndpointDisabledException for service response error code // "EndpointDisabled". // // Exception error indicating endpoint disabled. ErrCodeEndpointDisabledException = "EndpointDisabled" // ErrCodeFilterPolicyLimitExceededException for service response error code // "FilterPolicyLimitExceeded". // // Indicates that the number of filter polices in your AWS account exceeds the // limit. To add more filter polices, submit an SNS Limit Increase case in the // AWS Support Center. ErrCodeFilterPolicyLimitExceededException = "FilterPolicyLimitExceeded" // ErrCodeInternalErrorException for service response error code // "InternalError". // // Indicates an internal service error. ErrCodeInternalErrorException = "InternalError" // ErrCodeInvalidParameterException for service response error code // "InvalidParameter". // // Indicates that a request parameter does not comply with the associated constraints. ErrCodeInvalidParameterException = "InvalidParameter" // ErrCodeInvalidParameterValueException for service response error code // "ParameterValueInvalid". // // Indicates that a request parameter does not comply with the associated constraints. ErrCodeInvalidParameterValueException = "ParameterValueInvalid" // ErrCodeInvalidSecurityException for service response error code // "InvalidSecurity". // // The credential signature isn't valid. You must use an HTTPS endpoint and // sign your request using Signature Version 4. ErrCodeInvalidSecurityException = "InvalidSecurity" // ErrCodeKMSAccessDeniedException for service response error code // "KMSAccessDenied". // // The ciphertext references a key that doesn't exist or that you don't have // access to. ErrCodeKMSAccessDeniedException = "KMSAccessDenied" // ErrCodeKMSDisabledException for service response error code // "KMSDisabled". // // The request was rejected because the specified customer master key (CMK) // isn't enabled. ErrCodeKMSDisabledException = "KMSDisabled" // ErrCodeKMSInvalidStateException for service response error code // "KMSInvalidState". // // The request was rejected because the state of the specified resource isn't // valid for this request. For more information, see How Key State Affects Use // of a Customer Master Key (https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html) // in the AWS Key Management Service Developer Guide. ErrCodeKMSInvalidStateException = "KMSInvalidState" // ErrCodeKMSNotFoundException for service response error code // "KMSNotFound". // // The request was rejected because the specified entity or resource can't be // found. ErrCodeKMSNotFoundException = "KMSNotFound" // ErrCodeKMSOptInRequired for service response error code // "KMSOptInRequired". // // The AWS access key ID needs a subscription for the service. ErrCodeKMSOptInRequired = "KMSOptInRequired" // ErrCodeKMSThrottlingException for service response error code // "KMSThrottling". // // The request was denied due to request throttling. For more information about // throttling, see Limits (https://docs.aws.amazon.com/kms/latest/developerguide/limits.html#requests-per-second) // in the AWS Key Management Service Developer Guide. ErrCodeKMSThrottlingException = "KMSThrottling" // ErrCodeNotFoundException for service response error code // "NotFound". // // Indicates that the requested resource does not exist. ErrCodeNotFoundException = "NotFound" // ErrCodePlatformApplicationDisabledException for service response error code // "PlatformApplicationDisabled". // // Exception error indicating platform application disabled. ErrCodePlatformApplicationDisabledException = "PlatformApplicationDisabled" // ErrCodeResourceNotFoundException for service response error code // "ResourceNotFound". // // Can't tag resource. Verify that the topic exists. ErrCodeResourceNotFoundException = "ResourceNotFound" // ErrCodeStaleTagException for service response error code // "StaleTag". // // A tag has been added to a resource with the same ARN as a deleted resource. // Wait a short while and then retry the operation. ErrCodeStaleTagException = "StaleTag" // ErrCodeSubscriptionLimitExceededException for service response error code // "SubscriptionLimitExceeded". // // Indicates that the customer already owns the maximum allowed number of subscriptions. ErrCodeSubscriptionLimitExceededException = "SubscriptionLimitExceeded" // ErrCodeTagLimitExceededException for service response error code // "TagLimitExceeded". // // Can't add more than 50 tags to a topic. ErrCodeTagLimitExceededException = "TagLimitExceeded" // ErrCodeTagPolicyException for service response error code // "TagPolicy". // // The request doesn't comply with the IAM tag policy. Correct your request // and then retry it. ErrCodeTagPolicyException = "TagPolicy" // ErrCodeThrottledException for service response error code // "Throttled". // // Indicates that the rate at which requests have been submitted for this action // exceeds the limit for your account. ErrCodeThrottledException = "Throttled" // ErrCodeTopicLimitExceededException for service response error code // "TopicLimitExceeded". // // Indicates that the customer already owns the maximum allowed number of topics. ErrCodeTopicLimitExceededException = "TopicLimitExceeded" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddPermissionInput ¶
type AddPermissionInput struct { // The AWS account IDs of the users (principals) who will be given access to // the specified actions. The users must have AWS accounts, but do not need // to be signed up for this service. // // AWSAccountId is a required field AWSAccountId []string `type:"list" required:"true"` // The action you want to allow for the specified principal(s). // // Valid values: Any Amazon SNS action name, for example Publish. // // ActionName is a required field ActionName []string `type:"list" required:"true"` // A unique identifier for the new policy statement. // // Label is a required field Label *string `type:"string" required:"true"` // The ARN of the topic whose access control policy you wish to modify. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
func (AddPermissionInput) String ¶
func (s AddPermissionInput) String() string
String returns the string representation
func (*AddPermissionInput) Validate ¶
func (s *AddPermissionInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type AddPermissionOutput ¶
type AddPermissionOutput struct {
// contains filtered or unexported fields
}
func (AddPermissionOutput) String ¶
func (s AddPermissionOutput) String() string
String returns the string representation
type AddPermissionRequest ¶
type AddPermissionRequest struct { *aws.Request Input *AddPermissionInput Copy func(*AddPermissionInput) AddPermissionRequest }
AddPermissionRequest is the request type for the AddPermission API operation.
func (AddPermissionRequest) Send ¶
func (r AddPermissionRequest) Send(ctx context.Context) (*AddPermissionResponse, error)
Send marshals and sends the AddPermission API request.
type AddPermissionResponse ¶ added in v0.9.0
type AddPermissionResponse struct { *AddPermissionOutput // contains filtered or unexported fields }
AddPermissionResponse is the response type for the AddPermission API operation.
func (*AddPermissionResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *AddPermissionResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the AddPermission request.
type CheckIfPhoneNumberIsOptedOutInput ¶
type CheckIfPhoneNumberIsOptedOutInput struct { // The phone number for which you want to check the opt out status. // // PhoneNumber is a required field PhoneNumber *string `locationName:"phoneNumber" type:"string" required:"true"` // contains filtered or unexported fields }
The input for the CheckIfPhoneNumberIsOptedOut action.
func (CheckIfPhoneNumberIsOptedOutInput) String ¶
func (s CheckIfPhoneNumberIsOptedOutInput) String() string
String returns the string representation
func (*CheckIfPhoneNumberIsOptedOutInput) Validate ¶
func (s *CheckIfPhoneNumberIsOptedOutInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type CheckIfPhoneNumberIsOptedOutOutput ¶
type CheckIfPhoneNumberIsOptedOutOutput struct { // Indicates whether the phone number is opted out: // // * true – The phone number is opted out, meaning you cannot publish SMS // messages to it. // // * false – The phone number is opted in, meaning you can publish SMS // messages to it. IsOptedOut *bool `locationName:"isOptedOut" type:"boolean"` // contains filtered or unexported fields }
The response from the CheckIfPhoneNumberIsOptedOut action.
func (CheckIfPhoneNumberIsOptedOutOutput) String ¶
func (s CheckIfPhoneNumberIsOptedOutOutput) String() string
String returns the string representation
type CheckIfPhoneNumberIsOptedOutRequest ¶
type CheckIfPhoneNumberIsOptedOutRequest struct { *aws.Request Input *CheckIfPhoneNumberIsOptedOutInput Copy func(*CheckIfPhoneNumberIsOptedOutInput) CheckIfPhoneNumberIsOptedOutRequest }
CheckIfPhoneNumberIsOptedOutRequest is the request type for the CheckIfPhoneNumberIsOptedOut API operation.
func (CheckIfPhoneNumberIsOptedOutRequest) Send ¶
func (r CheckIfPhoneNumberIsOptedOutRequest) Send(ctx context.Context) (*CheckIfPhoneNumberIsOptedOutResponse, error)
Send marshals and sends the CheckIfPhoneNumberIsOptedOut API request.
type CheckIfPhoneNumberIsOptedOutResponse ¶ added in v0.9.0
type CheckIfPhoneNumberIsOptedOutResponse struct { *CheckIfPhoneNumberIsOptedOutOutput // contains filtered or unexported fields }
CheckIfPhoneNumberIsOptedOutResponse is the response type for the CheckIfPhoneNumberIsOptedOut API operation.
func (*CheckIfPhoneNumberIsOptedOutResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *CheckIfPhoneNumberIsOptedOutResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the CheckIfPhoneNumberIsOptedOut request.
type Client ¶ added in v0.9.0
Client provides the API operation methods for making requests to Amazon SNS. 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 := sns.New(myConfig)
func (*Client) AddPermissionRequest ¶ added in v0.9.0
func (c *Client) AddPermissionRequest(input *AddPermissionInput) AddPermissionRequest
AddPermissionRequest returns a request value for making API operation for Amazon Simple Notification Service.
Adds a statement to a topic's access control policy, granting access for the specified AWS accounts to the specified actions.
// Example sending a request using AddPermissionRequest. req := client.AddPermissionRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/AddPermission
func (*Client) CheckIfPhoneNumberIsOptedOutRequest ¶ added in v0.9.0
func (c *Client) CheckIfPhoneNumberIsOptedOutRequest(input *CheckIfPhoneNumberIsOptedOutInput) CheckIfPhoneNumberIsOptedOutRequest
CheckIfPhoneNumberIsOptedOutRequest returns a request value for making API operation for Amazon Simple Notification Service.
Accepts a phone number and indicates whether the phone holder has opted out of receiving SMS messages from your account. You cannot send SMS messages to a number that is opted out.
To resume sending messages, you can opt in the number by using the OptInPhoneNumber action.
// Example sending a request using CheckIfPhoneNumberIsOptedOutRequest. req := client.CheckIfPhoneNumberIsOptedOutRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/CheckIfPhoneNumberIsOptedOut
func (*Client) ConfirmSubscriptionRequest ¶ added in v0.9.0
func (c *Client) ConfirmSubscriptionRequest(input *ConfirmSubscriptionInput) ConfirmSubscriptionRequest
ConfirmSubscriptionRequest returns a request value for making API operation for Amazon Simple Notification Service.
Verifies an endpoint owner's intent to receive messages by validating the token sent to the endpoint by an earlier Subscribe action. If the token is valid, the action creates a new subscription and returns its Amazon Resource Name (ARN). This call requires an AWS signature only when the AuthenticateOnUnsubscribe flag is set to "true".
// Example sending a request using ConfirmSubscriptionRequest. req := client.ConfirmSubscriptionRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ConfirmSubscription
func (*Client) CreatePlatformApplicationRequest ¶ added in v0.9.0
func (c *Client) CreatePlatformApplicationRequest(input *CreatePlatformApplicationInput) CreatePlatformApplicationRequest
CreatePlatformApplicationRequest returns a request value for making API operation for Amazon Simple Notification Service.
Creates a platform application object for one of the supported push notification services, such as APNS and FCM, to which devices and mobile apps may register. You must specify PlatformPrincipal and PlatformCredential attributes when using the CreatePlatformApplication action. The PlatformPrincipal is received from the notification service. For APNS/APNS_SANDBOX, PlatformPrincipal is "SSL certificate". For FCM, PlatformPrincipal is not applicable. For ADM, PlatformPrincipal is "client id". The PlatformCredential is also received from the notification service. For WNS, PlatformPrincipal is "Package Security Identifier". For MPNS, PlatformPrincipal is "TLS certificate". For Baidu, PlatformPrincipal is "API key".
For APNS/APNS_SANDBOX, PlatformCredential is "private key". For FCM, PlatformCredential is "API key". For ADM, PlatformCredential is "client secret". For WNS, PlatformCredential is "secret key". For MPNS, PlatformCredential is "private key". For Baidu, PlatformCredential is "secret key". The PlatformApplicationArn that is returned when using CreatePlatformApplication is then used as an attribute for the CreatePlatformEndpoint action.
// Example sending a request using CreatePlatformApplicationRequest. req := client.CreatePlatformApplicationRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/CreatePlatformApplication
func (*Client) CreatePlatformEndpointRequest ¶ added in v0.9.0
func (c *Client) CreatePlatformEndpointRequest(input *CreatePlatformEndpointInput) CreatePlatformEndpointRequest
CreatePlatformEndpointRequest returns a request value for making API operation for Amazon Simple Notification Service.
Creates an endpoint for a device and mobile app on one of the supported push notification services, such as FCM and APNS. CreatePlatformEndpoint requires the PlatformApplicationArn that is returned from CreatePlatformApplication. The EndpointArn that is returned when using CreatePlatformEndpoint can then be used by the Publish action to send a message to a mobile app or by the Subscribe action for subscription to a topic. The CreatePlatformEndpoint action is idempotent, so if the requester already owns an endpoint with the same device token and attributes, that endpoint's ARN is returned without creating a new endpoint. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
When using CreatePlatformEndpoint with Baidu, two attributes must be provided: ChannelId and UserId. The token field must also contain the ChannelId. For more information, see Creating an Amazon SNS Endpoint for Baidu (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePushBaiduEndpoint.html).
// Example sending a request using CreatePlatformEndpointRequest. req := client.CreatePlatformEndpointRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/CreatePlatformEndpoint
func (*Client) CreateTopicRequest ¶ added in v0.9.0
func (c *Client) CreateTopicRequest(input *CreateTopicInput) CreateTopicRequest
CreateTopicRequest returns a request value for making API operation for Amazon Simple Notification Service.
Creates a topic to which notifications can be published. Users can create at most 100,000 topics. For more information, see https://aws.amazon.com/sns (http://aws.amazon.com/sns/). This action is idempotent, so if the requester already owns a topic with the specified name, that topic's ARN is returned without creating a new topic.
// Example sending a request using CreateTopicRequest. req := client.CreateTopicRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/CreateTopic
func (*Client) DeleteEndpointRequest ¶ added in v0.9.0
func (c *Client) DeleteEndpointRequest(input *DeleteEndpointInput) DeleteEndpointRequest
DeleteEndpointRequest returns a request value for making API operation for Amazon Simple Notification Service.
Deletes the endpoint for a device and mobile app from Amazon SNS. This action is idempotent. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
When you delete an endpoint that is also subscribed to a topic, then you must also unsubscribe the endpoint from the topic.
// Example sending a request using DeleteEndpointRequest. req := client.DeleteEndpointRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/DeleteEndpoint
func (*Client) DeletePlatformApplicationRequest ¶ added in v0.9.0
func (c *Client) DeletePlatformApplicationRequest(input *DeletePlatformApplicationInput) DeletePlatformApplicationRequest
DeletePlatformApplicationRequest returns a request value for making API operation for Amazon Simple Notification Service.
Deletes a platform application object for one of the supported push notification services, such as APNS and FCM. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
// Example sending a request using DeletePlatformApplicationRequest. req := client.DeletePlatformApplicationRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/DeletePlatformApplication
func (*Client) DeleteTopicRequest ¶ added in v0.9.0
func (c *Client) DeleteTopicRequest(input *DeleteTopicInput) DeleteTopicRequest
DeleteTopicRequest returns a request value for making API operation for Amazon Simple Notification Service.
Deletes a topic and all its subscriptions. Deleting a topic might prevent some messages previously sent to the topic from being delivered to subscribers. This action is idempotent, so deleting a topic that does not exist does not result in an error.
// Example sending a request using DeleteTopicRequest. req := client.DeleteTopicRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/DeleteTopic
func (*Client) GetEndpointAttributesRequest ¶ added in v0.9.0
func (c *Client) GetEndpointAttributesRequest(input *GetEndpointAttributesInput) GetEndpointAttributesRequest
GetEndpointAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Retrieves the endpoint attributes for a device on one of the supported push notification services, such as FCM and APNS. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
// Example sending a request using GetEndpointAttributesRequest. req := client.GetEndpointAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/GetEndpointAttributes
func (*Client) GetPlatformApplicationAttributesRequest ¶ added in v0.9.0
func (c *Client) GetPlatformApplicationAttributesRequest(input *GetPlatformApplicationAttributesInput) GetPlatformApplicationAttributesRequest
GetPlatformApplicationAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Retrieves the attributes of the platform application object for the supported push notification services, such as APNS and FCM. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
// Example sending a request using GetPlatformApplicationAttributesRequest. req := client.GetPlatformApplicationAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/GetPlatformApplicationAttributes
func (*Client) GetSMSAttributesRequest ¶ added in v0.9.0
func (c *Client) GetSMSAttributesRequest(input *GetSMSAttributesInput) GetSMSAttributesRequest
GetSMSAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Returns the settings for sending SMS messages from your account.
These settings are set with the SetSMSAttributes action.
// Example sending a request using GetSMSAttributesRequest. req := client.GetSMSAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/GetSMSAttributes
func (*Client) GetSubscriptionAttributesRequest ¶ added in v0.9.0
func (c *Client) GetSubscriptionAttributesRequest(input *GetSubscriptionAttributesInput) GetSubscriptionAttributesRequest
GetSubscriptionAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Returns all of the properties of a subscription.
// Example sending a request using GetSubscriptionAttributesRequest. req := client.GetSubscriptionAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/GetSubscriptionAttributes
func (*Client) GetTopicAttributesRequest ¶ added in v0.9.0
func (c *Client) GetTopicAttributesRequest(input *GetTopicAttributesInput) GetTopicAttributesRequest
GetTopicAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Returns all of the properties of a topic. Topic properties returned might differ based on the authorization of the user.
// Example sending a request using GetTopicAttributesRequest. req := client.GetTopicAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/GetTopicAttributes
func (*Client) ListEndpointsByPlatformApplicationRequest ¶ added in v0.9.0
func (c *Client) ListEndpointsByPlatformApplicationRequest(input *ListEndpointsByPlatformApplicationInput) ListEndpointsByPlatformApplicationRequest
ListEndpointsByPlatformApplicationRequest returns a request value for making API operation for Amazon Simple Notification Service.
Lists the endpoints and endpoint attributes for devices in a supported push notification service, such as FCM and APNS. The results for ListEndpointsByPlatformApplication are paginated and return a limited list of endpoints, up to 100. If additional records are available after the first page results, then a NextToken string will be returned. To receive the next page, you call ListEndpointsByPlatformApplication again using the NextToken string received from the previous call. When there are no more records to return, NextToken will be null. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
This action is throttled at 30 transactions per second (TPS).
// Example sending a request using ListEndpointsByPlatformApplicationRequest. req := client.ListEndpointsByPlatformApplicationRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ListEndpointsByPlatformApplication
func (*Client) ListPhoneNumbersOptedOutRequest ¶ added in v0.9.0
func (c *Client) ListPhoneNumbersOptedOutRequest(input *ListPhoneNumbersOptedOutInput) ListPhoneNumbersOptedOutRequest
ListPhoneNumbersOptedOutRequest returns a request value for making API operation for Amazon Simple Notification Service.
Returns a list of phone numbers that are opted out, meaning you cannot send SMS messages to them.
The results for ListPhoneNumbersOptedOut are paginated, and each page returns up to 100 phone numbers. If additional phone numbers are available after the first page of results, then a NextToken string will be returned. To receive the next page, you call ListPhoneNumbersOptedOut again using the NextToken string received from the previous call. When there are no more records to return, NextToken will be null.
// Example sending a request using ListPhoneNumbersOptedOutRequest. req := client.ListPhoneNumbersOptedOutRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ListPhoneNumbersOptedOut
func (*Client) ListPlatformApplicationsRequest ¶ added in v0.9.0
func (c *Client) ListPlatformApplicationsRequest(input *ListPlatformApplicationsInput) ListPlatformApplicationsRequest
ListPlatformApplicationsRequest returns a request value for making API operation for Amazon Simple Notification Service.
Lists the platform application objects for the supported push notification services, such as APNS and FCM. The results for ListPlatformApplications are paginated and return a limited list of applications, up to 100. If additional records are available after the first page results, then a NextToken string will be returned. To receive the next page, you call ListPlatformApplications using the NextToken string received from the previous call. When there are no more records to return, NextToken will be null. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
This action is throttled at 15 transactions per second (TPS).
// Example sending a request using ListPlatformApplicationsRequest. req := client.ListPlatformApplicationsRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ListPlatformApplications
func (*Client) ListSubscriptionsByTopicRequest ¶ added in v0.9.0
func (c *Client) ListSubscriptionsByTopicRequest(input *ListSubscriptionsByTopicInput) ListSubscriptionsByTopicRequest
ListSubscriptionsByTopicRequest returns a request value for making API operation for Amazon Simple Notification Service.
Returns a list of the subscriptions to a specific topic. Each call returns a limited list of subscriptions, up to 100. If there are more subscriptions, a NextToken is also returned. Use the NextToken parameter in a new ListSubscriptionsByTopic call to get further results.
This action is throttled at 30 transactions per second (TPS).
// Example sending a request using ListSubscriptionsByTopicRequest. req := client.ListSubscriptionsByTopicRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ListSubscriptionsByTopic
func (*Client) ListSubscriptionsRequest ¶ added in v0.9.0
func (c *Client) ListSubscriptionsRequest(input *ListSubscriptionsInput) ListSubscriptionsRequest
ListSubscriptionsRequest returns a request value for making API operation for Amazon Simple Notification Service.
Returns a list of the requester's subscriptions. Each call returns a limited list of subscriptions, up to 100. If there are more subscriptions, a NextToken is also returned. Use the NextToken parameter in a new ListSubscriptions call to get further results.
This action is throttled at 30 transactions per second (TPS).
// Example sending a request using ListSubscriptionsRequest. req := client.ListSubscriptionsRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ListSubscriptions
func (*Client) ListTagsForResourceRequest ¶ added in v0.9.0
func (c *Client) ListTagsForResourceRequest(input *ListTagsForResourceInput) ListTagsForResourceRequest
ListTagsForResourceRequest returns a request value for making API operation for Amazon Simple Notification Service.
List all tags added to the specified Amazon SNS topic. For an overview, see Amazon SNS Tags (https://docs.aws.amazon.com/sns/latest/dg/sns-tags.html) in the Amazon Simple Notification Service Developer Guide.
// Example sending a request using ListTagsForResourceRequest. req := client.ListTagsForResourceRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ListTagsForResource
func (*Client) ListTopicsRequest ¶ added in v0.9.0
func (c *Client) ListTopicsRequest(input *ListTopicsInput) ListTopicsRequest
ListTopicsRequest returns a request value for making API operation for Amazon Simple Notification Service.
Returns a list of the requester's topics. Each call returns a limited list of topics, up to 100. If there are more topics, a NextToken is also returned. Use the NextToken parameter in a new ListTopics call to get further results.
This action is throttled at 30 transactions per second (TPS).
// Example sending a request using ListTopicsRequest. req := client.ListTopicsRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/ListTopics
func (*Client) OptInPhoneNumberRequest ¶ added in v0.9.0
func (c *Client) OptInPhoneNumberRequest(input *OptInPhoneNumberInput) OptInPhoneNumberRequest
OptInPhoneNumberRequest returns a request value for making API operation for Amazon Simple Notification Service.
Use this request to opt in a phone number that is opted out, which enables you to resume sending SMS messages to the number.
You can opt in a phone number only once every 30 days.
// Example sending a request using OptInPhoneNumberRequest. req := client.OptInPhoneNumberRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/OptInPhoneNumber
func (*Client) PublishRequest ¶ added in v0.9.0
func (c *Client) PublishRequest(input *PublishInput) PublishRequest
PublishRequest returns a request value for making API operation for Amazon Simple Notification Service.
Sends a message to an Amazon SNS topic or sends a text message (SMS message) directly to a phone number.
If you send a message to a topic, Amazon SNS delivers the message to each endpoint that is subscribed to the topic. The format of the message depends on the notification protocol for each subscribed endpoint.
When a messageId is returned, the message has been saved and Amazon SNS will attempt to deliver it shortly.
To use the Publish action for sending a message to a mobile endpoint, such as an app on a Kindle device or mobile phone, you must specify the EndpointArn for the TargetArn parameter. The EndpointArn is returned when making a call with the CreatePlatformEndpoint action.
For more information about formatting messages, see Send Custom Platform-Specific Payloads in Messages to Mobile Devices (https://docs.aws.amazon.com/sns/latest/dg/mobile-push-send-custommessage.html).
// Example sending a request using PublishRequest. req := client.PublishRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/Publish
func (*Client) RemovePermissionRequest ¶ added in v0.9.0
func (c *Client) RemovePermissionRequest(input *RemovePermissionInput) RemovePermissionRequest
RemovePermissionRequest returns a request value for making API operation for Amazon Simple Notification Service.
Removes a statement from a topic's access control policy.
// Example sending a request using RemovePermissionRequest. req := client.RemovePermissionRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/RemovePermission
func (*Client) SetEndpointAttributesRequest ¶ added in v0.9.0
func (c *Client) SetEndpointAttributesRequest(input *SetEndpointAttributesInput) SetEndpointAttributesRequest
SetEndpointAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Sets the attributes for an endpoint for a device on one of the supported push notification services, such as FCM and APNS. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html).
// Example sending a request using SetEndpointAttributesRequest. req := client.SetEndpointAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/SetEndpointAttributes
func (*Client) SetPlatformApplicationAttributesRequest ¶ added in v0.9.0
func (c *Client) SetPlatformApplicationAttributesRequest(input *SetPlatformApplicationAttributesInput) SetPlatformApplicationAttributesRequest
SetPlatformApplicationAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Sets the attributes of the platform application object for the supported push notification services, such as APNS and FCM. For more information, see Using Amazon SNS Mobile Push Notifications (https://docs.aws.amazon.com/sns/latest/dg/SNSMobilePush.html). For information on configuring attributes for message delivery status, see Using Amazon SNS Application Attributes for Message Delivery Status (https://docs.aws.amazon.com/sns/latest/dg/sns-msg-status.html).
// Example sending a request using SetPlatformApplicationAttributesRequest. req := client.SetPlatformApplicationAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/SetPlatformApplicationAttributes
func (*Client) SetSMSAttributesRequest ¶ added in v0.9.0
func (c *Client) SetSMSAttributesRequest(input *SetSMSAttributesInput) SetSMSAttributesRequest
SetSMSAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Use this request to set the default settings for sending SMS messages and receiving daily SMS usage reports.
You can override some of these settings for a single message when you use the Publish action with the MessageAttributes.entry.N parameter. For more information, see Sending an SMS Message (https://docs.aws.amazon.com/sns/latest/dg/sms_publish-to-phone.html) in the Amazon SNS Developer Guide.
// Example sending a request using SetSMSAttributesRequest. req := client.SetSMSAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/SetSMSAttributes
func (*Client) SetSubscriptionAttributesRequest ¶ added in v0.9.0
func (c *Client) SetSubscriptionAttributesRequest(input *SetSubscriptionAttributesInput) SetSubscriptionAttributesRequest
SetSubscriptionAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Allows a subscription owner to set an attribute of the subscription to a new value.
// Example sending a request using SetSubscriptionAttributesRequest. req := client.SetSubscriptionAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/SetSubscriptionAttributes
func (*Client) SetTopicAttributesRequest ¶ added in v0.9.0
func (c *Client) SetTopicAttributesRequest(input *SetTopicAttributesInput) SetTopicAttributesRequest
SetTopicAttributesRequest returns a request value for making API operation for Amazon Simple Notification Service.
Allows a topic owner to set an attribute of the topic to a new value.
// Example sending a request using SetTopicAttributesRequest. req := client.SetTopicAttributesRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/SetTopicAttributes
func (*Client) SubscribeRequest ¶ added in v0.9.0
func (c *Client) SubscribeRequest(input *SubscribeInput) SubscribeRequest
SubscribeRequest returns a request value for making API operation for Amazon Simple Notification Service.
Prepares to subscribe an endpoint by sending the endpoint a confirmation message. To actually create a subscription, the endpoint owner must call the ConfirmSubscription action with the token from the confirmation message. Confirmation tokens are valid for three days.
This action is throttled at 100 transactions per second (TPS).
// Example sending a request using SubscribeRequest. req := client.SubscribeRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/Subscribe
func (*Client) TagResourceRequest ¶ added in v0.9.0
func (c *Client) TagResourceRequest(input *TagResourceInput) TagResourceRequest
TagResourceRequest returns a request value for making API operation for Amazon Simple Notification Service.
Add tags to the specified Amazon SNS topic. For an overview, see Amazon SNS Tags (https://docs.aws.amazon.com/sns/latest/dg/sns-tags.html) in the Amazon SNS Developer Guide.
When you use topic tags, keep the following guidelines in mind:
Adding more than 50 tags to a topic isn't recommended.
Tags don't have any semantic meaning. Amazon SNS interprets tags as character strings.
Tags are case-sensitive.
A new tag with a key identical to that of an existing tag overwrites the existing tag.
Tagging actions are limited to 10 TPS per AWS account, per AWS region. If your application requires a higher throughput, file a technical support request (https://console.aws.amazon.com/support/home#/case/create?issueType=technical).
// Example sending a request using TagResourceRequest. req := client.TagResourceRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/TagResource
func (*Client) UnsubscribeRequest ¶ added in v0.9.0
func (c *Client) UnsubscribeRequest(input *UnsubscribeInput) UnsubscribeRequest
UnsubscribeRequest returns a request value for making API operation for Amazon Simple Notification Service.
Deletes a subscription. If the subscription requires authentication for deletion, only the owner of the subscription or the topic's owner can unsubscribe, and an AWS signature is required. If the Unsubscribe call does not require authentication and the requester is not the subscription owner, a final cancellation message is delivered to the endpoint, so that the endpoint owner can easily resubscribe to the topic if the Unsubscribe request was unintended.
This action is throttled at 100 transactions per second (TPS).
// Example sending a request using UnsubscribeRequest. req := client.UnsubscribeRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/Unsubscribe
func (*Client) UntagResourceRequest ¶ added in v0.9.0
func (c *Client) UntagResourceRequest(input *UntagResourceInput) UntagResourceRequest
UntagResourceRequest returns a request value for making API operation for Amazon Simple Notification Service.
Remove tags from the specified Amazon SNS topic. For an overview, see Amazon SNS Tags (https://docs.aws.amazon.com/sns/latest/dg/sns-tags.html) in the Amazon SNS Developer Guide.
// Example sending a request using UntagResourceRequest. req := client.UntagResourceRequest(params) resp, err := req.Send(context.TODO()) if err == nil { fmt.Println(resp) }
Please also see https://docs.aws.amazon.com/goto/WebAPI/sns-2010-03-31/UntagResource
type ConfirmSubscriptionInput ¶
type ConfirmSubscriptionInput struct { // Disallows unauthenticated unsubscribes of the subscription. If the value // of this parameter is true and the request has an AWS signature, then only // the topic owner and the subscription owner can unsubscribe the endpoint. // The unsubscribe action requires AWS authentication. AuthenticateOnUnsubscribe *string `type:"string"` // Short-lived token sent to an endpoint during the Subscribe action. // // Token is a required field Token *string `type:"string" required:"true"` // The ARN of the topic for which you wish to confirm a subscription. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for ConfirmSubscription action.
func (ConfirmSubscriptionInput) String ¶
func (s ConfirmSubscriptionInput) String() string
String returns the string representation
func (*ConfirmSubscriptionInput) Validate ¶
func (s *ConfirmSubscriptionInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type ConfirmSubscriptionOutput ¶
type ConfirmSubscriptionOutput struct { // The ARN of the created subscription. SubscriptionArn *string `type:"string"` // contains filtered or unexported fields }
Response for ConfirmSubscriptions action.
func (ConfirmSubscriptionOutput) String ¶
func (s ConfirmSubscriptionOutput) String() string
String returns the string representation
type ConfirmSubscriptionRequest ¶
type ConfirmSubscriptionRequest struct { *aws.Request Input *ConfirmSubscriptionInput Copy func(*ConfirmSubscriptionInput) ConfirmSubscriptionRequest }
ConfirmSubscriptionRequest is the request type for the ConfirmSubscription API operation.
func (ConfirmSubscriptionRequest) Send ¶
func (r ConfirmSubscriptionRequest) Send(ctx context.Context) (*ConfirmSubscriptionResponse, error)
Send marshals and sends the ConfirmSubscription API request.
type ConfirmSubscriptionResponse ¶ added in v0.9.0
type ConfirmSubscriptionResponse struct { *ConfirmSubscriptionOutput // contains filtered or unexported fields }
ConfirmSubscriptionResponse is the response type for the ConfirmSubscription API operation.
func (*ConfirmSubscriptionResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ConfirmSubscriptionResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ConfirmSubscription request.
type CreatePlatformApplicationInput ¶
type CreatePlatformApplicationInput struct { // For a list of attributes, see SetPlatformApplicationAttributes (https://docs.aws.amazon.com/sns/latest/api/API_SetPlatformApplicationAttributes.html) // // Attributes is a required field Attributes map[string]string `type:"map" required:"true"` // Application names must be made up of only uppercase and lowercase ASCII letters, // numbers, underscores, hyphens, and periods, and must be between 1 and 256 // characters long. // // Name is a required field Name *string `type:"string" required:"true"` // The following platforms are supported: ADM (Amazon Device Messaging), APNS // (Apple Push Notification Service), APNS_SANDBOX, and FCM (Firebase Cloud // Messaging). // // Platform is a required field Platform *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for CreatePlatformApplication action.
func (CreatePlatformApplicationInput) String ¶
func (s CreatePlatformApplicationInput) String() string
String returns the string representation
func (*CreatePlatformApplicationInput) Validate ¶
func (s *CreatePlatformApplicationInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type CreatePlatformApplicationOutput ¶
type CreatePlatformApplicationOutput struct { // PlatformApplicationArn is returned. PlatformApplicationArn *string `type:"string"` // contains filtered or unexported fields }
Response from CreatePlatformApplication action.
func (CreatePlatformApplicationOutput) String ¶
func (s CreatePlatformApplicationOutput) String() string
String returns the string representation
type CreatePlatformApplicationRequest ¶
type CreatePlatformApplicationRequest struct { *aws.Request Input *CreatePlatformApplicationInput Copy func(*CreatePlatformApplicationInput) CreatePlatformApplicationRequest }
CreatePlatformApplicationRequest is the request type for the CreatePlatformApplication API operation.
func (CreatePlatformApplicationRequest) Send ¶
func (r CreatePlatformApplicationRequest) Send(ctx context.Context) (*CreatePlatformApplicationResponse, error)
Send marshals and sends the CreatePlatformApplication API request.
type CreatePlatformApplicationResponse ¶ added in v0.9.0
type CreatePlatformApplicationResponse struct { *CreatePlatformApplicationOutput // contains filtered or unexported fields }
CreatePlatformApplicationResponse is the response type for the CreatePlatformApplication API operation.
func (*CreatePlatformApplicationResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *CreatePlatformApplicationResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the CreatePlatformApplication request.
type CreatePlatformEndpointInput ¶
type CreatePlatformEndpointInput struct { // For a list of attributes, see SetEndpointAttributes (https://docs.aws.amazon.com/sns/latest/api/API_SetEndpointAttributes.html). Attributes map[string]string `type:"map"` // Arbitrary user data to associate with the endpoint. Amazon SNS does not use // this data. The data must be in UTF-8 format and less than 2KB. CustomUserData *string `type:"string"` // PlatformApplicationArn returned from CreatePlatformApplication is used to // create a an endpoint. // // PlatformApplicationArn is a required field PlatformApplicationArn *string `type:"string" required:"true"` // Unique identifier created by the notification service for an app on a device. // The specific name for Token will vary, depending on which notification service // is being used. For example, when using APNS as the notification service, // you need the device token. Alternatively, when using FCM or ADM, the device // token equivalent is called the registration ID. // // Token is a required field Token *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for CreatePlatformEndpoint action.
func (CreatePlatformEndpointInput) String ¶
func (s CreatePlatformEndpointInput) String() string
String returns the string representation
func (*CreatePlatformEndpointInput) Validate ¶
func (s *CreatePlatformEndpointInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type CreatePlatformEndpointOutput ¶
type CreatePlatformEndpointOutput struct { // EndpointArn returned from CreateEndpoint action. EndpointArn *string `type:"string"` // contains filtered or unexported fields }
Response from CreateEndpoint action.
func (CreatePlatformEndpointOutput) String ¶
func (s CreatePlatformEndpointOutput) String() string
String returns the string representation
type CreatePlatformEndpointRequest ¶
type CreatePlatformEndpointRequest struct { *aws.Request Input *CreatePlatformEndpointInput Copy func(*CreatePlatformEndpointInput) CreatePlatformEndpointRequest }
CreatePlatformEndpointRequest is the request type for the CreatePlatformEndpoint API operation.
func (CreatePlatformEndpointRequest) Send ¶
func (r CreatePlatformEndpointRequest) Send(ctx context.Context) (*CreatePlatformEndpointResponse, error)
Send marshals and sends the CreatePlatformEndpoint API request.
type CreatePlatformEndpointResponse ¶ added in v0.9.0
type CreatePlatformEndpointResponse struct { *CreatePlatformEndpointOutput // contains filtered or unexported fields }
CreatePlatformEndpointResponse is the response type for the CreatePlatformEndpoint API operation.
func (*CreatePlatformEndpointResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *CreatePlatformEndpointResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the CreatePlatformEndpoint request.
type CreateTopicInput ¶
type CreateTopicInput struct { // A map of attributes with their corresponding values. // // The following lists the names, descriptions, and values of the special request // parameters that the CreateTopic action uses: // // * DeliveryPolicy – The policy that defines how Amazon SNS retries failed // deliveries to HTTP/S endpoints. // // * DisplayName – The display name to use for a topic with SMS subscriptions. // // * Policy – The policy that defines who can access your topic. By default, // only the topic owner can publish or subscribe to the topic. // // The following attribute applies only to server-side-encryption (https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html): // // * KmsMasterKeyId - The ID of an AWS-managed customer master key (CMK) // for Amazon SNS or a custom CMK. For more information, see Key Terms (https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html#sse-key-terms). // For more examples, see KeyId (https://docs.aws.amazon.com/kms/latest/APIReference/API_DescribeKey.html#API_DescribeKey_RequestParameters) // in the AWS Key Management Service API Reference. Attributes map[string]string `type:"map"` // The name of the topic you want to create. // // Constraints: Topic names must be made up of only uppercase and lowercase // ASCII letters, numbers, underscores, and hyphens, and must be between 1 and // 256 characters long. // // Name is a required field Name *string `type:"string" required:"true"` // The list of tags to add to a new topic. // // To be able to tag a topic on creation, you must have the sns:CreateTopic // and sns:TagResource permissions. Tags []Tag `type:"list"` // contains filtered or unexported fields }
Input for CreateTopic action.
func (CreateTopicInput) String ¶
func (s CreateTopicInput) String() string
String returns the string representation
func (*CreateTopicInput) Validate ¶
func (s *CreateTopicInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type CreateTopicOutput ¶
type CreateTopicOutput struct { // The Amazon Resource Name (ARN) assigned to the created topic. TopicArn *string `type:"string"` // contains filtered or unexported fields }
Response from CreateTopic action.
func (CreateTopicOutput) String ¶
func (s CreateTopicOutput) String() string
String returns the string representation
type CreateTopicRequest ¶
type CreateTopicRequest struct { *aws.Request Input *CreateTopicInput Copy func(*CreateTopicInput) CreateTopicRequest }
CreateTopicRequest is the request type for the CreateTopic API operation.
func (CreateTopicRequest) Send ¶
func (r CreateTopicRequest) Send(ctx context.Context) (*CreateTopicResponse, error)
Send marshals and sends the CreateTopic API request.
type CreateTopicResponse ¶ added in v0.9.0
type CreateTopicResponse struct { *CreateTopicOutput // contains filtered or unexported fields }
CreateTopicResponse is the response type for the CreateTopic API operation.
func (*CreateTopicResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *CreateTopicResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the CreateTopic request.
type DeleteEndpointInput ¶
type DeleteEndpointInput struct { // EndpointArn of endpoint to delete. // // EndpointArn is a required field EndpointArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for DeleteEndpoint action.
func (DeleteEndpointInput) String ¶
func (s DeleteEndpointInput) String() string
String returns the string representation
func (*DeleteEndpointInput) Validate ¶
func (s *DeleteEndpointInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type DeleteEndpointOutput ¶
type DeleteEndpointOutput struct {
// contains filtered or unexported fields
}
func (DeleteEndpointOutput) String ¶
func (s DeleteEndpointOutput) String() string
String returns the string representation
type DeleteEndpointRequest ¶
type DeleteEndpointRequest struct { *aws.Request Input *DeleteEndpointInput Copy func(*DeleteEndpointInput) DeleteEndpointRequest }
DeleteEndpointRequest is the request type for the DeleteEndpoint API operation.
func (DeleteEndpointRequest) Send ¶
func (r DeleteEndpointRequest) Send(ctx context.Context) (*DeleteEndpointResponse, error)
Send marshals and sends the DeleteEndpoint API request.
type DeleteEndpointResponse ¶ added in v0.9.0
type DeleteEndpointResponse struct { *DeleteEndpointOutput // contains filtered or unexported fields }
DeleteEndpointResponse is the response type for the DeleteEndpoint API operation.
func (*DeleteEndpointResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *DeleteEndpointResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the DeleteEndpoint request.
type DeletePlatformApplicationInput ¶
type DeletePlatformApplicationInput struct { // PlatformApplicationArn of platform application object to delete. // // PlatformApplicationArn is a required field PlatformApplicationArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for DeletePlatformApplication action.
func (DeletePlatformApplicationInput) String ¶
func (s DeletePlatformApplicationInput) String() string
String returns the string representation
func (*DeletePlatformApplicationInput) Validate ¶
func (s *DeletePlatformApplicationInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type DeletePlatformApplicationOutput ¶
type DeletePlatformApplicationOutput struct {
// contains filtered or unexported fields
}
func (DeletePlatformApplicationOutput) String ¶
func (s DeletePlatformApplicationOutput) String() string
String returns the string representation
type DeletePlatformApplicationRequest ¶
type DeletePlatformApplicationRequest struct { *aws.Request Input *DeletePlatformApplicationInput Copy func(*DeletePlatformApplicationInput) DeletePlatformApplicationRequest }
DeletePlatformApplicationRequest is the request type for the DeletePlatformApplication API operation.
func (DeletePlatformApplicationRequest) Send ¶
func (r DeletePlatformApplicationRequest) Send(ctx context.Context) (*DeletePlatformApplicationResponse, error)
Send marshals and sends the DeletePlatformApplication API request.
type DeletePlatformApplicationResponse ¶ added in v0.9.0
type DeletePlatformApplicationResponse struct { *DeletePlatformApplicationOutput // contains filtered or unexported fields }
DeletePlatformApplicationResponse is the response type for the DeletePlatformApplication API operation.
func (*DeletePlatformApplicationResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *DeletePlatformApplicationResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the DeletePlatformApplication request.
type DeleteTopicInput ¶
type DeleteTopicInput struct { // The ARN of the topic you want to delete. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
func (DeleteTopicInput) String ¶
func (s DeleteTopicInput) String() string
String returns the string representation
func (*DeleteTopicInput) Validate ¶
func (s *DeleteTopicInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type DeleteTopicOutput ¶
type DeleteTopicOutput struct {
// contains filtered or unexported fields
}
func (DeleteTopicOutput) String ¶
func (s DeleteTopicOutput) String() string
String returns the string representation
type DeleteTopicRequest ¶
type DeleteTopicRequest struct { *aws.Request Input *DeleteTopicInput Copy func(*DeleteTopicInput) DeleteTopicRequest }
DeleteTopicRequest is the request type for the DeleteTopic API operation.
func (DeleteTopicRequest) Send ¶
func (r DeleteTopicRequest) Send(ctx context.Context) (*DeleteTopicResponse, error)
Send marshals and sends the DeleteTopic API request.
type DeleteTopicResponse ¶ added in v0.9.0
type DeleteTopicResponse struct { *DeleteTopicOutput // contains filtered or unexported fields }
DeleteTopicResponse is the response type for the DeleteTopic API operation.
func (*DeleteTopicResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *DeleteTopicResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the DeleteTopic request.
type Endpoint ¶
type Endpoint struct { // Attributes for endpoint. Attributes map[string]string `type:"map"` // EndpointArn for mobile app and device. EndpointArn *string `type:"string"` // contains filtered or unexported fields }
Endpoint for mobile app and device.
type GetEndpointAttributesInput ¶
type GetEndpointAttributesInput struct { // EndpointArn for GetEndpointAttributes input. // // EndpointArn is a required field EndpointArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for GetEndpointAttributes action.
func (GetEndpointAttributesInput) String ¶
func (s GetEndpointAttributesInput) String() string
String returns the string representation
func (*GetEndpointAttributesInput) Validate ¶
func (s *GetEndpointAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type GetEndpointAttributesOutput ¶
type GetEndpointAttributesOutput struct { // Attributes include the following: // // * CustomUserData – arbitrary user data to associate with the endpoint. // Amazon SNS does not use this data. The data must be in UTF-8 format and // less than 2KB. // // * Enabled – flag that enables/disables delivery to the endpoint. Amazon // SNS will set this to false when a notification service indicates to Amazon // SNS that the endpoint is invalid. Users can set it back to true, typically // after updating Token. // // * Token – device token, also referred to as a registration id, for an // app and mobile device. This is returned from the notification service // when an app and mobile device are registered with the notification service. // The device token for the iOS platform is returned in lowercase. Attributes map[string]string `type:"map"` // contains filtered or unexported fields }
Response from GetEndpointAttributes of the EndpointArn.
func (GetEndpointAttributesOutput) String ¶
func (s GetEndpointAttributesOutput) String() string
String returns the string representation
type GetEndpointAttributesRequest ¶
type GetEndpointAttributesRequest struct { *aws.Request Input *GetEndpointAttributesInput Copy func(*GetEndpointAttributesInput) GetEndpointAttributesRequest }
GetEndpointAttributesRequest is the request type for the GetEndpointAttributes API operation.
func (GetEndpointAttributesRequest) Send ¶
func (r GetEndpointAttributesRequest) Send(ctx context.Context) (*GetEndpointAttributesResponse, error)
Send marshals and sends the GetEndpointAttributes API request.
type GetEndpointAttributesResponse ¶ added in v0.9.0
type GetEndpointAttributesResponse struct { *GetEndpointAttributesOutput // contains filtered or unexported fields }
GetEndpointAttributesResponse is the response type for the GetEndpointAttributes API operation.
func (*GetEndpointAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *GetEndpointAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the GetEndpointAttributes request.
type GetPlatformApplicationAttributesInput ¶
type GetPlatformApplicationAttributesInput struct { // PlatformApplicationArn for GetPlatformApplicationAttributesInput. // // PlatformApplicationArn is a required field PlatformApplicationArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for GetPlatformApplicationAttributes action.
func (GetPlatformApplicationAttributesInput) String ¶
func (s GetPlatformApplicationAttributesInput) String() string
String returns the string representation
func (*GetPlatformApplicationAttributesInput) Validate ¶
func (s *GetPlatformApplicationAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type GetPlatformApplicationAttributesOutput ¶
type GetPlatformApplicationAttributesOutput struct { // Attributes include the following: // // * EventEndpointCreated – Topic ARN to which EndpointCreated event notifications // should be sent. // // * EventEndpointDeleted – Topic ARN to which EndpointDeleted event notifications // should be sent. // // * EventEndpointUpdated – Topic ARN to which EndpointUpdate event notifications // should be sent. // // * EventDeliveryFailure – Topic ARN to which DeliveryFailure event notifications // should be sent upon Direct Publish delivery failure (permanent) to one // of the application's endpoints. Attributes map[string]string `type:"map"` // contains filtered or unexported fields }
Response for GetPlatformApplicationAttributes action.
func (GetPlatformApplicationAttributesOutput) String ¶
func (s GetPlatformApplicationAttributesOutput) String() string
String returns the string representation
type GetPlatformApplicationAttributesRequest ¶
type GetPlatformApplicationAttributesRequest struct { *aws.Request Input *GetPlatformApplicationAttributesInput Copy func(*GetPlatformApplicationAttributesInput) GetPlatformApplicationAttributesRequest }
GetPlatformApplicationAttributesRequest is the request type for the GetPlatformApplicationAttributes API operation.
func (GetPlatformApplicationAttributesRequest) Send ¶
func (r GetPlatformApplicationAttributesRequest) Send(ctx context.Context) (*GetPlatformApplicationAttributesResponse, error)
Send marshals and sends the GetPlatformApplicationAttributes API request.
type GetPlatformApplicationAttributesResponse ¶ added in v0.9.0
type GetPlatformApplicationAttributesResponse struct { *GetPlatformApplicationAttributesOutput // contains filtered or unexported fields }
GetPlatformApplicationAttributesResponse is the response type for the GetPlatformApplicationAttributes API operation.
func (*GetPlatformApplicationAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *GetPlatformApplicationAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the GetPlatformApplicationAttributes request.
type GetSMSAttributesInput ¶
type GetSMSAttributesInput struct { // A list of the individual attribute names, such as MonthlySpendLimit, for // which you want values. // // For all attribute names, see SetSMSAttributes (https://docs.aws.amazon.com/sns/latest/api/API_SetSMSAttributes.html). // // If you don't use this parameter, Amazon SNS returns all SMS attributes. Attributes []string `locationName:"attributes" type:"list"` // contains filtered or unexported fields }
The input for the GetSMSAttributes request.
func (GetSMSAttributesInput) String ¶
func (s GetSMSAttributesInput) String() string
String returns the string representation
type GetSMSAttributesOutput ¶
type GetSMSAttributesOutput struct { // The SMS attribute names and their values. Attributes map[string]string `locationName:"attributes" type:"map"` // contains filtered or unexported fields }
The response from the GetSMSAttributes request.
func (GetSMSAttributesOutput) String ¶
func (s GetSMSAttributesOutput) String() string
String returns the string representation
type GetSMSAttributesRequest ¶
type GetSMSAttributesRequest struct { *aws.Request Input *GetSMSAttributesInput Copy func(*GetSMSAttributesInput) GetSMSAttributesRequest }
GetSMSAttributesRequest is the request type for the GetSMSAttributes API operation.
func (GetSMSAttributesRequest) Send ¶
func (r GetSMSAttributesRequest) Send(ctx context.Context) (*GetSMSAttributesResponse, error)
Send marshals and sends the GetSMSAttributes API request.
type GetSMSAttributesResponse ¶ added in v0.9.0
type GetSMSAttributesResponse struct { *GetSMSAttributesOutput // contains filtered or unexported fields }
GetSMSAttributesResponse is the response type for the GetSMSAttributes API operation.
func (*GetSMSAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *GetSMSAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the GetSMSAttributes request.
type GetSubscriptionAttributesInput ¶
type GetSubscriptionAttributesInput struct { // The ARN of the subscription whose properties you want to get. // // SubscriptionArn is a required field SubscriptionArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for GetSubscriptionAttributes.
func (GetSubscriptionAttributesInput) String ¶
func (s GetSubscriptionAttributesInput) String() string
String returns the string representation
func (*GetSubscriptionAttributesInput) Validate ¶
func (s *GetSubscriptionAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type GetSubscriptionAttributesOutput ¶
type GetSubscriptionAttributesOutput struct { // A map of the subscription's attributes. Attributes in this map include the // following: // // * ConfirmationWasAuthenticated – true if the subscription confirmation // request was authenticated. // // * DeliveryPolicy – The JSON serialization of the subscription's delivery // policy. // // * EffectiveDeliveryPolicy – The JSON serialization of the effective // delivery policy that takes into account the topic delivery policy and // account system defaults. // // * FilterPolicy – The filter policy JSON that is assigned to the subscription. // // * Owner – The AWS account ID of the subscription's owner. // // * PendingConfirmation – true if the subscription hasn't been confirmed. // To confirm a pending subscription, call the ConfirmSubscription action // with a confirmation token. // // * RawMessageDelivery – true if raw message delivery is enabled for the // subscription. Raw messages are free of JSON formatting and can be sent // to HTTP/S and Amazon SQS endpoints. // // * RedrivePolicy – When specified, sends undeliverable messages to the // specified Amazon SQS dead-letter queue. Messages that can't be delivered // due to client errors (for example, when the subscribed endpoint is unreachable) // or server errors (for example, when the service that powers the subscribed // endpoint becomes unavailable) are held in the dead-letter queue for further // analysis or reprocessing. // // * SubscriptionArn – The subscription's ARN. // // * TopicArn – The topic ARN that the subscription is associated with. Attributes map[string]string `type:"map"` // contains filtered or unexported fields }
Response for GetSubscriptionAttributes action.
func (GetSubscriptionAttributesOutput) String ¶
func (s GetSubscriptionAttributesOutput) String() string
String returns the string representation
type GetSubscriptionAttributesRequest ¶
type GetSubscriptionAttributesRequest struct { *aws.Request Input *GetSubscriptionAttributesInput Copy func(*GetSubscriptionAttributesInput) GetSubscriptionAttributesRequest }
GetSubscriptionAttributesRequest is the request type for the GetSubscriptionAttributes API operation.
func (GetSubscriptionAttributesRequest) Send ¶
func (r GetSubscriptionAttributesRequest) Send(ctx context.Context) (*GetSubscriptionAttributesResponse, error)
Send marshals and sends the GetSubscriptionAttributes API request.
type GetSubscriptionAttributesResponse ¶ added in v0.9.0
type GetSubscriptionAttributesResponse struct { *GetSubscriptionAttributesOutput // contains filtered or unexported fields }
GetSubscriptionAttributesResponse is the response type for the GetSubscriptionAttributes API operation.
func (*GetSubscriptionAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *GetSubscriptionAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the GetSubscriptionAttributes request.
type GetTopicAttributesInput ¶
type GetTopicAttributesInput struct { // The ARN of the topic whose properties you want to get. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for GetTopicAttributes action.
func (GetTopicAttributesInput) String ¶
func (s GetTopicAttributesInput) String() string
String returns the string representation
func (*GetTopicAttributesInput) Validate ¶
func (s *GetTopicAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type GetTopicAttributesOutput ¶
type GetTopicAttributesOutput struct { // A map of the topic's attributes. Attributes in this map include the following: // // * DeliveryPolicy – The JSON serialization of the topic's delivery policy. // // * DisplayName – The human-readable name used in the From field for notifications // to email and email-json endpoints. // // * Owner – The AWS account ID of the topic's owner. // // * Policy – The JSON serialization of the topic's access control policy. // // * SubscriptionsConfirmed – The number of confirmed subscriptions for // the topic. // // * SubscriptionsDeleted – The number of deleted subscriptions for the // topic. // // * SubscriptionsPending – The number of subscriptions pending confirmation // for the topic. // // * TopicArn – The topic's ARN. // // * EffectiveDeliveryPolicy – Yhe JSON serialization of the effective // delivery policy, taking system defaults into account. // // The following attribute applies only to server-side-encryption (https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html): // // * KmsMasterKeyId - The ID of an AWS-managed customer master key (CMK) // for Amazon SNS or a custom CMK. For more information, see Key Terms (https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html#sse-key-terms). // For more examples, see KeyId (https://docs.aws.amazon.com/kms/latest/APIReference/API_DescribeKey.html#API_DescribeKey_RequestParameters) // in the AWS Key Management Service API Reference. Attributes map[string]string `type:"map"` // contains filtered or unexported fields }
Response for GetTopicAttributes action.
func (GetTopicAttributesOutput) String ¶
func (s GetTopicAttributesOutput) String() string
String returns the string representation
type GetTopicAttributesRequest ¶
type GetTopicAttributesRequest struct { *aws.Request Input *GetTopicAttributesInput Copy func(*GetTopicAttributesInput) GetTopicAttributesRequest }
GetTopicAttributesRequest is the request type for the GetTopicAttributes API operation.
func (GetTopicAttributesRequest) Send ¶
func (r GetTopicAttributesRequest) Send(ctx context.Context) (*GetTopicAttributesResponse, error)
Send marshals and sends the GetTopicAttributes API request.
type GetTopicAttributesResponse ¶ added in v0.9.0
type GetTopicAttributesResponse struct { *GetTopicAttributesOutput // contains filtered or unexported fields }
GetTopicAttributesResponse is the response type for the GetTopicAttributes API operation.
func (*GetTopicAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *GetTopicAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the GetTopicAttributes request.
type ListEndpointsByPlatformApplicationInput ¶
type ListEndpointsByPlatformApplicationInput struct { // NextToken string is used when calling ListEndpointsByPlatformApplication // action to retrieve additional records that are available after the first // page results. NextToken *string `type:"string"` // PlatformApplicationArn for ListEndpointsByPlatformApplicationInput action. // // PlatformApplicationArn is a required field PlatformApplicationArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for ListEndpointsByPlatformApplication action.
func (ListEndpointsByPlatformApplicationInput) String ¶
func (s ListEndpointsByPlatformApplicationInput) String() string
String returns the string representation
func (*ListEndpointsByPlatformApplicationInput) Validate ¶
func (s *ListEndpointsByPlatformApplicationInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type ListEndpointsByPlatformApplicationOutput ¶
type ListEndpointsByPlatformApplicationOutput struct { // Endpoints returned for ListEndpointsByPlatformApplication action. Endpoints []Endpoint `type:"list"` // NextToken string is returned when calling ListEndpointsByPlatformApplication // action if additional records are available after the first page results. NextToken *string `type:"string"` // contains filtered or unexported fields }
Response for ListEndpointsByPlatformApplication action.
func (ListEndpointsByPlatformApplicationOutput) String ¶
func (s ListEndpointsByPlatformApplicationOutput) String() string
String returns the string representation
type ListEndpointsByPlatformApplicationPaginator ¶ added in v0.9.0
ListEndpointsByPlatformApplicationPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.
func NewListEndpointsByPlatformApplicationPaginator ¶ added in v0.9.0
func NewListEndpointsByPlatformApplicationPaginator(req ListEndpointsByPlatformApplicationRequest) ListEndpointsByPlatformApplicationPaginator
NewListEndpointsByPlatformApplicationRequestPaginator returns a paginator for ListEndpointsByPlatformApplication. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.
Note: This operation can generate multiple requests to a service.
// Example iterating over pages. req := client.ListEndpointsByPlatformApplicationRequest(input) p := sns.NewListEndpointsByPlatformApplicationRequestPaginator(req) for p.Next(context.TODO()) { page := p.CurrentPage() } if err := p.Err(); err != nil { return err }
func (*ListEndpointsByPlatformApplicationPaginator) CurrentPage ¶ added in v0.9.0
func (p *ListEndpointsByPlatformApplicationPaginator) CurrentPage() *ListEndpointsByPlatformApplicationOutput
type ListEndpointsByPlatformApplicationRequest ¶
type ListEndpointsByPlatformApplicationRequest struct { *aws.Request Input *ListEndpointsByPlatformApplicationInput Copy func(*ListEndpointsByPlatformApplicationInput) ListEndpointsByPlatformApplicationRequest }
ListEndpointsByPlatformApplicationRequest is the request type for the ListEndpointsByPlatformApplication API operation.
func (ListEndpointsByPlatformApplicationRequest) Send ¶
func (r ListEndpointsByPlatformApplicationRequest) Send(ctx context.Context) (*ListEndpointsByPlatformApplicationResponse, error)
Send marshals and sends the ListEndpointsByPlatformApplication API request.
type ListEndpointsByPlatformApplicationResponse ¶ added in v0.9.0
type ListEndpointsByPlatformApplicationResponse struct { *ListEndpointsByPlatformApplicationOutput // contains filtered or unexported fields }
ListEndpointsByPlatformApplicationResponse is the response type for the ListEndpointsByPlatformApplication API operation.
func (*ListEndpointsByPlatformApplicationResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ListEndpointsByPlatformApplicationResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ListEndpointsByPlatformApplication request.
type ListPhoneNumbersOptedOutInput ¶
type ListPhoneNumbersOptedOutInput struct { // A NextToken string is used when you call the ListPhoneNumbersOptedOut action // to retrieve additional records that are available after the first page of // results. NextToken *string `locationName:"nextToken" type:"string"` // contains filtered or unexported fields }
The input for the ListPhoneNumbersOptedOut action.
func (ListPhoneNumbersOptedOutInput) String ¶
func (s ListPhoneNumbersOptedOutInput) String() string
String returns the string representation
type ListPhoneNumbersOptedOutOutput ¶
type ListPhoneNumbersOptedOutOutput struct { // A NextToken string is returned when you call the ListPhoneNumbersOptedOut // action if additional records are available after the first page of results. NextToken *string `locationName:"nextToken" type:"string"` // A list of phone numbers that are opted out of receiving SMS messages. The // list is paginated, and each page can contain up to 100 phone numbers. PhoneNumbers []string `locationName:"phoneNumbers" type:"list"` // contains filtered or unexported fields }
The response from the ListPhoneNumbersOptedOut action.
func (ListPhoneNumbersOptedOutOutput) String ¶
func (s ListPhoneNumbersOptedOutOutput) String() string
String returns the string representation
type ListPhoneNumbersOptedOutRequest ¶
type ListPhoneNumbersOptedOutRequest struct { *aws.Request Input *ListPhoneNumbersOptedOutInput Copy func(*ListPhoneNumbersOptedOutInput) ListPhoneNumbersOptedOutRequest }
ListPhoneNumbersOptedOutRequest is the request type for the ListPhoneNumbersOptedOut API operation.
func (ListPhoneNumbersOptedOutRequest) Send ¶
func (r ListPhoneNumbersOptedOutRequest) Send(ctx context.Context) (*ListPhoneNumbersOptedOutResponse, error)
Send marshals and sends the ListPhoneNumbersOptedOut API request.
type ListPhoneNumbersOptedOutResponse ¶ added in v0.9.0
type ListPhoneNumbersOptedOutResponse struct { *ListPhoneNumbersOptedOutOutput // contains filtered or unexported fields }
ListPhoneNumbersOptedOutResponse is the response type for the ListPhoneNumbersOptedOut API operation.
func (*ListPhoneNumbersOptedOutResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ListPhoneNumbersOptedOutResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ListPhoneNumbersOptedOut request.
type ListPlatformApplicationsInput ¶
type ListPlatformApplicationsInput struct { // NextToken string is used when calling ListPlatformApplications action to // retrieve additional records that are available after the first page results. NextToken *string `type:"string"` // contains filtered or unexported fields }
Input for ListPlatformApplications action.
func (ListPlatformApplicationsInput) String ¶
func (s ListPlatformApplicationsInput) String() string
String returns the string representation
type ListPlatformApplicationsOutput ¶
type ListPlatformApplicationsOutput struct { // NextToken string is returned when calling ListPlatformApplications action // if additional records are available after the first page results. NextToken *string `type:"string"` // Platform applications returned when calling ListPlatformApplications action. PlatformApplications []PlatformApplication `type:"list"` // contains filtered or unexported fields }
Response for ListPlatformApplications action.
func (ListPlatformApplicationsOutput) String ¶
func (s ListPlatformApplicationsOutput) String() string
String returns the string representation
type ListPlatformApplicationsPaginator ¶ added in v0.9.0
ListPlatformApplicationsPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.
func NewListPlatformApplicationsPaginator ¶ added in v0.9.0
func NewListPlatformApplicationsPaginator(req ListPlatformApplicationsRequest) ListPlatformApplicationsPaginator
NewListPlatformApplicationsRequestPaginator returns a paginator for ListPlatformApplications. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.
Note: This operation can generate multiple requests to a service.
// Example iterating over pages. req := client.ListPlatformApplicationsRequest(input) p := sns.NewListPlatformApplicationsRequestPaginator(req) for p.Next(context.TODO()) { page := p.CurrentPage() } if err := p.Err(); err != nil { return err }
func (*ListPlatformApplicationsPaginator) CurrentPage ¶ added in v0.9.0
func (p *ListPlatformApplicationsPaginator) CurrentPage() *ListPlatformApplicationsOutput
type ListPlatformApplicationsRequest ¶
type ListPlatformApplicationsRequest struct { *aws.Request Input *ListPlatformApplicationsInput Copy func(*ListPlatformApplicationsInput) ListPlatformApplicationsRequest }
ListPlatformApplicationsRequest is the request type for the ListPlatformApplications API operation.
func (ListPlatformApplicationsRequest) Send ¶
func (r ListPlatformApplicationsRequest) Send(ctx context.Context) (*ListPlatformApplicationsResponse, error)
Send marshals and sends the ListPlatformApplications API request.
type ListPlatformApplicationsResponse ¶ added in v0.9.0
type ListPlatformApplicationsResponse struct { *ListPlatformApplicationsOutput // contains filtered or unexported fields }
ListPlatformApplicationsResponse is the response type for the ListPlatformApplications API operation.
func (*ListPlatformApplicationsResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ListPlatformApplicationsResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ListPlatformApplications request.
type ListSubscriptionsByTopicInput ¶
type ListSubscriptionsByTopicInput struct { // Token returned by the previous ListSubscriptionsByTopic request. NextToken *string `type:"string"` // The ARN of the topic for which you wish to find subscriptions. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for ListSubscriptionsByTopic action.
func (ListSubscriptionsByTopicInput) String ¶
func (s ListSubscriptionsByTopicInput) String() string
String returns the string representation
func (*ListSubscriptionsByTopicInput) Validate ¶
func (s *ListSubscriptionsByTopicInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type ListSubscriptionsByTopicOutput ¶
type ListSubscriptionsByTopicOutput struct { // Token to pass along to the next ListSubscriptionsByTopic request. This element // is returned if there are more subscriptions to retrieve. NextToken *string `type:"string"` // A list of subscriptions. Subscriptions []Subscription `type:"list"` // contains filtered or unexported fields }
Response for ListSubscriptionsByTopic action.
func (ListSubscriptionsByTopicOutput) String ¶
func (s ListSubscriptionsByTopicOutput) String() string
String returns the string representation
type ListSubscriptionsByTopicPaginator ¶ added in v0.9.0
ListSubscriptionsByTopicPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.
func NewListSubscriptionsByTopicPaginator ¶ added in v0.9.0
func NewListSubscriptionsByTopicPaginator(req ListSubscriptionsByTopicRequest) ListSubscriptionsByTopicPaginator
NewListSubscriptionsByTopicRequestPaginator returns a paginator for ListSubscriptionsByTopic. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.
Note: This operation can generate multiple requests to a service.
// Example iterating over pages. req := client.ListSubscriptionsByTopicRequest(input) p := sns.NewListSubscriptionsByTopicRequestPaginator(req) for p.Next(context.TODO()) { page := p.CurrentPage() } if err := p.Err(); err != nil { return err }
func (*ListSubscriptionsByTopicPaginator) CurrentPage ¶ added in v0.9.0
func (p *ListSubscriptionsByTopicPaginator) CurrentPage() *ListSubscriptionsByTopicOutput
type ListSubscriptionsByTopicRequest ¶
type ListSubscriptionsByTopicRequest struct { *aws.Request Input *ListSubscriptionsByTopicInput Copy func(*ListSubscriptionsByTopicInput) ListSubscriptionsByTopicRequest }
ListSubscriptionsByTopicRequest is the request type for the ListSubscriptionsByTopic API operation.
func (ListSubscriptionsByTopicRequest) Send ¶
func (r ListSubscriptionsByTopicRequest) Send(ctx context.Context) (*ListSubscriptionsByTopicResponse, error)
Send marshals and sends the ListSubscriptionsByTopic API request.
type ListSubscriptionsByTopicResponse ¶ added in v0.9.0
type ListSubscriptionsByTopicResponse struct { *ListSubscriptionsByTopicOutput // contains filtered or unexported fields }
ListSubscriptionsByTopicResponse is the response type for the ListSubscriptionsByTopic API operation.
func (*ListSubscriptionsByTopicResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ListSubscriptionsByTopicResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ListSubscriptionsByTopic request.
type ListSubscriptionsInput ¶
type ListSubscriptionsInput struct { // Token returned by the previous ListSubscriptions request. NextToken *string `type:"string"` // contains filtered or unexported fields }
Input for ListSubscriptions action.
func (ListSubscriptionsInput) String ¶
func (s ListSubscriptionsInput) String() string
String returns the string representation
type ListSubscriptionsOutput ¶
type ListSubscriptionsOutput struct { // Token to pass along to the next ListSubscriptions request. This element is // returned if there are more subscriptions to retrieve. NextToken *string `type:"string"` // A list of subscriptions. Subscriptions []Subscription `type:"list"` // contains filtered or unexported fields }
Response for ListSubscriptions action
func (ListSubscriptionsOutput) String ¶
func (s ListSubscriptionsOutput) String() string
String returns the string representation
type ListSubscriptionsPaginator ¶ added in v0.9.0
ListSubscriptionsPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.
func NewListSubscriptionsPaginator ¶ added in v0.9.0
func NewListSubscriptionsPaginator(req ListSubscriptionsRequest) ListSubscriptionsPaginator
NewListSubscriptionsRequestPaginator returns a paginator for ListSubscriptions. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.
Note: This operation can generate multiple requests to a service.
// Example iterating over pages. req := client.ListSubscriptionsRequest(input) p := sns.NewListSubscriptionsRequestPaginator(req) for p.Next(context.TODO()) { page := p.CurrentPage() } if err := p.Err(); err != nil { return err }
func (*ListSubscriptionsPaginator) CurrentPage ¶ added in v0.9.0
func (p *ListSubscriptionsPaginator) CurrentPage() *ListSubscriptionsOutput
type ListSubscriptionsRequest ¶
type ListSubscriptionsRequest struct { *aws.Request Input *ListSubscriptionsInput Copy func(*ListSubscriptionsInput) ListSubscriptionsRequest }
ListSubscriptionsRequest is the request type for the ListSubscriptions API operation.
func (ListSubscriptionsRequest) Send ¶
func (r ListSubscriptionsRequest) Send(ctx context.Context) (*ListSubscriptionsResponse, error)
Send marshals and sends the ListSubscriptions API request.
type ListSubscriptionsResponse ¶ added in v0.9.0
type ListSubscriptionsResponse struct { *ListSubscriptionsOutput // contains filtered or unexported fields }
ListSubscriptionsResponse is the response type for the ListSubscriptions API operation.
func (*ListSubscriptionsResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ListSubscriptionsResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ListSubscriptions request.
type ListTagsForResourceInput ¶ added in v0.9.0
type ListTagsForResourceInput struct { // The ARN of the topic for which to list tags. // // ResourceArn is a required field ResourceArn *string `min:"1" type:"string" required:"true"` // contains filtered or unexported fields }
func (ListTagsForResourceInput) String ¶ added in v0.9.0
func (s ListTagsForResourceInput) String() string
String returns the string representation
func (*ListTagsForResourceInput) Validate ¶ added in v0.9.0
func (s *ListTagsForResourceInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type ListTagsForResourceOutput ¶ added in v0.9.0
type ListTagsForResourceOutput struct { // The tags associated with the specified topic. Tags []Tag `type:"list"` // contains filtered or unexported fields }
func (ListTagsForResourceOutput) String ¶ added in v0.9.0
func (s ListTagsForResourceOutput) String() string
String returns the string representation
type ListTagsForResourceRequest ¶ added in v0.9.0
type ListTagsForResourceRequest struct { *aws.Request Input *ListTagsForResourceInput Copy func(*ListTagsForResourceInput) ListTagsForResourceRequest }
ListTagsForResourceRequest is the request type for the ListTagsForResource API operation.
func (ListTagsForResourceRequest) Send ¶ added in v0.9.0
func (r ListTagsForResourceRequest) Send(ctx context.Context) (*ListTagsForResourceResponse, error)
Send marshals and sends the ListTagsForResource API request.
type ListTagsForResourceResponse ¶ added in v0.9.0
type ListTagsForResourceResponse struct { *ListTagsForResourceOutput // contains filtered or unexported fields }
ListTagsForResourceResponse is the response type for the ListTagsForResource API operation.
func (*ListTagsForResourceResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ListTagsForResourceResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ListTagsForResource request.
type ListTopicsInput ¶
type ListTopicsInput struct { // Token returned by the previous ListTopics request. NextToken *string `type:"string"` // contains filtered or unexported fields }
func (ListTopicsInput) String ¶
func (s ListTopicsInput) String() string
String returns the string representation
type ListTopicsOutput ¶
type ListTopicsOutput struct { // Token to pass along to the next ListTopics request. This element is returned // if there are additional topics to retrieve. NextToken *string `type:"string"` // A list of topic ARNs. Topics []Topic `type:"list"` // contains filtered or unexported fields }
Response for ListTopics action.
func (ListTopicsOutput) String ¶
func (s ListTopicsOutput) String() string
String returns the string representation
type ListTopicsPaginator ¶ added in v0.9.0
ListTopicsPaginator is used to paginate the request. This can be done by calling Next and CurrentPage.
func NewListTopicsPaginator ¶ added in v0.9.0
func NewListTopicsPaginator(req ListTopicsRequest) ListTopicsPaginator
NewListTopicsRequestPaginator returns a paginator for ListTopics. Use Next method to get the next page, and CurrentPage to get the current response page from the paginator. Next will return false, if there are no more pages, or an error was encountered.
Note: This operation can generate multiple requests to a service.
// Example iterating over pages. req := client.ListTopicsRequest(input) p := sns.NewListTopicsRequestPaginator(req) for p.Next(context.TODO()) { page := p.CurrentPage() } if err := p.Err(); err != nil { return err }
func (*ListTopicsPaginator) CurrentPage ¶ added in v0.9.0
func (p *ListTopicsPaginator) CurrentPage() *ListTopicsOutput
type ListTopicsRequest ¶
type ListTopicsRequest struct { *aws.Request Input *ListTopicsInput Copy func(*ListTopicsInput) ListTopicsRequest }
ListTopicsRequest is the request type for the ListTopics API operation.
func (ListTopicsRequest) Send ¶
func (r ListTopicsRequest) Send(ctx context.Context) (*ListTopicsResponse, error)
Send marshals and sends the ListTopics API request.
type ListTopicsResponse ¶ added in v0.9.0
type ListTopicsResponse struct { *ListTopicsOutput // contains filtered or unexported fields }
ListTopicsResponse is the response type for the ListTopics API operation.
func (*ListTopicsResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *ListTopicsResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the ListTopics request.
type MessageAttributeValue ¶
type MessageAttributeValue struct { // Binary type attributes can store any binary data, for example, compressed // data, encrypted data, or images. // // BinaryValue is automatically base64 encoded/decoded by the SDK. BinaryValue []byte `type:"blob"` // Amazon SNS supports the following logical data types: String, String.Array, // Number, and Binary. For more information, see Message Attribute Data Types // (https://docs.aws.amazon.com/sns/latest/dg/SNSMessageAttributes.html#SNSMessageAttributes.DataTypes). // // DataType is a required field DataType *string `type:"string" required:"true"` // Strings are Unicode with UTF8 binary encoding. For a list of code values, // see ASCII Printable Characters (https://en.wikipedia.org/wiki/ASCII#ASCII_printable_characters). StringValue *string `type:"string"` // contains filtered or unexported fields }
The user-specified message attribute value. For string data types, the value attribute has the same restrictions on the content as the message body. For more information, see Publish (https://docs.aws.amazon.com/sns/latest/api/API_Publish.html).
Name, type, and value must not be empty or null. In addition, the message body should not be empty or null. All parts of the message attribute, including name, type, and value, are included in the message size restriction, which is currently 256 KB (262,144 bytes). For more information, see Using Amazon SNS Message Attributes (https://docs.aws.amazon.com/sns/latest/dg/SNSMessageAttributes.html).
func (MessageAttributeValue) String ¶
func (s MessageAttributeValue) String() string
String returns the string representation
func (*MessageAttributeValue) Validate ¶
func (s *MessageAttributeValue) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type OptInPhoneNumberInput ¶
type OptInPhoneNumberInput struct { // The phone number to opt in. // // PhoneNumber is a required field PhoneNumber *string `locationName:"phoneNumber" type:"string" required:"true"` // contains filtered or unexported fields }
Input for the OptInPhoneNumber action.
func (OptInPhoneNumberInput) String ¶
func (s OptInPhoneNumberInput) String() string
String returns the string representation
func (*OptInPhoneNumberInput) Validate ¶
func (s *OptInPhoneNumberInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type OptInPhoneNumberOutput ¶
type OptInPhoneNumberOutput struct {
// contains filtered or unexported fields
}
The response for the OptInPhoneNumber action.
func (OptInPhoneNumberOutput) String ¶
func (s OptInPhoneNumberOutput) String() string
String returns the string representation
type OptInPhoneNumberRequest ¶
type OptInPhoneNumberRequest struct { *aws.Request Input *OptInPhoneNumberInput Copy func(*OptInPhoneNumberInput) OptInPhoneNumberRequest }
OptInPhoneNumberRequest is the request type for the OptInPhoneNumber API operation.
func (OptInPhoneNumberRequest) Send ¶
func (r OptInPhoneNumberRequest) Send(ctx context.Context) (*OptInPhoneNumberResponse, error)
Send marshals and sends the OptInPhoneNumber API request.
type OptInPhoneNumberResponse ¶ added in v0.9.0
type OptInPhoneNumberResponse struct { *OptInPhoneNumberOutput // contains filtered or unexported fields }
OptInPhoneNumberResponse is the response type for the OptInPhoneNumber API operation.
func (*OptInPhoneNumberResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *OptInPhoneNumberResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the OptInPhoneNumber request.
type PlatformApplication ¶
type PlatformApplication struct { // Attributes for platform application object. Attributes map[string]string `type:"map"` // PlatformApplicationArn for platform application object. PlatformApplicationArn *string `type:"string"` // contains filtered or unexported fields }
Platform application object.
func (PlatformApplication) String ¶
func (s PlatformApplication) String() string
String returns the string representation
type PublishInput ¶
type PublishInput struct { // The message you want to send. // // If you are publishing to a topic and you want to send the same message to // all transport protocols, include the text of the message as a String value. // If you want to send different messages for each transport protocol, set the // value of the MessageStructure parameter to json and use a JSON object for // the Message parameter. // // Constraints: // // * With the exception of SMS, messages must be UTF-8 encoded strings and // at most 256 KB in size (262,144 bytes, not 262,144 characters). // // * For SMS, each message can contain up to 140 characters. This character // limit depends on the encoding schema. For example, an SMS message can // contain 160 GSM characters, 140 ASCII characters, or 70 UCS-2 characters. // If you publish a message that exceeds this size limit, Amazon SNS sends // the message as multiple messages, each fitting within the size limit. // Messages aren't truncated mid-word but are cut off at whole-word boundaries. // The total size limit for a single SMS Publish action is 1,600 characters. // // JSON-specific constraints: // // * Keys in the JSON object that correspond to supported transport protocols // must have simple JSON string values. // // * The values will be parsed (unescaped) before they are used in outgoing // messages. // // * Outbound notifications are JSON encoded (meaning that the characters // will be reescaped for sending). // // * Values have a minimum length of 0 (the empty string, "", is allowed). // // * Values have a maximum length bounded by the overall message size (so, // including multiple protocols may limit message sizes). // // * Non-string values will cause the key to be ignored. // // * Keys that do not correspond to supported transport protocols are ignored. // // * Duplicate keys are not allowed. // // * Failure to parse or validate any key or value in the message will cause // the Publish call to return an error (no partial delivery). // // Message is a required field Message *string `type:"string" required:"true"` // Message attributes for Publish action. MessageAttributes map[string]MessageAttributeValue `locationNameKey:"Name" locationNameValue:"Value" type:"map"` // Set MessageStructure to json if you want to send a different message for // each protocol. For example, using one publish action, you can send a short // message to your SMS subscribers and a longer message to your email subscribers. // If you set MessageStructure to json, the value of the Message parameter must: // // * be a syntactically valid JSON object; and // // * contain at least a top-level JSON key of "default" with a value that // is a string. // // You can define other top-level keys that define the message you want to send // to a specific transport protocol (e.g., "http"). // // Valid value: json MessageStructure *string `type:"string"` // The phone number to which you want to deliver an SMS message. Use E.164 format. // // If you don't specify a value for the PhoneNumber parameter, you must specify // a value for the TargetArn or TopicArn parameters. PhoneNumber *string `type:"string"` // Optional parameter to be used as the "Subject" line when the message is delivered // to email endpoints. This field will also be included, if present, in the // standard JSON messages delivered to other endpoints. // // Constraints: Subjects must be ASCII text that begins with a letter, number, // or punctuation mark; must not include line breaks or control characters; // and must be less than 100 characters long. Subject *string `type:"string"` // If you don't specify a value for the TargetArn parameter, you must specify // a value for the PhoneNumber or TopicArn parameters. TargetArn *string `type:"string"` // The topic you want to publish to. // // If you don't specify a value for the TopicArn parameter, you must specify // a value for the PhoneNumber or TargetArn parameters. TopicArn *string `type:"string"` // contains filtered or unexported fields }
Input for Publish action.
func (PublishInput) String ¶
func (s PublishInput) String() string
String returns the string representation
func (*PublishInput) Validate ¶
func (s *PublishInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type PublishOutput ¶
type PublishOutput struct { // Unique identifier assigned to the published message. // // Length Constraint: Maximum 100 characters MessageId *string `type:"string"` // contains filtered or unexported fields }
Response for Publish action.
func (PublishOutput) String ¶
func (s PublishOutput) String() string
String returns the string representation
type PublishRequest ¶
type PublishRequest struct { *aws.Request Input *PublishInput Copy func(*PublishInput) PublishRequest }
PublishRequest is the request type for the Publish API operation.
func (PublishRequest) Send ¶
func (r PublishRequest) Send(ctx context.Context) (*PublishResponse, error)
Send marshals and sends the Publish API request.
type PublishResponse ¶ added in v0.9.0
type PublishResponse struct { *PublishOutput // contains filtered or unexported fields }
PublishResponse is the response type for the Publish API operation.
func (*PublishResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *PublishResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the Publish request.
type RemovePermissionInput ¶
type RemovePermissionInput struct { // The unique label of the statement you want to remove. // // Label is a required field Label *string `type:"string" required:"true"` // The ARN of the topic whose access control policy you wish to modify. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for RemovePermission action.
func (RemovePermissionInput) String ¶
func (s RemovePermissionInput) String() string
String returns the string representation
func (*RemovePermissionInput) Validate ¶
func (s *RemovePermissionInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type RemovePermissionOutput ¶
type RemovePermissionOutput struct {
// contains filtered or unexported fields
}
func (RemovePermissionOutput) String ¶
func (s RemovePermissionOutput) String() string
String returns the string representation
type RemovePermissionRequest ¶
type RemovePermissionRequest struct { *aws.Request Input *RemovePermissionInput Copy func(*RemovePermissionInput) RemovePermissionRequest }
RemovePermissionRequest is the request type for the RemovePermission API operation.
func (RemovePermissionRequest) Send ¶
func (r RemovePermissionRequest) Send(ctx context.Context) (*RemovePermissionResponse, error)
Send marshals and sends the RemovePermission API request.
type RemovePermissionResponse ¶ added in v0.9.0
type RemovePermissionResponse struct { *RemovePermissionOutput // contains filtered or unexported fields }
RemovePermissionResponse is the response type for the RemovePermission API operation.
func (*RemovePermissionResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *RemovePermissionResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the RemovePermission request.
type SetEndpointAttributesInput ¶
type SetEndpointAttributesInput struct { // A map of the endpoint attributes. Attributes in this map include the following: // // * CustomUserData – arbitrary user data to associate with the endpoint. // Amazon SNS does not use this data. The data must be in UTF-8 format and // less than 2KB. // // * Enabled – flag that enables/disables delivery to the endpoint. Amazon // SNS will set this to false when a notification service indicates to Amazon // SNS that the endpoint is invalid. Users can set it back to true, typically // after updating Token. // // * Token – device token, also referred to as a registration id, for an // app and mobile device. This is returned from the notification service // when an app and mobile device are registered with the notification service. // // Attributes is a required field Attributes map[string]string `type:"map" required:"true"` // EndpointArn used for SetEndpointAttributes action. // // EndpointArn is a required field EndpointArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for SetEndpointAttributes action.
func (SetEndpointAttributesInput) String ¶
func (s SetEndpointAttributesInput) String() string
String returns the string representation
func (*SetEndpointAttributesInput) Validate ¶
func (s *SetEndpointAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type SetEndpointAttributesOutput ¶
type SetEndpointAttributesOutput struct {
// contains filtered or unexported fields
}
func (SetEndpointAttributesOutput) String ¶
func (s SetEndpointAttributesOutput) String() string
String returns the string representation
type SetEndpointAttributesRequest ¶
type SetEndpointAttributesRequest struct { *aws.Request Input *SetEndpointAttributesInput Copy func(*SetEndpointAttributesInput) SetEndpointAttributesRequest }
SetEndpointAttributesRequest is the request type for the SetEndpointAttributes API operation.
func (SetEndpointAttributesRequest) Send ¶
func (r SetEndpointAttributesRequest) Send(ctx context.Context) (*SetEndpointAttributesResponse, error)
Send marshals and sends the SetEndpointAttributes API request.
type SetEndpointAttributesResponse ¶ added in v0.9.0
type SetEndpointAttributesResponse struct { *SetEndpointAttributesOutput // contains filtered or unexported fields }
SetEndpointAttributesResponse is the response type for the SetEndpointAttributes API operation.
func (*SetEndpointAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *SetEndpointAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the SetEndpointAttributes request.
type SetPlatformApplicationAttributesInput ¶
type SetPlatformApplicationAttributesInput struct { // A map of the platform application attributes. Attributes in this map include // the following: // // * PlatformCredential – The credential received from the notification // service. For APNS/APNS_SANDBOX, PlatformCredential is private key. For // FCM, PlatformCredential is "API key". For ADM, PlatformCredential is "client // secret". // // * PlatformPrincipal – The principal received from the notification service. // For APNS/APNS_SANDBOX, PlatformPrincipal is SSL certificate. For FCM, // PlatformPrincipal is not applicable. For ADM, PlatformPrincipal is "client // id". // // * EventEndpointCreated – Topic ARN to which EndpointCreated event notifications // should be sent. // // * EventEndpointDeleted – Topic ARN to which EndpointDeleted event notifications // should be sent. // // * EventEndpointUpdated – Topic ARN to which EndpointUpdate event notifications // should be sent. // // * EventDeliveryFailure – Topic ARN to which DeliveryFailure event notifications // should be sent upon Direct Publish delivery failure (permanent) to one // of the application's endpoints. // // * SuccessFeedbackRoleArn – IAM role ARN used to give Amazon SNS write // access to use CloudWatch Logs on your behalf. // // * FailureFeedbackRoleArn – IAM role ARN used to give Amazon SNS write // access to use CloudWatch Logs on your behalf. // // * SuccessFeedbackSampleRate – Sample rate percentage (0-100) of successfully // delivered messages. // // Attributes is a required field Attributes map[string]string `type:"map" required:"true"` // PlatformApplicationArn for SetPlatformApplicationAttributes action. // // PlatformApplicationArn is a required field PlatformApplicationArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for SetPlatformApplicationAttributes action.
func (SetPlatformApplicationAttributesInput) String ¶
func (s SetPlatformApplicationAttributesInput) String() string
String returns the string representation
func (*SetPlatformApplicationAttributesInput) Validate ¶
func (s *SetPlatformApplicationAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type SetPlatformApplicationAttributesOutput ¶
type SetPlatformApplicationAttributesOutput struct {
// contains filtered or unexported fields
}
func (SetPlatformApplicationAttributesOutput) String ¶
func (s SetPlatformApplicationAttributesOutput) String() string
String returns the string representation
type SetPlatformApplicationAttributesRequest ¶
type SetPlatformApplicationAttributesRequest struct { *aws.Request Input *SetPlatformApplicationAttributesInput Copy func(*SetPlatformApplicationAttributesInput) SetPlatformApplicationAttributesRequest }
SetPlatformApplicationAttributesRequest is the request type for the SetPlatformApplicationAttributes API operation.
func (SetPlatformApplicationAttributesRequest) Send ¶
func (r SetPlatformApplicationAttributesRequest) Send(ctx context.Context) (*SetPlatformApplicationAttributesResponse, error)
Send marshals and sends the SetPlatformApplicationAttributes API request.
type SetPlatformApplicationAttributesResponse ¶ added in v0.9.0
type SetPlatformApplicationAttributesResponse struct { *SetPlatformApplicationAttributesOutput // contains filtered or unexported fields }
SetPlatformApplicationAttributesResponse is the response type for the SetPlatformApplicationAttributes API operation.
func (*SetPlatformApplicationAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *SetPlatformApplicationAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the SetPlatformApplicationAttributes request.
type SetSMSAttributesInput ¶
type SetSMSAttributesInput struct { // The default settings for sending SMS messages from your account. You can // set values for the following attribute names: // // MonthlySpendLimit – The maximum amount in USD that you are willing to spend // each month to send SMS messages. When Amazon SNS determines that sending // an SMS message would incur a cost that exceeds this limit, it stops sending // SMS messages within minutes. // // Amazon SNS stops sending SMS messages within minutes of the limit being crossed. // During that interval, if you continue to send SMS messages, you will incur // costs that exceed your limit. // // By default, the spend limit is set to the maximum allowed by Amazon SNS. // If you want to raise the limit, submit an SNS Limit Increase case (https://console.aws.amazon.com/support/home#/case/create?issueType=service-limit-increase&limitType=service-code-sns). // For New limit value, enter your desired monthly spend limit. In the Use Case // Description field, explain that you are requesting an SMS monthly spend limit // increase. // // DeliveryStatusIAMRole – The ARN of the IAM role that allows Amazon SNS // to write logs about SMS deliveries in CloudWatch Logs. For each SMS message // that you send, Amazon SNS writes a log that includes the message price, the // success or failure status, the reason for failure (if the message failed), // the message dwell time, and other information. // // DeliveryStatusSuccessSamplingRate – The percentage of successful SMS deliveries // for which Amazon SNS will write logs in CloudWatch Logs. The value can be // an integer from 0 - 100. For example, to write logs only for failed deliveries, // set this value to 0. To write logs for 10% of your successful deliveries, // set it to 10. // // DefaultSenderID – A string, such as your business brand, that is displayed // as the sender on the receiving device. Support for sender IDs varies by country. // The sender ID can be 1 - 11 alphanumeric characters, and it must contain // at least one letter. // // DefaultSMSType – The type of SMS message that you will send by default. // You can assign the following values: // // * Promotional – (Default) Noncritical messages, such as marketing messages. // Amazon SNS optimizes the message delivery to incur the lowest cost. // // * Transactional – Critical messages that support customer transactions, // such as one-time passcodes for multi-factor authentication. Amazon SNS // optimizes the message delivery to achieve the highest reliability. // // UsageReportS3Bucket – The name of the Amazon S3 bucket to receive daily // SMS usage reports from Amazon SNS. Each day, Amazon SNS will deliver a usage // report as a CSV file to the bucket. The report includes the following information // for each SMS message that was successfully delivered by your account: // // * Time that the message was published (in UTC) // // * Message ID // // * Destination phone number // // * Message type // // * Delivery status // // * Message price (in USD) // // * Part number (a message is split into multiple parts if it is too long // for a single message) // // * Total number of parts // // To receive the report, the bucket must have a policy that allows the Amazon // SNS service principle to perform the s3:PutObject and s3:GetBucketLocation // actions. // // For an example bucket policy and usage report, see Monitoring SMS Activity // (https://docs.aws.amazon.com/sns/latest/dg/sms_stats.html) in the Amazon // SNS Developer Guide. // // Attributes is a required field Attributes map[string]string `locationName:"attributes" type:"map" required:"true"` // contains filtered or unexported fields }
The input for the SetSMSAttributes action.
func (SetSMSAttributesInput) String ¶
func (s SetSMSAttributesInput) String() string
String returns the string representation
func (*SetSMSAttributesInput) Validate ¶
func (s *SetSMSAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type SetSMSAttributesOutput ¶
type SetSMSAttributesOutput struct {
// contains filtered or unexported fields
}
The response for the SetSMSAttributes action.
func (SetSMSAttributesOutput) String ¶
func (s SetSMSAttributesOutput) String() string
String returns the string representation
type SetSMSAttributesRequest ¶
type SetSMSAttributesRequest struct { *aws.Request Input *SetSMSAttributesInput Copy func(*SetSMSAttributesInput) SetSMSAttributesRequest }
SetSMSAttributesRequest is the request type for the SetSMSAttributes API operation.
func (SetSMSAttributesRequest) Send ¶
func (r SetSMSAttributesRequest) Send(ctx context.Context) (*SetSMSAttributesResponse, error)
Send marshals and sends the SetSMSAttributes API request.
type SetSMSAttributesResponse ¶ added in v0.9.0
type SetSMSAttributesResponse struct { *SetSMSAttributesOutput // contains filtered or unexported fields }
SetSMSAttributesResponse is the response type for the SetSMSAttributes API operation.
func (*SetSMSAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *SetSMSAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the SetSMSAttributes request.
type SetSubscriptionAttributesInput ¶
type SetSubscriptionAttributesInput struct { // A map of attributes with their corresponding values. // // The following lists the names, descriptions, and values of the special request // parameters that the SetTopicAttributes action uses: // // * DeliveryPolicy – The policy that defines how Amazon SNS retries failed // deliveries to HTTP/S endpoints. // // * FilterPolicy – The simple JSON object that lets your subscriber receive // only a subset of messages, rather than receiving every message published // to the topic. // // * RawMessageDelivery – When set to true, enables raw message delivery // to Amazon SQS or HTTP/S endpoints. This eliminates the need for the endpoints // to process JSON formatting, which is otherwise created for Amazon SNS // metadata. // // * RedrivePolicy – When specified, sends undeliverable messages to the // specified Amazon SQS dead-letter queue. Messages that can't be delivered // due to client errors (for example, when the subscribed endpoint is unreachable) // or server errors (for example, when the service that powers the subscribed // endpoint becomes unavailable) are held in the dead-letter queue for further // analysis or reprocessing. // // AttributeName is a required field AttributeName *string `type:"string" required:"true"` // The new value for the attribute in JSON format. AttributeValue *string `type:"string"` // The ARN of the subscription to modify. // // SubscriptionArn is a required field SubscriptionArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for SetSubscriptionAttributes action.
func (SetSubscriptionAttributesInput) String ¶
func (s SetSubscriptionAttributesInput) String() string
String returns the string representation
func (*SetSubscriptionAttributesInput) Validate ¶
func (s *SetSubscriptionAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type SetSubscriptionAttributesOutput ¶
type SetSubscriptionAttributesOutput struct {
// contains filtered or unexported fields
}
func (SetSubscriptionAttributesOutput) String ¶
func (s SetSubscriptionAttributesOutput) String() string
String returns the string representation
type SetSubscriptionAttributesRequest ¶
type SetSubscriptionAttributesRequest struct { *aws.Request Input *SetSubscriptionAttributesInput Copy func(*SetSubscriptionAttributesInput) SetSubscriptionAttributesRequest }
SetSubscriptionAttributesRequest is the request type for the SetSubscriptionAttributes API operation.
func (SetSubscriptionAttributesRequest) Send ¶
func (r SetSubscriptionAttributesRequest) Send(ctx context.Context) (*SetSubscriptionAttributesResponse, error)
Send marshals and sends the SetSubscriptionAttributes API request.
type SetSubscriptionAttributesResponse ¶ added in v0.9.0
type SetSubscriptionAttributesResponse struct { *SetSubscriptionAttributesOutput // contains filtered or unexported fields }
SetSubscriptionAttributesResponse is the response type for the SetSubscriptionAttributes API operation.
func (*SetSubscriptionAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *SetSubscriptionAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the SetSubscriptionAttributes request.
type SetTopicAttributesInput ¶
type SetTopicAttributesInput struct { // A map of attributes with their corresponding values. // // The following lists the names, descriptions, and values of the special request // parameters that the SetTopicAttributes action uses: // // * DeliveryPolicy – The policy that defines how Amazon SNS retries failed // deliveries to HTTP/S endpoints. // // * DisplayName – The display name to use for a topic with SMS subscriptions. // // * Policy – The policy that defines who can access your topic. By default, // only the topic owner can publish or subscribe to the topic. // // The following attribute applies only to server-side-encryption (https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html): // // * KmsMasterKeyId - The ID of an AWS-managed customer master key (CMK) // for Amazon SNS or a custom CMK. For more information, see Key Terms (https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html#sse-key-terms). // For more examples, see KeyId (https://docs.aws.amazon.com/kms/latest/APIReference/API_DescribeKey.html#API_DescribeKey_RequestParameters) // in the AWS Key Management Service API Reference. // // AttributeName is a required field AttributeName *string `type:"string" required:"true"` // The new value for the attribute. AttributeValue *string `type:"string"` // The ARN of the topic to modify. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for SetTopicAttributes action.
func (SetTopicAttributesInput) String ¶
func (s SetTopicAttributesInput) String() string
String returns the string representation
func (*SetTopicAttributesInput) Validate ¶
func (s *SetTopicAttributesInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type SetTopicAttributesOutput ¶
type SetTopicAttributesOutput struct {
// contains filtered or unexported fields
}
func (SetTopicAttributesOutput) String ¶
func (s SetTopicAttributesOutput) String() string
String returns the string representation
type SetTopicAttributesRequest ¶
type SetTopicAttributesRequest struct { *aws.Request Input *SetTopicAttributesInput Copy func(*SetTopicAttributesInput) SetTopicAttributesRequest }
SetTopicAttributesRequest is the request type for the SetTopicAttributes API operation.
func (SetTopicAttributesRequest) Send ¶
func (r SetTopicAttributesRequest) Send(ctx context.Context) (*SetTopicAttributesResponse, error)
Send marshals and sends the SetTopicAttributes API request.
type SetTopicAttributesResponse ¶ added in v0.9.0
type SetTopicAttributesResponse struct { *SetTopicAttributesOutput // contains filtered or unexported fields }
SetTopicAttributesResponse is the response type for the SetTopicAttributes API operation.
func (*SetTopicAttributesResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *SetTopicAttributesResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the SetTopicAttributes request.
type SubscribeInput ¶
type SubscribeInput struct { // A map of attributes with their corresponding values. // // The following lists the names, descriptions, and values of the special request // parameters that the SetTopicAttributes action uses: // // * DeliveryPolicy – The policy that defines how Amazon SNS retries failed // deliveries to HTTP/S endpoints. // // * FilterPolicy – The simple JSON object that lets your subscriber receive // only a subset of messages, rather than receiving every message published // to the topic. // // * RawMessageDelivery – When set to true, enables raw message delivery // to Amazon SQS or HTTP/S endpoints. This eliminates the need for the endpoints // to process JSON formatting, which is otherwise created for Amazon SNS // metadata. // // * RedrivePolicy – When specified, sends undeliverable messages to the // specified Amazon SQS dead-letter queue. Messages that can't be delivered // due to client errors (for example, when the subscribed endpoint is unreachable) // or server errors (for example, when the service that powers the subscribed // endpoint becomes unavailable) are held in the dead-letter queue for further // analysis or reprocessing. Attributes map[string]string `type:"map"` // The endpoint that you want to receive notifications. Endpoints vary by protocol: // // * For the http protocol, the endpoint is an URL beginning with http:// // // * For the https protocol, the endpoint is a URL beginning with https:// // // * For the email protocol, the endpoint is an email address // // * For the email-json protocol, the endpoint is an email address // // * For the sms protocol, the endpoint is a phone number of an SMS-enabled // device // // * For the sqs protocol, the endpoint is the ARN of an Amazon SQS queue // // * For the application protocol, the endpoint is the EndpointArn of a mobile // app and device. // // * For the lambda protocol, the endpoint is the ARN of an Amazon Lambda // function. Endpoint *string `type:"string"` // The protocol you want to use. Supported protocols include: // // * http – delivery of JSON-encoded message via HTTP POST // // * https – delivery of JSON-encoded message via HTTPS POST // // * email – delivery of message via SMTP // // * email-json – delivery of JSON-encoded message via SMTP // // * sms – delivery of message via SMS // // * sqs – delivery of JSON-encoded message to an Amazon SQS queue // // * application – delivery of JSON-encoded message to an EndpointArn for // a mobile app and device. // // * lambda – delivery of JSON-encoded message to an Amazon Lambda function. // // Protocol is a required field Protocol *string `type:"string" required:"true"` // Sets whether the response from the Subscribe request includes the subscription // ARN, even if the subscription is not yet confirmed. // // * If you have the subscription ARN returned, the response includes the // ARN in all cases, even if the subscription is not yet confirmed. // // * If you don't have the subscription ARN returned, in addition to the // ARN for confirmed subscriptions, the response also includes the pending // subscription ARN value for subscriptions that aren't yet confirmed. A // subscription becomes confirmed when the subscriber calls the ConfirmSubscription // action with a confirmation token. // // If you set this parameter to true, . // // The default value is false. ReturnSubscriptionArn *bool `type:"boolean"` // The ARN of the topic you want to subscribe to. // // TopicArn is a required field TopicArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for Subscribe action.
func (SubscribeInput) String ¶
func (s SubscribeInput) String() string
String returns the string representation
func (*SubscribeInput) Validate ¶
func (s *SubscribeInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type SubscribeOutput ¶
type SubscribeOutput struct { // The ARN of the subscription if it is confirmed, or the string "pending confirmation" // if the subscription requires confirmation. However, if the API request parameter // ReturnSubscriptionArn is true, then the value is always the subscription // ARN, even if the subscription requires confirmation. SubscriptionArn *string `type:"string"` // contains filtered or unexported fields }
Response for Subscribe action.
func (SubscribeOutput) String ¶
func (s SubscribeOutput) String() string
String returns the string representation
type SubscribeRequest ¶
type SubscribeRequest struct { *aws.Request Input *SubscribeInput Copy func(*SubscribeInput) SubscribeRequest }
SubscribeRequest is the request type for the Subscribe API operation.
func (SubscribeRequest) Send ¶
func (r SubscribeRequest) Send(ctx context.Context) (*SubscribeResponse, error)
Send marshals and sends the Subscribe API request.
type SubscribeResponse ¶ added in v0.9.0
type SubscribeResponse struct { *SubscribeOutput // contains filtered or unexported fields }
SubscribeResponse is the response type for the Subscribe API operation.
func (*SubscribeResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *SubscribeResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the Subscribe request.
type Subscription ¶
type Subscription struct { // The subscription's endpoint (format depends on the protocol). Endpoint *string `type:"string"` // The subscription's owner. Owner *string `type:"string"` // The subscription's protocol. Protocol *string `type:"string"` // The subscription's ARN. SubscriptionArn *string `type:"string"` // The ARN of the subscription's topic. TopicArn *string `type:"string"` // contains filtered or unexported fields }
A wrapper type for the attributes of an Amazon SNS subscription.
func (Subscription) String ¶
func (s Subscription) String() string
String returns the string representation
type Tag ¶ added in v0.9.0
type Tag struct { // The required key portion of the tag. // // Key is a required field Key *string `min:"1" type:"string" required:"true"` // The optional value portion of the tag. // // Value is a required field Value *string `type:"string" required:"true"` // contains filtered or unexported fields }
The list of tags to be added to the specified topic.
type TagResourceInput ¶ added in v0.9.0
type TagResourceInput struct { // The ARN of the topic to which to add tags. // // ResourceArn is a required field ResourceArn *string `min:"1" type:"string" required:"true"` // The tags to be added to the specified topic. A tag consists of a required // key and an optional value. // // Tags is a required field Tags []Tag `type:"list" required:"true"` // contains filtered or unexported fields }
func (TagResourceInput) String ¶ added in v0.9.0
func (s TagResourceInput) String() string
String returns the string representation
func (*TagResourceInput) Validate ¶ added in v0.9.0
func (s *TagResourceInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type TagResourceOutput ¶ added in v0.9.0
type TagResourceOutput struct {
// contains filtered or unexported fields
}
func (TagResourceOutput) String ¶ added in v0.9.0
func (s TagResourceOutput) String() string
String returns the string representation
type TagResourceRequest ¶ added in v0.9.0
type TagResourceRequest struct { *aws.Request Input *TagResourceInput Copy func(*TagResourceInput) TagResourceRequest }
TagResourceRequest is the request type for the TagResource API operation.
func (TagResourceRequest) Send ¶ added in v0.9.0
func (r TagResourceRequest) Send(ctx context.Context) (*TagResourceResponse, error)
Send marshals and sends the TagResource API request.
type TagResourceResponse ¶ added in v0.9.0
type TagResourceResponse struct { *TagResourceOutput // contains filtered or unexported fields }
TagResourceResponse is the response type for the TagResource API operation.
func (*TagResourceResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *TagResourceResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the TagResource request.
type Topic ¶
type Topic struct { // The topic's ARN. TopicArn *string `type:"string"` // contains filtered or unexported fields }
A wrapper type for the topic's Amazon Resource Name (ARN). To retrieve a topic's attributes, use GetTopicAttributes.
type UnsubscribeInput ¶
type UnsubscribeInput struct { // The ARN of the subscription to be deleted. // // SubscriptionArn is a required field SubscriptionArn *string `type:"string" required:"true"` // contains filtered or unexported fields }
Input for Unsubscribe action.
func (UnsubscribeInput) String ¶
func (s UnsubscribeInput) String() string
String returns the string representation
func (*UnsubscribeInput) Validate ¶
func (s *UnsubscribeInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type UnsubscribeOutput ¶
type UnsubscribeOutput struct {
// contains filtered or unexported fields
}
func (UnsubscribeOutput) String ¶
func (s UnsubscribeOutput) String() string
String returns the string representation
type UnsubscribeRequest ¶
type UnsubscribeRequest struct { *aws.Request Input *UnsubscribeInput Copy func(*UnsubscribeInput) UnsubscribeRequest }
UnsubscribeRequest is the request type for the Unsubscribe API operation.
func (UnsubscribeRequest) Send ¶
func (r UnsubscribeRequest) Send(ctx context.Context) (*UnsubscribeResponse, error)
Send marshals and sends the Unsubscribe API request.
type UnsubscribeResponse ¶ added in v0.9.0
type UnsubscribeResponse struct { *UnsubscribeOutput // contains filtered or unexported fields }
UnsubscribeResponse is the response type for the Unsubscribe API operation.
func (*UnsubscribeResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *UnsubscribeResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the Unsubscribe request.
type UntagResourceInput ¶ added in v0.9.0
type UntagResourceInput struct { // The ARN of the topic from which to remove tags. // // ResourceArn is a required field ResourceArn *string `min:"1" type:"string" required:"true"` // The list of tag keys to remove from the specified topic. // // TagKeys is a required field TagKeys []string `type:"list" required:"true"` // contains filtered or unexported fields }
func (UntagResourceInput) String ¶ added in v0.9.0
func (s UntagResourceInput) String() string
String returns the string representation
func (*UntagResourceInput) Validate ¶ added in v0.9.0
func (s *UntagResourceInput) Validate() error
Validate inspects the fields of the type to determine if they are valid.
type UntagResourceOutput ¶ added in v0.9.0
type UntagResourceOutput struct {
// contains filtered or unexported fields
}
func (UntagResourceOutput) String ¶ added in v0.9.0
func (s UntagResourceOutput) String() string
String returns the string representation
type UntagResourceRequest ¶ added in v0.9.0
type UntagResourceRequest struct { *aws.Request Input *UntagResourceInput Copy func(*UntagResourceInput) UntagResourceRequest }
UntagResourceRequest is the request type for the UntagResource API operation.
func (UntagResourceRequest) Send ¶ added in v0.9.0
func (r UntagResourceRequest) Send(ctx context.Context) (*UntagResourceResponse, error)
Send marshals and sends the UntagResource API request.
type UntagResourceResponse ¶ added in v0.9.0
type UntagResourceResponse struct { *UntagResourceOutput // contains filtered or unexported fields }
UntagResourceResponse is the response type for the UntagResource API operation.
func (*UntagResourceResponse) SDKResponseMetdata ¶ added in v0.9.0
func (r *UntagResourceResponse) SDKResponseMetdata() *aws.Response
SDKResponseMetdata returns the response metadata for the UntagResource request.
Source Files ¶
- api_client.go
- api_doc.go
- api_enums.go
- api_errors.go
- api_op_AddPermission.go
- api_op_CheckIfPhoneNumberIsOptedOut.go
- api_op_ConfirmSubscription.go
- api_op_CreatePlatformApplication.go
- api_op_CreatePlatformEndpoint.go
- api_op_CreateTopic.go
- api_op_DeleteEndpoint.go
- api_op_DeletePlatformApplication.go
- api_op_DeleteTopic.go
- api_op_GetEndpointAttributes.go
- api_op_GetPlatformApplicationAttributes.go
- api_op_GetSMSAttributes.go
- api_op_GetSubscriptionAttributes.go
- api_op_GetTopicAttributes.go
- api_op_ListEndpointsByPlatformApplication.go
- api_op_ListPhoneNumbersOptedOut.go
- api_op_ListPlatformApplications.go
- api_op_ListSubscriptions.go
- api_op_ListSubscriptionsByTopic.go
- api_op_ListTagsForResource.go
- api_op_ListTopics.go
- api_op_OptInPhoneNumber.go
- api_op_Publish.go
- api_op_RemovePermission.go
- api_op_SetEndpointAttributes.go
- api_op_SetPlatformApplicationAttributes.go
- api_op_SetSMSAttributes.go
- api_op_SetSubscriptionAttributes.go
- api_op_SetTopicAttributes.go
- api_op_Subscribe.go
- api_op_TagResource.go
- api_op_Unsubscribe.go
- api_op_UntagResource.go
- api_types.go
Directories ¶
Path | Synopsis |
---|---|
Package snsiface provides an interface to enable mocking the Amazon Simple Notification Service service client for testing your code.
|
Package snsiface provides an interface to enable mocking the Amazon Simple Notification Service service client for testing your code. |