API methods
All API methods. Base URL: https://panel.esmsy.pl/api/v1
Account
Account, balance and sender names.
Check the key
GET/ping
The simplest call: returns ok when the key works. Changes nothing.
Responses
200 OK
| Field | Type | Description |
|---|---|---|
okrequired | boolean | Always true. |
user_idrequired | integer | Your account id. |
{
"ok": true,
"user_id": 1042
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl "https://panel.esmsy.pl/api/v1/ping" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Accept: application/json"<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/ping');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Content-Type: application/json',
'Accept: application/json',
],
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.get(
"https://panel.esmsy.pl/api/v1/ping",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"]},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/ping", {
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
},
});
console.log(response.status, await response.json());Balance
GET/balance
The account's primary wallet.
Responses
200 OK
| Field | Type | Description |
|---|---|---|
balancerequired | number | Funds on the account. |
creditrequired | number | Granted credit limit. |
viberCreditrequired | number | Not used for SMS, you can ignore it. |
realBalancerequired | number | Amount available for sending: balance + credit. |
currencyrequirednullable | string | Wallet currency, e.g. PLN. |
isPrimaryrequired | boolean | Whether this is the primary wallet that gets charged. |
{
"balance": 250.4,
"credit": 0,
"viberCredit": 0,
"realBalance": 250.4,
"currency": "PLN",
"isPrimary": true
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl "https://panel.esmsy.pl/api/v1/balance" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Accept: application/json"<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/balance');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Content-Type: application/json',
'Accept: application/json',
],
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.get(
"https://panel.esmsy.pl/api/v1/balance",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"]},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/balance", {
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
},
});
console.log(response.status, await response.json());Balance per channel
GET/balance/ext
The amount you can spend on SMS.
Responses
200 OK
| Field | Type | Description |
|---|---|---|
balancerequired | object | Available amount by channel. |
balance.smsrequired | number | Amount available for SMS. |
currencyrequirednullable | string | Wallet currency. |
{
"balance": {
"sms": 250.4
},
"currency": "PLN"
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl "https://panel.esmsy.pl/api/v1/balance/ext" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Accept: application/json"<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/balance/ext');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Content-Type: application/json',
'Accept: application/json',
],
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.get(
"https://panel.esmsy.pl/api/v1/balance/ext",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"]},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/balance/ext", {
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
},
});
console.log(response.status, await response.json());Sender names
GET/sources
Sender names that passed moderation and are active on the account. Only these are accepted as source.
Query parameters
| Field | Type | Description |
|---|---|---|
channel | string | Filter by channel. Example: sms |
Responses
200 OK
| Field | Type | Description |
|---|---|---|
datarequired | Source[] | The names. |
data[].namerequired | string | The sender name the recipient sees. |
data[].directionrequired | string | Registration scope: national or international. Values: nationalinternational |
data[].channelrequired | string | Channel the name is active for. |
data[].isDefaultrequired | boolean | The account default, used when source is omitted. |
{
"data": [
{
"name": "MojaFirma",
"direction": "national",
"channel": "sms",
"isDefault": true
}
]
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl "https://panel.esmsy.pl/api/v1/sources?channel=sms" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Accept: application/json"<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/sources?channel=sms');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Content-Type: application/json',
'Accept: application/json',
],
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.get(
"https://panel.esmsy.pl/api/v1/sources?channel=sms",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"]},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/sources?channel=sms", {
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
},
});
console.log(response.status, await response.json());Pricing
Sending prices.
Price for a number
GET/price
Price of one SMS part to a number or a network. Pass phone, or the mcc + mnc pair.
Query parameters
| Field | Type | Description |
|---|---|---|
phone | string | Recipient number. Required without mcc. Example: 48500600700 |
mcc | string | Mobile Country Code. Required without phone. Example: 260 |
mnc | string | Mobile Network Code. Required with mcc. Example: 02 |
channel | string | Channel. Defaults to sms. |
volume | integer | Planned number of messages when the price depends on volume. Defaults to 1. |
Responses
200 OK
| Field | Type | Description |
|---|---|---|
phonerequirednullable | string | The normalized number; null when asked by mcc/mnc. |
mccrequired | string | Mobile Country Code. |
mncrequired | string | Mobile Network Code. |
pricerequired | number | Price of one SMS part. |
currencyrequired | string | Price currency. |
{
"phone": "48500600700",
"mcc": "260",
"mnc": "02",
"price": 0.11,
"currency": "PLN"
}404 No price is set for this network.
{
"error": "No price configured for this destination."
}422 No phone and no mcc, an unknown mcc/mnc pair, or a number we found no network for.
{
"message": "Unable to resolve an operator for this phone number.",
"errors": {
"phone": [
"Unable to resolve an operator for this phone number."
]
}
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl "https://panel.esmsy.pl/api/v1/price?phone=48500600700" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Accept: application/json"<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/price?phone=48500600700');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Content-Type: application/json',
'Accept: application/json',
],
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.get(
"https://panel.esmsy.pl/api/v1/price?phone=48500600700",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"]},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/price?phone=48500600700", {
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
},
});
console.log(response.status, await response.json());Price list
GET/price-list
The account's full current price list: your own negotiated one, or the standard one if you have none.
Responses
200 OK
| Field | Type | Description |
|---|---|---|
currencyrequirednullable | string | Price list currency; null when there is none. |
datarequired | PriceListEntry[] | The entries. |
data[].mccrequired | string | Mobile Country Code. |
data[].mncrequired | string | Mobile Network Code. |
data[].countryrequired | integer | Internal country id. |
data[].channelrequired | string | Channel. |
data[].volumeFromrequired | integer | The price applies from this many messages. |
data[].pricerequired | number | Price of one SMS part. |
{
"currency": "PLN",
"data": [
{
"mcc": "260",
"mnc": "02",
"country": 37,
"channel": "sms",
"volumeFrom": 1,
"price": 0.11
}
]
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl "https://panel.esmsy.pl/api/v1/price-list" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Accept: application/json"<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/price-list');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Content-Type: application/json',
'Accept: application/json',
],
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.get(
"https://panel.esmsy.pl/api/v1/price-list",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"]},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/price-list", {
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
},
});
console.log(response.status, await response.json());Messages
Sending SMS and delivery statuses.
Send an SMS
POST/messages
Sends one message to one recipient right away. The charge is taken on acceptance. Keep messageId to check the status.
Supports the Idempotency-Key header.
Request body (JSON)
| Field | Type | Description |
|---|---|---|
phonerequired | string | Recipient number: 48XXXXXXXXX, +48 XXX XXX XXX or 9 digits without the prefix (we add 48). |
textrequired | string | Text. Up to 160 GSM-7 characters is one part; longer text is split by 153. Polish letters and other non-GSM-7 characters: 70 / 67. |
channel | string | Sending channel. Defaults to sms. |
source | string ≤ 30 | Sender name active on your account (see GET /sources). Without it, the account's default sender is used. |
ttl | integer 1–1440 | Message validity in minutes (1–1440). After that an undelivered message becomes expired. |
flash | boolean | Flash SMS: shown on screen at once and not saved to the inbox. |
Responses
201 Message accepted.
| Field | Type | Description |
|---|---|---|
messageIdrequirednullable | integer | Message id for GET /messages/{id}. |
campaignIdrequired | integer | Id of the send the message belongs to. |
statusrequirednullable | string | Message status at acceptance. Values: newpendingin_progresssentdeliveredviewedexpiredundeliveredstoppederrordeletedreserveduser_stoppedstop_flaginsufficient_fundsalpha_name_limitedmoderation |
costrequired | number | Amount charged, for all parts. |
{
"messageId": 918273,
"campaignId": 55120,
"status": "pending",
"cost": 0.11
}402 Not enough funds on the account.
{
"error": "insufficient_funds",
"message": "Insufficient wallet balance to cover this request."
}422 Invalid data (ValidationError), or the send cannot be launched (Error: no_chargeable_recipients when no number is valid; no_route when there is no route to the network).
{
"message": "The phone field is required.",
"errors": {
"phone": [
"The phone field is required."
]
}
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl -X POST "https://panel.esmsy.pl/api/v1/messages" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Idempotency-Key: order-2026-000123" \
-H "Content-Type: application/json" \
-d '{"phone":"48500600700","text":"Twój kod: 4821","source":"MojaFirma"}'<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/messages');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Idempotency-Key: order-2026-000123',
'Content-Type: application/json',
'Accept: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'phone' => '48500600700',
'text' => 'Twój kod: 4821',
'source' => 'MojaFirma',
]),
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.post(
"https://panel.esmsy.pl/api/v1/messages",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"], "Idempotency-Key": "order-2026-000123"},
json={"phone":"48500600700","text":"Twój kod: 4821","source":"MojaFirma"},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/messages", {
method: "POST",
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
"Idempotency-Key": "order-2026-000123",
"Content-Type": "application/json",
},
body: JSON.stringify({"phone":"48500600700","text":"Twój kod: 4821","source":"MojaFirma"}),
});
console.log(response.status, await response.json());{
"phone": "48500600700",
"text": "Twój kod: 4821",
"source": "MojaFirma"
}Message status
GET/messages/{id}
Current delivery status of a message sent from your account.
Path parameters
| Field | Type | Description |
|---|---|---|
idrequired | integer | messageId from the POST /messages response. Example: 918273 |
Responses
200 OK
| Field | Type | Description |
|---|---|---|
idrequired | integer | Message id. |
phonerequired | string | Recipient number. |
channelrequired | string | Channel. |
statusrequired | string | Delivery status, see Statuses. Values: newpendingin_progresssentdeliveredviewedexpiredundeliveredstoppederrordeletedreserveduser_stoppedstop_flaginsufficient_fundsalpha_name_limitedmoderation |
costrequired | number | Cost, for all parts. |
partrequired | integer | Always 1: a long SMS is one message. |
partsrequired | integer | How many parts the SMS was split into. |
alphaNamerequirednullable | string | Sender name. |
textrequired | string | Text. |
scheduledAtrequirednullable | string (date-time) | Scheduled send time. |
sentAtrequirednullable | string (date-time) | Time handed to the operator. |
createdAtrequirednullable | string (date-time) | Creation time. |
failureReasonrequirednullable | string | Why it was not delivered; null when fine. Values: sender_not_registeredinvalid_numberexpirednot_deliveredrejectedgateway_unavailable |
{
"id": 918273,
"phone": "48500600700",
"channel": "sms",
"status": "delivered",
"cost": 0.11,
"part": 1,
"parts": 1,
"alphaName": "MojaFirma",
"text": "Twój kod: 4821",
"scheduledAt": null,
"sentAt": "2026-12-02T10:15:04+00:00",
"createdAt": "2026-12-02T10:15:02+00:00",
"failureReason": null
}404 No such message on your account.
{
"error": "Message not found."
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl "https://panel.esmsy.pl/api/v1/messages/918273" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Accept: application/json"<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/messages/918273');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Content-Type: application/json',
'Accept: application/json',
],
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.get(
"https://panel.esmsy.pl/api/v1/messages/918273",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"]},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/messages/918273", {
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
},
});
console.log(response.status, await response.json());Send to many recipients
POST/campaigns
The same text to a list of numbers, launched right away. Invalid numbers are skipped; if none is left you get 422 no_chargeable_recipients.
Supports the Idempotency-Key header.
Request body (JSON)
| Field | Type | Description |
|---|---|---|
textrequired | string | Text, same rules as POST /messages. |
recipientsrequired | string[] | Recipient numbers, at least one. Same format as phone. |
channel | string | Sending channel. Defaults to sms. |
source | string ≤ 30 | Sender name active on your account (see GET /sources). Without it, the account's default sender is used. |
ttl | integer 1–1440 | Message validity in minutes (1–1440). After that an undelivered message becomes expired. |
flash | boolean | Flash SMS: shown on screen at once and not saved to the inbox. |
Responses
201 Send launched.
| Field | Type | Description |
|---|---|---|
idrequired | integer | Send id. |
namerequirednullable | string | Send name. |
channelrequired | string | Channel. |
typerequired | string | single: one recipient, group: a list. Values: singlegroup |
statusrequired | string | Send status. Values: newpendingin_progresssentsystem_stoppeduser_stoppederrordeletedcompleteresumestop_flaglockedtempsuspendedfrozen |
moderationReasonrequirednullable | string | Moderation hold reason, if any. |
textrequired | string | Text. |
billingBasisrequired | string | Billed per sent or per delivered. Values: sentdelivered |
deliveriesTotalrequired | integer | Number of messages in the send. |
totalCostrequired | number | Total cost. |
alphaNameIdrequirednullable | integer | Sender name id. |
alphaNamerequirednullable | string | Sender name. |
startedAtrequirednullable | string (date-time) | Send start. |
completedAtrequirednullable | string (date-time) | Send completion. |
createdAtrequirednullable | string (date-time) | Creation time. |
{
"id": 55121,
"name": null,
"channel": "sms",
"type": "group",
"status": "pending",
"moderationReason": null,
"text": "Promocja -20% do niedzieli. Sklep MojaFirma",
"billingBasis": "sent",
"deliveriesTotal": 2,
"totalCost": 0.22,
"alphaNameId": 311,
"alphaName": "MojaFirma",
"startedAt": "2026-12-02T10:20:00+00:00",
"completedAt": null,
"createdAt": "2026-12-02T10:20:00+00:00"
}402 Not enough funds on the account.
{
"error": "insufficient_funds",
"message": "Insufficient wallet balance to cover this request."
}422 Invalid data (ValidationError), or the send cannot be launched (Error: no_chargeable_recipients when no number is valid; no_route when there is no route to the network).
{
"message": "The recipients field is required.",
"errors": {
"recipients": [
"The recipients field is required."
]
}
}401 Missing or wrong key, HTTP API disabled in the panel, IP outside the filter, or a blocked account.
{
"message": "Unauthenticated."
}429 Rate limit exceeded. Wait the number of seconds in the Retry-After header.
{
"message": "Too Many Attempts."
}curl -X POST "https://panel.esmsy.pl/api/v1/campaigns" \
-H "X-Api-Key: $ESMSY_API_KEY" \
-H "Idempotency-Key: order-2026-000123" \
-H "Content-Type: application/json" \
-d '{"text":"Promocja -20% do niedzieli. Sklep MojaFirma","recipients":["48500600700","501234567"],"source":"MojaFirma"}'<?php
$ch = curl_init('https://panel.esmsy.pl/api/v1/campaigns');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => [
'X-Api-Key: ' . getenv('ESMSY_API_KEY'),
'Idempotency-Key: order-2026-000123',
'Content-Type: application/json',
'Accept: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'text' => 'Promocja -20% do niedzieli. Sklep MojaFirma',
'recipients' => ['48500600700', '501234567'],
'source' => 'MojaFirma',
]),
]);
$response = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);import os
import requests
response = requests.post(
"https://panel.esmsy.pl/api/v1/campaigns",
headers={"X-Api-Key": os.environ["ESMSY_API_KEY"], "Idempotency-Key": "order-2026-000123"},
json={"text":"Promocja -20% do niedzieli. Sklep MojaFirma","recipients":["48500600700","501234567"],"source":"MojaFirma"},
timeout=30,
)
print(response.status_code, response.json())const response = await fetch("https://panel.esmsy.pl/api/v1/campaigns", {
method: "POST",
headers: {
"X-Api-Key": process.env.ESMSY_API_KEY,
"Idempotency-Key": "order-2026-000123",
"Content-Type": "application/json",
},
body: JSON.stringify({"text":"Promocja -20% do niedzieli. Sklep MojaFirma","recipients":["48500600700","501234567"],"source":"MojaFirma"}),
});
console.log(response.status, await response.json());{
"text": "Promocja -20% do niedzieli. Sklep MojaFirma",
"recipients": [
"48500600700",
"501234567"
],
"source": "MojaFirma"
}