wildix-send-message
Original:🇺🇸 English
Translated
2 scripts
Use when asked to send a message to an x-bees, collaboration 7, x-hoppers chat channel on behalf of a bot or user. Triggers on requests like "send a message to channel X", "notify channel", "post to chat", "reply to message", "send file", "attach file to message".
5installs
Sourcewildix/agent-skills
Added on
NPX Install
npx skill4agent add wildix/agent-skills wildix-send-messageTags
Translated version includes tags in frontmatterSKILL.md Content
View Translation Comparison →Send Message
Send a text message (with optional file attachments or as a reply) to an x-bees, collaboration 7, or x-hoppers channel — either as a bot or on behalf of a user.
Peer Skills
Before running, check if required peer skills are installed:
bash
Glob ~/.claude/skills/wildix-auth/SKILL.md
# If missing: npx skills add Wildix/agent-skills --s wildix-auth -ySee for full peer manifest.
peers.yamlChoosing a Token
BOT_TOKEN in .env?
YES → use bot mode (no auth needed)
NO → user wants to send as themselves?
YES → get ID_TOKEN via wildix-auth skill
NO → ask: "Provide BOT_TOKEN or send as your user account?"
BOT_TOKEN provided → save to .env, use bot mode
user account → get ID_TOKEN via wildix-auth skillMode 1: Simple text message
Bot:
bash
bash <BASE_DIR>/scripts/send-message.sh "<channelId>" "<text>"User (pass ID_TOKEN via env):
bash
ID_TOKEN="$ID_TOKEN" bash <BASE_DIR>/scripts/send-message.sh "<channelId>" "<text>"Mode 2: Reply to a message (quote)
Pass — the server renders the quoted message in the UI automatically.
--reply-to <messageId>bash
# Bot:
bash <BASE_DIR>/scripts/send-message.sh "<channelId>" "<replyText>" \
--reply-to "<messageId>"
# User (token via env):
ID_TOKEN="$ID_TOKEN" bash <BASE_DIR>/scripts/send-message.sh "<channelId>" "<replyText>" \
--reply-to "<messageId>"The is the 32-char ID from a previous message (available in chat history).
messageIdThe script automatically fetches the original message to build the full object (API requires , , , ).
quotemessageIdchannelIdcreatedAtuserMode 3: Send with file attachments
Step 1 — upload each file
bash
# Bot:
ATTACH1=$(bash <BASE_DIR>/scripts/upload-file.sh "<channelId>" "/path/to/file.pdf")
ATTACH2=$(bash <BASE_DIR>/scripts/upload-file.sh "<channelId>" "/path/to/image.png")
# User (token via env):
ATTACH1=$(ID_TOKEN="$ID_TOKEN" bash <BASE_DIR>/scripts/upload-file.sh "<channelId>" "/path/to/file.pdf")
ATTACH2=$(ID_TOKEN="$ID_TOKEN" bash <BASE_DIR>/scripts/upload-file.sh "<channelId>" "/path/to/image.png")upload-file.shMessageAttachment- Requests a presigned S3 URL from the API
- Uploads the file binary to S3
- Fetches file metadata and returns it as JSON
Step 2 — send message with attachments
bash
# Bot:
bash <BASE_DIR>/scripts/send-message.sh "<channelId>" "<text>" \
--attach "$ATTACH1" \
--attach "$ATTACH2"
# User (token via env):
ID_TOKEN="$ID_TOKEN" bash <BASE_DIR>/scripts/send-message.sh "<channelId>" "<text>" \
--attach "$ATTACH1"Mode 4: Reply with attachments
Combine and :
--reply-to--attachbash
ATTACH=$(bash <BASE_DIR>/scripts/upload-file.sh "<channelId>" "/path/to/file.pdf")
bash <BASE_DIR>/scripts/send-message.sh "<channelId>" "<text>" \
--reply-to "<messageId>" \
--attach "$ATTACH"API
| Operation | Endpoint |
|---|---|
| Send message | |
| Request upload URL | |
| Upload binary | |
| Get file metadata | |
Send message body fields:
- — message text (required unless attachments present)
text - — messageId to reply to
quote.messageId - — array of
attachmentsobjects from upload stepMessageAttachment
.env format
<BASE_DIR>/.envBOT_TOKEN=wsk-v1-...Common Mistakes
| Problem | Fix |
|---|---|
| Using AccessToken instead of IdToken | Always use IdToken (from wildix-auth) for user-mode sends |
Passing raw file path to | First run |
| On macOS |
| S3 upload 403 | Presigned URL expired — re-run |