Skip to content

Instantly share code, notes, and snippets.

@missnora07
Last active May 27, 2023 14:44
Show Gist options
  • Save missnora07/1bb657d22eaa7325a50255a82a34f84c to your computer and use it in GitHub Desktop.
Save missnora07/1bb657d22eaa7325a50255a82a34f84c to your computer and use it in GitHub Desktop.
const {Module} = require('../main')
const {skbuffer} = require('raganork-bot');
const {MODE} = require('../config');
let auto = MODE == 'public' ? false : true
Module({
pattern: 'wame ?(.*)',
fromMe: auto,
desc: 'wa.me url maker',
use: 'utility',
}, async (message, match) => {
const ak= (message.mention[0] || message.reply_message.jid || message.sender).split("@")[0]
if(!match[1]) {
message.sendReply(`https://wa.me/${ak}/`);
}
if(match[1]) {
message.sendReply(`https://wa.me/${ak}?text=${encodeURIComponent(match[1])}`);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment