FAQ • How to send an e-mail message with an attachment via the HTTP API
For sending e-mail messages with the subject "Holiday" and two photos through our
library based on the cURL you can use the following example:
<?php
include "smsc_api.php";
send_sms("alex@mysite.com", "Hello", 0, 0, 0, 8, "alex2@mysite2.com", "subj=Holiday", ["/home/alex/1.jpg", "/home/alex/2.jpg"]);
?>
Send e-mail with the subject "Hello" and a photo that you previously downloaded to the server:
<?php
include "smsc_api.php";
send_sms("alex@mysite.com", "Hello, this is my photo <file /upload/files/sms/123abc/photo.jpg width=200 height=400>", 0, 0, 0, 8, "alex2@mysite2.com", "subj=Hello");
?>
← Ago All questions