Skip to main content
View SourceRelease Notes

Simple Notification Service (SNS) Topic Module

This module makes it easy to deploy a SNS topic along with the publisher and subscriber policies for the topic.

How do I access the SNS topic?

This module includes several Terraform outputs, including:

  1. topic_name: The Name of the created topic
  2. topic_display_name: The Display Name of the created topic
  3. topic_arn: The ARN of the created topic
  4. topic_policy: The Access policy of the created topic

Reference

Required

namestringrequired

The name of the SNS topic.

Optional

allow_publish_accountslist(string)optional

A list of IAM ARNs that will be given the rights to publish to the SNS topic.

[]
allow_publish_serviceslist(string)optional

A list of AWS services that will be given the rights to publish to the SNS topic.

[]
allow_subscribe_accountslist(string)optional

A list of IAM ARNs that will be given the rights to subscribe to the SNS topic.

[]
allow_subscribe_protocolslist(string)optional

A list of protocols that are allowed for subscription.

[
"http",
"https",
"email",
"email-json",
"sms",
"sqs",
"application",
"lambda"
]
create_resourcesbooloptional

Enable or disable creation of the resources of this module.

true
display_namestringoptional

The display name of the SNS topic. NOTE: Maximum length is 100 characters.

""
kms_master_key_idstringoptional

The ID of an AWS-managed customer master key (CMK) for Amazon SNS or a custom CMK

null
tagsmap(string)optional

A map of key value pairs to apply as tags to the SNS topic.

{}