Sviluppatori
API SMS
Integra l'invio SMS nel tuo sistema.
🚀 Avvio Rapido
- 01.Crea account e richiedi API Key
- 02.Usa la chiave nel header
Authorization: Bearer SUA_API_KEY - 03.Fai una richiesta POST
BASE URL
https://api.smsgratis.online
Endpoints
POST
/v1/sendPOST
/v1/send-bulkGET
/v1/balanceGET
/v1/status/:idGET
/v1/historyEsempi di Codice
curl
curl -X POST https://api.smsgratis.online/v1/send \
-H "Authorization: Bearer SUA_API_KEY" \
-H "Content-Type: application/json" \
-d '{"to": "5511999999999", "message": "Hello!"}'python
import requests
response = requests.post(
"https://api.smsgratis.online/v1/send",
headers={"Authorization": "Bearer SUA_API_KEY"},
json={"to": "5511999999999", "message": "Hello!"}
)
print(response.json())javascript
const response = await fetch("https://api.smsgratis.online/v1/send", {
method: "POST",
headers: {"Authorization": "Bearer SUA_API_KEY", "Content-Type": "application/json"},
body: JSON.stringify({to: "5511999999999", message: "Hello!"})
});
const data = await response.json();php
<?php
$ch = curl_init("https://api.smsgratis.online/v1/send");
curl_setopt_array($ch, [
CURLOPT_POST => true, CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ["Authorization: Bearer SUA_API_KEY", "Content-Type: application/json"],
CURLOPT_POSTFIELDS => json_encode(["to" => "5511999999999", "message" => "Hello!"])
]);
echo curl_exec($ch);Risposta
JSON RESPONSE
{
"success": true,
"id": "sms_abc123",
"status": "sent",
"credits_used": 1
}