sendblue-api
Skill này làm gì
Công cụ này cho phép chương trình máy tính gửi và nhận tin nhắn văn bản (SMS, iMessage, RCS) bằng một số điện thoại. Bạn có thể gửi tin nhắn cá nhân hoặc nhóm, thêm hiệu ứng đặc biệt, phản ứng, và thậm chí biết khi ai đó đang gõ.
Khi nào nên dùng
- ✓Khi một ứng dụng cần gửi thông báo qua SMS.
- ✓Khi xây dựng một chatbot phản hồi tin nhắn văn bản.
- ✓Khi tích hợp việc gửi tin nhắn vào một hệ thống lớn hơn.
Liên kết skill
https://github.com/sickn33/agentic-awesome-skills/blob/main/skills/sendblue/sendblue-api/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Gửi một tin nhắn có hiệu ứng đặc biệt cho một người bạn.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Chương trình của bạn gửi yêu cầu tới Sendblue API với các chi tiết tin nhắn (gửi cho ai, nội dung gì, v.v.). Sendblue xử lý việc gửi tin nhắn qua số điện thoại đã cấu hình.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Sendblue API
Overview
Sendblue is a REST API that sends iMessage (blue bubbles), SMS, and RCS from a provisioned phone number. Everything is plain JSON over HTTPS — no SDK is required. The API covers outbound 1:1 and group sends, iMessage effects, reactions, typing indicators, status callbacks, and inbound webhooks.
When to Use This Skill
- Use when writing application code (server, worker, function) that sends Sendblue messages as part of a long-running service.
- Use when receiving inbound messages via webhooks.
- Use when you need features the CLI does not expose: send styles, reactions, group messages, typing indicators, status callbacks, media uploads, or the contacts API beyond basic CRUD.
- Reach for [[sendblue-cli]] instead for shell-context outbound: one-shot scripts, cron jobs, agent hooks, "ping me when X" workflows.
How It Works
Step 1: Authenticate
https://api.sendblue.com
Every request needs two headers:
sb-api-key-id: <YOUR_API_KEY_ID>
sb-api-secret-key: <YOUR_API_SECRET>
Content-Type: application/json
Keep both values server-side — never ship them to a browser or mobile client.
Step 2: Send a message
curl -X POST https://api.sendblue.com/api/send-message \
-H "sb-api-key-id: $KEY_ID" \
-H "sb-api-secret-key: $SECRET" \
-H 'Content-Type: application/json' \
-d '{
"number": "+15551234567",
"from_number": "+1YOUR_SENDBLUE_NUMBER",
"content": "Hello from the API!"
}'
Phone numbers must be E.164. from_number must be a line you own — list yours with GET /api/lines.
Step 3: Track delivery
The synchronous response includes a message_handle (Apple GUID — persist this; you need it for reactions and replies) and a status from REGISTERED, PENDING, QUEUED, ACCEPTED, SENT, DELIVERED, DECLINED, ERROR. Only DELIVERED means it landed. Use status_callback instead of polling /api/status.
Step 4: Receive inbound
Configure webhook URLs in the dashboard or via POST /api/account/webhooks. Sendblue POSTs JSON to your endpoint. Respond with 2xx promptly — non-2xx triggers retries and duplicate deliveries. Event types: receive, outbound, typing_indicator, call_log, line_blocked, line_assigned, contact_created.
Core Endpoints
| Method | Path | Purpose |
|---|---|---|
| POST | /api/send-message |
Send a 1:1 message (text and/or media) |
| POST | /api/send-group-message |
Send to multiple recipients |
| POST | /api/create-group |
Create a named group thread |
| POST | /api/send-reaction |
Send a tapback (love/like/dislike/laugh/emphasize/question) |
| POST | /api/send-typing-indicator |
Show "typing…" in the recipient's thread |
| POST | /api/mark-read |
Send a read receipt |
| POST | /api/upload-file / /api/upload-media-object |
Upload media (direct or from URL) |
| GET | /api/status |
Poll a message's delivery status |
| GET | /api/evaluate-service |
Check whether a number is on iMessage |
| GET | /api/v2/messages / /api/v2/messages/:id |
Read message history |
| GET / POST / PUT / DELETE | /api/v2/contacts[...] |
Manage contacts |
| GET | /api/lines |
List your Sendblue phone numbers |
| POST | /api/account/webhooks |
CRUD webhook subscriptions |
Examples
Example 1: Send with media, effects, and a status callback
POST /api/send-message
{
"number": "+15551234567",
"from_number": "+1YOUR_SENDBLUE_NUMBER",
"content": "Optional text",
"media_url": "https://example.com/img.jpg",
"send_style": "celebration",
"status_callback": "https://yourapp.com/sendblue/status"
}
content and/or media_url is required. send_style is iMessage-only — valid values: celebration, shooting_star, fireworks, lasers, love, confetti, balloons, spotlight, echo, invisible, gentle, loud, slam. Ignored on SMS. Text up to 18,996 chars; media up to 100 MB on iMessage, 5 MB on SMS.
Example 2: Group message
POST /api/send-group-message
{
"numbers": ["+15551234567", "+15557654321"],
"from_number": "+1YOUR_SENDBLUE_NUMBER",
"content": "Hey team"
}
The response returns a group_id — persist it to send follow-ups into the same thread instead of creating a new one each time.
Example 3: React to a message
POST /api/send-reaction
{
"from_number": "+1YOUR_SENDBLUE_NUMBER",
"message_handle": "<message_handle from prior send>",
"reaction": "love"
}
…
Câu hỏi thường gặp
iMessage, SMS và RCS là gì?
Đây là các cách gửi tin nhắn khác nhau. iMessage là của Apple (bong bóng xanh), SMS là tin nhắn văn bản truyền thống, còn RCS là phiên bản hiện đại hơn của SMS.
“Webhooks” là gì?
Đó giống như một “thông báo” mà Sendblue gửi đến chương trình của bạn khi có tin nhắn mới đến hoặc khi tin nhắn đã gửi được chuyển đến nơi.
Tôi có thể gửi hình ảnh và video không?
Có, bạn có thể gửi đa phương tiện như ảnh và video, nhưng có giới hạn kích thước tùy theo là iMessage hay SMS.
Chi tiết
Mô tả gốc của tác giả
Send and receive iMessage, SMS, and RCS from application code via the Sendblue HTTP API — text, media, group messages, send styles, reactions, typing indicators, status callbacks, and inbound webhooks.
Độ phổ biến
- Sao GitHub
- 48k
- Vị trí xếp hạng
- #6293
- Giấy phép
- MIT
- Cập nhật
- 15/10/2026
Bình luận
- …
Thêm skill từ kho mã này
00-andruia-consultant
48kGiúp agent của bạn bắt đầu hoặc cải thiện các dự án AI. Phân tích mã, gợi ý công cụ và lập kế hoạch hành động bằng tiếng Tây Ban Nha.
007
48kCho phép agent của bạn thực hiện kiểm toán bảo mật và mô hình hóa mối đe dọa. Hữu ích để bảo vệ dự án khỏi các cuộc tấn công và lỗ hổng.
10-andruia-skill-smith
48kGiúp agent của bạn tạo hoặc cải thiện các công cụ AI. Xác định cách công cụ hoạt động, viết tài liệu và kiểm tra cấu trúc.
20-andruia-niche-intelligence
48kGiúp agent của bạn tạo bản tóm tắt về một ngành cụ thể. Hữu ích để hiểu bối cảnh, quy tắc, cách người dùng tương tác và rủi ro của dự án.
Skill tương tự
api-connector-builder
280kGiúp agent của bạn xây dựng kết nối API mới theo đúng mẫu đã có, dùng khi bạn cần thêm một tích hợp mà không tạo cách làm mới.
api-design
280kGiúp agent của bạn thiết kế REST API theo các thực hành tốt nhất, hữu ích để định nghĩa cách API giao tiếp, hiển thị lỗi và tổ chức dữ liệu.
backend-patterns
280kGiúp agent của bạn với các mẫu kiến trúc phía máy chủ và tối ưu cơ sở dữ liệu, hữu ích khi xây dựng hoặc rà soát code chạy trên máy chủ.