astro-web.js
v1.0.7
Published
Library for interacting with the WhatsApp Web API
Maintainers
Readme
Installation
multi-device source. stable
The module is now available on npm! npm i astro-web.js
errors
if you get any errors or have a issue email use at [email protected]
Example usage
const { Client } = require('astro-web.js');
const fs = require('fs');
const { Client , LocalAuth} = require('astro-web.js');
const qrcode = require('qrcode-terminal');
const client = new Client(
{ puppeteer: { headless: true, args: ['--no-sandbox']},
authStrategy: new LocalAuth({ clientId: 'astro' })
});
client.initialize();
//qr comes out
client.on('qr', qr => {
qrcode.generate(qr, {small: true});
});
// if qr was successful
client.on('authenticated', () => {
console.log('AUTHENTICATED');
});
// your bot is now online
client.on('ready', () => {
console.log(`bot connected`);
});Supported features
| Feature | Status | | ------------- | ------------- | | Multi Device | ✅ | | Send messages | ✅ | | Receive messages | ✅ | | Send media (video) | ✅ | Send stickers | ✅ | | Receive media (images/audio/video/documents) | ✅ | | Message replies | ✅ | | Join groups by invite | ✅ | | Get invite for group | ✅ | | send sticker | ✅ | | Add group participants | ✅ | | Kick group participants | ✅ | | Promote/demote group participants | ✅ | | Mention users | ✅ | | Mute/unmute chats | ✅ | | Block/unblock contacts | ✅ | | Get contact info | ✅ | | Get profile pictures | ✅ | | Set user status message | ✅ |
thanks to
@adiwajshing/baileys @open-wa/wa-automate @Wwebjs @vemon-bot @astro-team example : https://github.com/astroincz/astro-web.js-example
