Skip to content

Notifications

Send messages via Slack, Discord, Teams, Telegram, email, SMS, and WhatsApp.

9 modules

ModuleDescription
Twilio โทรออกโทรออกผ่าน Twilio
Twilio ส่ง SMSส่งข้อความ SMS ผ่าน Twilio
ส่งข้อความ Discordส่งข้อความไปยัง Discord ผ่าน webhook
ส่งอีเมลส่งอีเมลผ่าน SMTP
ส่งข้อความ Slackส่งข้อความไปยัง Slack ผ่าน webhook
ส่งข้อความ Teamsส่งข้อความไปยัง Microsoft Teams ผ่าน incoming webhook
ส่งข้อความ Telegramส่งข้อความผ่าน Telegram Bot API
ส่งข้อความ WhatsAppส่งข้อความผ่าน WhatsApp Business API (Meta Cloud API)
Send NotificationSend notification to Telegram, Discord, Slack, LINE, or any webhook URL

Modules

Twilio โทรออก

communication.twilio.make_call

โทรออกผ่าน Twilio

Parameters:

NameTypeRequiredDefaultDescription
account_sidstringNo-Twilio Account SID (หรือใช้ตัวแปรสภาพแวดล้อม TWILIO_ACCOUNT_SID)
auth_tokenstringNo-Twilio Auth Token (หรือใช้ตัวแปรสภาพแวดล้อม TWILIO_AUTH_TOKEN)
from_numberstringYes-Twilio Auth Token (หรือใช้ตัวแปรสภาพแวดล้อม TWILIO_AUTH_TOKEN)
to_numberstringYes-หมายเลขโทรศัพท์ Twilio
twiml_urlstringYes-หมายเลขโทรศัพท์ผู้รับ

Output:

FieldTypeDescription
sidstringThe sid
statusstringOperation status (success/error)
tostringThe to
fromstringThe from

Example: Make automated call

yaml
from_number: +1234567890
to_number: +0987654321
twiml_url: https://example.com/voice.xml

Twilio ส่ง SMS

communication.twilio.send_sms

ส่งข้อความ SMS ผ่าน Twilio

Parameters:

NameTypeRequiredDefaultDescription
account_sidstringNo-Twilio Account SID (หรือใช้ตัวแปรสภาพแวดล้อม TWILIO_ACCOUNT_SID)
auth_tokenstringNo-Twilio Auth Token (หรือใช้ตัวแปรสภาพแวดล้อม TWILIO_AUTH_TOKEN)
from_numberstringYes-หมายเลขโทรศัพท์ Twilio (เช่น +1234567890)
to_numberstringYes-หมายเลขโทรศัพท์ Twilio (เช่น +1234567890)
messagestringYes-หมายเลขโทรศัพท์ผู้รับ (เช่น +1234567890)

Output:

FieldTypeDescription
sidstringข้อความ SMS
statusstringข้อความ SMS
tostringSID
fromstringสถานะการดำเนินการ (สำเร็จ/ข้อผิดพลาด)

Example: Send notification SMS

yaml
from_number: +1234567890
to_number: +0987654321
message: Your order has been shipped!

Example: Send verification code

yaml
from_number: +1234567890
to_number: +0987654321
message: Your verification code is: 123456

ส่งข้อความ Discord

notification.discord.send_message

ส่งข้อความไปยัง Discord ผ่าน webhook

Parameters:

NameTypeRequiredDefaultDescription
webhook_urlstringNo-Discord webhook URL (จาก env.DISCORD_WEBHOOK_URL หรืออินพุตโดยตรง)
contentstringYes-Discord webhook URL (จาก env.DISCORD_WEBHOOK_URL หรืออินพุตโดยตรง)
usernamestringNo-ข้อความที่จะส่ง
avatar_urlstringNo-แทนที่ชื่อผู้ใช้บอท (ไม่บังคับ)

Output:

FieldTypeDescription
statusstringURL รูปภาพ avatar ของบอท (ไม่บังคับ)
sentbooleanสถานะการดำเนินการ (success/error)
messagestringส่งข้อความไปยังช่อง Discord ผ่าน webhook URL

Example: Example

yaml
content: Workflow completed successfully!

ส่งอีเมล

notification.email.send

ส่งอีเมลผ่าน SMTP

Parameters:

NameTypeRequiredDefaultDescription
smtp_serverstringYes-ชื่อโฮสต์เซิร์ฟเวอร์ SMTP (เช่น smtp.gmail.com)
smtp_portnumberNo587ชื่อโฮสต์เซิร์ฟเวอร์ SMTP (เช่น smtp.gmail.com)
usernamestringYes-พอร์ต SMTP (587 สำหรับ TLS, 465 สำหรับ SSL)
passwordstringYes-ชื่อผู้ใช้ SMTP
from_emailstringYes-รหัสผ่าน SMTP (ใช้ตัวแปร env!)
to_emailstringYes-ที่อยู่อีเมลผู้ส่ง
subjectstringYes-ที่อยู่อีเมลผู้รับ
bodytextYes-หัวข้ออีเมล
htmlbooleanNoFalseเนื้อหาอีเมล (รองรับ HTML)

Output:

FieldTypeDescription
statusstringส่งเนื้อหาเป็น HTML
sentbooleanสถานะการดำเนินการ (success/error)
messagestringสถานะการดำเนินการ (success/error)

Example: Example

yaml
smtp_server: smtp.gmail.com
smtp_port: 587
from_email: bot@example.com
to_email: user@example.com
subject: Workflow Complete
body: Your automation workflow has finished successfully.

ส่งข้อความ Slack

notification.slack.send_message

ส่งข้อความไปยัง Slack ผ่าน webhook

Parameters:

NameTypeRequiredDefaultDescription
webhook_urlstringNo-Slack webhook URL (จาก env.SLACK_WEBHOOK_URL หรืออินพุตโดยตรง)
textstringYes-Slack webhook URL (จาก env.SLACK_WEBHOOK_URL หรืออินพุตโดยตรง)
channelstringNo-ข้อความที่จะส่ง
usernamestringNo-แทนที่ช่องเริ่มต้น (ไม่บังคับ)
icon_emojistringNo-แทนที่ชื่อผู้ใช้บอท (ไม่บังคับ)

Output:

FieldTypeDescription
statusstringอิโมจิไอคอนบอท (ไม่บังคับ)
sentbooleanสถานะการดำเนินการ (success/error)
messagestringสถานะการดำเนินการ (success/error)

Example: Example

yaml
text: Workflow completed successfully!

Example: Example

yaml
text: Alert: New user registered!
channel: #alerts
username: Alert Bot
icon_emoji: :warning:

ส่งข้อความ Teams

notification.teams.send_message

ส่งข้อความไปยัง Microsoft Teams ผ่าน incoming webhook

Parameters:

NameTypeRequiredDefaultDescription
webhook_urlstringYes-URL ของ Microsoft Teams incoming webhook
messagetextYes-ข้อความที่ต้องการส่ง
titlestringNo-ชื่อการ์ดข้อความ (ไม่บังคับ)
colorstringNo-รหัสสีธีมแบบ hex (ไม่บังคับ)
sectionsarrayNo-ส่วนเพิ่มเติมของ MessageCard (ไม่บังคับ)

Output:

FieldTypeDescription
okbooleanการดำเนินการสำเร็จหรือไม่
dataobjectข้อมูลตอบกลับพร้อมสถานะและ webhook_url

Example: Example

yaml
webhook_url: https://outlook.office.com/webhook/...
message: Deployment completed successfully!
title: Deploy Status
color: #00FF00

ส่งข้อความ Telegram

notification.telegram.send_message

ส่งข้อความผ่าน Telegram Bot API

Parameters:

NameTypeRequiredDefaultDescription
bot_tokenstringNo-Telegram bot token (จาก env.TELEGRAM_BOT_TOKEN หรืออินพุตโดยตรง)
chat_idstringYes-Telegram bot token (จาก env.TELEGRAM_BOT_TOKEN หรืออินพุตโดยตรง)
textstringYes-Telegram chat ID หรือชื่อผู้ใช้ช่อง
parse_modeselect (Markdown, HTML, None)NoMarkdownข้อความที่จะส่ง

Output:

FieldTypeDescription
statusstringโหมดจัดรูปแบบข้อความ
sentbooleanสถานะการดำเนินการ (success/error)
message_idnumberสถานะการดำเนินการ (success/error)
messagestringการแจ้งเตือนส่งสำเร็จหรือไม่

Example: Example

yaml
chat_id: @mychannel
text: Workflow completed!

Example: Example

yaml
chat_id: 123456789
text: *Bold* _italic_ `code`
parse_mode: Markdown

ส่งข้อความ WhatsApp

notification.whatsapp.send_message

ส่งข้อความผ่าน WhatsApp Business API (Meta Cloud API)

Parameters:

NameTypeRequiredDefaultDescription
phone_number_idstringYes-ID หมายเลขโทรศัพท์ผู้ส่งของ WhatsApp Business
tostringYes-หมายเลขโทรศัพท์ผู้รับพร้อมรหัสประเทศ
messagetextYes-ข้อความที่ต้องการส่ง
access_tokenpasswordYes-Meta access token สำหรับ WhatsApp Business API
message_typeselect (text, template)Notextประเภทของข้อความที่ต้องการส่ง
template_namestringNo-ชื่อเทมเพลตข้อความ WhatsApp (จำเป็นถ้าประเภทข้อความคือเทมเพลต)
template_languagestringNoenรหัสภาษาของเทมเพลต

Output:

FieldTypeDescription
okbooleanการดำเนินการสำเร็จหรือไม่
dataobjectข้อมูลตอบกลับพร้อมสถานะ, message_id และ to

Example: Example

yaml
phone_number_id: 1234567890
to: +1987654321
message: Your order has been shipped!
access_token: EAAx...

Example: Example

yaml
phone_number_id: 1234567890
to: +1987654321
message: 
access_token: EAAx...
message_type: template
template_name: hello_world
template_language: en

Send Notification

notify.send

Send notification to Telegram, Discord, Slack, LINE, or any webhook URL

Parameters:

NameTypeRequiredDefaultDescription
urlstringYes-Webhook URL (Telegram, Discord, Slack, or custom)
messagestringYes-Notification message content
titlestringNo-Notification message content
chat_idstringNo-Optional title (for Discord, Slack, Teams)

Output:

FieldTypeDescription
okbooleanTelegram chat ID (required for Telegram)
platformstringWhether notification was sent successfully
status_codenumberWhether notification was sent successfully
responseobjectDetected platform (telegram, discord, slack, etc.)

Example: Send Telegram notification

yaml
url: https://api.telegram.org/bot<TOKEN>/sendMessage
message: BTC: $42,350 (+1.7%)
chat_id: 123456789

Example: Send Discord notification

yaml
url: https://discord.com/api/webhooks/xxx/yyy
message: Price alert triggered!
title: Crypto Alert

Example: Send Slack notification

yaml
url: https://hooks.slack.com/services/xxx/yyy/zzz
message: Deployment completed successfully

Released under the Apache 2.0 License.