vodafone-station-cli
Version:
Access your Vodafone Station from the comfort of the command line.
14 lines (13 loc) • 579 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.compressDocsisStatus = compressDocsisStatus;
exports.webDiagnoseLink = webDiagnoseLink;
const node_zlib_1 = require("node:zlib");
function compressDocsisStatus(docsisStatus) {
const json = JSON.stringify(docsisStatus);
const compressed = (0, node_zlib_1.brotliCompressSync)(Buffer.from(json, 'utf8'));
return compressed.toString('base64url');
}
function webDiagnoseLink(docsisStatus) {
return `https://docsis-diagnose.totev.dev/#docsis=${compressDocsisStatus(docsisStatus)}`;
}