Schreiben Sie die Datei mit NodeJs an das Betriebssystem

fs.writeFileSync('./data.json', JSON.stringify(obj, null, 2) , 'utf-8');
Noorullah Ahmadzai