Closed Parveen-Mothsara closed 1 year ago
Looks like they put a limit on opening new conversations by link. 2 numbers of mine have already stopped, it only works with number already open before
any solution?
Is this error fired using Whatsapp Multi device Beta?
for now is to use the API solution > wapi.js > WAPI.sendMessageToID()
// use this code window.WAPI.sendMessageToID2 = function (id, message, done) { try { // Create user var idx = new window.Store.UserConstructor(id, {intentionallyUsePrivateConstructor: true}); // Get chat var chat = window.Store.Chat.find(idx); // Send message chat._value.sendMessage(message); } catch (e) { return false;
}
if (done !== undefined) done(false);
return false;
}; //window.WAPI.sendMessageToID2 ('0000000000@c.us','oi');
@duzaq please share latest wapi.js
Dear all,
i am getting this response "Phone number shared via url is invalid" when i try below code.Its start given this response from 2 days before it works properly ,please suggest .... any alternate please suggest.. function createMessageLink(number, text) { return new Promise((resolve, reject) => { const encodedText = text; const link = document.createElement("a"); link.setAttribute("href",
whatsapp://send?phone=${number}&text=${encodedText}
); document.body.append(link); console.log('new linq applied'); setTimeout(() => { link.click(); document.body.removeChild(link); resolve() }, 1000) }) }Thanks