You are viewing documentation for version 2 of the AWS SDK for Ruby. Version 1 documentation can be found here.

Module: Aws::SNS

Defined in:
aws-sdk-resources/lib/aws-sdk-resources/services/sns.rb,
aws-sdk-resources/lib/aws-sdk-resources/services/sns/message_verifier.rb

Overview

This module provides a client for making API requests to Amazon Simple Notification Service.

Aws::SNS::Client

The Client class provides one-to-one mapping for each API operation.

sns = Aws::SNS::Client.new(region: 'us-east-1')
sns.operation_names
#=> [:add_permission, :check_if_phone_number_is_opted_out, :confirm_subscription, :create_platform_application, ...]

Each API operation method accepts a hash of request parameters and returns a response object.

resp = sns.add_permission(params)

See Client for more information.

Aws::SNS::Errors

Errors returned from Amazon Simple Notification Service are defined in the Errors module and extend Errors::ServiceError.

begin
  # do stuff
rescue Aws::SNS::Errors::ServiceError
  # rescues all errors returned by Amazon Simple Notification Service
end

See Errors for more information.

Defined Under Namespace

Modules: Errors, Types Classes: Client, MessageVerifier, PlatformApplication, PlatformEndpoint, Resource, Subscription, Topic