Developers

    SMS API

    Integrate SMS sending directly into your system with our simple and well-documented REST API.

    🚀 Quick Start

    1. 01.Create your account via WhatsApp and request your API Key
    2. 02.Use the API Key in the header Authorization: Bearer SUA_API_KEY
    3. 03.Make a POST request to send your first SMS
    BASE URL

    https://api.smsgratis.online

    Endpoints

    POST/v1/send
    POST/v1/send-bulk
    GET/v1/balance
    GET/v1/status/:id
    GET/v1/history

    Code Examples

    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);

    Response

    JSON RESPONSE
    {
      "success": true,
      "id": "sms_abc123",
      "status": "sent",
      "credits_used": 1
    }

    Need help with integration?

    Our technical team is ready to help you integrate the API into your system.

    Talk to Technical Team