Look up messages
Read one message with its timeline, list messages and cancel scheduled ones.
Get one message
curl -X GET "https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID" \
-H "Authorization: Bearer $JTSMS_API_KEY"const resp = await fetch('https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID', {
method: 'GET',
headers: { Authorization: `Bearer ${process.env.JTSMS_API_KEY}` },
});
console.log(resp.status, await resp.text());import os
import requests
resp = requests.get(
"https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID",
headers={"Authorization": f"Bearer {os.environ['JTSMS_API_KEY']}"},
timeout=30,
)
print(resp.status_code, resp.text)<?php
$ch = curl_init('https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . getenv('JTSMS_API_KEY')],
]);
$body = curl_exec($ch);
echo curl_getinfo($ch, CURLINFO_RESPONSE_CODE), ' ', $body, PHP_EOL;HTTP 200:
{
"id": "6f1c2b9e-1d2a-4c55-9a0e-2b7f0c1d3e4f",
"phone": "+2348030000000",
"text": "Your order 1042 is ready.",
"sender_id": "MYSHOP",
"route": "NG",
"country": "NG",
"segments": 1,
"cost": 35.0,
"cost_currency": "USD",
"status": "delivered",
"error_code": null,
"error_message": null,
"retry_count": 0,
"created_at": "2026-11-05T08:30:00+00:00",
"submitted_at": "2026-11-05T08:30:01+00:00",
"delivered_at": "2026-11-05T08:30:06+00:00",
"failed_at": null,
"timeline": [
{ "event": "accepted", "status": "queued", "detail": "API request received", "at": "2026-11-05T08:30:00+00:00" },
{ "event": "submitted", "status": "submitted", "detail": "Gateway accepted", "at": "2026-11-05T08:30:01+00:00" },
{ "event": "delivered", "status": "delivered", "detail": "Delivered", "at": "2026-11-05T08:30:06+00:00" }
]
}A message that is not yours, or does not exist, returns HTTP 404 with code not_found.
List messages
GET https://api.sms.jtnoble.com/v1/messages?limit=20&page=0&status=delivered| Query | Meaning |
|---|---|
page | Page number, starting at 0. |
limit | 1 to 100. Default 20. |
status | Only messages with this status. |
to | Only messages to this number. |
batch_id | Only messages of this batch. |
environment | live (default), test or all. Test keys always see test messages. |
date_from, date_to | ISO date or date and time. |
The answer has messages, total, page and limit.
Several at once
GET /v1/messages/status?ids=ID1,ID2 returns the status of each id you list.
Cancel a scheduled message
curl -X POST "https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID/cancel" \
-H "Authorization: Bearer $JTSMS_API_KEY"const resp = await fetch('https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID/cancel', {
method: 'POST',
headers: { Authorization: `Bearer ${process.env.JTSMS_API_KEY}` },
});
console.log(resp.status, await resp.text());import os
import requests
resp = requests.post(
"https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID/cancel",
headers={"Authorization": f"Bearer {os.environ['JTSMS_API_KEY']}"},
timeout=30,
)
print(resp.status_code, resp.text)<?php
$ch = curl_init('https://api.sms.jtnoble.com/v1/messages/MESSAGE_ID/cancel');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . getenv('JTSMS_API_KEY')],
]);
$body = curl_exec($ch);
echo curl_getinfo($ch, CURLINFO_RESPONSE_CODE), ' ', $body, PHP_EOL;Only messages with status scheduled can be cancelled. The charge goes back to your balance.
See all message routes.