let http = require('follow-redirects').http;
let fs = require('fs');
let login = <...>
let password = <...>'
let saymonHostname = <...>
let classId = <...>
let path = "/node/api/classes/" + classId;
let auth = "Basic " + Buffer.from(login + ":" + password).toString("base64");
'hostname': '192.168.1.101',
'path': '/node/api/classes/4',
let req = http.request(options, function (res) {
res.on("data", function (chunk) {
res.on("end", function (chunk) {
let body = Buffer.concat(chunks);
console.log(body.toString());
res.on("error", function (error) {