Skip to content
Skip to main content
POST
/v3/channels/sns

Create an Amazon SNS channel

Create an Amazon SNS notification channel in the specified application.

The topic must be a valid Amazon SNS topic ARN (starting with arn:aws:sns:).

NYLAS API KEY

Request body

Amazon SNS channel definition

descriptionstring

A human-readable description of the Amazon SNS channel.

Example: "Production SNS channel for Events notifications"
trigger_types*array<string>

The event that triggers the notification. See the notification schemas for details about each trigger type.

See the Grants, Calendar, Events, and Messages references for information on how to trigger each event type.

topic*string

The Amazon SNS topic ARN that Nylas sends notifications to. Must start with arn:aws:sns:.

Example: "arn:aws:sns:us-east-1:123456789012:my-topic"
role_arn*string

The ARN of the IAM role that Nylas assumes to publish messages to the SNS topic. Must match arn:aws:iam::<account-id>:role/<role-name>.

Example: "arn:aws:iam::123456789012:role/nylas-sns-role"
notification_email_addressesarray<string>

The email addresses that Nylas notifies if delivery to the Amazon SNS channel fails.

compressed_deliveryboolean

If true, Nylas gzip-compresses and then base64-encodes notification payloads before delivering them. Nylas adds a content_encoding: gzip+base64 message attribute to the SNS message. To decode, base64-decode the message body, then gzip-decompress. Default is false.

Default: false
Example: true

Responses

dataobject
request_idstring

The unique ID of the request that generated this response.

POSThttps://api.us.nylas.com/v3/channels/sns

Find your API key in the Nylas Dashboard under API Keys in your application settings.

Loading editor...

Autocomplete and validation come from this endpoint's request schema.