Send images, video clips, invoice PDFs, or audio guides directly by providing remote HTTP links. The AISoule engine downloads and encodes these files seamlessly for Meta's servers.
POST /v1/messages
| Type | Formats Supported | Max File Size |
|---|---|---|
image | .png, .jpeg, .webp | 5 MB |
video | .mp4, .3gp (H.264 codec recommended) | 16 MB |
document | .pdf, .doc, .xls, .zip | 100 MB |
audio | .aac, .mp3, .ogg | 16 MB |
| Parameter | Type | Required | Description |
|---|---|---|---|
to | string | Yes | Destination mobile number (country code prefix, no formatting). |
type | string | Yes | Set to matching type: image, video, document, or audio. |
[type] | object | Yes | The media payload wrapper matching your type definition (e.g. image parameter block). |
[type].link | string | Yes | Secure HTTP URL hosting the public file to send. |
[type].caption | string | No | Text description accompanying the image, video, or document. |
[type].filename | string | No | Descriptive filename overriding the URL string (mostly for documents). |
# Send Image via remote URL
curl -X POST "https://api.aisoule.com/v1/messages" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"to": "918856879188",
"type": "image",
"image": {
"link": "https://aisoule.com/images/home/calling-feature.webp",
"caption": "Check out our latest WebRTC feature dashboard! 📞"
}
}'