Rest API


Send Message Personal

Untuk mengirim pesan yang isinya hanya text.

POST (URL) : https://instansender.com/api-v1/send-message
token : Device Token API Key, bisa Anda dapatkan di menu Device
number : Nomor whatsapp tujuan
message : Pesan yang dikirimkan

Contoh penggunaan PHP Curl seperti di bawah ini.

Code :

$token      = 'Token API';
$number     = '62812345678910';
$message    = 'Ini pesan percobaan';

$data = [
    'token'     => $token,
    'number'    => $number,
    'message'   => $message,
];
$url = 'https://instansender.com/api-v1/send-message';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_MAXREDIRS, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 0);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$output = curl_exec($ch);
curl_close($ch);
echo $output;

Send Media Personal

Untuk mengirim pesan yang isinya text dan lampiran media.

POST (URL) : https://instansender.com/api-v1/send-media
token : Device Token API Key, bisa Anda dapatkan di menu Device
number : Nomor whatsapp tujuan
caption : Text kalimat yang ingin Anda lampirkan di bawah gambar / lampiran
url : link gambar / lampiran pesan Anda
type : Type lampiran Anda (image, video, audio, mp3, xlsx, zip, pdf)

Contoh penggunaan PHP Curl seperti di bawah ini.

Code :

$token      = 'Token API';
$number     = '62812345678910';
$message    = 'Ini pesan percobaan';
$url        = 'https://domain.com/image.jpg';
$type       = 'image'; // type = image, video, mp3, pdf, xlsx, zip

$data = [
    'token'     => $token,
    'number'    => $number,
    'caption'   => $message,
    'url'       => $url,
    'type'      => $type
];
$url = 'https://instansender.com/api-v1/send-media';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_MAXREDIRS, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 0);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$output = curl_exec($ch);
curl_close($ch);
echo $output;

Send Message Group

Untuk mengirim pesan yang isinya hanya text.

POST (URL) : https://instansender.com/api-v1/group-send-message
token : Device Token API Key, bisa Anda dapatkan di menu Device
number : Grup ID whatsapp tujuan pesan dikirim
message : Pesan yang dikirimkan

Contoh penggunaan PHP Curl seperti di bawah ini.

Code :

$token      = 'Token API';
$number     = '120363115957493434@g.us';
$message    = 'Ini pesan percobaan';

$data = [
    'token'     => $token,
    'number'    => $number,
    'message'   => $message,
];
$url = 'https://instansender.com/api-v1/group-send-message';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_MAXREDIRS, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 0);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$output = curl_exec($ch);
curl_close($ch);
echo $output;

Send Media Group

Untuk mengirim pesan yang isinya text dan lampiran media.

POST (URL) : https://instansender.com/api-v1/group-send-media
token : Device Token API Key, bisa Anda dapatkan di menu Device
number : Nomor whatsapp tujuan
caption : Text kalimat yang ingin Anda lampirkan di bawah gambar / lampiran
url : link gambar / lampiran pesan Anda
type : Type lampiran Anda (image, video, audio, mp3, xlsx, zip, pdf)

Contoh penggunaan PHP Curl seperti di bawah ini.

Code :

$token      = 'Token API';
$number     = '120363115957493434@g.us';
$message    = 'Ini pesan percobaan';
$url        = 'https://domain.com/image.jpg';
$type       = 'image'; // type = image, video, mp3, pdf, xlsx, zip

$data = [
    'token'     => $token,
    'number'    => $number,
    'caption'   => $message,
    'url'       => $url,
    'type'      => $type
];
$url = 'https://instansender.com/api-v1/group-send-media';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_MAXREDIRS, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 0);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$output = curl_exec($ch);
curl_close($ch);
echo $output;

Get Group List ID

Untuk mendapatkan data semua grup whatsapp di akun Anda.

POST (URL) : https://instansender.com/api-v1/get-group-id
token : Device Token API Key, bisa Anda dapatkan di menu Device

Contoh penggunaan PHP Curl seperti di bawah ini.

Code :

$token      = 'Token API';

$data = [
    'token'     => $token
];
$url = 'https://instansender.com/api-v1/get-group-id';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_MAXREDIRS, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 0);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$output = curl_exec($ch);
curl_close($ch);
echo $output;

Get Group Data

Untuk mendapatkan data grup whatsapp tertentu.

POST (URL) : https://instansender.com/api-v1/get-group-data
token : Device Token API Key, bisa Anda dapatkan di menu Device
number : Grup ID whatsapp tujuan pesan dikirim

Contoh penggunaan PHP Curl seperti di bawah ini.

Code :

$token      = 'Token API';
$number     = '120363115957493434@g.us';

$data = [
    'token'     => $token,
    'number'     => $number,
];
$url = 'https://instansender.com/api-v1/get-group-data';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_MAXREDIRS, 10);
curl_setopt($ch, CURLOPT_TIMEOUT, 0);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
$output = curl_exec($ch);
curl_close($ch);
echo $output;