From 7957fa686eb6e8cf57bcb62ff4e6d2785693030b Mon Sep 17 00:00:00 2001 From: Christophe Besson Date: Sat, 10 Oct 2026 16:29:20 +0200 Subject: feat(android): back up WhatsApp's own chat backups, and its media if asked A WhatsApp section takes WhatsApp's folder through the picker, sends its encrypted Databases and Backups (not the dated copies of earlier weeks) into /-whatsapp, and names the restore set in the manifest. Co-Authored-By: Claude Opus 5.5 --- .../meshbay-hub/src/meshbay_hub/static/platform.js | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'packages/meshbay-hub/src/meshbay_hub/static/platform.js') diff --git a/packages/meshbay-hub/src/meshbay_hub/static/platform.js b/packages/meshbay-hub/src/meshbay_hub/static/platform.js index b1a8ae9..596c327 100644 --- a/packages/meshbay-hub/src/meshbay_hub/static/platform.js +++ b/packages/meshbay-hub/src/meshbay_hub/static/platform.js @@ -295,6 +295,27 @@ export const driveSync = { file: (token, name, size) => rangedFile('/drivesync/', token, name, size), }; +/** + * Backing up WhatsApp's own folder, chosen once through the picker (its + * encrypted chat backups, and its media if asked), like `driveSync`. + */ +const waBridge = bridge && bridge.whatsappSync; +export const whatsappSync = { + available: Boolean(waBridge), + status() { return waBridge.status(); }, + chooseFolder() { return waBridge.chooseFolder(); }, + forgetFolder(id) { return waBridge.forgetFolder(id); }, + configure(settings) { return waBridge.configure(settings); }, + plan() { return waBridge.plan(); }, + sent(token, dir, name) { return waBridge.sent(token, dir, name); }, + manifest() { return waBridge.manifest(); }, + manifestSent(token) { return waBridge.manifestSent(token); }, + completed() { return waBridge.completed(); }, + failed(code, text) { return waBridge.failed(code, text); }, + keepAlive(on, text) { return waBridge.keepAlive(on, text); }, + file: (token, name, size) => rangedFile('/wasync/', token, name, size), +}; + /** * Where every backup of this phone goes: one folder of a group the account * owns and is alone in (docs/MESHBAY_DESIGN.md ยง9.12). Android only, like -- cgit v1.2.3