Jump to content
Get 20% off with our White Friday Deal🥳 ×

Whatsapp Gateway | Multi Device v8.5.1


Magd Almuntaser

Recommended Posts

19 hours ago, Gusik Prasetyo said:

The message appear, select phonebook first then add contact

Om Gusik, mau tanya, ini biar bisa balas dari nomor apapun yang chat ke sender, untuk number harus kita isi apa ya?

function sendWaText(number, messagetosend) {
  var APIKey = "Hcu8aDaGnxI6Utf9kWjQsjlpX5taFy" //ganti dengan API
  var sender = "628xxxxxxxxxx"  // ganti nomer HP
  var url = "https://websitekamu/send-message"; //ganti website
  var msgtext = {
    'api_key': APIKey,
    'sender': sender,
    "number": number,
    'message': messagetosend,
    };
Edited by adhiete
Link to comment
Share on other sites

4 hours ago, adhiete said:

Om Gusik, mau tanya, ini biar bisa balas dari nomor apapun yang chat ke sender, untuk number harus kita isi apa ya?

function sendWaText(number, messagetosend) {
  var APIKey = "Hcu8aDaGnxI6Utf9kWjQsjlpX5taFy" //ganti dengan API
  var sender = "628xxxxxxxxxx"  // ganti nomer HP
  var url = "https://websitekamu/send-message"; //ganti website
  var msgtext = {
    'api_key': APIKey,
    'sender': sender,
    "number": number,
    'message': messagetosend,
    };

g bisa om, d versi ini belum bisa rotasi nomer. jadi yg balas dari nomer yang d tentukan aja. di versi yang akan datang sepertinya bisa rotasi nomer.

Link to comment
Share on other sites

10 hours ago, adhiete said:

Om Gusik, mau tanya, ini biar bisa balas dari nomor apapun yang chat ke sender, untuk number harus kita isi apa ya?

function sendWaText(number, messagetosend) {
  var APIKey = "Hcu8aDaGnxI6Utf9kWjQsjlpX5taFy" //ganti dengan API
  var sender = "628xxxxxxxxxx"  // ganti nomer HP
  var url = "https://websitekamu/send-message"; //ganti website
  var msgtext = {
    'api_key': APIKey,
    'sender': sender,
    "number": number,
    'message': messagetosend,
    };

Coba begini om..
 

function sendWaText(number, messagetosend) {
  const senders = [
    "628xxxxxxxxxx1", 
    "628xxxxxxxxxx2", 
    "628xxxxxxxxxx3"
  ]; //beberapa nomor sender yang konek dengan api key yang sama

  const randomIndex = Math.floor(Math.random() * senders.length);
  const sender = senders[randomIndex]; //random nomor sender

  const APIKey = "Hcu8aDaGnxI6Utf9kWjQsjlpX5taFy"; // Ganti dengan API
  const url = "https://websitekamu/send-message"; // Ganti website

  const msgtext = {
    'api_key': APIKey,
    'sender': sender, //nomor sender acak
    "number": number,
    'message': messagetosend,
  };

itu dari script mana om?

Link to comment
Share on other sites

1 hour ago, Dammah Sifla said:

Coba begini om..
 

function sendWaText(number, messagetosend) {
  const senders = [
    "628xxxxxxxxxx1", 
    "628xxxxxxxxxx2", 
    "628xxxxxxxxxx3"
  ]; //beberapa nomor sender yang konek dengan api key yang sama

  const randomIndex = Math.floor(Math.random() * senders.length);
  const sender = senders[randomIndex]; //random nomor sender

  const APIKey = "Hcu8aDaGnxI6Utf9kWjQsjlpX5taFy"; // Ganti dengan API
  const url = "https://websitekamu/send-message"; // Ganti website

  const msgtext = {
    'api_key': APIKey,
    'sender': sender, //nomor sender acak
    "number": number,
    'message': messagetosend,
  };

itu dari script mana om?

Itu om dam, script autoreply dari googlesheet ntar d pasang d webhook

 

 

Link to comment
Share on other sites

Hello, i want to suggest something please add multi reply for same trigger message lets suppose i want to add many messages including media, sticker, text so we can with one trigger for now we can create only one trigger with one thing, but sometimes we need to create multi images/videos and text

Link to comment
Share on other sites

@Gusik Prasetyo maksud ane si pengirimnya (lawan bicara chatnya, bukan sender) Om Gusik. Biar bisa reply to all.

Kalau sendernya sih ane maunya satu aj yang sudah ane tentuin.
Om Gusik itu scriptnya masih belum bisa kirim ya yang dulu Om kirim. Lupa halaman berapa gitu.

@Dammah Sifla ane mau cobain dulu, soalnya kalau numbernya engga di definisikan pasti error.

  const msgtext = {
    'api_key': APIKey,
    'sender': sender, //nomor sender acak
    "number": number, <<<------- ini maunya semua yang chat ke sender engga perlu numbernya di definisikan, Om.
    'message': messagetosend,
  

maksud ane itu Om Dam. Jadi semua yang chat (semua nomor yang chat ke sender) dibalas dengan apa yang sudah ane definisikan.
Scriptnya ada lengkapnya engga Om, scriptnya gagal test kirim.

 

@adriano  you install on VPS, Bro? if yes, just change .env on root your host folder. To this,

APP_URL=https://yourwebsite
WA_URL_SERVER=https://yourwebsite:yournodeport
Because i solved mine with this.

Edited by adhiete
Link to comment
Share on other sites

2 hours ago, adhiete said:

@Gusik Prasetyo maksud ane si pengirimnya (lawan bicara chatnya, bukan sender) Om Gusik. Biar bisa reply to all.

Kalau sendernya sih ane maunya satu aj yang sudah ane tentuin.
Om Gusik itu scriptnya masih belum bisa kirim ya yang dulu Om kirim. Lupa halaman berapa gitu.

@Dammah Sifla ane mau cobain dulu, soalnya kalau numbernya engga di definisikan pasti error.

  const msgtext = {
    'api_key': APIKey,
    'sender': sender, //nomor sender acak
    "number": number, <<<------- ini maunya semua yang chat ke sender engga perlu numbernya di definisikan, Om.
    'message': messagetosend,
  

maksud ane itu Om Dam. Jadi semua yang chat (semua nomor yang chat ke sender) dibalas dengan apa yang sudah ane definisikan.
Scriptnya ada lengkapnya engga Om, scriptnya gagal test kirim.

 

harusnya nomor penerima itu udah automatis om, krn dia melalui incommingMessage to Webhook dari MPWA.
lihat script lengkapnya om..

function doPost(e) {
    var data =  e.postData.contents;
    var json = JSON.parse(data);
    var number = json['from'];
    var senderMessage = json['message'];
    var file = json['bufferImage'];
    var pesan = senderMessage.toLowerCase();
    var newMessage = pesan.split(" ");
    var searchreply = autoreply(newMessage[0]);
    var type = searchreply[1];
    var messagetosend = searchreply[2];
    var file = searchreply[3];
    if(type == "file"){
        sendWaFile(number, messagetosend, file);
    } else if(type == "button") {
        sendWaButton(number, messagetosend, file);
    } else if(type == "list") {
        sendWaList(number, messagetosend, file);        
    } else {
        sendWaText(number, messagetosend); // <-- variabel number
    }
}

function sendWaText(number, messagetosend) { // <-- variabel number
  var APIKey = "Hcu8aDaGnxI6Utf9kWjQsjlpX5taFy" //ganti dengan API
  var sender = "628xxxxxxxxxx"  // ganti nomer HP
  var url = "https://websitekamu/send-message"; //ganti website
  var msgtext = {
    'api_key': APIKey,
    'sender': sender,
    "number": number, // <-- variabel number sudah automatis beda dengan sender
    'message': messagetosend,
    };
  var response = UrlFetchApp.fetch(url, {
    "method": "POST",
    "contentType": "application/json",
    "payload" : JSON.stringify(msgtext),
      });
    Logger.log(response.getContentText());
}

kalau gagal kirim coba periksa lagi variabel nya.. cek log errornya

Link to comment
Share on other sites

43 minutes ago, Hit Solanki said:

Having trouble installing node.js.

Please explain me the correct and correct method to install node.js.
and node.js. Which version of would be suitable

Are you using it on Cpanel or other panels?
Compatible version of node.js in my opinion is version 18 and above..

Link to comment
Share on other sites

14 minutes ago, Dammah Sifla said:

harusnya nomor penerima itu udah automatis om, krn dia melalui incommingMessage to Webhook dari MPWA.
lihat script lengkapnya om..

function doPost(e) {
    var data =  e.postData.contents;
    var json = JSON.parse(data);
    var number = json['from'];
    var senderMessage = json['message'];
    var file = json['bufferImage'];
    var pesan = senderMessage.toLowerCase();
    var newMessage = pesan.split(" ");
    var searchreply = autoreply(newMessage[0]);
    var type = searchreply[1];
    var messagetosend = searchreply[2];
    var file = searchreply[3];
    if(type == "file"){
        sendWaFile(number, messagetosend, file);
    } else if(type == "button") {
        sendWaButton(number, messagetosend, file);
    } else if(type == "list") {
        sendWaList(number, messagetosend, file);        
    } else {
        sendWaText(number, messagetosend); // <-- variabel number
    }
}

function sendWaText(number, messagetosend) { // <-- variabel number
  var APIKey = "Hcu8aDaGnxI6Utf9kWjQsjlpX5taFy" //ganti dengan API
  var sender = "628xxxxxxxxxx"  // ganti nomer HP
  var url = "https://websitekamu/send-message"; //ganti website
  var msgtext = {
    'api_key': APIKey,
    'sender': sender,
    "number": number, // <-- variabel number sudah automatis beda dengan sender
    'message': messagetosend,
    };
  var response = UrlFetchApp.fetch(url, {
    "method": "POST",
    "contentType": "application/json",
    "payload" : JSON.stringify(msgtext),
      });
    Logger.log(response.getContentText());
}

kalau gagal kirim coba periksa lagi variabel nya.. cek log errornya

Bahhhh, aneh, akhirnya jalan juga Om wakakaka. Asemmmmm. Argghhhh udah dua mingguan utak atik. Grrrr....
Baru jalan ini tadi Om Dam. Makasih banyak. Kayanya ada salah di tanda mungkin ya.
 

57 minutes ago, Hit Solanki said:

Having trouble installing node.js.

Please explain me the correct and correct method to install node.js.
and node.js. Which version of would be suitable

Install on VPS? cPanel? AAPanel? or?
Node 18 or above is ok. I'm using 20 on my VPS.

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...