URL WhatsApp Gateway

 Buat file baru di cpanel hosting anda. Contoh Script WhatsApp Gateway


<?php

function contohscript($pesan,$hp) {

    $param = array(

        "recipient_type" => "individual",

        "to" => $hp,

        "type" => "text",

        "text" => array(

            "body" => $pesan

        ),

    );

    $data_json = json_encode($param);

    $ch = curl_init();

    curl_setopt($ch,CURLOPT_URL,"https://contohscript/api/v1/messages");

    curl_setopt($ch,CURLOPT_POST, true );

    curl_setopt($ch,CURLOPT_RETURNTRANSFER, true );

    curl_setopt($ch,CURLOPT_POSTFIELDS, $data_json);

    curl_setopt($ch,CURLOPT_HTTPHEADER, array(

        "Content-Type: application/json",

        "Authorization: Bearer dk_6463b62d93b748fb8d381e7fd60e782Xf")); 

    $response = curl_exec($ch);

    curl_close($ch);

    echo $response;    

}   


$pesan = $_POST['pesan']; //paramater yang dikirim MBT

$hp = $_POST['hp']; //paramater yang dikirim MBT

contohscript($pesan,$hp); //contoh script function dari developer WhatsApp Gateway

?>

Copy url file script WAnya

misal: https://yantonaim.web.id/coba/wabiz

Paste di Set Notifikasi MBT Tab 8). Custom WhatsApp Gateway, Simpan dan Test Ngirim

Jika gak paham integrasikan, silahkan konsultasi dengan kami.

Yanto

Author & Editor

Tim Creator BIZNIS.TOP.