sns

package
v0.0.0-...-69b7239 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 17, 2016 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package sns provides a client for Amazon Simple Notification Service.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddPermissionInput

type AddPermissionInput struct {
	AWSAccountID []string        `query:"AWSAccountId.member" xml:"AWSAccountId>member"`
	ActionName   []string        `query:"ActionName.member" xml:"ActionName>member"`
	Label        aws.StringValue `query:"Label" xml:"Label"`
	TopicARN     aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

AddPermissionInput is undocumented.

type ConfirmSubscriptionInput

type ConfirmSubscriptionInput struct {
	AuthenticateOnUnsubscribe aws.StringValue `query:"AuthenticateOnUnsubscribe" xml:"AuthenticateOnUnsubscribe"`
	Token                     aws.StringValue `query:"Token" xml:"Token"`
	TopicARN                  aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

ConfirmSubscriptionInput is undocumented.

type ConfirmSubscriptionResponse

type ConfirmSubscriptionResponse struct {
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"ConfirmSubscriptionResult>SubscriptionArn"`
}

ConfirmSubscriptionResponse is undocumented.

type ConfirmSubscriptionResult

type ConfirmSubscriptionResult struct {
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"ConfirmSubscriptionResult>SubscriptionArn"`
}

ConfirmSubscriptionResult is a wrapper for ConfirmSubscriptionResponse.

type CreateEndpointResponse

type CreateEndpointResponse struct {
	EndpointARN aws.StringValue `query:"EndpointArn" xml:"CreatePlatformEndpointResult>EndpointArn"`
}

CreateEndpointResponse is undocumented.

type CreatePlatformApplicationInput

type CreatePlatformApplicationInput struct {
	Attributes MapStringToString `query:"Attributes.entry" xml:"Attributes>entry"`
	Name       aws.StringValue   `query:"Name" xml:"Name"`
	Platform   aws.StringValue   `query:"Platform" xml:"Platform"`
}

CreatePlatformApplicationInput is undocumented.

type CreatePlatformApplicationResponse

type CreatePlatformApplicationResponse struct {
	PlatformApplicationARN aws.StringValue `query:"PlatformApplicationArn" xml:"CreatePlatformApplicationResult>PlatformApplicationArn"`
}

CreatePlatformApplicationResponse is undocumented.

type CreatePlatformApplicationResult

type CreatePlatformApplicationResult struct {
	PlatformApplicationARN aws.StringValue `query:"PlatformApplicationArn" xml:"CreatePlatformApplicationResult>PlatformApplicationArn"`
}

CreatePlatformApplicationResult is a wrapper for CreatePlatformApplicationResponse.

type CreatePlatformEndpointInput

type CreatePlatformEndpointInput struct {
	Attributes             MapStringToString `query:"Attributes.entry" xml:"Attributes>entry"`
	CustomUserData         aws.StringValue   `query:"CustomUserData" xml:"CustomUserData"`
	PlatformApplicationARN aws.StringValue   `query:"PlatformApplicationArn" xml:"PlatformApplicationArn"`
	Token                  aws.StringValue   `query:"Token" xml:"Token"`
}

CreatePlatformEndpointInput is undocumented.

type CreatePlatformEndpointResult

type CreatePlatformEndpointResult struct {
	EndpointARN aws.StringValue `query:"EndpointArn" xml:"CreatePlatformEndpointResult>EndpointArn"`
}

CreatePlatformEndpointResult is a wrapper for CreateEndpointResponse.

type CreateTopicInput

type CreateTopicInput struct {
	Name aws.StringValue `query:"Name" xml:"Name"`
}

CreateTopicInput is undocumented.

type CreateTopicResponse

type CreateTopicResponse struct {
	TopicARN aws.StringValue `query:"TopicArn" xml:"CreateTopicResult>TopicArn"`
}

CreateTopicResponse is undocumented.

type CreateTopicResult

type CreateTopicResult struct {
	TopicARN aws.StringValue `query:"TopicArn" xml:"CreateTopicResult>TopicArn"`
}

CreateTopicResult is a wrapper for CreateTopicResponse.

type DeleteEndpointInput

type DeleteEndpointInput struct {
	EndpointARN aws.StringValue `query:"EndpointArn" xml:"EndpointArn"`
}

DeleteEndpointInput is undocumented.

type DeletePlatformApplicationInput

type DeletePlatformApplicationInput struct {
	PlatformApplicationARN aws.StringValue `query:"PlatformApplicationArn" xml:"PlatformApplicationArn"`
}

DeletePlatformApplicationInput is undocumented.

type DeleteTopicInput

type DeleteTopicInput struct {
	TopicARN aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

DeleteTopicInput is undocumented.

type Endpoint

type Endpoint struct {
	Attributes  MapStringToString `query:"Attributes.entry" xml:"Attributes>entry"`
	EndpointARN aws.StringValue   `query:"EndpointArn" xml:"EndpointArn"`
}

Endpoint is undocumented.

type GetEndpointAttributesInput

type GetEndpointAttributesInput struct {
	EndpointARN aws.StringValue `query:"EndpointArn" xml:"EndpointArn"`
}

GetEndpointAttributesInput is undocumented.

type GetEndpointAttributesResponse

type GetEndpointAttributesResponse struct {
	Attributes MapStringToString `query:"Attributes.entry" xml:"GetEndpointAttributesResult>Attributes>entry"`
}

GetEndpointAttributesResponse is undocumented.

type GetEndpointAttributesResult

type GetEndpointAttributesResult struct {
	Attributes MapStringToString `query:"Attributes.entry" xml:"GetEndpointAttributesResult>Attributes>entry"`
}

GetEndpointAttributesResult is a wrapper for GetEndpointAttributesResponse.

type GetPlatformApplicationAttributesInput

type GetPlatformApplicationAttributesInput struct {
	PlatformApplicationARN aws.StringValue `query:"PlatformApplicationArn" xml:"PlatformApplicationArn"`
}

GetPlatformApplicationAttributesInput is undocumented.

type GetPlatformApplicationAttributesResponse

type GetPlatformApplicationAttributesResponse struct {
	Attributes MapStringToString `query:"Attributes.entry" xml:"GetPlatformApplicationAttributesResult>Attributes>entry"`
}

GetPlatformApplicationAttributesResponse is undocumented.

type GetPlatformApplicationAttributesResult

type GetPlatformApplicationAttributesResult struct {
	Attributes MapStringToString `query:"Attributes.entry" xml:"GetPlatformApplicationAttributesResult>Attributes>entry"`
}

GetPlatformApplicationAttributesResult is a wrapper for GetPlatformApplicationAttributesResponse.

type GetSubscriptionAttributesInput

type GetSubscriptionAttributesInput struct {
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"SubscriptionArn"`
}

GetSubscriptionAttributesInput is undocumented.

type GetSubscriptionAttributesResponse

type GetSubscriptionAttributesResponse struct {
	Attributes SubscriptionAttributesMap `query:"Attributes.entry" xml:"GetSubscriptionAttributesResult>Attributes>entry"`
}

GetSubscriptionAttributesResponse is undocumented.

type GetSubscriptionAttributesResult

type GetSubscriptionAttributesResult struct {
	Attributes SubscriptionAttributesMap `query:"Attributes.entry" xml:"GetSubscriptionAttributesResult>Attributes>entry"`
}

GetSubscriptionAttributesResult is a wrapper for GetSubscriptionAttributesResponse.

type GetTopicAttributesInput

type GetTopicAttributesInput struct {
	TopicARN aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

GetTopicAttributesInput is undocumented.

type GetTopicAttributesResponse

type GetTopicAttributesResponse struct {
	Attributes TopicAttributesMap `query:"Attributes.entry" xml:"GetTopicAttributesResult>Attributes>entry"`
}

GetTopicAttributesResponse is undocumented.

type GetTopicAttributesResult

type GetTopicAttributesResult struct {
	Attributes TopicAttributesMap `query:"Attributes.entry" xml:"GetTopicAttributesResult>Attributes>entry"`
}

GetTopicAttributesResult is a wrapper for GetTopicAttributesResponse.

type ListEndpointsByPlatformApplicationInput

type ListEndpointsByPlatformApplicationInput struct {
	NextToken              aws.StringValue `query:"NextToken" xml:"NextToken"`
	PlatformApplicationARN aws.StringValue `query:"PlatformApplicationArn" xml:"PlatformApplicationArn"`
}

ListEndpointsByPlatformApplicationInput is undocumented.

type ListEndpointsByPlatformApplicationResponse

type ListEndpointsByPlatformApplicationResponse struct {
	Endpoints []Endpoint      `query:"Endpoints.member" xml:"ListEndpointsByPlatformApplicationResult>Endpoints>member"`
	NextToken aws.StringValue `query:"NextToken" xml:"ListEndpointsByPlatformApplicationResult>NextToken"`
}

ListEndpointsByPlatformApplicationResponse is undocumented.

type ListEndpointsByPlatformApplicationResult

type ListEndpointsByPlatformApplicationResult struct {
	Endpoints []Endpoint      `query:"Endpoints.member" xml:"ListEndpointsByPlatformApplicationResult>Endpoints>member"`
	NextToken aws.StringValue `query:"NextToken" xml:"ListEndpointsByPlatformApplicationResult>NextToken"`
}

ListEndpointsByPlatformApplicationResult is a wrapper for ListEndpointsByPlatformApplicationResponse.

type ListPlatformApplicationsInput

type ListPlatformApplicationsInput struct {
	NextToken aws.StringValue `query:"NextToken" xml:"NextToken"`
}

ListPlatformApplicationsInput is undocumented.

type ListPlatformApplicationsResponse

type ListPlatformApplicationsResponse struct {
	NextToken            aws.StringValue       `query:"NextToken" xml:"ListPlatformApplicationsResult>NextToken"`
	PlatformApplications []PlatformApplication `query:"PlatformApplications.member" xml:"ListPlatformApplicationsResult>PlatformApplications>member"`
}

ListPlatformApplicationsResponse is undocumented.

type ListPlatformApplicationsResult

type ListPlatformApplicationsResult struct {
	NextToken            aws.StringValue       `query:"NextToken" xml:"ListPlatformApplicationsResult>NextToken"`
	PlatformApplications []PlatformApplication `query:"PlatformApplications.member" xml:"ListPlatformApplicationsResult>PlatformApplications>member"`
}

ListPlatformApplicationsResult is a wrapper for ListPlatformApplicationsResponse.

type ListSubscriptionsByTopicInput

type ListSubscriptionsByTopicInput struct {
	NextToken aws.StringValue `query:"NextToken" xml:"NextToken"`
	TopicARN  aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

ListSubscriptionsByTopicInput is undocumented.

type ListSubscriptionsByTopicResponse

type ListSubscriptionsByTopicResponse struct {
	NextToken     aws.StringValue `query:"NextToken" xml:"ListSubscriptionsByTopicResult>NextToken"`
	Subscriptions []Subscription  `query:"Subscriptions.member" xml:"ListSubscriptionsByTopicResult>Subscriptions>member"`
}

ListSubscriptionsByTopicResponse is undocumented.

type ListSubscriptionsByTopicResult

type ListSubscriptionsByTopicResult struct {
	NextToken     aws.StringValue `query:"NextToken" xml:"ListSubscriptionsByTopicResult>NextToken"`
	Subscriptions []Subscription  `query:"Subscriptions.member" xml:"ListSubscriptionsByTopicResult>Subscriptions>member"`
}

ListSubscriptionsByTopicResult is a wrapper for ListSubscriptionsByTopicResponse.

type ListSubscriptionsInput

type ListSubscriptionsInput struct {
	NextToken aws.StringValue `query:"NextToken" xml:"NextToken"`
}

ListSubscriptionsInput is undocumented.

type ListSubscriptionsResponse

type ListSubscriptionsResponse struct {
	NextToken     aws.StringValue `query:"NextToken" xml:"ListSubscriptionsResult>NextToken"`
	Subscriptions []Subscription  `query:"Subscriptions.member" xml:"ListSubscriptionsResult>Subscriptions>member"`
}

ListSubscriptionsResponse is undocumented.

type ListSubscriptionsResult

type ListSubscriptionsResult struct {
	NextToken     aws.StringValue `query:"NextToken" xml:"ListSubscriptionsResult>NextToken"`
	Subscriptions []Subscription  `query:"Subscriptions.member" xml:"ListSubscriptionsResult>Subscriptions>member"`
}

ListSubscriptionsResult is a wrapper for ListSubscriptionsResponse.

type ListTopicsInput

type ListTopicsInput struct {
	NextToken aws.StringValue `query:"NextToken" xml:"NextToken"`
}

ListTopicsInput is undocumented.

type ListTopicsResponse

type ListTopicsResponse struct {
	NextToken aws.StringValue `query:"NextToken" xml:"ListTopicsResult>NextToken"`
	Topics    []Topic         `query:"Topics.member" xml:"ListTopicsResult>Topics>member"`
}

ListTopicsResponse is undocumented.

type ListTopicsResult

type ListTopicsResult struct {
	NextToken aws.StringValue `query:"NextToken" xml:"ListTopicsResult>NextToken"`
	Topics    []Topic         `query:"Topics.member" xml:"ListTopicsResult>Topics>member"`
}

ListTopicsResult is a wrapper for ListTopicsResponse.

type MapStringToString

type MapStringToString map[string]string

func (*MapStringToString) UnmarshalXML

func (m *MapStringToString) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

UnmarshalXML implements xml.UnmarshalXML interface for map

type MessageAttributeMap

type MessageAttributeMap map[string]MessageAttributeValue

func (*MessageAttributeMap) UnmarshalXML

func (m *MessageAttributeMap) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

UnmarshalXML implements xml.UnmarshalXML interface for map

type MessageAttributeValue

type MessageAttributeValue struct {
	BinaryValue []byte          `query:"BinaryValue" xml:"BinaryValue"`
	DataType    aws.StringValue `query:"DataType" xml:"DataType"`
	StringValue aws.StringValue `query:"StringValue" xml:"StringValue"`
}

MessageAttributeValue is undocumented.

type PlatformApplication

type PlatformApplication struct {
	Attributes             MapStringToString `query:"Attributes.entry" xml:"Attributes>entry"`
	PlatformApplicationARN aws.StringValue   `query:"PlatformApplicationArn" xml:"PlatformApplicationArn"`
}

PlatformApplication is undocumented.

type PublishInput

type PublishInput struct {
	Message           aws.StringValue     `query:"Message" xml:"Message"`
	MessageAttributes MessageAttributeMap `query:"MessageAttributes.entry" xml:"MessageAttributes>entry"`
	MessageStructure  aws.StringValue     `query:"MessageStructure" xml:"MessageStructure"`
	Subject           aws.StringValue     `query:"Subject" xml:"Subject"`
	TargetARN         aws.StringValue     `query:"TargetArn" xml:"TargetArn"`
	TopicARN          aws.StringValue     `query:"TopicArn" xml:"TopicArn"`
}

PublishInput is undocumented.

type PublishResponse

type PublishResponse struct {
	MessageID aws.StringValue `query:"MessageId" xml:"PublishResult>MessageId"`
}

PublishResponse is undocumented.

type PublishResult

type PublishResult struct {
	MessageID aws.StringValue `query:"MessageId" xml:"PublishResult>MessageId"`
}

PublishResult is a wrapper for PublishResponse.

type RemovePermissionInput

type RemovePermissionInput struct {
	Label    aws.StringValue `query:"Label" xml:"Label"`
	TopicARN aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

RemovePermissionInput is undocumented.

type SNS

type SNS struct {
	// contains filtered or unexported fields
}

SNS is a client for Amazon Simple Notification Service.

func New

func New(creds aws.CredentialsProvider, region string, client *http.Client) *SNS

New returns a new SNS client.

func (*SNS) AddPermission

func (c *SNS) AddPermission(req *AddPermissionInput) (err error)

AddPermission adds a statement to a topic's access control policy, granting access for the specified AWS accounts to the specified actions.

func (*SNS) ConfirmSubscription

func (c *SNS) ConfirmSubscription(req *ConfirmSubscriptionInput) (resp *ConfirmSubscriptionResult, err error)

ConfirmSubscription 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 This call requires an AWS signature only when the AuthenticateOnUnsubscribe flag is set to "true".

func (*SNS) CreatePlatformApplication

func (c *SNS) CreatePlatformApplication(req *CreatePlatformApplicationInput) (resp *CreatePlatformApplicationResult, err error)

CreatePlatformApplication creates a platform application object for one of the supported push notification services, such as and 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 PlatformPrincipal is certificate". For PlatformPrincipal is not applicable. For PlatformPrincipal is "client id". The PlatformCredential is also received from the notification service. For PlatformCredential is "private key". For PlatformCredential is key". For PlatformCredential is "client secret". The PlatformApplicationArn that is returned when using CreatePlatformApplication is then used as an attribute for the CreatePlatformEndpoint action. For more information, see Using Amazon SNS Mobile Push Notifications .

func (*SNS) CreatePlatformEndpoint

func (c *SNS) CreatePlatformEndpoint(req *CreatePlatformEndpointInput) (resp *CreatePlatformEndpointResult, err error)

CreatePlatformEndpoint creates an endpoint for a device and mobile app on one of the supported push notification services, such as GCM and 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 . 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 .

func (*SNS) CreateTopic

func (c *SNS) CreateTopic(req *CreateTopicInput) (resp *CreateTopicResult, err error)

CreateTopic creates a topic to which notifications can be published. Users can create at most 3000 topics. For more information, see 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.

func (*SNS) DeleteEndpoint

func (c *SNS) DeleteEndpoint(req *DeleteEndpointInput) (err error)

DeleteEndpoint deletes the endpoint from Amazon This action is idempotent. For more information, see Using Amazon SNS Mobile Push Notifications .

func (*SNS) DeletePlatformApplication

func (c *SNS) DeletePlatformApplication(req *DeletePlatformApplicationInput) (err error)

DeletePlatformApplication deletes a platform application object for one of the supported push notification services, such as and For more information, see Using Amazon SNS Mobile Push Notifications .

func (*SNS) DeleteTopic

func (c *SNS) DeleteTopic(req *DeleteTopicInput) (err error)

DeleteTopic 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.

func (*SNS) GetEndpointAttributes

func (c *SNS) GetEndpointAttributes(req *GetEndpointAttributesInput) (resp *GetEndpointAttributesResult, err error)

GetEndpointAttributes retrieves the endpoint attributes for a device on one of the supported push notification services, such as GCM and For more information, see Using Amazon SNS Mobile Push Notifications .

func (*SNS) GetPlatformApplicationAttributes

func (c *SNS) GetPlatformApplicationAttributes(req *GetPlatformApplicationAttributesInput) (resp *GetPlatformApplicationAttributesResult, err error)

GetPlatformApplicationAttributes retrieves the attributes of the platform application object for the supported push notification services, such as and For more information, see Using Amazon SNS Mobile Push Notifications .

func (*SNS) GetSubscriptionAttributes

func (c *SNS) GetSubscriptionAttributes(req *GetSubscriptionAttributesInput) (resp *GetSubscriptionAttributesResult, err error)

GetSubscriptionAttributes is undocumented.

func (*SNS) GetTopicAttributes

func (c *SNS) GetTopicAttributes(req *GetTopicAttributesInput) (resp *GetTopicAttributesResult, err error)

GetTopicAttributes returns all of the properties of a topic. Topic properties returned might differ based on the authorization of the user.

func (*SNS) ListEndpointsByPlatformApplication

func (c *SNS) ListEndpointsByPlatformApplication(req *ListEndpointsByPlatformApplicationInput) (resp *ListEndpointsByPlatformApplicationResult, err error)

ListEndpointsByPlatformApplication lists the endpoints and endpoint attributes for devices in a supported push notification service, such as GCM and 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 .

func (*SNS) ListPlatformApplications

func (c *SNS) ListPlatformApplications(req *ListPlatformApplicationsInput) (resp *ListPlatformApplicationsResult, err error)

ListPlatformApplications lists the platform application objects for the supported push notification services, such as and 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 .

func (*SNS) ListSubscriptions

func (c *SNS) ListSubscriptions(req *ListSubscriptionsInput) (resp *ListSubscriptionsResult, err error)

ListSubscriptions 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.

func (*SNS) ListSubscriptionsByTopic

func (c *SNS) ListSubscriptionsByTopic(req *ListSubscriptionsByTopicInput) (resp *ListSubscriptionsByTopicResult, err error)

ListSubscriptionsByTopic 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.

func (*SNS) ListTopics

func (c *SNS) ListTopics(req *ListTopicsInput) (resp *ListTopicsResult, err error)

ListTopics 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.

func (*SNS) Publish

func (c *SNS) Publish(req *PublishInput) (resp *PublishResult, err error)

Publish sends a message to all of a topic's subscribed endpoints. When a messageId is returned, the message has been saved and Amazon SNS will attempt to deliver it to the topic's subscribers shortly. The format of the outgoing message to each subscribed endpoint depends on the notification protocol selected. 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. The EndpointArn is returned when making a call with the CreatePlatformEndpoint action. The second example below shows a request and response for publishing to a mobile endpoint.

func (*SNS) RemovePermission

func (c *SNS) RemovePermission(req *RemovePermissionInput) (err error)

RemovePermission removes a statement from a topic's access control policy.

func (*SNS) SetEndpointAttributes

func (c *SNS) SetEndpointAttributes(req *SetEndpointAttributesInput) (err error)

SetEndpointAttributes sets the attributes for an endpoint for a device on one of the supported push notification services, such as GCM and For more information, see Using Amazon SNS Mobile Push Notifications .

func (*SNS) SetPlatformApplicationAttributes

func (c *SNS) SetPlatformApplicationAttributes(req *SetPlatformApplicationAttributesInput) (err error)

SetPlatformApplicationAttributes sets the attributes of the platform application object for the supported push notification services, such as and For more information, see Using Amazon SNS Mobile Push Notifications .

func (*SNS) SetSubscriptionAttributes

func (c *SNS) SetSubscriptionAttributes(req *SetSubscriptionAttributesInput) (err error)

SetSubscriptionAttributes allows a subscription owner to set an attribute of the topic to a new value.

func (*SNS) SetTopicAttributes

func (c *SNS) SetTopicAttributes(req *SetTopicAttributesInput) (err error)

SetTopicAttributes allows a topic owner to set an attribute of the topic to a new value.

func (*SNS) Subscribe

func (c *SNS) Subscribe(req *SubscribeInput) (resp *SubscribeResult, err error)

Subscribe 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.

func (*SNS) Unsubscribe

func (c *SNS) Unsubscribe(req *UnsubscribeInput) (err error)

Unsubscribe 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.

type SetEndpointAttributesInput

type SetEndpointAttributesInput struct {
	Attributes  MapStringToString `query:"Attributes.entry" xml:"Attributes>entry"`
	EndpointARN aws.StringValue   `query:"EndpointArn" xml:"EndpointArn"`
}

SetEndpointAttributesInput is undocumented.

type SetPlatformApplicationAttributesInput

type SetPlatformApplicationAttributesInput struct {
	Attributes             MapStringToString `query:"Attributes.entry" xml:"Attributes>entry"`
	PlatformApplicationARN aws.StringValue   `query:"PlatformApplicationArn" xml:"PlatformApplicationArn"`
}

SetPlatformApplicationAttributesInput is undocumented.

type SetSubscriptionAttributesInput

type SetSubscriptionAttributesInput struct {
	AttributeName   aws.StringValue `query:"AttributeName" xml:"AttributeName"`
	AttributeValue  aws.StringValue `query:"AttributeValue" xml:"AttributeValue"`
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"SubscriptionArn"`
}

SetSubscriptionAttributesInput is undocumented.

type SetTopicAttributesInput

type SetTopicAttributesInput struct {
	AttributeName  aws.StringValue `query:"AttributeName" xml:"AttributeName"`
	AttributeValue aws.StringValue `query:"AttributeValue" xml:"AttributeValue"`
	TopicARN       aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

SetTopicAttributesInput is undocumented.

type SubscribeInput

type SubscribeInput struct {
	Endpoint aws.StringValue `query:"Endpoint" xml:"Endpoint"`
	Protocol aws.StringValue `query:"Protocol" xml:"Protocol"`
	TopicARN aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

SubscribeInput is undocumented.

type SubscribeResponse

type SubscribeResponse struct {
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"SubscribeResult>SubscriptionArn"`
}

SubscribeResponse is undocumented.

type SubscribeResult

type SubscribeResult struct {
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"SubscribeResult>SubscriptionArn"`
}

SubscribeResult is a wrapper for SubscribeResponse.

type Subscription

type Subscription struct {
	Endpoint        aws.StringValue `query:"Endpoint" xml:"Endpoint"`
	Owner           aws.StringValue `query:"Owner" xml:"Owner"`
	Protocol        aws.StringValue `query:"Protocol" xml:"Protocol"`
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"SubscriptionArn"`
	TopicARN        aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

Subscription is undocumented.

type SubscriptionAttributesMap

type SubscriptionAttributesMap map[string]string

func (*SubscriptionAttributesMap) UnmarshalXML

func (m *SubscriptionAttributesMap) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

UnmarshalXML implements xml.UnmarshalXML interface for map

type Topic

type Topic struct {
	TopicARN aws.StringValue `query:"TopicArn" xml:"TopicArn"`
}

Topic is undocumented.

type TopicAttributesMap

type TopicAttributesMap map[string]string

func (*TopicAttributesMap) UnmarshalXML

func (m *TopicAttributesMap) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

UnmarshalXML implements xml.UnmarshalXML interface for map

type UnsubscribeInput

type UnsubscribeInput struct {
	SubscriptionARN aws.StringValue `query:"SubscriptionArn" xml:"SubscriptionArn"`
}

UnsubscribeInput is undocumented.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL