Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

493
Visualizações
Whatsapp-Web.js restore session

I'm using the whatsapp-web.js library and I would like to stay logged in after restarting the script. Currently I have to scan the QR code every time I start. The things I found online couldn't get to work (probably cuz I'm dumb but still). For reference this is the code I am trying to get it working with.

const { Client, LocalAuth, MessageMedia } = require('whatsapp-web.js');
const fs = require('fs');



const client = new Client({
    ffmpegPath: "C:/ffmpeg/bin/ffmpeg.exe"
});



client.on('qr', async qr=> {
     qrcode.generate(qr, {small: true});

});

client.on('ready', async function () {
    console.log('Client is ready!');
});

Thanks in advance.

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda