API KIRIM SMS REGULER

Untuk mengirim SMS ke satu penerima.

Perintah:

POSThttps://gsm.zenziva.net/api/sendsms/
PARAMETERDESKRIPSI
userkeyUserkey anda
passkeyPasskey anda
nohpNomor tujuan
pesanIsi pesan

Contoh respon dalam format JSON.

{	"messageId":"157365",	"to":"081111111111",	"status":"1",	"text":"Success"
}

Contoh script php:

$userkey = "xxxxxx"; //userkey lihat di zenziva
$passkey = "xxxxxx"; // set passkey di zenziva
$telepon = "081234567890";
$message = "Terima Kasih, pendaftaran atas nama $nama telah berhasil di websiteAnda.com. Silahkan baca dan download petunjuk selanjutnya. Harap Maklum";
$url = "https://gsm.zenziva.net/api/sendsms/";
$curlHandle = curl_init();
curl_setopt($curlHandle, CURLOPT_URL, $url);
curl_setopt($curlHandle, CURLOPT_HEADER, 0);
curl_setopt($curlHandle, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curlHandle, CURLOPT_TIMEOUT,30);
curl_setopt($curlHandle, CURLOPT_POST, 1);
curl_setopt($curlHandle, CURLOPT_POSTFIELDS, array( 'userkey' => $userkey, 'passkey' => $passkey, 'nohp' => $telepon, 'pesan' => $message
));
$results = json_decode(curl_exec($curlHandle), true);
curl_close($curlHandle);

API KIRIM SMS MASKING

Untuk mengirim SMS ke satu penerima.

Perintah:

POSThttps://masking.zenziva.net/api/sendsms/
PARAMETERDESKRIPSI
userkeyUserkey anda
passkeyPasskey anda
nohpNomor tujuan
pesanIsi pesan (Maksimum 580 karakter)

Contoh respon dalam format JSON.

{	"messageId":"157365",	"to":"081111111111",	"status":"1",	"text":"Success"
}

Contoh script php:

$userkey = "xxxxxx"; //userkey lihat di zenziva
$passkey = "xxxxxx"; // set passkey di zenziva
$telepon = "081234567890";
$message = "Terima Kasih, pendaftaran atas nama $nama telah berhasil di websiteAnda.com. Silahkan baca dan download petunjuk selanjutnya. Harap Maklum";
$url = "https://masking.zenziva.net/api/sendsms/";
$curlHandle = curl_init();
curl_setopt($curlHandle, CURLOPT_URL, $url);
curl_setopt($curlHandle, CURLOPT_HEADER, 0);
curl_setopt($curlHandle, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curlHandle, CURLOPT_TIMEOUT,30);
curl_setopt($curlHandle, CURLOPT_POST, 1);
curl_setopt($curlHandle, CURLOPT_POSTFIELDS, array( 'userkey' => $userkey, 'passkey' => $passkey, 'nohp' => $telepon, 'pesan' => $message
));
$results = json_decode(curl_exec($curlHandle), true);
curl_close($curlHandle);

API KIRIM SMS CENTER V2.0

API KIRIM SMS V2.0 hanya untuk pelanggan SMS Center yang terdaftar mulai dari Januari 2018.

Perintah:

POSThttp://SUBDOMAIN/api/sendsms/
PARAMETERDESKRIPSI
userkeyUserkey anda
passkeyPasskey anda
nohpNomor tujuan
pesanIsi pesan

Respon dari perintah di atas dalam format JSON.

Contoh respon:

{	"messageId":"157365",	"to":"081111111111",	"status":"1",	"text":"Success"
}

Contoh script php:

$userkey = 'XXXXX';
$passkey = 'XXXXX';
$telepon = '081111111111';
$message = 'Terima Kasih, pendaftaran atas nama $nama telah berhasil di websiteAnda.com';
$url = 'http://SUBDOMAIN_ANDA/api/sendsms/';
$curlHandle = curl_init();
curl_setopt($curlHandle, CURLOPT_URL, $url);
curl_setopt($curlHandle, CURLOPT_HEADER, 0);
curl_setopt($curlHandle, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curlHandle, CURLOPT_TIMEOUT,30);
curl_setopt($curlHandle, CURLOPT_POST, 1);
curl_setopt($curlHandle, CURLOPT_POSTFIELDS, array( 'userkey' => $userkey, 'passkey' => $passkey, 'nohp' => $telepon, 'pesan' => $message
));
$results = json_decode(curl_exec($curlHandle), true);
curl_close($curlHandle);
echo $results ;

API KIRIM PESAN WA REGULER

Perintah:

POSThttps://gsm.zenziva.net/api/sendWA/
PARAMETERDESKRIPSI
userkeyUserkey anda
passkeyPasskey anda
nohpNomor tujuan
pesanIsi pesan

Respon dari perintah di atas dalam format JSON.

Contoh respon:

{	"messageId":"157365",	"to":"081111111111",	"status":"1",	"text":"Success"
}

Contoh script php:

$userkey = "xxxxxx";
$passkey = "xxxxxx";
$telepon = "6281234567890";
$message = "Hi, This is WA message.";
$url = "https://gsm.zenziva.net/api/sendWA/";
$curlHandle = curl_init();
curl_setopt($curlHandle, CURLOPT_URL, $url);
curl_setopt($curlHandle, CURLOPT_HEADER, 0);
curl_setopt($curlHandle, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curlHandle, CURLOPT_TIMEOUT,30);
curl_setopt($curlHandle, CURLOPT_POST, 1);
curl_setopt($curlHandle, CURLOPT_POSTFIELDS, array( 'userkey' => $userkey, 'passkey' => $passkey, 'nohp' => $telepon, 'pesan' => $message
));
$results = json_decode(curl_exec($curlHandle), true);
curl_close($curlHandle);

API KIRIM PESAN WA CENTER

Perintah:

POSThttp://SUBDOMAIN/api/WAsendMsg/
PARAMETERDESKRIPSI
userkeyUserkey anda
passkeyPasskey anda
instanceWA instance ID
nohpNomor tujuan
pesanIsi pesan

Respon dari perintah di atas dalam format JSON.

Contoh respon:

{ "msg-count":1, "msg":[ { "messageId":"2349", "to":"+628123456789", "status":"1", "text":"Success" } ]
}

Contoh script php:

$userkey = "xxxxxx";
$passkey = "xxxxxx";
$instanceID = '12345';
$telepon = "6281234567890";
$message = "Hi, This is WA message.";
$url = "http://SUBDOMAIN_ANDA/api/WAsendMsg/";
$curlHandle = curl_init();
curl_setopt($curlHandle, CURLOPT_URL, $url);
curl_setopt($curlHandle, CURLOPT_HEADER, 0);
curl_setopt($curlHandle, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curlHandle, CURLOPT_TIMEOUT,30);
curl_setopt($curlHandle, CURLOPT_POST, 1);
curl_setopt($curlHandle, CURLOPT_POSTFIELDS, array( 'userkey' => $userkey, 'passkey' => $passkey, 'instance' => $instanceID, 'nohp' => $telepon, 'pesan' => $message
));
$results = json_decode(curl_exec($curlHandle), true);
curl_close($curlHandle);

API KIRIM TEXT To VOICE

Perintah:

POSThttps://console.zenziva.net/voice/api/sendvoice/
PARAMETERDESKRIPSI
userkeyUserkey anda
passkeyPasskey anda
toNomor tujuan
messageIsi pesan

Respon dari perintah di atas dalam format JSON.

Contoh respon:

{ "messageId":"2349", "to":"+628123456789", "status":"1", "text":"Success"
}

Contoh script php:

$userkey = "xxxxxx";
$passkey = "xxxxxx";
$telepon = '081111111111';
$message = 'Hi John Doe, have a nice day.';
$url = 'https://console.zenziva.net/voice/api/sendvoice/';
$curlHandle = curl_init();
curl_setopt($curlHandle, CURLOPT_URL, $url);
curl_setopt($curlHandle, CURLOPT_HEADER, 0);
curl_setopt($curlHandle, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($curlHandle, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curlHandle, CURLOPT_TIMEOUT,30);
curl_setopt($curlHandle, CURLOPT_POST, 1);
curl_setopt($curlHandle, CURLOPT_POSTFIELDS, array( 'userkey' => $userkey, 'passkey' => $passkey, 'to' => $telepon, 'message' => $message
));
$results = json_decode(curl_exec($curlHandle), true);
curl_close($curlHandle);