node-firewalla
Version:
Package to talk your firewalla box & API
24 lines (23 loc) • 768 B
JavaScript
import { FWGroupApi } from "../api/index.js";
import { FWGetMessage, FWInitMessage } from "../models/index.js";
import { FWGroupService } from "./FWGroupService.js";
export class InitService extends FWGroupService {
/**
* @param {string} target - ?? unknown parameter
*/
async init(target = "0.0.0.0") {
let msg = new FWInitMessage(target);
return FWGroupApi.sendMessageToBox(this.fwGroup, msg);
}
async liveStats() {
let msg = new FWGetMessage("liveStats", {
type: "system",
target: "",
queries: {
throughput: {},
activeConn: {}
}
});
return FWGroupApi.sendMessageToBox(this.fwGroup, msg);
}
}