← 返回 Skills 市场
mattboston

SMS Gateway

作者 Matt Shields · GitHub ↗ · v0.0.4 · MIT-0
cross-platform ✓ 安全检测通过
241
总下载
0
收藏
0
当前安装
3
版本数
在 OpenClaw 中安装
/install gsm-sms-gateway
功能描述
Send and receive SMS messages through a self-hosted SMS Gateway running on a USB GSM modem. Use when the user needs to send text messages, check for incoming...
使用说明 (SKILL.md)

SMS Gateway Skill

You can send and receive SMS messages through the SMS Gateway using shell scripts located in ~/.openclaw/workspace/skills/sms-gateway/scripts.

Prerequisites

Before using the SMS Gateway skill with OpenClaw, you need to install the SMS Gateway service. Read the README.md for more details.

Setup

Before using this skill, create a .env file in the ~/.openclaw/workspace/skills/sms-gateway/scripts directory with the following variables:

SMS_GATEWAY_URL=http://127.0.0.1:5174
SMS_GATEWAY_API_KEY=your-api-key-here

If the .env file is missing or SMS_GATEWAY_API_KEY is not set, the scripts will exit with an error.

Allowlist

The file ~/.openclaw/workspace/skills/sms-gateway/scripts/allowlist.json contains a list of users and phone numbers that are permitted to send and receive messages. The send script will refuse to send to numbers not in this list. The receive script only shows messages from allowlisted numbers by default, filtering out unknown senders. To add or remove allowed contacts, edit the allowlist.json file directly.

Capabilities

Send an SMS

Send a text message to an allowed phone number.

~/.openclaw/workspace/skills/sms-gateway/scripts/send_sms.sh -t "+15551234567" -m "Hello from SMS Gateway"

Options:

  • -t - Recipient phone number (must be in allowlist.json)
  • -m - Message body

The script validates the recipient against allowlist.json before sending. If the number is not in the allowlist, it prints the list of allowed numbers and exits with an error.

On success, the script prints "Message sent successfully." followed by the JSON response containing the message ID and status.

On failure, the script prints the HTTP status code and error response.

Receive SMS Messages

Check the inbox for received messages.

~/.openclaw/workspace/skills/sms-gateway/scripts/receive_sms.sh

Options:

  • -s \x3Cstatus> - Filter by status: received (default), read, or all
  • -a - Include messages from numbers not in the allowlist (by default, only allowlisted numbers are shown)

Examples:

~/.openclaw/workspace/skills/sms-gateway/scripts/receive_sms.sh              # Unread messages from allowlisted numbers
~/.openclaw/workspace/skills/sms-gateway/scripts/receive_sms.sh -s all       # All messages from allowlisted numbers
~/.openclaw/workspace/skills/sms-gateway/scripts/receive_sms.sh -s read      # Previously read messages from allowlisted numbers
~/.openclaw/workspace/skills/sms-gateway/scripts/receive_sms.sh -a           # Unread messages from all numbers
~/.openclaw/workspace/skills/sms-gateway/scripts/receive_sms.sh -a -s all    # All messages from all numbers

The script displays each message with its timestamp, sender number, status, body, and ID. Any unread messages (status=received) are automatically marked as read after being displayed. By default, messages from numbers not in allowlist.json are filtered out.

Output Format

Send output

Message sent successfully.
{
  "id": "uuid",
  "status": "sent",
  "message": "message sent"
}

Receive output

Inbox messages (received): 2

[2026-03-08T12:00:00Z] From: +15551234567
  Status: received
  Body: Hey there
  ID: some-uuid

Marked message some-uuid as read.

Usage Guidelines

  • Only send SMS messages to numbers listed in allowlist.json
  • Only accept SMS messages from numbers listed in allowlist.json
  • Always include the country code in phone numbers (e.g., +1 for US)
  • When the user asks to "text" or "message" someone, use send_sms.sh
  • When the user asks about new messages, run receive_sms.sh with no flags
  • When the user asks to see all messages, run receive_sms.sh -s all
  • If a send fails, relay the error message to the user
  • Only use the send_sms.sh and receive_sms.sh scripts to send and receive, do not communicate directly with the SMS_GATEWAY_API_KEY
  • When you receive an SMS from a contact, check whether you previously sent an SMS to that same number in the current session or a recent workflow — if so, treat the incoming message as a reply to that conversation rather than an unrelated inbound message

Troubleshooting

"Phone number is not in the allowlist"

The recipient number must exactly match an entry in allowlist.json, including the country code prefix (e.g., +1). Check the allowlist and add the number if appropriate.

"SMS_GATEWAY_API_KEY is not set"

Create a .env file in ~/.openclaw/workspace/skills/sms-gateway/scripts/ with your API key. See the Setup section above.

Send fails with error

Check that the SMS Gateway is running and accessible at the URL configured in .env. You can verify connectivity with:

curl -s http://127.0.0.1:5174/api/v1/health
安全使用建议
This skill appears to do what it claims: call a local SMS Gateway API to send/receive messages and enforce a local allowlist. Before installing or using it, consider: 1) The README suggests installing a separate SMS Gateway service via a remote install script (curl | sudo bash) — review that install script before running it; 2) The gateway has a known default admin user/password on first-run (admin/admin123) — change it immediately and use a strong JWT/API secret; 3) The SMS_GATEWAY_API_KEY is stored/read from a plaintext .env file in the skill directory by default — ensure file permissions are restrictive and that you trust the machine/user accounts that can read it; 4) Confirm SMS_GATEWAY_URL is pointed to a local, trusted instance (default localhost:5174) before starting to avoid unintentionally sending API requests to a remote host; 5) Follow the skill’s allowlist guidance (only send to/accept from listed numbers) and review allowlist.json periodically. If you want extra assurance, inspect the referenced SMS Gateway install script and the service’s API behavior before connecting this skill to a production SIM or sensitive phone numbers.
功能分析
Type: OpenClaw Skill Name: gsm-sms-gateway Version: 0.0.4 The skill bundle provides a legitimate interface for a self-hosted GSM SMS gateway. It consists of shell scripts (send_sms.sh, receive_sms.sh) that interact with a local API using curl and jq, and includes security features such as a mandatory API key and a phone number allowlist (allowlist.json) to prevent unauthorized usage. No evidence of data exfiltration, malicious execution, or prompt injection was found.
能力评估
Purpose & Capability
Name/description match the included scripts and README. The skill only requires curl and jq and a single SMS_GATEWAY_API_KEY to talk to a local SMS Gateway API URL (default localhost:5174), which is proportionate for a local SMS gateway integration.
Instruction Scope
SKILL.md limits runtime activity to running the provided send_sms.sh and receive_sms.sh scripts and editing a local allowlist.json. It instructs the agent not to access the API key directly. One minor note: guidance to 'check whether you previously sent an SMS in the current session' depends on agent session memory (not the scripts) — this is an application-level behavior, not a hidden I/O operation. The scripts themselves only read files from their script directory and call the configured SMS_GATEWAY_URL.
Install Mechanism
There is no install spec executed by the skill (instruction-only for the agent plus local scripts). The README references an external GitHub install script for installing the SMS Gateway service, but that script is not executed by the skill itself. Because the skill does not automatically download or extract remote code at install/runtime, install risk is low — users should review any external install scripts before running them.
Credentials
Only a single credential is requested (SMS_GATEWAY_API_KEY) and it is the declared primaryEnv. The scripts read a local .env or environment variables and use the API key only in requests to the configured SMS_GATEWAY_URL. No unrelated secrets or multiple service credentials are requested.
Persistence & Privilege
Skill is not always:true, does not claim system-wide modifications, and only operates within its workspace scripts and allowlist.json. It does not modify other skills or global agent configuration.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install gsm-sms-gateway
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /gsm-sms-gateway 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v0.0.4
- Added a direct link to the SMS Gateway README for installation instructions in the Prerequisites section. - No other user-facing functionality or instructions were changed.
v0.0.3
- Major cleanup: removed all example scripts and documentation files from the repository. - README.md and all shell scripts (send, receive, allowlist, config) are no longer included. - SKILL.md updated to reference external README for installation. - Core usage details and troubleshooting guidance remain available in SKILL.md.
v0.0.2
- Added detailed setup instructions, including required environment variables and allowlist management. - Documented usage of send_sms.sh and receive_sms.sh scripts for controlled SMS sending and receiving. - Described output formats for both sending and receiving SMS messages. - Provided clear usage guidelines, including safety precautions for allowed contacts. - Included troubleshooting tips for common errors such as missing API keys or allowlist issues.
元数据
Slug gsm-sms-gateway
版本 0.0.4
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 3
常见问题

SMS Gateway 是什么?

Send and receive SMS messages through a self-hosted SMS Gateway running on a USB GSM modem. Use when the user needs to send text messages, check for incoming... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 241 次。

如何安装 SMS Gateway?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install gsm-sms-gateway」即可一键安装,无需额外配置。

SMS Gateway 是免费的吗?

是的,SMS Gateway 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

SMS Gateway 支持哪些平台?

SMS Gateway 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 SMS Gateway?

由 Matt Shields(@mattboston)开发并维护,当前版本 v0.0.4。

💬 留言讨论