FAQ
SMS API — Integration Guide
SMS API — Integration Guide
Send SMS and MMS, queue bulk messages and configure inbound webhooks with the IXICA mysms API.
https://api.mysms.caAll examples use this API host and the application success code
200. Do not substitute endpoints or codes from a third-party integration guide.Examples contain sample numbers, media URLs and placeholder IDs—not live credentials. Replace them with your own assigned DID, recipient numbers, accessible files and API key before use.
API endpoints at a glance
| Method | Endpoint | Purpose |
|---|---|---|
| POST | https://api.mysms.ca/send |
Single SMS, bulk SMS and MMS. |
| POST | https://api.mysms.ca/webhook |
Update the inbound webhook URL. |
1. How do I authenticate?
Include your account’s API key in every API request. View and manage the key in the portal under Account Settings. Requests with a missing or invalid key are rejected.
Authorization: Bearer YOUR_API_KEY
For the JSON requests below, also send Content-Type: application/json. Keep your real key private.
2. How do I send an SMS?
POST https://api.mysms.ca/send
| Field | Type / requirement | Description |
|---|---|---|
from |
string · required | Your assigned SMS DID in E.164 format. |
to |
string · required | Destination number in E.164 format. |
text |
string · required for SMS | Message text. |
Request body
{
"from": "+15145551212",
"to": "+15145550000",
"text": "Hello from API"
}
Success response — HTTP 200
{
"success": true,
"code": "200",
"message": "SMS SENT",
"message_id": "<provider_msg_id>"
}
cURL
curl -X POST "https://api.mysms.ca/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"from": "+15145551212",
"to": "+15145550000",
"text": "Hello from API"
}'
PHP (Guzzle)
This example requires Guzzle and an API_KEY environment variable containing your API key.
$client = new \GuzzleHttp\Client();
$response = $client->post('https://api.mysms.ca/send', [
'headers' => [
'Authorization' => 'Bearer ' . getenv('API_KEY'),
'Content-Type' => 'application/json',
],
'json' => [
'from' => '+15145551212',
'to' => '+15145550000',
'text' => 'Hello from API'
],
]);
echo $response->getStatusCode();
echo (string) $response->getBody();
3. How do I send bulk SMS?
Use the same /send endpoint, but set to to a JSON array of E.164 numbers. The same message is sent to every recipient; optional media can also be included.
{
"from": "+15145551212",
"to": [
"+12025550100",
"+12025550101"
],
"text": "Same text to every recipient"
}
Queued response
{
"success": true,
"code": "200",
"message": "BATCH SMS QUEUED",
"batch_id": "<batch-uuid>",
"queued_recipients": 2
}
queued_recipients is 2. A batch-queued response confirms queuing; it is not proof of delivery to each handset.cURL
curl -X POST "https://api.mysms.ca/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"from": "+15145551212",
"to": [
"+12025550100",
"+12025550101"
],
"text": "Same text to every recipient"
}'
4. How do I send an MMS?
Send a JSON request to POST https://api.mysms.ca/send with from, to and an attachments array of media URLs. The supplied MMS example does not require a text value.
{
"from": "+15145551212",
"to": "+15145550000",
"attachments": [
"https://example.com/image1.jpg",
"https://example.com/image2.png"
]
}
Both phone numbers must use E.164 format. Files must be accessible over HTTPS and comply with the supported size and type limits.
Supported content types
image/jpeg, image/jpg, image/png, image/gif, video/mp4, audio/mp3, audio/mpeg, application/pdf, text/plain
The supplied specification does not give numeric file-size limits. Confirm those limits with IXICA before production use.
5. What do the response codes mean?
| Application code | Meaning |
|---|---|
000 |
Invalid API key. |
001 |
DID not assigned. |
002 |
API functionality is not enabled on this DID. |
200 |
SMS sent successfully; webhook updates also use 200 for success. Bulk sends return BATCH SMS QUEUED. |
The JSON code field is an application code. The success examples also show HTTP 200, but these are separate values; error HTTP status mappings are not specified in the supplied reference.
6. How do I configure my inbound webhook?
POST https://api.mysms.ca/webhookAuthorization: Bearer YOUR_API_KEYContent-Type: application/json
{
"url": "https://yourapp.example.com/webhooks/sms"
}
Success response — HTTP 200
{
"code": "200",
"message": "WEBHOOK URL UPDATED"
}
Webhook updates return application code 000 for an invalid key and 200 when the URL is updated.
cURL
curl -X POST "https://api.mysms.ca/webhook" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://yourapp.example.com/webhooks/sms"
}'
7. What does an inbound SMS webhook contain?
When a message arrives on one of your DIDs, the system sends a POST request with a JSON event to your configured webhook URL.
{
"data": {
"event_type": "message.received",
"id": "<uuid>",
"completed_at": null,
"cost": null,
"direction": "inbound",
"errors": [],
"payload": {
"id": "<uuid>",
"from": {
"phone_number": "+15145551212"
},
"text": "Hello from the sender",
"to": [
{
"phone_number": "+15145550000"
}
],
"received_at": "2026-02-12T15:39:43+00:00",
"record_type": "message"
},
"record_type": "event"
}
}
8. How are inbound MMS attachments delivered?
An inbound message with attachments includes a media array under data.payload. Each item provides the media file’s public URL. The text field can be empty, as shown below.
{
"data": {
"event_type": "message.received",
"id": "<uuid>",
"direction": "inbound",
"errors": [],
"payload": {
"id": "<uuid>",
"from": {
"phone_number": "+15145551212"
},
"text": "",
"to": [
{
"phone_number": "+15145550000"
}
],
"media": [
{
"url": "https://ww2.mysms.ca/storage/mms/image1.jpg"
},
{
"url": "https://ww2.mysms.ca/storage/mms/image2.png"
}
],
"received_at": "2026-02-12T15:39:43+00:00",
"record_type": "message"
},
"record_type": "event"
}
}
attachments when sending. Read data.payload.media[].url when receiving.Inbound field reference
| Field | Type | Description |
|---|---|---|
data.event_type |
string | Always message.received. |
data.id |
string (UUID) | Unique event identifier. |
data.direction |
string | Always inbound. |
data.completed_at |
null | Reserved for future use. |
data.cost |
null | Reserved for future use. |
data.errors |
array | Empty array; reserved for future use. |
data.payload.id |
string (UUID) | Unique message identifier. |
data.payload.from.phone_number |
string | Sender’s number in E.164 format. |
data.payload.text |
string | Message body; may be empty in the MMS example. |
data.payload.to[].phone_number |
string | Your receiving DID in E.164 format. |
data.payload.received_at |
string | ISO 8601 timestamp. |
data.payload.record_type |
string | Always message. |
data.record_type |
string | Always event. |
data.payload.media |
array | Present only when attachments exist. |
data.payload.media[].url |
string | Public URL of a media file. |
9. How should my webhook acknowledge receipt?
Your endpoint must return an HTTP 2xx status code to acknowledge receipt. The supplied specification does not define retry timing, delivery guarantees, a signature-verification scheme or media retention periods; confirm those details with IXICA if your application depends on them.
Troubleshooting checklist
- Confirm the
fromnumber is assigned to your user. - Enable API functionality for the DID using the portal toggle.
- Check the Bearer API key in the Authorization header.
- Use E.164 phone numbers and valid JSON.
- For MMS, verify HTTPS accessibility and supported media types.
- For inbound messages, verify the webhook URL and return HTTP 2xx.
Share
