Documentazione api per id mittente

Documentazione | SmsGateway24.com

v.1.0

1. Ottenere un token:

Descrizione: Dopo aver eseguito con successo questa interrogazione, riceverai un token. Successivamente, puoi usare questo token per accedere al server e fare richieste aggiuntive.
Endpoint https://smsgateway24.com/getdata/gettoken
Metodo:: GET
Parametri della richiesta:
Variabile Tipo Descrizione
email string [obbligatorio] Your login in the system. Usually email
pass string [obbligatorio] Your password in the system

Risposta formattata JSON::
Variabile Tipo Descrizione
token string Il token viene acquisito attraverso il metodo di recupero token:
error int 0 <unk> 1 - indica se c'è un errore nell'elaborazione della richiesta
message string Messaggio di errore, vuoto se tutto è in ordine.
Link all'esempio di codice Curl
Link all'esempio di codice Guzzle
Esempio di risposta:
{"error":0,"message":"OK","token":"abbde3e31e9d026c02f41119fc551111e"}
or
{"error":1,"message":"Login or password incorrect"}

2. Invia SMS utilizzando l'ID Mittente.:

Descrizione: Quando hai richiesto un ID Mittente per la tua azienda, puoi inviare richieste API SMS.
Endpoint https://smsgateway24.com/getdata/addsmstosenderid
Metodo:: POST
Parametri della richiesta come JSON come:
{
    "token":"5f0eb980819f0e07b9b14d52c185ac6a",
    "send_to":"+4915752982212",
    "sender_id":2,
    "template_id":9,
    "template_data":{
        "var_1":"John",
        "order":"777"
    }
}
Dove:
Variabile Tipo Descrizione
token string [obbligatorio] Il token viene acquisito attraverso il metodo di recupero del token.
send_to string [obbligatorio] Numero di telefono del cliente. Per esempio: +4915752982212
sender_id int [obbligatorio] IDs Of your sender ID. You can find your Sender IDs here: Sender ID list
template_id int [obbligatorio] You can get your template IDs here: Template list
template_data json [opzionale] Your dynamic variable names. .

Risposta formattata JSON::
Variabile Tipo Descrizione
token string Il token viene acquisito attraverso il metodo di recupero token:
error int 0 <unk> 1 - indica se c'è un errore nell'elaborazione della richiesta
message string Messaggio di errore, vuoto se tutto è in ordine.
cost float Costo SMS
Esempio di risposta:
{"error":0,"sms_id":63752087,"message":"Sms has been saved successfully","cost":0.068}