0.0.5 • Published 7 years ago
archomp v0.0.5
archompjs
JS client for the archive and compression service from @orijtech
Sample
const fs = require('fs');
const archomp = require('archomp');
var arc = new archomp({apiKey: 'd0aa7829-e5d1-4d7f-8917-5327653f9bee'});
arc.compress({
"files": [{
"url": "https://orijtech.com/", "name": "orijtech-homepage.html"
}, {
"url": "https://tatan.s3-us-west-2.amazonaws.com/uno.gif", "name": "guap.gif"
}]
}, function(statusCode, r) {
if (statusCode !== 200) {
console.log(r);
return;
}
fs.writeFile('outf.zip', r, function(err) {
if (err)
throw err;
console.log('file saved successfully!');
});
});