Overview
This node sends SMS notifications using the 97Display notification API. It supports sending messages either by selecting a predefined SMS template or by composing a custom message directly. This flexibility makes it useful for automating SMS alerts, reminders, or marketing messages within workflows.
Common scenarios:
- Sending transactional SMS notifications based on workflow events.
- Using predefined SMS templates to maintain consistent messaging.
- Sending custom SMS messages when templates are not applicable.
- Integrating SMS notifications into larger automation processes.
Practical example:
A workflow triggers when a new order is placed. The node uses a selected SMS template to notify the customer with order details. Alternatively, if no template fits, it sends a custom message entered in the node.
Properties
| Name | Meaning |
|---|---|
| Organization ID | Hidden field automatically populated from webhook data; identifies the organization context. |
| Workflow ID | Hidden field set to the current workflow's ID. |
| Use Sms Template? | Boolean option to choose between sending an SMS via a predefined template (true) or a custom message (false). |
| SMS Template | Dropdown list of available SMS templates loaded dynamically from the API; required if "Use Sms Template?" is true. |
| To | Phone number to send the SMS to; required if "Use Sms Template?" is false. |
| Message | Custom SMS message content; required if "Use Sms Template?" is false. Supports multiline input. |
| APIKey | Hidden field that takes the API key from environment variables for authenticating API requests. |
Output
The node outputs an array of JSON objects, each representing the response from the SMS API for each input item processed. Each output JSON contains the full API response confirming the SMS sending status.
If an error occurs and the node is configured to continue on failure, the output JSON will contain an error field with the error message.
No binary data is produced by this node.
Dependencies
- Requires access to the 97Display notification API endpoint at
https://notificationapitest.api97.com. - Needs an API key credential provided via an environment variable (e.g.,
MY_API_KEY) for authentication. - The node dynamically loads SMS templates from the API based on the current workflow ID.
- Proper network connectivity and valid API credentials are necessary for successful operation.
Troubleshooting
Common issues:
- Failure to load SMS templates due to invalid API key or network issues.
- Errors sending SMS if phone numbers are incorrectly formatted or missing.
- API errors if the selected template ID is invalid or the API service is down.
Error messages:
"Error loading templates: <message>": Indicates failure to fetch templates; verify API key and network.- API response errors during sending: Usually include descriptive messages; check phone number validity and API quota.
- If the node throws exceptions and does not continue, ensure "Continue On Fail" is enabled to handle partial failures gracefully.
Resolutions:
- Confirm the API key environment variable is correctly set.
- Validate phone numbers and message content before execution.
- Check API service status and permissions for the used API key.
Links and References
- 97Display Notification API Documentation (Assumed URL based on code; verify actual docs)
- n8n Documentation on Creating Custom Nodes
- General SMS formatting guidelines and best practices for international phone numbers.