home/versioned_docs/version-1.6.x/help/alert_sms.md
After the threshold is triggered send alarm information and notify the recipient by SMS.
Only when you successfully configure your own SMS service will the alert SMS triggered within the monitoring system be sent correctly.
HertzBeat provides two ways to configure the SMS service: modifying the application.yml configuration file directly or configuring it through the HertzBeat frontend interface (Settings > Message Server Setting).
⚠️ Note: Only one method can be effective at a time. If both methods are configured and enabled, HertzBeat will prioritize the SMS service configured in the frontend interface.
Add/Fill in the following Tencent Cloud SMS server configuration to application.yml (replace parameters with your own SMS server configuration):
alerter:
sms:
enable: true # Whether to enable
type: tencent # SMS provider type, supports "tencent"
tencent: # Tencent Cloud SMS configuration
secret-id: AKIDbQ4VhdMr89wDedFrIcgU2PaaMvOuBCzY
secret-key: PaXGl0ziY9UcWFjUyiFlCPMr77rLkJYlyA
app-id: 1435441637
sign-name: HertzBeat
template-id: 1343434
Create a signature (sign-name) in Tencent Cloud SMS
Create a message template (template-id) in Tencent Cloud SMS
Monitor: {1}, Alert Level: {2}. Content: {3}
Create an application (app-id) in Tencent Cloud SMS
Obtain Tencent Cloud Access Management credentials (secret-id, secret-key)
To activate and use Alibaba Cloud SMS service, you can refer to the official Alibaba Cloud documentation: SMS Getting Started Guide
You can configure the Alibaba Cloud SMS service either through the graphical interface or in the application.yml file.
To use application.yml, add/fill in the following Alibaba Cloud SMS configuration (replace parameters with your own SMS server configuration):
alerter:
sms:
enable: true # Whether to enable
type: alibaba # SMS provider type, supports "alibaba"
alibaba: # Alibaba Cloud SMS configuration
access-key-id: # Your AccessKey ID
access-key-secret: # Your AccessKey Secret
sign-name: # SMS signature
template-code: # SMS template code
Create an Alibaba Cloud account and activate SMS service
Create a signature (sign-name)
Create a message template (template-code)
Monitor: `instance`, Alert Level: `priority`. Content: `content`
Obtain Access Key credentials (access-key-id, access-key-secret) :::tip Alibaba Cloud officially recommends using RAM user AccessKey with minimal permissions. :::
Now you can configure this information in your hertzbeat application.
UniSMS is an aggregated SMS service platform. You can refer to UniSMS Documentation for configuration.
Add/Fill in the following UniSMS configuration to application.yml (replace parameters with your own SMS server configuration):
alerter:
sms:
enable: true # Whether to enable
type: unisms # SMS provider type, set to unisms
unisms: # UniSMS configuration
# auth-mode: simple or hmac
auth-mode: simple
access-key-id: YOUR_ACCESS_KEY_ID
# hmac mode need to fill in access-key-secret
access-key-secret: YOUR_ACCESS_KEY_SECRET
signature: YOUR_SMS_SIGNATURE
template-id: YOUR_TEMPLATE_ID
Register UniSMS account
Create signature
Create message template
Monitor: {instance}, Alert Level: {priority}. Content: {content}
Obtain access-key-id and access-key-secret
:::note UniSMS provides two authentication methods for developers to choose from, which can be set in Console - Credential Management, with Simple Mode as default.
Now you can configure this information in your hertzbeat application.
SMSLocal is an all-in-one SMS service for businesses, with features like multi-way sending, strong security, and 24/7 support. You can refer to smslocal's Developer Documentation for configuration.
Add/Fill in the following Smslocal configuration to application.yml (replace parameters with your own SMS server configuration):
alerter:
sms:
enable: true # Whether to enable
type: smslocal # SMS provider type, set to smslocal
smslocal: # Smslocal configuration
api-key: YOUR_API_KEY_HERE
Register smslocal account
Obtain api-key
application.yml fileNow you can configure this information in your hertzbeat application.
To activate and use the AWS Cloud SMS service, refer to the official AWS documentation: SMS Getting Started Guide
You can configure the AWS Cloud SMS service either through the graphical interface or in the application.yml file.
To use application.yml, add/fill in the following AWS Cloud SMS configuration (replace parameters with your own SMS server configuration):
alerter:
sms:
enable: true # Whether to enable
type: aws # SMS provider type, supports "aws"
aws: # AWS Cloud SMS configuration
access-key-id: # Your AccessKey ID
access-key-secret: # Your AccessKey Secret
region: # Region Of Your AWS
Create an AWS Cloud account
Obtain Access Key credentials (access-key-id, access-key-secret)
Select a Specific AWS Region for SMS Messaging
Move from the AWS SMS Sandbox to Production
Verify Destination Phone Numbers (for Sandbox Mode)
The message template is fixed as follows: "Instance: {}, Priority: {}, Content: {}"
Now you can configure this information in your hertzbeat application.
To activate and use the Twilio SMS service, refer to the official Twilio documentation: SMS Getting Started Guide
You can configure the Twilio SMS service either through the graphical interface or in the application.yml file.
To use application.yml, add/fill in the following Twilio SMS configuration (replace parameters with your own SMS server configuration):
alerter:
sms:
enable: true # Whether to enable
type: twilio # SMS provider type, supports "twilio"
twilio: # Twilio SMS configuration
account-sid: # Your Twilio Account SID
auth-token: # Your Twilio Auth Token
twilio-phone-number: # Your Twilio Phone Number
Create a Twilio account
Obtain Twilio credentials
Get a Twilio Phone Number
Testing Your Configuration on Twilio
The message follows the format: "Instance: {}, Priority: {}, Content: {}"
This information can be configured in the HertzBeat application.
【Alarm notification】->【Add new recipient】 ->【Select SMS notification method】
Configure the associated alarm notification strategy⚠️ 【Add new notification strategy】-> 【Associate the recipient just set】-> 【Confirm】
Note⚠️ Adding a new recipient does not mean that it is effective to receive alarm information. It is also necessary to configure the associated alarm notification strategy, that is, to specify which messages are sent to which recipients.
If you have any issues, please provide feedback through the communication group or ISSUE!