import*asflowfrom'flow';letmng = flow.newManager();// get flowletflow0 = mng.getById("000y0000");letflow1 = mng.getByNameVersion("xx__flow1", "1.0.1");console.log(flow0.id);console.log(flow1.name);// update flowflow0.description = "desc"// If a compilation error is reported after modification, the modification will be rolled backletresult0 = mng.updateById("000y0000", flow0, {"option":false});flow0.description = "desc2"// If a compilation error is reported after modification, it will still be modifiedmng.updateById("000y0000", flow0, {"option":true});flow1.label = "label"letresult1 = mng.updateByNameVersion("xx__flow1", "1.0.1", flow1, {"option":false});// active flowmng.changeActiveById("000y0000", true);// deactive flowmng.changeActiveByNameVersion("xx__flow1", "1.0.1", false);// delete flowmng.deleteById("000y0000");mng.deleteByNameVersion("xx__flow1", "1.0.1");// create flowflow0.name = "createFlow0"mng.createFlow(flow0);// update extRefmng.updateExtRefById("000y0000", "ref");mng.updateExtRefByNameVersion("xx__flow1", "1.0.1", "ref");
The variable interface.