wwebjs-google-cloud-storage
Version:
A Google Cloud Storage plugin for whatsapp-web.js!
40 lines (27 loc) • 1.05 kB
Markdown
A Google Cloud Storage plugin for whatsapp-web.js!
Use WwebjsCloudStorage to save your WhatsApp MultiDevice session on a Google Cloud Storage.
* [Guide / Getting Started](https://wwebjs.dev/guide/authentication.html) _(work in progress)_
* [GitHub](https://github.com/Tots-Agency/wwebjs-google-cloud-storage)
* [npm](https://www.npmjs.com/package/wwebjs-google-cloud-storage)
The module is now available on npm! `npm i wwebjs-google-cloud-storage`
```js
const { Client, RemoteAuth } = require('whatsapp-web.js');
const { WwebjsCloudStorage } = require('wwebjs-google-cloud-storage');
const store = new WwebjsCloudStorage('./key.json', 'bucket-name');
const client = new Client({
authStrategy: new RemoteAuth({
store: store,
backupSyncIntervalMs: 300000
})
});
client.initialize();
```
How to force delete a specific remote session on the Database:
```js
await store.delete({session: 'yourSessionName'});
```